SlideShare a Scribd company logo
Understanding	Microservice	Architecture	
Kasun	Indrasiri		
Director,	Integra.on	Technologies	
WSO2
Microservices?
Monolithic	Architecture
Monolithic	Architecture		
•  All	func.onali.es	are	implemented/deployed	into	a	single	
soBware	applica.on.		
•  Enterprise	soBware	applica.ons	-	ERPs,	CRMs	etc.	
•  SOA/web	services:	'coarse-grained'	services,	broad	scope,	
mammoth	services	with	several	dozens	of	opera.ons	and	
complex	message	formats
Monolithic	Architecture		
•  Use	case	:	Online	Retail	soBware	applica.on	which	comprises	of	
mul.ple	business	func.onali.es.		
	
JVM
Monolithic	Architecture		
•  Developed	and	deployed	as	a	single	unit.	
•  Overwhelmingly	complex;	which	leads	to	nightmares	in	
maintaining,	upgrading	and	adding	new	features.	
•  Redeploy	the	en>re	applica>on,	in	order	to	update	a	part	of	it.	
•  Scaling	:	scaled	as	a	single	applica>on	and	difficult	to	scale	with	
conflic>ng	resource	requirements	whole	applica>on	down	
•  Reliability	-	One	unstable	service	can	bring	the.		
•  Hard	to	innovate,	prac>ce	agile	development	and	delivery	
methodologies
Microservices	Architecture
Microservices	Architecture	
•  The	founda.on	of	microservices	architecture(MSA)	is	about	
developing	a	single	applica.on	as	a	suite	of	fine-grained	and	
independent	services	that	are		running	in	its	own	process,	
developed	and	deployed	independently.	
•  It	is	more	than	just	segrega.ng	the	services	in	a	monolith…
Microservices	Architecture	
•  Use	case	:	Online	retail	applica.on	can	be	implemented	with	a	
suite	of	microservices		
	
JVM	
JVM	
JVM	
JVM
Designing	Microservices	:	Size,	scope	and	capabili.es	
•  Common	Misconcep.ons		
–  Lines	of	Code	
–  Team	size		
–  'Micro'	is	a	bit	misleading	term		
–  Use	web	services	and	rebranding	them	as	microservices
Designing	Microservices	:	Size,	scope	and	capabili.es	
•  Common	Misconcep.ons		
–  Lines	of	Code	
–  Team	size		
–  'Micro'	is	a	bit	misleading	term		
–  Use	web	services	and	rebranding	them	as	microservices
Designing	Microservices	:	Size,	scope	and	capabili.es	
•  Single	Responsibility	Principle(SRP):	Having	a	limited	and	a	focused	
business	scope.		
•  Scope	
–  Find	the	service	boundaries	and	align	them	with	the	business	
capabili.es	(aka	DDD)	
–  Focus	on	scope	of	the	microservice.		
–  Its	not	about	making	services	small…		
•  Agile	and	independent	development	and	deployment	of	the	service.	
•  Microservice	should	have	a	very	few	opera.ons/func.onali.es	and	
simple	message	format.
Messaging	in	Microservices		
•  In	Monolithic	architecture:		
–  Func.on	calls	or	language-level	method	calls	
–  SOA/web	services	:	SOAP	and	WS*	with	HTTP,	JMS	etc.		
–  Web	services	with	several	dozens	of	opera.ons	and	complex	
message	schemas		
•  In	Microservices	architecture:		
–  Simple	and	lightweight	messaging	mechanism.
Messaging	in	Microservices		
•  Synchronous	Messaging	
–  Client	expects	a	.mely	response	from	the	service	and	waits	.ll	it	get	it.		
–  REST,	ThriB
Messaging	in	Microservices		
•  Asynchronous	Messaging	
–  Client	doesn't	expects	a	response	immediately,	or	not	accepts	a	response	at	all	
–  AMQP,	STOMP,	MQTT	
•  Message	Formats	
–  JSON,	XML,	ThriB,	ProtoBuf,	Avro		
•  Service	Contracts		
–  Defining	the	service	interfaces	-	Swagger,	RAML,	ThriB	IDL
Data	Management		
•  Monolithic	applica.ons	use	a	centralized	database
Data	Management		
•  Monolithic	applica.ons	use	a	centralized	database
Data	Management		
•  Decentralized	Data	management	with	Microservices		
–  Each	microservice	can	have	a	private	database	to	persist	the	data	that	
requires	to	implement	the	business	func.onality	offered	from	it.	
–  	Can	only	access	the	dedicated	private	database	but	not	the	databases	
of	other	microservices.	
–  You	might	have	to	update	several	database	for	a	single	transac.on.	In	
such	scenarios,	the	databases	of	other	microservices	should	be	
updated	through	its	service	API	only.
Decentralized	Governance		
•  Governance	–	“establishing	and	enforcing	how	people	and	
solu.ons	work	together	to	achieve	organiza.onal	objec.ves”,	
run.me/design	.me.	
•  In	MSA:			
–  No	centralized	design-.me	governance.	
–  Make	their	own	decisions	about	its	design	and	implementa.on.	
–  Foster	the	sharing	of	common/reusable	services.	
–  Run-.me	governance	aspects	such	as	SLAs,	throgling,	monitoring,	
common	security	requirements	and	service	discovery	may	be	
implemented	at	API-GW	level.
Service	Registry	and	Service	Discovery		
•  Service	Registry	
–  Holds	the	microservices	instances	and	their	loca.ons	
•  Service	Discovery	
–  find	the	available	microservices	and	their	loca.on
Service	Discovery	
•  Client-side	Discovery
Service	Discovery	
•  Server-side	Discovery
Microservices	Deployment		
•  Ability	to	deploy/un-deploy	independently	of	other	microservices.	
•  Must	be	able	to	scale	at	each	microservices	level.		
•  Building	and	deploying	microservices	quickly.		
•  Failure	in	one	microservice	must	not	affect	any	of	the	other	
services.
Microservices	Deployment		
•  Docker	
–  Docker	is	becoming	an	extremely	popular	way	of	packaging	and	
deploying	services.		
–  Package	the	microservice	as	a	(Docker)	container	image.	
–  Deploy	each	service	instance	as	a	container.	
–  Scaling	is	done	based	on	changing	the	number	of	container	instances.	
–  Building,	deploying	and	star.ng	microservices	will	be	much	faster	as	
we	are	using	Docker	containers
Microservices	Deployment		
•  Kubernetes	
–  Extending	Docker	capabili.es	by	allowing	to	manage	a	cluster	of	Linux	
containers	as	a	single	system,	managing	and	running	Docker	
containers	across	mul.ple	hosts,	offering	co-loca.on	of	containers,	
service	discovery	and	replica.on	control.
Microservices	Deployment		
•  Use	case	:	The	microservices	of	Online	Retail	soBware	applica.on	
with	can	be	deployed	and	scaled	with	Docker	and	Kubernetes.
Security	
•  Security	in	Monolithic	applica.ons		
–  	'who	is	the	caller',	'what	can	the	caller	do'	and	'how	do	we	propagate	
that	informa>on’	
–  Implemented	at	a	common	security	component	which	is	at	the	
beginning	of	the	request	handling	chain	and	that	component	
populates	the	required	informa.on	with	the	use	of	an	underlying	user	
repository
Security	
•  Security	in	Microservices	
–  	A	security	component	has	to	be	implemented	at	each	microservices	
level	that	uses	a	central	user	repository/store.	–	Not	scalable!		
–  Leverage	the	widely	used	API-Security	standards	such	as	OAuth2	and	
OpenID	Connect(OIDC)	
	
	
OAuth	2.0	–	Access	Token	:		By	Reference		 OIDC	–	JWT	:	By	Value
Security	
•  Microservice	security	with	OAuth2	and	OpenID	Connect
Orchestra.ng	Microservices		
•  No	ESB	in	MSA.	Then	how?
Orchestra.ng	Microservices		
•  Point-to-point	style	-	Invoking	services	directly	
–  Spaghej	integra.on	an.-pagern?
Orchestra.ng	Microservices		
•  Orchestra.on	at	the	Gateway	Layer
Orchestra.ng	Microservices		
•  Orchestra.on	at	Microservices	Layer
Microservices	in	Modern	Enterprises		
•  Inner	and	Outer	Architecture	
–  Inner	Architecture	:	The	pure	microservices	components		which	is	less	complex	are	
categorized	under	'Inner	Architecture'		
–  Outer	Architecture	:	This	delivers	the	plakorm	capabili.es	that	are	required	to	build	a	
solu.on	around	the	microservices	that	we	build.
Microservices	in	Modern	Enterprises		
	
	
	
Micro	Integra.ons
WSO2	MSF4J		
•  A	lightweight,	high	performance	framework	for	building	
microservices	in	Java.		
•  Agend	Sameera’s	talk	on	App-Dev	track.
Conclusion	
•  Microservices	is	not	a	panacea	:	It	won't	solve	all	your	enterprise	IT	
needs.	
•  ‘SOA	done	right’!	
•  Most	enterprise	won't	be	able	to	convert	their	en.re	enterprise	IT	
systems	to	microservices.		
•  Enterprise	Integra.on	never	goes	away.	
•  Microservices	are	exposed	as	APIs.		
•  Interac.on	between	microservices	should	be	support	via	a	
lightweight	orchestra.on	engine	or	inside	another	microservice.
Reference		
•  hgp://kasunpanorama.blogspot.co.uk/2015/11/microservices-in-
prac.ce.html	
•  hgp://microservices.io/pagerns/microservices.html
Thank	You!	
#WSO2ConEU	
Share	your	feedback	for	this	session	
wso2con.com/app

More Related Content

PDF
WSO2Con EU 2016: Introduction to the All New WSO2 Governance Centre
PDF
WSO2Con EU 2016: Building Enterprise Apps Using WSO2 Platform
PDF
WSO2Con EU 2016: How WSO2 Products Facilitate the Digital Economy in the Tel...
PDF
WSO2Con USA 2017: Implement an Effective Digital Platform Using WSO2 Integration
PDF
Develop an Infrastructure Cost Optimization Strategy
PDF
WSO2Con USA 2017: Providing a Pathway from Stovepipe Systems to a Secure SOA ...
PDF
WSO2Con ASIA 2016: Building Web Apps Using Web-Oriented Architecture
PDF
WSO2Con USA 2017: Implementing a Modern API Management Solution that Benefits...
WSO2Con EU 2016: Introduction to the All New WSO2 Governance Centre
WSO2Con EU 2016: Building Enterprise Apps Using WSO2 Platform
WSO2Con EU 2016: How WSO2 Products Facilitate the Digital Economy in the Tel...
WSO2Con USA 2017: Implement an Effective Digital Platform Using WSO2 Integration
Develop an Infrastructure Cost Optimization Strategy
WSO2Con USA 2017: Providing a Pathway from Stovepipe Systems to a Secure SOA ...
WSO2Con ASIA 2016: Building Web Apps Using Web-Oriented Architecture
WSO2Con USA 2017: Implementing a Modern API Management Solution that Benefits...

What's hot (20)

PDF
WSO2Con ASIA 2016: Moulding Your Enterprise with Resource Oriented Architecture
PPTX
Role of integration in Digital Transformation
PDF
WSO2Con USA 2017: WSO2 Partner Program – Engaging with WSO2
PDF
WSO2Con USA 2017: Journey of Migration from Legacy ESB to Modern WSO2 ESB Pla...
PDF
WSO2Con USA 2017: Building Platforms for Rapid Application Development
PDF
VMworld 2013: Moving Beyond Infrastructure: Meeting Demands on App Lifecycle ...
PDF
Rxt demo-part3
PPTX
Developing Enterprise Applications with the WSO2 Application Platform
PPTX
Cloud to Cloud and Cloud to Enterprise Integration - WSO2Con 2014 USA
PDF
WSO2Con USA 2017: Cloud as a Delivery Channel
PDF
Architecting the Digital Enterprise
PDF
How the WSO2 App factory can help Manage your Applications
PPTX
Enhancing Unified Communication Experience through Microsoft Lync SDK and UCMA
PDF
WSO2Con USA 2017: The Role of Enterprise Integration in Digital Transformation
PDF
WSO2 Product Release Webinar Introducing WSO2 API Manager for Complete API ...
PPTX
WSO2Con USA 2017: Multi-tenanted, Role-based Identity & Access Management sol...
PDF
WSO2Con ASIA 2016: Understanding Microservice Architecture
PPT
SaaS Business Architecture
PPTX
Lightweight ESB Alternatives
PPTX
WSO2 Summit London 2018: Delivering Business Value with WSO2
WSO2Con ASIA 2016: Moulding Your Enterprise with Resource Oriented Architecture
Role of integration in Digital Transformation
WSO2Con USA 2017: WSO2 Partner Program – Engaging with WSO2
WSO2Con USA 2017: Journey of Migration from Legacy ESB to Modern WSO2 ESB Pla...
WSO2Con USA 2017: Building Platforms for Rapid Application Development
VMworld 2013: Moving Beyond Infrastructure: Meeting Demands on App Lifecycle ...
Rxt demo-part3
Developing Enterprise Applications with the WSO2 Application Platform
Cloud to Cloud and Cloud to Enterprise Integration - WSO2Con 2014 USA
WSO2Con USA 2017: Cloud as a Delivery Channel
Architecting the Digital Enterprise
How the WSO2 App factory can help Manage your Applications
Enhancing Unified Communication Experience through Microsoft Lync SDK and UCMA
WSO2Con USA 2017: The Role of Enterprise Integration in Digital Transformation
WSO2 Product Release Webinar Introducing WSO2 API Manager for Complete API ...
WSO2Con USA 2017: Multi-tenanted, Role-based Identity & Access Management sol...
WSO2Con ASIA 2016: Understanding Microservice Architecture
SaaS Business Architecture
Lightweight ESB Alternatives
WSO2 Summit London 2018: Delivering Business Value with WSO2
Ad

Viewers also liked (15)

PDF
WSO2Con USA 2015: Deployment Patterns and Capacity Planning
PDF
WSO2Con EU 2016: Building Your Deployment Architecture Through Requirements, ...
PDF
WSO2Con Asia 2014 - Accelerating Mobile Development with Mobile Enterprise Ap...
PPTX
Wso2 con building the api centric enterprise - towards a connected business
PPTX
Wso2 v ision api centric
PDF
WSO2Con ASIA 2016: Pattern-Driven Enterprise Architecture: Applying Patterns ...
PDF
WSO2Con ASIA 2016: Iterative Architecture: Your Path to On-Time Delivery
PPTX
Achieve business agility with Cloud APIs, Cloud-aware Apps, and Cloud DevOps ...
PDF
Large-Scale Enterprise Platform Transformation with Microservices, DevOps, an...
PPTX
Building a Digital Enterprise: Learning from Experience
PDF
WSO2Con USA 2017: Building an Effective API Architecture
PDF
WSO2Con USA 2017: Keynote - The Blockchain’s Digital Disruption
PDF
WSO2Con USA 2017: Iterative Architecture: A Pragmatic Approach to Digital Tra...
PDF
Introducing Ballerina
PPTX
Platform for Digital Transformation
WSO2Con USA 2015: Deployment Patterns and Capacity Planning
WSO2Con EU 2016: Building Your Deployment Architecture Through Requirements, ...
WSO2Con Asia 2014 - Accelerating Mobile Development with Mobile Enterprise Ap...
Wso2 con building the api centric enterprise - towards a connected business
Wso2 v ision api centric
WSO2Con ASIA 2016: Pattern-Driven Enterprise Architecture: Applying Patterns ...
WSO2Con ASIA 2016: Iterative Architecture: Your Path to On-Time Delivery
Achieve business agility with Cloud APIs, Cloud-aware Apps, and Cloud DevOps ...
Large-Scale Enterprise Platform Transformation with Microservices, DevOps, an...
Building a Digital Enterprise: Learning from Experience
WSO2Con USA 2017: Building an Effective API Architecture
WSO2Con USA 2017: Keynote - The Blockchain’s Digital Disruption
WSO2Con USA 2017: Iterative Architecture: A Pragmatic Approach to Digital Tra...
Introducing Ballerina
Platform for Digital Transformation
Ad

Similar to WSO2Con EU 2016: Understanding Microservice Architecture (20)

PPTX
Understanding Microservice Architecture WSO2Con Asia 2016
PDF
170215 msa intro
PDF
Understanding MicroSERVICE Architecture with Java & Spring Boot
PDF
Microservices in Practice
PPTX
Software architectures
PPTX
Microservices with Mule
PPTX
Microservices Architecture (MSA) - Presentation made at AEA-MN quarterly even...
PDF
Microservices Architecture (MSA) - Presentation made at The Open Group confer...
PPTX
Microserces Architecture
PDF
Microservices for Enterprises
PPTX
MONOLITHIC & MICROSERVICES difference and their properties
PPTX
Microservices with mule
PDF
Microservices: Where do they fit within a rapidly evolving integration archit...
PDF
[WSO2Con EU 2017] Microservices for Enterprises
PDF
WSO2Con USA 2015: Pattern Driven Enterprise Architecture
PDF
Microservices, Monoliths, SOA and How We Got Here
PPTX
Microservice's in detailed
PPSX
Microservices Architecture, Monolith Migration Patterns
PDF
Micro Services Architecture
PDF
Enterprise Integration in Cloud Native Microservices Architectures
Understanding Microservice Architecture WSO2Con Asia 2016
170215 msa intro
Understanding MicroSERVICE Architecture with Java & Spring Boot
Microservices in Practice
Software architectures
Microservices with Mule
Microservices Architecture (MSA) - Presentation made at AEA-MN quarterly even...
Microservices Architecture (MSA) - Presentation made at The Open Group confer...
Microserces Architecture
Microservices for Enterprises
MONOLITHIC & MICROSERVICES difference and their properties
Microservices with mule
Microservices: Where do they fit within a rapidly evolving integration archit...
[WSO2Con EU 2017] Microservices for Enterprises
WSO2Con USA 2015: Pattern Driven Enterprise Architecture
Microservices, Monoliths, SOA and How We Got Here
Microservice's in detailed
Microservices Architecture, Monolith Migration Patterns
Micro Services Architecture
Enterprise Integration in Cloud Native Microservices Architectures

More from WSO2 (20)

PDF
Demystifying CMS-0057-F - Compliance Made Seamless with WSO2
PDF
Quantum Threats Are Closer Than You Think – Act Now to Stay Secure
PDF
Modern Platform Engineering with Choreo - The AI-Native Internal Developer Pl...
PDF
Application Modernization with Choreo - The AI-Native Internal Developer Plat...
PDF
Build Smarter, Deliver Faster with Choreo - An AI Native Internal Developer P...
PDF
Platformless Modernization with Choreo.pdf
PDF
Application Modernization with Choreo for the BFSI Sector
PDF
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
PDF
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
PPTX
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
PPTX
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
PPTX
WSO2Con 2025 - Building Secure Customer Experience Apps
PPTX
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
PPTX
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
PPTX
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
PPTX
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
PPTX
WSO2Con 2025 - Architecting Cloud-Native Applications
PDF
Mastering Intelligent Digital Experiences with Platformless Modernization
PDF
Accelerate Enterprise Software Engineering with Platformless
PDF
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
Demystifying CMS-0057-F - Compliance Made Seamless with WSO2
Quantum Threats Are Closer Than You Think – Act Now to Stay Secure
Modern Platform Engineering with Choreo - The AI-Native Internal Developer Pl...
Application Modernization with Choreo - The AI-Native Internal Developer Plat...
Build Smarter, Deliver Faster with Choreo - An AI Native Internal Developer P...
Platformless Modernization with Choreo.pdf
Application Modernization with Choreo for the BFSI Sector
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2Con 2025 - Architecting Cloud-Native Applications
Mastering Intelligent Digital Experiences with Platformless Modernization
Accelerate Enterprise Software Engineering with Platformless
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation

Recently uploaded (20)

PDF
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Machine learning based COVID-19 study performance prediction
PDF
cuic standard and advanced reporting.pdf
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PDF
Unlocking AI with Model Context Protocol (MCP)
PPTX
Big Data Technologies - Introduction.pptx
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Approach and Philosophy of On baking technology
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Spectral efficient network and resource selection model in 5G networks
Shreyas Phanse Resume: Experienced Backend Engineer | Java • Spring Boot • Ka...
The AUB Centre for AI in Media Proposal.docx
Chapter 3 Spatial Domain Image Processing.pdf
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Digital-Transformation-Roadmap-for-Companies.pptx
Review of recent advances in non-invasive hemoglobin estimation
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Machine learning based COVID-19 study performance prediction
cuic standard and advanced reporting.pdf
CIFDAQ's Market Insight: SEC Turns Pro Crypto
20250228 LYD VKU AI Blended-Learning.pptx
Understanding_Digital_Forensics_Presentation.pptx
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
Unlocking AI with Model Context Protocol (MCP)
Big Data Technologies - Introduction.pptx
The Rise and Fall of 3GPP – Time for a Sabbatical?
Approach and Philosophy of On baking technology
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Spectral efficient network and resource selection model in 5G networks

WSO2Con EU 2016: Understanding Microservice Architecture