SlideShare a Scribd company logo
Distributed Adaptive Systems (DAS) Unit
A Model-Driven Approach Towards
Automatic Migration to Microservices
Antonio Bucchiarone, Kemal Soysal, Claudio Guidi
bucchiarone@fbk.eu, kemal.Soysal@ls-it-solutions.de, cguidi@italianasoftware.com
LS IT-Solutions GmbH
Microservices 2020 Towards Automatic Migration to Microservices 2
Introduction
 Scalability and Availability of modern software systems.
 Microservices is an architectural style originating from SOA.
 Microservices to realize complex systems.
 A set of small services that operate independently.
 Services that are easy to maintain and evolve.
 Each service represents a single business capability.
 Each service can be developed and managed by a single team.
 Migration from monolithic applications to microservices-based
applications.
 Is a challenging task that very often is done manually and without a
supporting tool.
Microservices 2020 Towards Automatic Migration to Microservices 3
The microservice paradigm still misses a conceptual
model able to support engineers starting from early
phases of development.
Research Challenge
conceptual model
A Model-Driven approach for
the automatic migration to microservices.
Microservices 2020 Towards Automatic Migration to Microservices 4
Model-Driven Engineering
 Software Engineering Methodology that proposes to shift the
focus of the development from coding to modelling.
 The goal is to reduce the complexity of software development by
raising the level of abstraction:
 Analyzing application properties earlier.
 Introducing automation in the development process.
 Models are expected to allow domain experts to reason about a
certain solution by means of concerns closer to their area of
expertise than to implementation details.
 Model transformation techniques manipulate models to evaluate
the attributes of the application and generate implementation code.
Microservices 2020 Towards Automatic Migration to Microservices 5
Domain Specific Languages (DSLs)
 Languages introduced for expressing problems by using terms
closer to a particular domain of application.
 The definition of DSLs can be challenging due:
 The nature of the specific domain.
 How the concepts should be interconnected to ease the modelling
activity.
 What kind of concrete syntaxes the users desire to exploits.
 Etc…
 To support the development of DSLs, it is common practice to use a
language workbench.
 A toolkit supporting the definition of various aspects of the DSL under
development
 Syntax, semantics, validation constraints, generators
 Code competition, syntax coloring, find usages, refactoring, etc..
Microservices 2020 Towards Automatic Migration to Microservices 6
JetBrains MPS - I
 Text-based meta-programming system that enables language-
oriented programming.
 Open Source and used to implement languages with different
notations.
 Based on MPS BaseLanguage is possible to define new custom
languages through extension and composition of concepts.
 A new language is composed by different aspects making its
specification modular and therefore easy to maintain.
 Structure Definition: Abstract Syntax Tree (AST) of a language as a
collection of concepts.
https://www.jetbrains.com/mps/
Microservices 2020 Towards Automatic Migration to Microservices 7
JetBrains MPS - II
 Structure Definition aspect: Abstract Syntax Tree (AST) of a language as
a collection of concepts.
 Editor Definition aspect deals with the definition of the concrete
syntax for a DSL:
 It specifies the notation (i.e., tabular, diagram, tree, etc..) and the
interaction behavior of the editor.
 Generators Definition aspect is used to define the denotational
semantics for the language concepts.
 AST to text (model-to-text)
 AST to AST (model-to-model)
 Type System Definition and Constraints Definition aspects.
https://www.jetbrains.com/mps/
Microservices 2020 Towards Automatic Migration to Microservices 8
Jolie Language for Microservices
 A programming language which offers a native linguistic tool for
defining microservices following a structured service-oriented
paradigm.
 It provides an integrated syntax for defining API interfaces and types;
 It provides specific communication primitives for dealing with
communication (synch, asynch).
 It allows for defining the service behaviour in a workflow manner:
easy definition of orchestrators and coordinators of services.
https://www.jolie-lang.org/
Microservices 2020 Towards Automatic Migration to Microservices 9
Jolie Language for Microservices
 Each operation comes with a request message and a response
message (synchronous operations).
https://www.jolie-lang.org/
Microservices 2020 Towards Automatic Migration to Microservices 10
Jolie Language for Microservices
 Declarative Part where all the
interfaces and ports are
defined.
 Behavioral Part where the
implementation of the
operations is provided.
 The primitive execution defines
the execution modality of the
service (concurrent, sequential,
single).
https://www.jolie-lang.org/
Microservices 2020 Towards Automatic Migration to Microservices 11
Deploying a Jolie Service
 The available image jolielang/jolie provides a core layer where both
Java and Jolie are installed.
 Docker file allows for the creation of a docker image of the service
“calculator”.
https://www.jolie-lang.org/
Microservices 2020 Towards Automatic Migration to Microservices 12
Our Vision towards an Automatic Migration
 There is an extreme and increasingly emerging need to migrate applications
from monolithic to microservices.
 Rare are the approaches that try to make this process automatic and tool
supported.
 Most of the migration approaches proposed are guided by the developers
experience and are not supported by a specific tool or language.
Towards the realization of a
general framework
for automatic migration to microservices.
Microservices 2020 Towards Automatic Migration to Microservices 13
Model-Driven Migration Approach
 Two components, Two DSLs, and a set of Generators
Microservices 2020 Towards Automatic Migration to Microservices 14
The Microservice Language - I
Microservices 2020 Towards Automatic Migration to Microservices 15
Calculator Microservice Model
Microservices 2020 Towards Automatic Migration to Microservices 16
The Deployment Language
Concepts of the
Deployment
Language
Dockerfile Editor
and Model
Microservices 2020 Towards Automatic Migration to Microservices 17
Microservices Miner
 To analyze the monolithic application written in Java and to retrieve the set of
needed microservices.
 To search in the Abstract Syntax Tree (AST) of the imported Java code for patterns of
interest and suggest to the developer the set of microservices for the migration.
Microservices 2020 Towards Automatic Migration to Microservices 18
Microservices “Searcher”
 Each searcher is realized by implementing the interface or the abstract
implementation and finds nodes in the AST that comply to the semantic
understanding of the searcher.
Microservices 2020 Towards Automatic Migration to Microservices 19
Microservices Generator
 AST to Text (model-to-text) transformation.
 To run a microservice we provide one file for the service specification (.ol)
and one file for each interface the microservices uses (.iol)
Microservices 2020 Towards Automatic Migration to Microservices 20
Dockerfile Generator
We generate the Dockerfile used to deploy the microservice in a Docker
container.
 This generator is used to generate the corresponding Dockerfile document
needed to deploy the microservice in a Docker container.
Microservices 2020 Towards Automatic Migration to Microservices 21
Prototype Implementation
https://github.com/antbucc/Migration
Microservices 2020 Towards Automatic Migration to Microservices 22
Open Research Challenges
• Microservices Modeling
• Define a more abstract DSL that can be used to model more general
microservices.
• Microservices Mining
• AI-based approach to extract automatically microservices from
monolithic application
• Microservices Composition
• Introduce the way to realize not only microservices but a complete
Microservice-based Application (MSA)
• Abstraction / Generalization
• To target multiple microservices technologies from the same abstraction
Distributed Adaptive Systems (DAS) Unit
A Model-Driven Approach Towards
Automatic Migration to Microservices
Antonio Bucchiarone
bucchiarone@fbk.eu
Thank you!
Any questions?

More Related Content

Similar to Towards Automatic Migration to Microservices

Approach to Unified Mobile Application Implementation for Multisystem Integra...
Approach to Unified Mobile Application Implementation for Multisystem Integra...Approach to Unified Mobile Application Implementation for Multisystem Integra...
Approach to Unified Mobile Application Implementation for Multisystem Integra...
RapidValue
 
Full lifecycle of a microservice
Full lifecycle of a microserviceFull lifecycle of a microservice
Full lifecycle of a microservice
Luigi Bennardis
 
Mdd Lcds
Mdd LcdsMdd Lcds
Mdd Lcdsravinxg
 
Microservice Pattern Launguage
Microservice Pattern LaunguageMicroservice Pattern Launguage
Microservice Pattern Launguage
Inho Kang
 
Enabling application portability with the greatest of ease!
Enabling application portability with the greatest of ease!Enabling application portability with the greatest of ease!
Enabling application portability with the greatest of ease!
Ken Owens
 
Architecting for Scale
Architecting for ScaleArchitecting for Scale
Architecting for Scale
Pooyan Jamshidi
 
Microservice architecture
Microservice architectureMicroservice architecture
Microservice architecture
Touraj Ebrahimi
 
Basics of Java Microservices: Frameworks, Examples & Use Cases
Basics of Java Microservices: Frameworks, Examples & Use CasesBasics of Java Microservices: Frameworks, Examples & Use Cases
Basics of Java Microservices: Frameworks, Examples & Use Cases
GrapesTech Solutions
 
agile microservices @scaibo
agile microservices @scaiboagile microservices @scaibo
agile microservices @scaibo
Ciro Donato Caiazzo
 
Vancouver Microservices Meetup - Kickoff Session
Vancouver Microservices Meetup - Kickoff SessionVancouver Microservices Meetup - Kickoff Session
Vancouver Microservices Meetup - Kickoff Session
Matt McLarty
 
Introduction to Microservices
Introduction to MicroservicesIntroduction to Microservices
Introduction to Microservices
Fayçal Bziou
 
Microservices Design Principles.pdf
Microservices Design Principles.pdfMicroservices Design Principles.pdf
Microservices Design Principles.pdf
Simform
 
All-inclusive insights on Building JavaScript microservices with Node!.pdf
All-inclusive insights on Building JavaScript microservices with Node!.pdfAll-inclusive insights on Building JavaScript microservices with Node!.pdf
All-inclusive insights on Building JavaScript microservices with Node!.pdf
Shelly Megan
 
Let's talk about... Microservices
Let's talk about... MicroservicesLet's talk about... Microservices
Let's talk about... Microservices
Alessandro Giorgetti
 
Microservices Design Patterns
Microservices Design PatternsMicroservices Design Patterns
Microservices Design Patterns
Haim Michael
 
Best Spring Boot & MicroServices Classroom & Online Training Naresh-IT
Best Spring Boot & MicroServices Classroom & Online Training Naresh-ITBest Spring Boot & MicroServices Classroom & Online Training Naresh-IT
Best Spring Boot & MicroServices Classroom & Online Training Naresh-IT
manoharjgpsolutions
 
Service Oriented Architecture (SOA)
Service Oriented Architecture (SOA)Service Oriented Architecture (SOA)
Service Oriented Architecture (SOA)
Biniam Asnake
 
Introducing MartianBank - a microservice demo application for cloud-native pr...
Introducing MartianBank - a microservice demo application for cloud-native pr...Introducing MartianBank - a microservice demo application for cloud-native pr...
Introducing MartianBank - a microservice demo application for cloud-native pr...
Cisco Tech Blog
 
Software Architecture for Robotics
Software Architecture for RoboticsSoftware Architecture for Robotics
Software Architecture for Robotics
Lorran Pegoretti
 

Similar to Towards Automatic Migration to Microservices (20)

Approach to Unified Mobile Application Implementation for Multisystem Integra...
Approach to Unified Mobile Application Implementation for Multisystem Integra...Approach to Unified Mobile Application Implementation for Multisystem Integra...
Approach to Unified Mobile Application Implementation for Multisystem Integra...
 
Full lifecycle of a microservice
Full lifecycle of a microserviceFull lifecycle of a microservice
Full lifecycle of a microservice
 
Mdd Lcds
Mdd LcdsMdd Lcds
Mdd Lcds
 
Microservice Pattern Launguage
Microservice Pattern LaunguageMicroservice Pattern Launguage
Microservice Pattern Launguage
 
Enabling application portability with the greatest of ease!
Enabling application portability with the greatest of ease!Enabling application portability with the greatest of ease!
Enabling application portability with the greatest of ease!
 
Architecting for Scale
Architecting for ScaleArchitecting for Scale
Architecting for Scale
 
Microservice architecture
Microservice architectureMicroservice architecture
Microservice architecture
 
Basics of Java Microservices: Frameworks, Examples & Use Cases
Basics of Java Microservices: Frameworks, Examples & Use CasesBasics of Java Microservices: Frameworks, Examples & Use Cases
Basics of Java Microservices: Frameworks, Examples & Use Cases
 
agile microservices @scaibo
agile microservices @scaiboagile microservices @scaibo
agile microservices @scaibo
 
Mdd lcds
Mdd lcdsMdd lcds
Mdd lcds
 
Vancouver Microservices Meetup - Kickoff Session
Vancouver Microservices Meetup - Kickoff SessionVancouver Microservices Meetup - Kickoff Session
Vancouver Microservices Meetup - Kickoff Session
 
Introduction to Microservices
Introduction to MicroservicesIntroduction to Microservices
Introduction to Microservices
 
Microservices Design Principles.pdf
Microservices Design Principles.pdfMicroservices Design Principles.pdf
Microservices Design Principles.pdf
 
All-inclusive insights on Building JavaScript microservices with Node!.pdf
All-inclusive insights on Building JavaScript microservices with Node!.pdfAll-inclusive insights on Building JavaScript microservices with Node!.pdf
All-inclusive insights on Building JavaScript microservices with Node!.pdf
 
Let's talk about... Microservices
Let's talk about... MicroservicesLet's talk about... Microservices
Let's talk about... Microservices
 
Microservices Design Patterns
Microservices Design PatternsMicroservices Design Patterns
Microservices Design Patterns
 
Best Spring Boot & MicroServices Classroom & Online Training Naresh-IT
Best Spring Boot & MicroServices Classroom & Online Training Naresh-ITBest Spring Boot & MicroServices Classroom & Online Training Naresh-IT
Best Spring Boot & MicroServices Classroom & Online Training Naresh-IT
 
Service Oriented Architecture (SOA)
Service Oriented Architecture (SOA)Service Oriented Architecture (SOA)
Service Oriented Architecture (SOA)
 
Introducing MartianBank - a microservice demo application for cloud-native pr...
Introducing MartianBank - a microservice demo application for cloud-native pr...Introducing MartianBank - a microservice demo application for cloud-native pr...
Introducing MartianBank - a microservice demo application for cloud-native pr...
 
Software Architecture for Robotics
Software Architecture for RoboticsSoftware Architecture for Robotics
Software Architecture for Robotics
 

Recently uploaded

Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Globus
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke
 
BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024
Ortus Solutions, Corp
 
Accelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with PlatformlessAccelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with Platformless
WSO2
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
Tier1 app
 
Why React Native as a Strategic Advantage for Startup Innovation.pdf
Why React Native as a Strategic Advantage for Startup Innovation.pdfWhy React Native as a Strategic Advantage for Startup Innovation.pdf
Why React Native as a Strategic Advantage for Startup Innovation.pdf
ayushiqss
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
Globus
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
Matt Welsh
 
Explore Modern SharePoint Templates for 2024
Explore Modern SharePoint Templates for 2024Explore Modern SharePoint Templates for 2024
Explore Modern SharePoint Templates for 2024
Sharepoint Designs
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus
 
A Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdfA Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdf
kalichargn70th171
 
2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx
Georgi Kodinov
 
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Globus
 
Designing for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web ServicesDesigning for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web Services
KrzysztofKkol1
 
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisProviding Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Globus
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
Globus
 
GlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote sessionGlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote session
Globus
 
Strategies for Successful Data Migration Tools.pptx
Strategies for Successful Data Migration Tools.pptxStrategies for Successful Data Migration Tools.pptx
Strategies for Successful Data Migration Tools.pptx
varshanayak241
 
Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024
Paco van Beckhoven
 
Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
Globus
 

Recently uploaded (20)

Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
 
BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024BoxLang: Review our Visionary Licenses of 2024
BoxLang: Review our Visionary Licenses of 2024
 
Accelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with PlatformlessAccelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with Platformless
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
 
Why React Native as a Strategic Advantage for Startup Innovation.pdf
Why React Native as a Strategic Advantage for Startup Innovation.pdfWhy React Native as a Strategic Advantage for Startup Innovation.pdf
Why React Native as a Strategic Advantage for Startup Innovation.pdf
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
 
Large Language Models and the End of Programming
Large Language Models and the End of ProgrammingLarge Language Models and the End of Programming
Large Language Models and the End of Programming
 
Explore Modern SharePoint Templates for 2024
Explore Modern SharePoint Templates for 2024Explore Modern SharePoint Templates for 2024
Explore Modern SharePoint Templates for 2024
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
 
A Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdfA Comprehensive Look at Generative AI in Retail App Testing.pdf
A Comprehensive Look at Generative AI in Retail App Testing.pdf
 
2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx2024 RoOUG Security model for the cloud.pptx
2024 RoOUG Security model for the cloud.pptx
 
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
 
Designing for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web ServicesDesigning for Privacy in Amazon Web Services
Designing for Privacy in Amazon Web Services
 
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data AnalysisProviding Globus Services to Users of JASMIN for Environmental Data Analysis
Providing Globus Services to Users of JASMIN for Environmental Data Analysis
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
 
GlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote sessionGlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote session
 
Strategies for Successful Data Migration Tools.pptx
Strategies for Successful Data Migration Tools.pptxStrategies for Successful Data Migration Tools.pptx
Strategies for Successful Data Migration Tools.pptx
 
Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024Cracking the code review at SpringIO 2024
Cracking the code review at SpringIO 2024
 
Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
 

Towards Automatic Migration to Microservices

  • 1. Distributed Adaptive Systems (DAS) Unit A Model-Driven Approach Towards Automatic Migration to Microservices Antonio Bucchiarone, Kemal Soysal, Claudio Guidi bucchiarone@fbk.eu, kemal.Soysal@ls-it-solutions.de, cguidi@italianasoftware.com LS IT-Solutions GmbH
  • 2. Microservices 2020 Towards Automatic Migration to Microservices 2 Introduction  Scalability and Availability of modern software systems.  Microservices is an architectural style originating from SOA.  Microservices to realize complex systems.  A set of small services that operate independently.  Services that are easy to maintain and evolve.  Each service represents a single business capability.  Each service can be developed and managed by a single team.  Migration from monolithic applications to microservices-based applications.  Is a challenging task that very often is done manually and without a supporting tool.
  • 3. Microservices 2020 Towards Automatic Migration to Microservices 3 The microservice paradigm still misses a conceptual model able to support engineers starting from early phases of development. Research Challenge conceptual model A Model-Driven approach for the automatic migration to microservices.
  • 4. Microservices 2020 Towards Automatic Migration to Microservices 4 Model-Driven Engineering  Software Engineering Methodology that proposes to shift the focus of the development from coding to modelling.  The goal is to reduce the complexity of software development by raising the level of abstraction:  Analyzing application properties earlier.  Introducing automation in the development process.  Models are expected to allow domain experts to reason about a certain solution by means of concerns closer to their area of expertise than to implementation details.  Model transformation techniques manipulate models to evaluate the attributes of the application and generate implementation code.
  • 5. Microservices 2020 Towards Automatic Migration to Microservices 5 Domain Specific Languages (DSLs)  Languages introduced for expressing problems by using terms closer to a particular domain of application.  The definition of DSLs can be challenging due:  The nature of the specific domain.  How the concepts should be interconnected to ease the modelling activity.  What kind of concrete syntaxes the users desire to exploits.  Etc…  To support the development of DSLs, it is common practice to use a language workbench.  A toolkit supporting the definition of various aspects of the DSL under development  Syntax, semantics, validation constraints, generators  Code competition, syntax coloring, find usages, refactoring, etc..
  • 6. Microservices 2020 Towards Automatic Migration to Microservices 6 JetBrains MPS - I  Text-based meta-programming system that enables language- oriented programming.  Open Source and used to implement languages with different notations.  Based on MPS BaseLanguage is possible to define new custom languages through extension and composition of concepts.  A new language is composed by different aspects making its specification modular and therefore easy to maintain.  Structure Definition: Abstract Syntax Tree (AST) of a language as a collection of concepts. https://www.jetbrains.com/mps/
  • 7. Microservices 2020 Towards Automatic Migration to Microservices 7 JetBrains MPS - II  Structure Definition aspect: Abstract Syntax Tree (AST) of a language as a collection of concepts.  Editor Definition aspect deals with the definition of the concrete syntax for a DSL:  It specifies the notation (i.e., tabular, diagram, tree, etc..) and the interaction behavior of the editor.  Generators Definition aspect is used to define the denotational semantics for the language concepts.  AST to text (model-to-text)  AST to AST (model-to-model)  Type System Definition and Constraints Definition aspects. https://www.jetbrains.com/mps/
  • 8. Microservices 2020 Towards Automatic Migration to Microservices 8 Jolie Language for Microservices  A programming language which offers a native linguistic tool for defining microservices following a structured service-oriented paradigm.  It provides an integrated syntax for defining API interfaces and types;  It provides specific communication primitives for dealing with communication (synch, asynch).  It allows for defining the service behaviour in a workflow manner: easy definition of orchestrators and coordinators of services. https://www.jolie-lang.org/
  • 9. Microservices 2020 Towards Automatic Migration to Microservices 9 Jolie Language for Microservices  Each operation comes with a request message and a response message (synchronous operations). https://www.jolie-lang.org/
  • 10. Microservices 2020 Towards Automatic Migration to Microservices 10 Jolie Language for Microservices  Declarative Part where all the interfaces and ports are defined.  Behavioral Part where the implementation of the operations is provided.  The primitive execution defines the execution modality of the service (concurrent, sequential, single). https://www.jolie-lang.org/
  • 11. Microservices 2020 Towards Automatic Migration to Microservices 11 Deploying a Jolie Service  The available image jolielang/jolie provides a core layer where both Java and Jolie are installed.  Docker file allows for the creation of a docker image of the service “calculator”. https://www.jolie-lang.org/
  • 12. Microservices 2020 Towards Automatic Migration to Microservices 12 Our Vision towards an Automatic Migration  There is an extreme and increasingly emerging need to migrate applications from monolithic to microservices.  Rare are the approaches that try to make this process automatic and tool supported.  Most of the migration approaches proposed are guided by the developers experience and are not supported by a specific tool or language. Towards the realization of a general framework for automatic migration to microservices.
  • 13. Microservices 2020 Towards Automatic Migration to Microservices 13 Model-Driven Migration Approach  Two components, Two DSLs, and a set of Generators
  • 14. Microservices 2020 Towards Automatic Migration to Microservices 14 The Microservice Language - I
  • 15. Microservices 2020 Towards Automatic Migration to Microservices 15 Calculator Microservice Model
  • 16. Microservices 2020 Towards Automatic Migration to Microservices 16 The Deployment Language Concepts of the Deployment Language Dockerfile Editor and Model
  • 17. Microservices 2020 Towards Automatic Migration to Microservices 17 Microservices Miner  To analyze the monolithic application written in Java and to retrieve the set of needed microservices.  To search in the Abstract Syntax Tree (AST) of the imported Java code for patterns of interest and suggest to the developer the set of microservices for the migration.
  • 18. Microservices 2020 Towards Automatic Migration to Microservices 18 Microservices “Searcher”  Each searcher is realized by implementing the interface or the abstract implementation and finds nodes in the AST that comply to the semantic understanding of the searcher.
  • 19. Microservices 2020 Towards Automatic Migration to Microservices 19 Microservices Generator  AST to Text (model-to-text) transformation.  To run a microservice we provide one file for the service specification (.ol) and one file for each interface the microservices uses (.iol)
  • 20. Microservices 2020 Towards Automatic Migration to Microservices 20 Dockerfile Generator We generate the Dockerfile used to deploy the microservice in a Docker container.  This generator is used to generate the corresponding Dockerfile document needed to deploy the microservice in a Docker container.
  • 21. Microservices 2020 Towards Automatic Migration to Microservices 21 Prototype Implementation https://github.com/antbucc/Migration
  • 22. Microservices 2020 Towards Automatic Migration to Microservices 22 Open Research Challenges • Microservices Modeling • Define a more abstract DSL that can be used to model more general microservices. • Microservices Mining • AI-based approach to extract automatically microservices from monolithic application • Microservices Composition • Introduce the way to realize not only microservices but a complete Microservice-based Application (MSA) • Abstraction / Generalization • To target multiple microservices technologies from the same abstraction
  • 23. Distributed Adaptive Systems (DAS) Unit A Model-Driven Approach Towards Automatic Migration to Microservices Antonio Bucchiarone bucchiarone@fbk.eu Thank you! Any questions?