SlideShare a Scribd company logo
Microservices
Alessandro Giorgetti
www.primordialcode.com
Microservices
“If you are looking for a technical solution
for what it is a business problem,
you are looking the wrong way.”
The monolithic software weak points
oArchitecture/Solution is hard to evolve.
oDifficult to Scale.
oLong development pipeline (build, test, release).
oAdding a feature takes time.
oA lot of time between releases.
oContinous Delivery is challenging.
Microservices definition
Microservices is an architectural design for building a
distributed application using containers.
Microservices a «better» definition
Microservices is an “architectural style” for building a
distributed application as a collection of small and
loosely coupled services
(each service implementing a business capability).
Services should have the following properties…
Microservices «properties»:
•Autonomy.
•Small and Focused on a single «thing».
•Independent Development: the right tools for the right job!
•Independent Deployment.
•Independent Scalability.
Microservices «properties»:
•Reusable (through composition).
•Owned by a small team.
•Designed for Failure / No single point of failure: the system
can “degrade”, but it should never be fully down.
•Promotes the adoptions of new technologies.
Microservices promise to be like:
The Monolith
(the big ball of mud)
Service 1
Service 3
Website
Service 4
APP
Service 7 Service 6
Service 5
Service 8
Service
10
Service 2
Service 9
Microservices leads to Reactive Systems
https://www.reactivemanifesto.org/
Loosely Coupled
Loose coupling through
async message passing
Resilient
Error containment
Fault tolerance and recovery
Elastic
Scalability
React to workload change
Responsive
Rapid and consistent response times
A Reactive System is made of services and components that have the following properties:
Microservices «pain points»
•Increased complexity for developers.
•Increased complexity for operators.
•Increased complexity for devops (ALM madness!).
•It requires serious expertise.
•Unclear or not well defined Service Boundaries.
•(Distributed) State management ?
Microservices «pain points»
•Versioning.
•Communications issues.
•Distributed Transactions: Can they be avoided? At which cost?
•Performances: many services with many «dependencies» = many network calls!
•Managing and «orchestration»: logging, monitoring, discovery, etc...
•Debugging.
Distributed computing is hard!
The fallacies of distributed computing:
1. The network is reliable.
2. Latency is zero.
3. Bandwidth is infinite.
4. The network is secure.
5. Topology doesn't change.
6. There is one administrator.
7. Transport cost is zero.
8. The network is homogeneous.
And we always underestimate:
1. Error Handling, Failures and Recovery.
2. Performance and Bottlenecks.
3. Blocking operations.
4. Concurrency.
5. Consistency.
6. State Management / Locks / Threads.
7. Parallelism.
8. Availability.
The Microservices thing can become…
Service 3 Service 4
APP
Service 7
Service 6
Service 5 Service 8
Service
10
Service 9
Service 1
Service 3
Website
Service 4
APP
Service 7 Service 6
Service 5
Service 8
Service
10
Service
11
Service 9
Microservices fundamentals
Service Oriented Architecture
• Ownership of data and behavior.
• Autonomy.
• And more…
Domain Driven Design
• Bounded Context.
• Aggregate.
• Events.
Event Driven Architecture
• Loose coupling.
Patterns & Practices
The first thing that comes in mind when
thinking about «architecture»!
You cannot fight the «Coupling»!
A long time ago
in a galaxy far, far away…. SOA
Service Oriented Architecture
A service is a technical authority for a business capability.
Any piece of data or rule must be owned by only one service.
http://www.soa-manifesto.org/
https://www.infoq.com/articles/tilkov-10-soa-principles https://en.wikipedia.org/wiki/Service-orientation_design_principles
SOA Elements
https://en.wikipedia.org/wiki/Service-oriented_architecture
Web Services
SOA Service: a definition (sort of)
We can define a service by its fundamentals / principles (the four tenets):
oServices are autonomous.
oServices have well defined boundaries.
oServices share contracts and schema.
oServices interactions are controlled by policies.
A Service provide the implementation for a specific Business Capability!
http://www.dbizinstitute.org/resources/articles/four-tenets-service-orientation
SOA: «decouple» the different business
capabilities… in «services»!
We might end up with something like this: slices of a layered architecture!
Each slice representing a capability of the system!
They are Autonomous and Loosely Coupled!
Product Catalog Sales Shipping
Infrastructure
logging, communication, …
The major problems of SOA:
oServices could be «very big» (monolithic services).
oToo much tied to a specific technology (Web Services, ESB).
oIf done wrong we’ll end up having tight coupling with one service directly
calling into another.
(welcome the distributed monolith… with latency and reliability problems).
MicroServices: SOA vNext
Microservices is a variant of SOA that structures an application as a collection of loosely
coupled services. Services should be fine-grained and the communication protocols should be
lightweight.
Another Microservices Definition:
Microservices is an “architectural style” for building a
distributed application as a collection of small and loosely
coupled services.
A service is a technical authority for a business capability. Any
piece of data or rule must be owned by only one service.
MicroServices: SOA vNext
From an “operative” standpoint:
Small, independent applications, loosely coupled,
communicating (asynchronously) with each other, and can
fail independently, and if one or some fails, the system as a
whole still works (the functionality might be downgraded).
How is it different from SOA ?
•Tries to reduce the size of services: Small services with a single focus.
•Promotes the usage of technology agnostic APIs.
• Services can be consumed by other services written in different technologies.
•Promotes the usage of independent data storage (for each service).
•Promotes the usage of lightweight communication protocols.
•Puts the emphasis on loose coupling even more.
•Improves the scalability.
•Improve the flexibility.
Microservices goes further!
Product Catalog Sales Shipping
Infrastructure
P.C. Service 1
P.C. Service 3 P.C. Service 4
P.C. Service 5 P.C. Service N
P.C. Service 2 S. Service 1 S. Service 2
S. Service 5 S. Service N
S. Service 3 S. Service 4
Sales Service 1 Sales Service 2
Sales Service 3 Sales Service 4
Sales Service 5 Sales Service N
How to «discover» the
Services?
DDD TO THE RESCUE
Finding out what’s inside a service
We need logical view of the system. Some practices worked very well (for us):
oDDD (Domain Driven Design).
oEvent Storming.
Domain Driven Design
An approach to software development for «complex systems»
that works promoting the adoption of an evolving domain model,
that derives from a collaboration between developers and domain experts
to iteratively refine a conceptual model that addresses particular domain
problems.
DDD key concepts
Ubiquitous Language - the language used by domain experts and
developers that defines elements/processes of the business.
Events (and Commands) – facts, evidences that something happened in
the business.
Aggregate – a cluster of domain objects that represent a single
(transactional) unit, it supports the business providing behavior and rules.
Bounded Context - the “environment” in which a specific Ubiquitous
Language is valid.
Context-Map – shows the interactions between Bounded-Contexts.
Event Storming – talk the (ubiquitous)
language of the business!
«Tool / Workshop» that allows to quickly explore complex business domains.
You can figure out how the system works (how much in detail it is up to you);
you’ll also get an overrall idea of the «shape» of the system.
Aggregate
An Aggregate encapsulates state and behavior.
An Aggregate guarantees that Business Rules are satisfied.
An Aggregate is a «Transactional» and «Computational» Unit.
An aggregate accepts Commands and emits Events, Event
represents Business Transactions outcome.
A DDD aggregate is a cluster of domain objects that can be
treated as a single unit.
Aggregate
Cmd(s) Evt(s)
Cmd(s) Evt(s)
Evt(s)
Bounded Contexts
Catalog
Aggregate(s)
Cmd(s) Evt(s)
Catalog
Aggregate(s)
Cmd(s) Evt(s)
Catalog
Aggregate(s)
Cmd(s) Evt(s)
Sales
Aggregate(s)
Cmd(s) Evt(s)
Catalog
Aggregate(s)
Cmd(s) Evt(s)
Shipping
Aggregate(s)
Cmd(s) Evt(s)
Catalog
Bounded Context
Sales
Bounded Context
Shipping
Bounded Context
Context Map
Context Maps draw the relationships between the Bounded Contexts, they are:
oConformist relationship: the downstream context might follow and adapt to what the upstream context says.
oPartnership relationships (both context work towards a common goal; the same term might exists in multiple contexts with different behaviors).
oTechnical relationships (how they talk).
A system will almost never be made of a single bounded context, BCs operate toghether to fulfill the system requirements and implement business capabilities.
BC 1
BC 3 BC 4
BC 2
External System
https://www.infoq.com/articles/ddd-contextmapping
Bounded Contexts
oThey are Autonomous / have Explicit Boundaries: encapsulation, they «contain» everything
that’s needed to implement a business capability.
oThey share contract and schema: that’s a «communication protocol».
BC 1
BC 3 BC 4
BC 2
External SystemBC 1
BC 3 BC 4
BC 2
External System
Bounded Contexts  SOA Services
oThey are Autonomous / have Explicit Boundaries: encapsulation, they «contain» everything
that’s needed to implement a business capability.
oThey share contract and schema: that’s a «communication protocol».
BC 1
BC 3 BC 4
BC 2
External System
Service 1
Service 3 Service 4
Service 2
External System
How do Services talk?
REDUCING COUPLING IS THE KEY!
How do these Services communicate?
You can still have coupling!!!
Shopping Cart
Sales
bool placeOrder(id, items)
Process 1
Shopping Cart
Sales
bool placeOrder(id, items)
In-Process
Process 2
H
T
T
P
BTW… This is coupling too!!!
Process 1
Shopping Cart Sales
Process 2
The Database
The
Table
How do services talk ?
o(SYNC) RPC and the likes.
o(ASYNC) Messaging.
RPC
and the likes: gRPC, Web Services, anything over TCP, HTTP and so on…
In distributed computing, a remote procedure call (RPC) is
an Inter-process communication technology that allows a
computer program to causes a procedure (subroutine) to
execute in a different address space (commonly another
process on another computer on a shared network).
https://en.wikipedia.org/wiki/Remote_procedure_call
RPC (underlying concepts)
Location Transparency: the function call is coded as if it were a normal
(local) procedure call, without the programmer explicitly coding the
details for the remote interaction.
RPC is typically implemented via a (blocking) request – response message-
passing system.
Remote calls are usually slower and less reliable than local calls.
Messaging
Message: an immutable data structure
used to exchange a piece of information.
Why Messages are so important?
They have properties that open up many scenarios:
•Asynchronous Communication.
•Can be serialized and stored (debugging, event sourcing).
•Can be ordered (priority, deferred elaboration).
•Carry metadata / context information (like a reply-to).
•Can be forwarded.
•Can be broadcasted.
Messaging Patterns
Service ServiceOne Way
Service ServiceBroadcast
Service
Service
Messaging Patterns
Service ServiceProxy
Service ServicePub/Sub
Service
Service
Service
forward
subscribe
publish
Message Delivery Patterns
•at-most-once: for each message handed to the mechanism, that message is delivered zero or
one times; the messages may be lost.
•at-least-once: for each message handed to the mechanism potentially multiple attempts are
made at delivering it, until at least one succeeds; the messages may be duplicated but not lost.
•exactly-once: for each message handed to the mechanism exactly one delivery is made to the
recipient; the message can neither be lost nor duplicated.
Event Driven Architecture
•Event Producers: generate streams of events.
•Event Consumers: listen to events.
Producers are decoupled from consumers: a producer doesn't know which consumers are
listening. Consumers are also decoupled from each other.
Every Consumer can potentially see all the events / messages.
Event Producer
Event Consumer
Event Consumer
Event Streaming
Infrastructure
Event Driven Architecture
Can use two communication models:
•Pub/sub: the messaging infrastructure keeps track of subscriptions. After an
event is received, it cannot be replayed, and new subscribers do not see past
events.
•Event streaming: events are written to a durable log. Events are strictly ordered
within a partition. Consumers don't subscribe to the stream, instead a consumer
can read from any part of the stream. The consumer is responsible for advancing
its position in the stream.
Logical Architecture
vs.
Physical Architecture
A Microservice in a Distributed App.
OWNS and PROTECTS data and behavior… it’s responsible for their exposure to
the rest of the system.
Ideally, everything that «belongs» to a service is managed by the service itself:
oFrom the Databases  to the Backend  to the UI components (widgets).
oThe Team responsible for the service should have expertise in all the areas.
A Service spans multiple «technologies»
and «responsibilities»
Product Catalog Sales Logistics
Backend
( .net / java / go / … )
Web Portal
( web api / html /
javascript / …)
Mobile Apps
( .net / xamarin / swift /
… )
Microservices is also for scaling People!
Not only the Deployment Unit(s)!
Team 1
Team 1
Team 1
Team 2
Team 2
Team 2
Team 3
Team 3
Team 3
When it comes to the physical view…
A service is a composition of components and smaller
«services»… that collaborate to implement a specific business
capability!!
The term service is «overloaded» and has slightly different properties:
oA service, in this context, is a support entity for other components in order to fulfill very specific
tasks.
oMight not be fully autonomous.
oThere will be coupling, a lot of coupling… there will be cohesion!
Microservices «Physical View»:
composition of components & services
Web Crawler
(stateful)
Crawling Job Coordinator 1
(stateful)
Parser 1
(stateless)
Downloader 1
(stateless)
Analyzer 1
(stateless)
Parser n
(stateless)
Downloader n
(stateless)
Analyzer n
(stateless)
Crawling Job Coordinator n
(stateful)
Parser 1
(stateless)
Downloader 1
(stateless)
Analyzer 1
(stateless)
Parser n
(stateless)
Downloader n
(stateless)
Analyzer n
(stateless)
How do we «code» each Service /
Bounded Context?
Inside a Microservice we can follow any architectural style we want!
They are «small» and «autonomous» and «easily replaceable»!
(Given we respect the communication protocol contracts).
Multi-Tier Layered Architecture
CQRS / ES (Aggregate  Domain Object)
We can also consider tools designed to
help us build distributed applications
Akka (https://akka.io) & Akka.NET (https://getakka.net/)
Microsoft Orleans (https://dotnet.github.io/orleans/)
Dapr - Distributed Application Runtime (https://dapr.io/)
Chosing the «communication protocols»
at the highest level of the system
Product Catalog
Service
Inventory
Service
Account
Service
Sales
Service
Shipping
Service
Whatever
Service
My favorites:
• Event Streams.
• Enterprise Service Bus.
• Independent Queues.
Less favorites:
• Lightweight RPC (gRPC /
WebServices).
Event Streams / ESB
Communications «within» a Microservice
If our Microservice can be made of a subset of cohesive
sub-services:
•Few stateful services.
•Many stateless services.
We can deploy them on several machines (cluster), how
do they communicate?
My Favorites:
•RPC.
•Async Messaging.
Crawling Job Coordinator 1
(stateful)
Parser 1
(stateless)
Downloader 1
(stateless)
Analyzer 1
(stateless)
Parser n
(stateless)
Downloader n
(stateless)
Analyzer n
(stateless)
Microservices + API Gateway +
Monolithic UI
https://docs.microsoft.com/en-us/dotnet/standard/microservices-architecture/architect-microservice-container-applications/microservice-based-composite-ui-shape-layout
Microservices + UI Composition
https://docs.microsoft.com/en-us/dotnet/standard/microservices-architecture/architect-microservice-container-applications/microservice-based-composite-ui-shape-layout
Microservices Lifecycle Management ?
Microservices are biased towards organizations with multiple teams.
oBest practices as Continous Integration / Continous Deployment should be encouraged.
oMultiple backlogs (Agile, SCRUM, Kanban, etc…) ?
oMultiple Repositories ?
oMultiple Deployment tools & Deployment Strategies ?
So we have all our nice Microservices…
How do we package them?
How do we deploy them?
How do we orchestrate & manage them?
How do we monitor them?
How do we handle failing microservices?
Resources – Distributed Applications
•Designing Data-Intensive Applications
https://www.amazon.it/Designing-Data-Intensive-Applications-Reliable-
Maintainable/dp/1449373321
•Designing Distributed Systems
https://www.amazon.it/Designing-Distributed-Systems-Patterns-Paradigms/dp/1491983647
Resources - Microservices
•Microservices.io
https://microservices.io/
•Building Microservices
https://www.amazon.it/Building-Microservices-Sam-Newman/dp/1491950358
•.NET Architecture Guides
https://dotnet.microsoft.com/learn/dotnet/architecture-guides
•.NET Microservices Architecture Guidance
https://dotnet.microsoft.com/learn/aspnet/microservices-architecture
•.NET Microservices: Architecture for Containerized .NET Applications
https://docs.microsoft.com/en-us/dotnet/architecture/microservices/
Resources – DDD
•Domain Driven Design
https://www.amazon.it/Domain-Driven-Design-Tackling-Complexity-Software-
ebook/dp/B00794TAUG/
•Implementing Domain Driven Design
https://www.amazon.it/Implementing-Domain-Driven-Design-English-Vaughn-
ebook/dp/B00BCLEBN8
•Strategic Domain Driven Design with Context Mapping
https://www.infoq.com/articles/ddd-contextmapping/
Resources – Reactive Applications
•Reactive Design Patterns
https://www.amazon.it/Reactive-Design-Patterns-Roland-Kuhn/dp/1617291803/
•Reactive Messaging Patterns with the Actor Model
https://www.amazon.it/dp/B011S8YC5G
Keep in touch
Dott.ing. Alessandro Giorgetti
Facebook: https://www.facebook.com/giorgetti.alessandro
Twitter: @a_giorgetti
LinkedIn: https://it.linkedin.com/in/giorgettialessandro
E-mail: alessandro.giorgetti@live.com
Blog: www.primordialcode.com
Alessandro Giorgetti
www.primordialcode.com
Ad

More Related Content

What's hot (20)

Return of the transaction king
Return of the transaction kingReturn of the transaction king
Return of the transaction king
Ryan Knight
 
Microservices vs SOA
Microservices vs SOAMicroservices vs SOA
Microservices vs SOA
inovia
 
Duplicating data or replicating data in Micro Services
Duplicating data or replicating data in Micro ServicesDuplicating data or replicating data in Micro Services
Duplicating data or replicating data in Micro Services
Dennis van der Stelt
 
Icsa2018 blockchain tutorial
Icsa2018 blockchain tutorialIcsa2018 blockchain tutorial
Icsa2018 blockchain tutorial
Len Bass
 
Designing loosely coupled services
Designing loosely coupled servicesDesigning loosely coupled services
Designing loosely coupled services
Chris Richardson
 
Developing microservices with aggregates (devnexus2017)
Developing microservices with aggregates (devnexus2017)Developing microservices with aggregates (devnexus2017)
Developing microservices with aggregates (devnexus2017)
Chris Richardson
 
Modularity by Microservices
Modularity by MicroservicesModularity by Microservices
Modularity by Microservices
Andrei Rugina
 
Antifragile, Microservices and DevOps - A Study
Antifragile, Microservices and DevOps - A StudyAntifragile, Microservices and DevOps - A Study
Antifragile, Microservices and DevOps - A Study
William Yang
 
The Cloud is dead ?! Blockchain in the new cloud
The Cloud is dead ?! Blockchain in the new cloudThe Cloud is dead ?! Blockchain in the new cloud
The Cloud is dead ?! Blockchain in the new cloud
Yuval Birenboum
 
Microservices architecture
Microservices architectureMicroservices architecture
Microservices architecture
Abdelghani Azri
 
Events on the outside, on the inside and at the core (jfokus jfokus2016)
Events on the outside, on the inside and at the core (jfokus jfokus2016)Events on the outside, on the inside and at the core (jfokus jfokus2016)
Events on the outside, on the inside and at the core (jfokus jfokus2016)
Chris Richardson
 
Polyglot persistence for Java developers: time to move out of the relational ...
Polyglot persistence for Java developers: time to move out of the relational ...Polyglot persistence for Java developers: time to move out of the relational ...
Polyglot persistence for Java developers: time to move out of the relational ...
Chris Richardson
 
Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)
Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)
Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)
Chris Richardson
 
What Is Solution Architecture? The Black Art Of I/T Solution Architecture
What Is Solution Architecture? The Black Art Of I/T Solution ArchitectureWhat Is Solution Architecture? The Black Art Of I/T Solution Architecture
What Is Solution Architecture? The Black Art Of I/T Solution Architecture
Nick Noecker
 
Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...
Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...
Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...
Ingo Weber
 
Hyperledger Blockchain
Hyperledger BlockchainHyperledger Blockchain
Hyperledger Blockchain
Afraz Khan
 
Hyperledger: Advancing Blockchain Technology for Business
Hyperledger: Advancing Blockchain Technology for BusinessHyperledger: Advancing Blockchain Technology for Business
Hyperledger: Advancing Blockchain Technology for Business
Cloud Standards Customer Council
 
Distributed Systems for Blockchain using Cloud
Distributed  Systems for Blockchain  using CloudDistributed  Systems for Blockchain  using Cloud
Distributed Systems for Blockchain using Cloud
Hridyesh Bisht
 
DevDay: The Corda Network, James Carlyle
DevDay: The Corda Network, James CarlyleDevDay: The Corda Network, James Carlyle
DevDay: The Corda Network, James Carlyle
R3
 
Slides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBA
Slides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBASlides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBA
Slides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBA
Severalnines
 
Return of the transaction king
Return of the transaction kingReturn of the transaction king
Return of the transaction king
Ryan Knight
 
Microservices vs SOA
Microservices vs SOAMicroservices vs SOA
Microservices vs SOA
inovia
 
Duplicating data or replicating data in Micro Services
Duplicating data or replicating data in Micro ServicesDuplicating data or replicating data in Micro Services
Duplicating data or replicating data in Micro Services
Dennis van der Stelt
 
Icsa2018 blockchain tutorial
Icsa2018 blockchain tutorialIcsa2018 blockchain tutorial
Icsa2018 blockchain tutorial
Len Bass
 
Designing loosely coupled services
Designing loosely coupled servicesDesigning loosely coupled services
Designing loosely coupled services
Chris Richardson
 
Developing microservices with aggregates (devnexus2017)
Developing microservices with aggregates (devnexus2017)Developing microservices with aggregates (devnexus2017)
Developing microservices with aggregates (devnexus2017)
Chris Richardson
 
Modularity by Microservices
Modularity by MicroservicesModularity by Microservices
Modularity by Microservices
Andrei Rugina
 
Antifragile, Microservices and DevOps - A Study
Antifragile, Microservices and DevOps - A StudyAntifragile, Microservices and DevOps - A Study
Antifragile, Microservices and DevOps - A Study
William Yang
 
The Cloud is dead ?! Blockchain in the new cloud
The Cloud is dead ?! Blockchain in the new cloudThe Cloud is dead ?! Blockchain in the new cloud
The Cloud is dead ?! Blockchain in the new cloud
Yuval Birenboum
 
Microservices architecture
Microservices architectureMicroservices architecture
Microservices architecture
Abdelghani Azri
 
Events on the outside, on the inside and at the core (jfokus jfokus2016)
Events on the outside, on the inside and at the core (jfokus jfokus2016)Events on the outside, on the inside and at the core (jfokus jfokus2016)
Events on the outside, on the inside and at the core (jfokus jfokus2016)
Chris Richardson
 
Polyglot persistence for Java developers: time to move out of the relational ...
Polyglot persistence for Java developers: time to move out of the relational ...Polyglot persistence for Java developers: time to move out of the relational ...
Polyglot persistence for Java developers: time to move out of the relational ...
Chris Richardson
 
Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)
Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)
Developing Event-driven Microservices with Event Sourcing & CQRS (gotoams)
Chris Richardson
 
What Is Solution Architecture? The Black Art Of I/T Solution Architecture
What Is Solution Architecture? The Black Art Of I/T Solution ArchitectureWhat Is Solution Architecture? The Black Art Of I/T Solution Architecture
What Is Solution Architecture? The Black Art Of I/T Solution Architecture
Nick Noecker
 
Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...
Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...
Blockchains and Smart Contracts: Architecture Design and Model-Driven Develop...
Ingo Weber
 
Hyperledger Blockchain
Hyperledger BlockchainHyperledger Blockchain
Hyperledger Blockchain
Afraz Khan
 
Distributed Systems for Blockchain using Cloud
Distributed  Systems for Blockchain  using CloudDistributed  Systems for Blockchain  using Cloud
Distributed Systems for Blockchain using Cloud
Hridyesh Bisht
 
DevDay: The Corda Network, James Carlyle
DevDay: The Corda Network, James CarlyleDevDay: The Corda Network, James Carlyle
DevDay: The Corda Network, James Carlyle
R3
 
Slides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBA
Slides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBASlides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBA
Slides: Polyglot Persistence for the MongoDB, MySQL & PostgreSQL DBA
Severalnines
 

Similar to Microservices Architecture (20)

The Big Picture - Integrating Buzzwords
The Big Picture - Integrating BuzzwordsThe Big Picture - Integrating Buzzwords
The Big Picture - Integrating Buzzwords
Alessandro Giorgetti
 
ASAS 2014 - Simon Brown
ASAS 2014 - Simon BrownASAS 2014 - Simon Brown
ASAS 2014 - Simon Brown
Avisi B.V.
 
Microservices Architecture - Cloud Native Apps
Microservices Architecture - Cloud Native AppsMicroservices Architecture - Cloud Native Apps
Microservices Architecture - Cloud Native Apps
Araf Karsh Hamid
 
Domain Driven Design
Domain Driven DesignDomain Driven Design
Domain Driven Design
Muhammad Ali
 
Microservices for performance - GOTO Chicago 2016
Microservices for performance - GOTO Chicago 2016Microservices for performance - GOTO Chicago 2016
Microservices for performance - GOTO Chicago 2016
Peter Lawrey
 
Timeless design in a cloud-native world
Timeless design in a cloud-native worldTimeless design in a cloud-native world
Timeless design in a cloud-native world
Uwe Friedrichsen
 
Microservices: Where do they fit within a rapidly evolving integration archit...
Microservices: Where do they fit within a rapidly evolving integration archit...Microservices: Where do they fit within a rapidly evolving integration archit...
Microservices: Where do they fit within a rapidly evolving integration archit...
Kim Clark
 
CWIN17 Utrecht / cg u services - frank van der wal
CWIN17 Utrecht / cg u services - frank van der walCWIN17 Utrecht / cg u services - frank van der wal
CWIN17 Utrecht / cg u services - frank van der wal
Capgemini
 
Microsoft Microservices
Microsoft MicroservicesMicrosoft Microservices
Microsoft Microservices
Chase Aucoin
 
Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"
Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"
Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"
GlobalLogic Ukraine
 
Microservices architecture
Microservices architectureMicroservices architecture
Microservices architecture
Faren faren
 
Microservices - when, why and how incontrodevops.it
Microservices  - when, why and how incontrodevops.itMicroservices  - when, why and how incontrodevops.it
Microservices - when, why and how incontrodevops.it
Giuseppe Lavagetto
 
Accelerate DevOps/Microservices and Kubernetes
Accelerate DevOps/Microservices and KubernetesAccelerate DevOps/Microservices and Kubernetes
Accelerate DevOps/Microservices and Kubernetes
Rick Hightower
 
The Reality of Managing Microservices in Your CD Pipeline
The Reality of Managing Microservices in Your CD PipelineThe Reality of Managing Microservices in Your CD Pipeline
The Reality of Managing Microservices in Your CD Pipeline
DevOps.com
 
Microservices vs monolithics betabeers
Microservices vs monolithics   betabeersMicroservices vs monolithics   betabeers
Microservices vs monolithics betabeers
Jesús Mª Villar Vazquez
 
Best Practices Building Cloud Scale Apps with Microservices
Best Practices Building Cloud Scale Apps with MicroservicesBest Practices Building Cloud Scale Apps with Microservices
Best Practices Building Cloud Scale Apps with Microservices
Jim (张建军) Zhang
 
The Essentials Of Project Management
The Essentials Of Project ManagementThe Essentials Of Project Management
The Essentials Of Project Management
Laura Arrigo
 
Evolutionary evnt-driven-architecture-for-accelerated-digital-transformation
Evolutionary evnt-driven-architecture-for-accelerated-digital-transformationEvolutionary evnt-driven-architecture-for-accelerated-digital-transformation
Evolutionary evnt-driven-architecture-for-accelerated-digital-transformation
Slobodan Sipcic
 
Domain Driven Design & Hexagonal Architecture
Domain Driven Design & Hexagonal ArchitectureDomain Driven Design & Hexagonal Architecture
Domain Driven Design & Hexagonal Architecture
Can Pekdemir
 
Microservices Corporate Style
Microservices Corporate StyleMicroservices Corporate Style
Microservices Corporate Style
Narendranath Reddy
 
The Big Picture - Integrating Buzzwords
The Big Picture - Integrating BuzzwordsThe Big Picture - Integrating Buzzwords
The Big Picture - Integrating Buzzwords
Alessandro Giorgetti
 
ASAS 2014 - Simon Brown
ASAS 2014 - Simon BrownASAS 2014 - Simon Brown
ASAS 2014 - Simon Brown
Avisi B.V.
 
Microservices Architecture - Cloud Native Apps
Microservices Architecture - Cloud Native AppsMicroservices Architecture - Cloud Native Apps
Microservices Architecture - Cloud Native Apps
Araf Karsh Hamid
 
Domain Driven Design
Domain Driven DesignDomain Driven Design
Domain Driven Design
Muhammad Ali
 
Microservices for performance - GOTO Chicago 2016
Microservices for performance - GOTO Chicago 2016Microservices for performance - GOTO Chicago 2016
Microservices for performance - GOTO Chicago 2016
Peter Lawrey
 
Timeless design in a cloud-native world
Timeless design in a cloud-native worldTimeless design in a cloud-native world
Timeless design in a cloud-native world
Uwe Friedrichsen
 
Microservices: Where do they fit within a rapidly evolving integration archit...
Microservices: Where do they fit within a rapidly evolving integration archit...Microservices: Where do they fit within a rapidly evolving integration archit...
Microservices: Where do they fit within a rapidly evolving integration archit...
Kim Clark
 
CWIN17 Utrecht / cg u services - frank van der wal
CWIN17 Utrecht / cg u services - frank van der walCWIN17 Utrecht / cg u services - frank van der wal
CWIN17 Utrecht / cg u services - frank van der wal
Capgemini
 
Microsoft Microservices
Microsoft MicroservicesMicrosoft Microservices
Microsoft Microservices
Chase Aucoin
 
Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"
Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"
Java TechTalk "Spring boot made life easier with Kubernetes and Microservices"
GlobalLogic Ukraine
 
Microservices architecture
Microservices architectureMicroservices architecture
Microservices architecture
Faren faren
 
Microservices - when, why and how incontrodevops.it
Microservices  - when, why and how incontrodevops.itMicroservices  - when, why and how incontrodevops.it
Microservices - when, why and how incontrodevops.it
Giuseppe Lavagetto
 
Accelerate DevOps/Microservices and Kubernetes
Accelerate DevOps/Microservices and KubernetesAccelerate DevOps/Microservices and Kubernetes
Accelerate DevOps/Microservices and Kubernetes
Rick Hightower
 
The Reality of Managing Microservices in Your CD Pipeline
The Reality of Managing Microservices in Your CD PipelineThe Reality of Managing Microservices in Your CD Pipeline
The Reality of Managing Microservices in Your CD Pipeline
DevOps.com
 
Best Practices Building Cloud Scale Apps with Microservices
Best Practices Building Cloud Scale Apps with MicroservicesBest Practices Building Cloud Scale Apps with Microservices
Best Practices Building Cloud Scale Apps with Microservices
Jim (张建军) Zhang
 
The Essentials Of Project Management
The Essentials Of Project ManagementThe Essentials Of Project Management
The Essentials Of Project Management
Laura Arrigo
 
Evolutionary evnt-driven-architecture-for-accelerated-digital-transformation
Evolutionary evnt-driven-architecture-for-accelerated-digital-transformationEvolutionary evnt-driven-architecture-for-accelerated-digital-transformation
Evolutionary evnt-driven-architecture-for-accelerated-digital-transformation
Slobodan Sipcic
 
Domain Driven Design & Hexagonal Architecture
Domain Driven Design & Hexagonal ArchitectureDomain Driven Design & Hexagonal Architecture
Domain Driven Design & Hexagonal Architecture
Can Pekdemir
 
Ad

More from Alessandro Giorgetti (7)

Angular Unit Testing
Angular Unit TestingAngular Unit Testing
Angular Unit Testing
Alessandro Giorgetti
 
AngularConf2016 - A leap of faith !?
AngularConf2016 - A leap of faith !?AngularConf2016 - A leap of faith !?
AngularConf2016 - A leap of faith !?
Alessandro Giorgetti
 
AngularConf2015
AngularConf2015AngularConf2015
AngularConf2015
Alessandro Giorgetti
 
TypeScript . the JavaScript developer best friend!
TypeScript . the JavaScript developer best friend!TypeScript . the JavaScript developer best friend!
TypeScript . the JavaScript developer best friend!
Alessandro Giorgetti
 
«Real Time» Web Applications with SignalR in ASP.NET
«Real Time» Web Applications with SignalR in ASP.NET«Real Time» Web Applications with SignalR in ASP.NET
«Real Time» Web Applications with SignalR in ASP.NET
Alessandro Giorgetti
 
DNM19 Sessione1 Orchard Primo Impatto (ita)
DNM19 Sessione1 Orchard Primo Impatto (ita)DNM19 Sessione1 Orchard Primo Impatto (ita)
DNM19 Sessione1 Orchard Primo Impatto (ita)
Alessandro Giorgetti
 
DNM19 Sessione2 Orchard Temi e Layout (Ita)
DNM19 Sessione2 Orchard Temi e Layout (Ita)DNM19 Sessione2 Orchard Temi e Layout (Ita)
DNM19 Sessione2 Orchard Temi e Layout (Ita)
Alessandro Giorgetti
 
AngularConf2016 - A leap of faith !?
AngularConf2016 - A leap of faith !?AngularConf2016 - A leap of faith !?
AngularConf2016 - A leap of faith !?
Alessandro Giorgetti
 
TypeScript . the JavaScript developer best friend!
TypeScript . the JavaScript developer best friend!TypeScript . the JavaScript developer best friend!
TypeScript . the JavaScript developer best friend!
Alessandro Giorgetti
 
«Real Time» Web Applications with SignalR in ASP.NET
«Real Time» Web Applications with SignalR in ASP.NET«Real Time» Web Applications with SignalR in ASP.NET
«Real Time» Web Applications with SignalR in ASP.NET
Alessandro Giorgetti
 
DNM19 Sessione1 Orchard Primo Impatto (ita)
DNM19 Sessione1 Orchard Primo Impatto (ita)DNM19 Sessione1 Orchard Primo Impatto (ita)
DNM19 Sessione1 Orchard Primo Impatto (ita)
Alessandro Giorgetti
 
DNM19 Sessione2 Orchard Temi e Layout (Ita)
DNM19 Sessione2 Orchard Temi e Layout (Ita)DNM19 Sessione2 Orchard Temi e Layout (Ita)
DNM19 Sessione2 Orchard Temi e Layout (Ita)
Alessandro Giorgetti
 
Ad

Recently uploaded (20)

Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdfMicrosoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
TechSoup
 
Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025
mu394968
 
Adobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest VersionAdobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest Version
kashifyounis067
 
Douwan Crack 2025 new verson+ License code
Douwan Crack 2025 new verson+ License codeDouwan Crack 2025 new verson+ License code
Douwan Crack 2025 new verson+ License code
aneelaramzan63
 
Download YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full ActivatedDownload YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full Activated
saniamalik72555
 
The Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdfThe Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdf
drewplanas10
 
Kubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptxKubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptx
CloudScouts
 
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRYLEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
NidaFarooq10
 
Adobe After Effects Crack FREE FRESH version 2025
Adobe After Effects Crack FREE FRESH version 2025Adobe After Effects Crack FREE FRESH version 2025
Adobe After Effects Crack FREE FRESH version 2025
kashifyounis067
 
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software DevelopmentSecure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Shubham Joshi
 
PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025
mu394968
 
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
ssuserb14185
 
Expand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchangeExpand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchange
Fexle Services Pvt. Ltd.
 
Pixologic ZBrush Crack Plus Activation Key [Latest 2025] New Version
Pixologic ZBrush Crack Plus Activation Key [Latest 2025] New VersionPixologic ZBrush Crack Plus Activation Key [Latest 2025] New Version
Pixologic ZBrush Crack Plus Activation Key [Latest 2025] New Version
saimabibi60507
 
Meet the Agents: How AI Is Learning to Think, Plan, and Collaborate
Meet the Agents: How AI Is Learning to Think, Plan, and CollaborateMeet the Agents: How AI Is Learning to Think, Plan, and Collaborate
Meet the Agents: How AI Is Learning to Think, Plan, and Collaborate
Maxim Salnikov
 
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Dele Amefo
 
How can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptxHow can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptx
laravinson24
 
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Orangescrum
 
FL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full VersionFL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full Version
tahirabibi60507
 
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AIScaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
danshalev
 
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdfMicrosoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
TechSoup
 
Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025
mu394968
 
Adobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest VersionAdobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest Version
kashifyounis067
 
Douwan Crack 2025 new verson+ License code
Douwan Crack 2025 new verson+ License codeDouwan Crack 2025 new verson+ License code
Douwan Crack 2025 new verson+ License code
aneelaramzan63
 
Download YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full ActivatedDownload YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full Activated
saniamalik72555
 
The Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdfThe Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdf
drewplanas10
 
Kubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptxKubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptx
CloudScouts
 
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRYLEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
NidaFarooq10
 
Adobe After Effects Crack FREE FRESH version 2025
Adobe After Effects Crack FREE FRESH version 2025Adobe After Effects Crack FREE FRESH version 2025
Adobe After Effects Crack FREE FRESH version 2025
kashifyounis067
 
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software DevelopmentSecure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Shubham Joshi
 
PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025
mu394968
 
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
ssuserb14185
 
Expand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchangeExpand your AI adoption with AgentExchange
Expand your AI adoption with AgentExchange
Fexle Services Pvt. Ltd.
 
Pixologic ZBrush Crack Plus Activation Key [Latest 2025] New Version
Pixologic ZBrush Crack Plus Activation Key [Latest 2025] New VersionPixologic ZBrush Crack Plus Activation Key [Latest 2025] New Version
Pixologic ZBrush Crack Plus Activation Key [Latest 2025] New Version
saimabibi60507
 
Meet the Agents: How AI Is Learning to Think, Plan, and Collaborate
Meet the Agents: How AI Is Learning to Think, Plan, and CollaborateMeet the Agents: How AI Is Learning to Think, Plan, and Collaborate
Meet the Agents: How AI Is Learning to Think, Plan, and Collaborate
Maxim Salnikov
 
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Dele Amefo
 
How can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptxHow can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptx
laravinson24
 
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025Why Orangescrum Is a Game Changer for Construction Companies in 2025
Why Orangescrum Is a Game Changer for Construction Companies in 2025
Orangescrum
 
FL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full VersionFL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full Version
tahirabibi60507
 
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AIScaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
danshalev
 

Microservices Architecture

  • 2. Microservices “If you are looking for a technical solution for what it is a business problem, you are looking the wrong way.”
  • 3. The monolithic software weak points oArchitecture/Solution is hard to evolve. oDifficult to Scale. oLong development pipeline (build, test, release). oAdding a feature takes time. oA lot of time between releases. oContinous Delivery is challenging.
  • 4. Microservices definition Microservices is an architectural design for building a distributed application using containers.
  • 5. Microservices a «better» definition Microservices is an “architectural style” for building a distributed application as a collection of small and loosely coupled services (each service implementing a business capability). Services should have the following properties…
  • 6. Microservices «properties»: •Autonomy. •Small and Focused on a single «thing». •Independent Development: the right tools for the right job! •Independent Deployment. •Independent Scalability.
  • 7. Microservices «properties»: •Reusable (through composition). •Owned by a small team. •Designed for Failure / No single point of failure: the system can “degrade”, but it should never be fully down. •Promotes the adoptions of new technologies.
  • 8. Microservices promise to be like: The Monolith (the big ball of mud) Service 1 Service 3 Website Service 4 APP Service 7 Service 6 Service 5 Service 8 Service 10 Service 2 Service 9
  • 9. Microservices leads to Reactive Systems https://www.reactivemanifesto.org/ Loosely Coupled Loose coupling through async message passing Resilient Error containment Fault tolerance and recovery Elastic Scalability React to workload change Responsive Rapid and consistent response times A Reactive System is made of services and components that have the following properties:
  • 10. Microservices «pain points» •Increased complexity for developers. •Increased complexity for operators. •Increased complexity for devops (ALM madness!). •It requires serious expertise. •Unclear or not well defined Service Boundaries. •(Distributed) State management ?
  • 11. Microservices «pain points» •Versioning. •Communications issues. •Distributed Transactions: Can they be avoided? At which cost? •Performances: many services with many «dependencies» = many network calls! •Managing and «orchestration»: logging, monitoring, discovery, etc... •Debugging.
  • 12. Distributed computing is hard! The fallacies of distributed computing: 1. The network is reliable. 2. Latency is zero. 3. Bandwidth is infinite. 4. The network is secure. 5. Topology doesn't change. 6. There is one administrator. 7. Transport cost is zero. 8. The network is homogeneous. And we always underestimate: 1. Error Handling, Failures and Recovery. 2. Performance and Bottlenecks. 3. Blocking operations. 4. Concurrency. 5. Consistency. 6. State Management / Locks / Threads. 7. Parallelism. 8. Availability.
  • 13. The Microservices thing can become… Service 3 Service 4 APP Service 7 Service 6 Service 5 Service 8 Service 10 Service 9 Service 1 Service 3 Website Service 4 APP Service 7 Service 6 Service 5 Service 8 Service 10 Service 11 Service 9
  • 14. Microservices fundamentals Service Oriented Architecture • Ownership of data and behavior. • Autonomy. • And more… Domain Driven Design • Bounded Context. • Aggregate. • Events. Event Driven Architecture • Loose coupling. Patterns & Practices
  • 15. The first thing that comes in mind when thinking about «architecture»!
  • 16. You cannot fight the «Coupling»!
  • 17. A long time ago in a galaxy far, far away…. SOA Service Oriented Architecture A service is a technical authority for a business capability. Any piece of data or rule must be owned by only one service. http://www.soa-manifesto.org/ https://www.infoq.com/articles/tilkov-10-soa-principles https://en.wikipedia.org/wiki/Service-orientation_design_principles
  • 19. SOA Service: a definition (sort of) We can define a service by its fundamentals / principles (the four tenets): oServices are autonomous. oServices have well defined boundaries. oServices share contracts and schema. oServices interactions are controlled by policies. A Service provide the implementation for a specific Business Capability! http://www.dbizinstitute.org/resources/articles/four-tenets-service-orientation
  • 20. SOA: «decouple» the different business capabilities… in «services»! We might end up with something like this: slices of a layered architecture! Each slice representing a capability of the system! They are Autonomous and Loosely Coupled! Product Catalog Sales Shipping Infrastructure logging, communication, …
  • 21. The major problems of SOA: oServices could be «very big» (monolithic services). oToo much tied to a specific technology (Web Services, ESB). oIf done wrong we’ll end up having tight coupling with one service directly calling into another. (welcome the distributed monolith… with latency and reliability problems).
  • 22. MicroServices: SOA vNext Microservices is a variant of SOA that structures an application as a collection of loosely coupled services. Services should be fine-grained and the communication protocols should be lightweight. Another Microservices Definition: Microservices is an “architectural style” for building a distributed application as a collection of small and loosely coupled services. A service is a technical authority for a business capability. Any piece of data or rule must be owned by only one service.
  • 23. MicroServices: SOA vNext From an “operative” standpoint: Small, independent applications, loosely coupled, communicating (asynchronously) with each other, and can fail independently, and if one or some fails, the system as a whole still works (the functionality might be downgraded).
  • 24. How is it different from SOA ? •Tries to reduce the size of services: Small services with a single focus. •Promotes the usage of technology agnostic APIs. • Services can be consumed by other services written in different technologies. •Promotes the usage of independent data storage (for each service). •Promotes the usage of lightweight communication protocols. •Puts the emphasis on loose coupling even more. •Improves the scalability. •Improve the flexibility.
  • 25. Microservices goes further! Product Catalog Sales Shipping Infrastructure P.C. Service 1 P.C. Service 3 P.C. Service 4 P.C. Service 5 P.C. Service N P.C. Service 2 S. Service 1 S. Service 2 S. Service 5 S. Service N S. Service 3 S. Service 4 Sales Service 1 Sales Service 2 Sales Service 3 Sales Service 4 Sales Service 5 Sales Service N
  • 26. How to «discover» the Services? DDD TO THE RESCUE
  • 27. Finding out what’s inside a service We need logical view of the system. Some practices worked very well (for us): oDDD (Domain Driven Design). oEvent Storming.
  • 28. Domain Driven Design An approach to software development for «complex systems» that works promoting the adoption of an evolving domain model, that derives from a collaboration between developers and domain experts to iteratively refine a conceptual model that addresses particular domain problems.
  • 29. DDD key concepts Ubiquitous Language - the language used by domain experts and developers that defines elements/processes of the business. Events (and Commands) – facts, evidences that something happened in the business. Aggregate – a cluster of domain objects that represent a single (transactional) unit, it supports the business providing behavior and rules. Bounded Context - the “environment” in which a specific Ubiquitous Language is valid. Context-Map – shows the interactions between Bounded-Contexts.
  • 30. Event Storming – talk the (ubiquitous) language of the business! «Tool / Workshop» that allows to quickly explore complex business domains. You can figure out how the system works (how much in detail it is up to you); you’ll also get an overrall idea of the «shape» of the system.
  • 31. Aggregate An Aggregate encapsulates state and behavior. An Aggregate guarantees that Business Rules are satisfied. An Aggregate is a «Transactional» and «Computational» Unit. An aggregate accepts Commands and emits Events, Event represents Business Transactions outcome. A DDD aggregate is a cluster of domain objects that can be treated as a single unit. Aggregate Cmd(s) Evt(s) Cmd(s) Evt(s) Evt(s)
  • 32. Bounded Contexts Catalog Aggregate(s) Cmd(s) Evt(s) Catalog Aggregate(s) Cmd(s) Evt(s) Catalog Aggregate(s) Cmd(s) Evt(s) Sales Aggregate(s) Cmd(s) Evt(s) Catalog Aggregate(s) Cmd(s) Evt(s) Shipping Aggregate(s) Cmd(s) Evt(s) Catalog Bounded Context Sales Bounded Context Shipping Bounded Context
  • 33. Context Map Context Maps draw the relationships between the Bounded Contexts, they are: oConformist relationship: the downstream context might follow and adapt to what the upstream context says. oPartnership relationships (both context work towards a common goal; the same term might exists in multiple contexts with different behaviors). oTechnical relationships (how they talk). A system will almost never be made of a single bounded context, BCs operate toghether to fulfill the system requirements and implement business capabilities. BC 1 BC 3 BC 4 BC 2 External System https://www.infoq.com/articles/ddd-contextmapping
  • 34. Bounded Contexts oThey are Autonomous / have Explicit Boundaries: encapsulation, they «contain» everything that’s needed to implement a business capability. oThey share contract and schema: that’s a «communication protocol». BC 1 BC 3 BC 4 BC 2 External SystemBC 1 BC 3 BC 4 BC 2 External System
  • 35. Bounded Contexts  SOA Services oThey are Autonomous / have Explicit Boundaries: encapsulation, they «contain» everything that’s needed to implement a business capability. oThey share contract and schema: that’s a «communication protocol». BC 1 BC 3 BC 4 BC 2 External System Service 1 Service 3 Service 4 Service 2 External System
  • 36. How do Services talk? REDUCING COUPLING IS THE KEY!
  • 37. How do these Services communicate? You can still have coupling!!! Shopping Cart Sales bool placeOrder(id, items) Process 1 Shopping Cart Sales bool placeOrder(id, items) In-Process Process 2 H T T P
  • 38. BTW… This is coupling too!!! Process 1 Shopping Cart Sales Process 2 The Database The Table
  • 39. How do services talk ? o(SYNC) RPC and the likes. o(ASYNC) Messaging.
  • 40. RPC and the likes: gRPC, Web Services, anything over TCP, HTTP and so on… In distributed computing, a remote procedure call (RPC) is an Inter-process communication technology that allows a computer program to causes a procedure (subroutine) to execute in a different address space (commonly another process on another computer on a shared network). https://en.wikipedia.org/wiki/Remote_procedure_call
  • 41. RPC (underlying concepts) Location Transparency: the function call is coded as if it were a normal (local) procedure call, without the programmer explicitly coding the details for the remote interaction. RPC is typically implemented via a (blocking) request – response message- passing system. Remote calls are usually slower and less reliable than local calls.
  • 42. Messaging Message: an immutable data structure used to exchange a piece of information.
  • 43. Why Messages are so important? They have properties that open up many scenarios: •Asynchronous Communication. •Can be serialized and stored (debugging, event sourcing). •Can be ordered (priority, deferred elaboration). •Carry metadata / context information (like a reply-to). •Can be forwarded. •Can be broadcasted.
  • 44. Messaging Patterns Service ServiceOne Way Service ServiceBroadcast Service Service
  • 45. Messaging Patterns Service ServiceProxy Service ServicePub/Sub Service Service Service forward subscribe publish
  • 46. Message Delivery Patterns •at-most-once: for each message handed to the mechanism, that message is delivered zero or one times; the messages may be lost. •at-least-once: for each message handed to the mechanism potentially multiple attempts are made at delivering it, until at least one succeeds; the messages may be duplicated but not lost. •exactly-once: for each message handed to the mechanism exactly one delivery is made to the recipient; the message can neither be lost nor duplicated.
  • 47. Event Driven Architecture •Event Producers: generate streams of events. •Event Consumers: listen to events. Producers are decoupled from consumers: a producer doesn't know which consumers are listening. Consumers are also decoupled from each other. Every Consumer can potentially see all the events / messages. Event Producer Event Consumer Event Consumer Event Streaming Infrastructure
  • 48. Event Driven Architecture Can use two communication models: •Pub/sub: the messaging infrastructure keeps track of subscriptions. After an event is received, it cannot be replayed, and new subscribers do not see past events. •Event streaming: events are written to a durable log. Events are strictly ordered within a partition. Consumers don't subscribe to the stream, instead a consumer can read from any part of the stream. The consumer is responsible for advancing its position in the stream.
  • 50. A Microservice in a Distributed App. OWNS and PROTECTS data and behavior… it’s responsible for their exposure to the rest of the system. Ideally, everything that «belongs» to a service is managed by the service itself: oFrom the Databases  to the Backend  to the UI components (widgets). oThe Team responsible for the service should have expertise in all the areas.
  • 51. A Service spans multiple «technologies» and «responsibilities» Product Catalog Sales Logistics Backend ( .net / java / go / … ) Web Portal ( web api / html / javascript / …) Mobile Apps ( .net / xamarin / swift / … ) Microservices is also for scaling People! Not only the Deployment Unit(s)! Team 1 Team 1 Team 1 Team 2 Team 2 Team 2 Team 3 Team 3 Team 3
  • 52. When it comes to the physical view… A service is a composition of components and smaller «services»… that collaborate to implement a specific business capability!! The term service is «overloaded» and has slightly different properties: oA service, in this context, is a support entity for other components in order to fulfill very specific tasks. oMight not be fully autonomous. oThere will be coupling, a lot of coupling… there will be cohesion!
  • 53. Microservices «Physical View»: composition of components & services Web Crawler (stateful) Crawling Job Coordinator 1 (stateful) Parser 1 (stateless) Downloader 1 (stateless) Analyzer 1 (stateless) Parser n (stateless) Downloader n (stateless) Analyzer n (stateless) Crawling Job Coordinator n (stateful) Parser 1 (stateless) Downloader 1 (stateless) Analyzer 1 (stateless) Parser n (stateless) Downloader n (stateless) Analyzer n (stateless)
  • 54. How do we «code» each Service / Bounded Context? Inside a Microservice we can follow any architectural style we want! They are «small» and «autonomous» and «easily replaceable»! (Given we respect the communication protocol contracts).
  • 56. CQRS / ES (Aggregate  Domain Object)
  • 57. We can also consider tools designed to help us build distributed applications Akka (https://akka.io) & Akka.NET (https://getakka.net/) Microsoft Orleans (https://dotnet.github.io/orleans/) Dapr - Distributed Application Runtime (https://dapr.io/)
  • 58. Chosing the «communication protocols» at the highest level of the system Product Catalog Service Inventory Service Account Service Sales Service Shipping Service Whatever Service My favorites: • Event Streams. • Enterprise Service Bus. • Independent Queues. Less favorites: • Lightweight RPC (gRPC / WebServices). Event Streams / ESB
  • 59. Communications «within» a Microservice If our Microservice can be made of a subset of cohesive sub-services: •Few stateful services. •Many stateless services. We can deploy them on several machines (cluster), how do they communicate? My Favorites: •RPC. •Async Messaging. Crawling Job Coordinator 1 (stateful) Parser 1 (stateless) Downloader 1 (stateless) Analyzer 1 (stateless) Parser n (stateless) Downloader n (stateless) Analyzer n (stateless)
  • 60. Microservices + API Gateway + Monolithic UI https://docs.microsoft.com/en-us/dotnet/standard/microservices-architecture/architect-microservice-container-applications/microservice-based-composite-ui-shape-layout
  • 61. Microservices + UI Composition https://docs.microsoft.com/en-us/dotnet/standard/microservices-architecture/architect-microservice-container-applications/microservice-based-composite-ui-shape-layout
  • 62. Microservices Lifecycle Management ? Microservices are biased towards organizations with multiple teams. oBest practices as Continous Integration / Continous Deployment should be encouraged. oMultiple backlogs (Agile, SCRUM, Kanban, etc…) ? oMultiple Repositories ? oMultiple Deployment tools & Deployment Strategies ?
  • 63. So we have all our nice Microservices… How do we package them? How do we deploy them? How do we orchestrate & manage them? How do we monitor them? How do we handle failing microservices?
  • 64. Resources – Distributed Applications •Designing Data-Intensive Applications https://www.amazon.it/Designing-Data-Intensive-Applications-Reliable- Maintainable/dp/1449373321 •Designing Distributed Systems https://www.amazon.it/Designing-Distributed-Systems-Patterns-Paradigms/dp/1491983647
  • 65. Resources - Microservices •Microservices.io https://microservices.io/ •Building Microservices https://www.amazon.it/Building-Microservices-Sam-Newman/dp/1491950358 •.NET Architecture Guides https://dotnet.microsoft.com/learn/dotnet/architecture-guides •.NET Microservices Architecture Guidance https://dotnet.microsoft.com/learn/aspnet/microservices-architecture •.NET Microservices: Architecture for Containerized .NET Applications https://docs.microsoft.com/en-us/dotnet/architecture/microservices/
  • 66. Resources – DDD •Domain Driven Design https://www.amazon.it/Domain-Driven-Design-Tackling-Complexity-Software- ebook/dp/B00794TAUG/ •Implementing Domain Driven Design https://www.amazon.it/Implementing-Domain-Driven-Design-English-Vaughn- ebook/dp/B00BCLEBN8 •Strategic Domain Driven Design with Context Mapping https://www.infoq.com/articles/ddd-contextmapping/
  • 67. Resources – Reactive Applications •Reactive Design Patterns https://www.amazon.it/Reactive-Design-Patterns-Roland-Kuhn/dp/1617291803/ •Reactive Messaging Patterns with the Actor Model https://www.amazon.it/dp/B011S8YC5G
  • 68. Keep in touch Dott.ing. Alessandro Giorgetti Facebook: https://www.facebook.com/giorgetti.alessandro Twitter: @a_giorgetti LinkedIn: https://it.linkedin.com/in/giorgettialessandro E-mail: [email protected] Blog: www.primordialcode.com Alessandro Giorgetti www.primordialcode.com