WSO2	Integra-on	Pla1orm	
Deep	Dive	
Malaka	Silva	
Senior	Technical	Lead	
WSO2	
Isuru	Udana	
Associate	Technical	Lead	
WSO2
Agenda	
	
•  Introduc-on	to	WSO2	Integra-on	Pla1orm	
•  Fundamentals	of	WSO2	ESB	
•  Demonstra-on		
•  Q&A
Evolu-on	of	Integra-on	
	
Point	to	Point	Integra-on	
	
	
●  Custom	code,	data	formats	for	
majority	of	integra-on	(	data	
extrac-on,	business	rule	processing,	
data	loading)	
	
●  Costly	over	-me	(maintenance,	
complexity)	
	
●  Tight	Coupling	
	
●  Scalability	is	an	issue	
	
●  Less	reusability
Evolu-on	of	Integra-on	
•  Rise	of	SOA	and	ESB	
– Avoid	point	to	point	integra-on	with	an		
ESB
Connected	Business	
•  An	internally	and	externally	connected		
business.	
Customers	
Poten-al		
Customers/Partners	
Employees	
Partners	
Internal		
Systems	
External		
Systems	
Image	courtesy		hUp://jdamico.net/wp---content/uploads/2010/04/collaborate---with---B2B---channel---
partners.jpg
Connected	Business	and	Integra-on	
•  Integra-on	is	a	key	factor	for	having	fric-onless		
interac-ons,	inside	and	outside	the		organiza-on.
WSO2	Integra-on	Pla<orm
Integra-on	and	APIs	-	The	Close	Cousins
WSO2	Integra-on	+	API	Management	Pla<orm
WSO2	ESB	
•  A	lightweight,	high	performance	ESB	
•  Feature	rich	and	standards	compliant	
–  SOAP	and	WS-*	standards	
–  REST	support	
•  Domain	specific	protocol	support	(eg:	FIX,	HL7)	
•  User	friendly	and	highly	extensible	
•  100%	free	and	open	source	with	commercial	support
Key	Features	-	Rou-ng
Key	Features	-	Filtering
Key	Features	-	Transforma-on
Key	Features	–	Protocol	Switching
Key	Features	–	Load	Balancing
Key	Features	–	Quality	of	Service
Key	Features	-	Service	Orchestra-on	
•  Orchestra-ng/Combining	mul-ple	Services
Fundamentals	of	WSO2	ESB	
•  Understanding	ESB	message	flow
Fundamentals	of	WSO2	ESB
Message	Processing	Units	
-  Sequences,	mediators	
Message	Entry	Points	
-  Proxy	Services,	APIs,	Inbound	
endpoints.	
Message	Exit	Points	
-  Endpoints	
Fundamentals	of	WSO2	ESB
Message	Processing	Units	
Mediators
Mediators	
•  Transforma-on	Mediators	
•  Filters,	Switches,	Iterate,	Aggregate,	Clone	
•  Property	Mediator	
•  Script	Mediators	
•  Custom	Mediators
Some	Mediators	
Name	 Descrip-on	
Log	Mediator	 Logs	full	or	part	of	the	message,	at	various	severity	levels	(	Trace,	Debug,	etc)	
Sequence	Mediator	 Invokes	exis-ng	sequence	-	Sequence	name	can	be	sta-c	or	dynamic	
Send	Mediator	 Sends	a	message	out,	using	sta-c	informa-on	or	endpoint	defini-on.	
Callout	Mediator	 Performs	a	blocking	external	service	invoca-on.	
Switch	Mediator	 Evaluates	messages	contents	against	regular	expression	and	invokes	the	corresponding	
mediator	(switch-case-default)	
Validate	Mediator	 Validates	message	or	parts	of	message	against	XML	schema	(schema	can	be	local	or	in	
registry)	
Drop	Mediator	 Stops	processing	of	current	message	
Fault	Mediator	 Transforms	current	message	into	custom	Fault	message
Sequences
Programming	Model	
Client	 Service	
In	Sequence	
Out	Sequence	
Fault	Seq.	
1	
2	
3	
6	 5	 4	
!
Message	Processing	Units	
-  Sequences,	mediators	
Message	Entry	Points	
-  Proxy	Services,	APIs,	Inbound	
endpoints.	
Message	Exit	Points	
-  Endpoints	
Fundamentals	of	WSO2	ESB
Message	Entry	Points	
Messages can be injected into sequences through the
following interfaces:
27	
Service	
o  Proxy Services
o  APIs
o  Inbound Endpoints
o  Tasks
Proxy	Services	
o  Acts	like	a	virtual	service.		
o  Receives	messages	and	mediates	them	before	sending	them	to	the	endpoint	
(usually	an	actual	service)	
28	
Client	 Service	
In	Sequence	
Out	Sequence	
Fault	Seq.	
1	
2	
3	
6	 5	 4	
!
Service	
APIs	(hUp	services)	
o  APIs	can	accept	REST	messages	which	allow	clients	to	provide	addi-onal	
informa-on	on	how	to	manage	the	message	
o  Unmanaged	API	(API-Manager	for	managed	APIs)			
29	
API
Inbound	Endpoints	
•  Crea-ng	inbound	messaging	channels	
dynamically.	
–  Listening	Inbound	–	HTTP,	HL7,	TCP	
–  Polling	Inbound	–	JMS,	File/VFS	
	
•  Injects	the	inbound	messages	into	an	
ESB	message	flow.
Coordina-on	
	-	In-order	delivery	with	single	consumer	
Inbound	Endpoints
Coordina-on	
	-	Mul-ple	Consumers	
Inbound	Endpoints
Service	
Tasks	
Allow	configura-on	of	scheduled	jobs	to	execute	internal/external	commands	
o 		Inject	a	message	into	a	proxy	service,	Main	sequence	or	a	named	sequence	
o 		Example:	
o ESB	allows	scheduled	tasks	to	go	fetch	data	
33
Task	Coordina-on	
Tasks
Message	Processing	Units	
-  Sequences,	mediators	
Message	Entry	Points	
-  Proxy	Services,	APIs,	Inbound	
endpoints	
Message	Exit	Points	
-  Endpoints	
Fundamentals	of	WSO2	ESB
Endpoints	
•  Logical	representa-on	of	one	or	more	real	backend	
service,	jms	queue	etc.	
•  Address,	HTTP	Endpoints		–	A	logical	endpoint	for	an	
exis-ng	BE	service	
•  Load	balancing	/	Failover	–	Group	of	endpoints	for	
exis-ng	BE	services
Connectors	
•  A	connector	is	a	ready	made	and	convenient	
tool	to	reach	publicly	available	web	API’s.	
•  ‘Cloud	to	Cloud’	and	‘Cloud	to	Enterprise’	
Integra-on	
•  ESB	Connector	Store	:	hUps://store.wso2.com/
•  Every connector is self-contained and
independent from ESB code
•  Dynamically plug in to ESB
•  Dynamic Tooling support with WSO2 Developer
Studio
•  You can write, ‘your own connector’ and just
plug it in
Connectors
Message	Store	and	Message	Processor	
•  Asynchronous/One-way	Messaging,	JMS	
•  Store	and	forward	
•  Guaranteed	Delivery	and	Rate	matching	
•  JMS	Message	broker	as	the	persistence	store	–	WSO2	MB,	Apache	
Ac-ve	MQ	etc.
Enterprise	Integra-on	PaUerns	
hUps://docs.wso2.com/display/Integra-onPaUerns/
Enterprise+Integra-on+PaUerns+with+WSO2+ESB
Tooling	Support	for	WSO2	ESB
WSO2	Integra-on	Pla<orm
WSO2	Data	Services	Server	
Painpoints:		
●  Different	data	stores	
●  Cumbersome	data	access/	
transforma-on	logic	
●  Business	logic	vs	Data	access	
logic	
●  Repe--ve	Code	
DSS:	
●  Well	defined	interfaces	(standard	based)	
●  Encapsulated	data	logic	
●  Configura-on	driven	
●  Loose	Coupling	between	App	&	Data	
stores	
●  Scale	as	a	separate	architectural	layer.
WSO2	Data	Services	Server	:	Features	
•  Mul-ple	Data	Sources	
•  Nested	Queries	
•  No-fica-ons	
•  Batch	Processing	
•  Distributed	Transac-ons
Use	Case	–	Phone	Retail		
•  A	phone	retail	business	wants	to	expose	its	phone	search	and		
buying	func-onali-es	to	its	mobile	applica-on	users.	
•  Mobile	phone	user	searches	for	all	the	available	phones	in	a		
store	with	a	specific	brand.	
•  Once	the	user	select	the	phone	with	matching	features,	he/she		
purchases	by	providing	required	informa-on	
•  The	customers	who	purchase	phones	will	be	added	to		
Salesforce	
•  WSO2	DAS	monitors	and	analyzes	the	stats	on	users	and		
phone	brands
Solu-on	Architecture
Searching	for	a	phone
Purchasing	a	phone
Phone	Search	
•  Conversion	from	JSON	to	XML	
•  Message	transforma-on	
•  Extrac-ng	values	from	incoming	message	
•  Invoking	endpoint	
•  Sending	response	with	XML	to	JSON		
conversion
Phone	Search
Phone	Search
Phone	Purchase	
•  Extract	informa-on	
•  Update	store	
•  Update	Salesforce	via	Salesforce	connector	
•  Stat	publishing
Phone	Purchase	
•  Extract	informa-on
Phone	Purchase	
•  Update	Store
Phone	Purchase	
•  Salesforce	Connector
Phone	Purchase	
•  Publishing	Sta-s-cs
DAS	Gadgets
WSO2	Integra-on	Pla<orm
WSO2	Business	Process	Server	
•  BPMN	2.0	
•  WS-BPEL	2.0	
•  WS-HumanTask	1.1	
•  BPEL4People
Human	Task	Support
WSO2	Integra-on	Pla<orm
WSO2	Message	Broker	
Unique	distributable,	fault	tolerant	and	scalable	enterprise	
message	broker	to	connect,	persist	and	reliably	distribute	
data,	event	informa-on	generated	from	mul-ple	systems,	
applica-ons	and	IoT	devices.
WSO2	MB	-	Advantages	
•  Integrate	easily	with	exis-ng	IT	Infrastructure	.	
•  Select	storage	based	on	messaging	demands	.	
•  Low	maintenance	through	minimum	deployment	
effort.	
•  Highly	interoperable	with	AMQP	clients.	
•  Effortlessly	handle	large	message	transfer.	
•  Seamless	feature	integra-on	with	WSO2	ESB.
Supported	Protocols	&	Specifica-ons	
	
•  JMS	(Java	Message	Service)	
•  A	Standard	Java	API	for	programmers	to	handle	
messaging	by	interac-ng	with	a	message	broker	
•  AMQP	(Advanced	Message	Queuing	Protocol)	
•  Open	Standard	for	passing	business	messages	
between	applica-ons	or	organiza-ons	
•  MQTT	(Message	Queuing	Telemetry	Transport)
WSO2	MB	-	Features	
•  Point	to	Point	(Queues)	
-	A	message	is	delivered	only	once	to	a	single	
consumer	
•  Publish/Subscribe	(Topics)	
-	Broadcast	a	message	to	all	the	subscribers
WSO2	MB	-	Features	
•  Distributed	Queues	
	-	Provides	strict	or	best	effort	support	for	in-order	delivery.
WSO2	MB	-	Features	
•  Durable	Subscrip-on	
	-	Same	topic	as	subscrip-on.	
					Subscriber	offline	>	Message	gets	queued	
									Subscriber	back	online	>	Messages	gerng	delivered
WSO2	MB	-	Features	
•  Share	Durable	Subscrip-on	
	-Purpose	of	load	balancing
WSO2	ESB	5.0	
What’s	Next	?	
•  Media-on	Debugger	
•  BeUer	Sta-s-cs	
•  Message	Tracer	
•  Websockets	
•  Data	Mapper
ESB	5.0	-	Media-on	Debugger	
What’s	Next	?
ESB	5.0	-	Message	Tracer	
What’s	Next	?
ESB	5.0	-	Media-on	Sta-s-cs	
What’s	Next	?
WSO2	Process	Center	
What’s	Next	?	
Process	
par-cipant	
Create	/	Improve	/	Standardize	
Search	/	
Browse	/	
Follow	
Develop	executable	
processes	
Executable	
process	is	
associated	
with	Process	
Center
WSO2	Gateway	
What’s	Next	?	
	
•  Ultra	high	performance	and	low	latency	HTTP/S	
messaging	
•  Supports	thousands	of	concurrent	connec-ons/clients	
•  Fastest	open	source	HTTP	messaging	gateway	
•  Lightweight	Message	Media-on	
•  Header-based	rou-ng	
•  Fully	configura-on	driven	
•  Lightweight	and	stateless	service	orchestra-on
Ques-ons	?
Thank	You

WSO2Con ASIA 2016: WSO2 Integration Platform Deep Dive