SlideShare a Scribd company logo
WSO2 ESB Integration with REST
Dushan Abeyruwan
Associate Tech Lead, Integration Tech Group
Ravi Undupitiya
Software Engineer, Integration Tech Group
About WSO2
•  Providing the only complete open source componentized cloud
platform
–  Dedicated to removing all the stumbling blocks to enterprise agility
–  Enabling you to focus on business logic and business value
•  Recognized by leading analyst firms as visionaries and leaders
–  Gartner cites WSO2 as visionaries in all 3 categories of application
infrastructure
–  Forrester places WSO2 in top 2 for API Management
•  Global corporation with offices in USA, UK & Sri Lanka
–  200+ employees and growing
•  Business model of selling comprehensive support &
maintenance for our products
150+ globally positioned support customers
Background	
  
•  Service	
  Oriented	
  Architecture	
  (SOA)	
  
–  A	
  style	
  of	
  so:ware	
  architecture	
  that	
  is	
  modular,	
  distributed	
  and	
  
loosely	
  coupled.	
  
–  ComponenBzaBon	
  –	
  The	
  main	
  driver	
  of	
  SOA	
  
–  Business	
  FuncBonaliBes	
  are	
  implemented	
  in	
  different	
  Business	
  
Components	
  
–  Business	
  Components	
  provide	
  their	
  funcBonality	
  to	
  its	
  consumers	
  
as	
  a	
  ‘Service’	
  with	
  the	
  well-­‐defined	
  service	
  interfaces.	
  
	
  
Background	
  
•  Enterprise	
  Service	
  Bus	
  (ESB)	
  
–  An	
  ESB	
  is	
  a	
  middleware	
  soluBon	
  that	
  enables	
  interoperability	
  
among	
  heterogeneous	
  environments	
  using	
  a	
  service-­‐oriented	
  
model.	
  
–  Stateless	
  and	
  Seamless	
  IntegraBon	
  
–  Standard	
  Protocols	
  –	
  SOAP,	
  REST,	
  JSON	
  etc.	
  
–  Transports	
  –	
  HTTP/S,	
  JMS,	
  TCP,	
  VFS	
  etc.	
  
	
  
Source : http://graegert.com/programming/no-soa-criticism-somewhere
Under	
  the	
  Hood:	
  Apache	
  Synapse	
  
•  A	
  lightweight,	
  open	
  source	
  ESB	
  implementaBon	
  from	
  the	
  
ASF	
  :	
  hXp://synapse.apache.org	
  
•  Makes	
  up	
  the	
  mediaBon	
  engine	
  of	
  WSO2	
  ESB	
  
•  MulBthreaded	
  and	
  asynchronous	
  message	
  processing	
  core	
  
•  Based	
  on	
  a	
  number	
  of	
  well	
  known	
  open	
  source	
  projects	
  (eg:	
  
Axis2,	
  HXp	
  Core)	
  
 
• 	
  	
  REpresentaBonal	
  State	
  Transfer	
  	
  
• 	
  	
  An	
  architectural	
  Style	
  –	
  Not	
  a	
  Standard	
  	
  
• 	
  	
  RESTful	
  applicaBons	
  use	
  HTTP	
  requests	
  to	
  	
  
•  post	
  data	
  (create	
  and/or	
  update)	
  	
  
•  read	
  data	
  (e.g.,	
  make	
  queries)	
  	
  
•  Delete	
  data.	
  	
  
• 	
  	
  REST	
  uses	
  HTTP	
  for	
  CRUD	
  (Create/Read/Update/Delete)	
  
operaBons.	
  	
  
Eg:	
  TwiXer	
  REST	
  API	
  	
  
•	
  	
  hXps://dev.twiXer.com/docs/api/1.1	
  	
  
	
  
What	
  is	
  REST?	
  
“How	
  OrganizaBons	
  thinks	
  RESTFul	
  Apps”	
  
“Hang	
  in	
  There	
  SOAP”	
  
Moral	
  of	
  the	
  Story…	
  
• 	
  	
  Replacing	
  exisBng	
  technologies	
  is	
  not	
  easy	
  
• 	
  	
  Every	
  technology	
  has	
  its	
  own	
  strengths	
  and	
  
weaknesses	
  
– Despite	
  its	
  arcane	
  terminology,	
  the	
  structured	
  
descripBon	
  capabiliBes	
  of	
  the	
  WSDL	
  standard	
  is	
  
being	
  praised	
  even	
  by	
  hard-­‐core	
  fans	
  of	
  REST	
  
– No	
  technology	
  can	
  be	
  designated	
  “universally	
  
superior”	
  
	
  
REST API
•  Exposing	
  RESTful	
  APIs	
  	
  
•  A	
  easy	
  way	
  to	
  expose	
  exisBng	
  SOAP	
  services	
  over	
  REST	
  
•  REST	
  à	
  SOAP	
  conversion	
  
•  Mainly	
  used	
  in	
  WSO2	
  API	
  Manager	
  	
  
	
  
HTTP Based RESTful Interactions
IntegraBng	
  RESTful	
  ApplicaBons	
  
Demo	
  
REST APIs
l  An API is similar to a web application hosted on the
ESB
l  Anchored at a specific URL path (context)
l  /test
l  /dictionary
l  /foo/bar
l  Can be bound to a specific host and a port
l  Contains one or more resources
Resources
l  A RESTful resource exposed over HTTP
l  Similar to a proxy service but focuses on REST
l  Can be associated with
l  A set of HTTP methods
-  GET only, GET and POST only, All HTTP
methods
l  A specific content type
-  application/xml, application/json
l  A particular class of clients (user agents)
Dispatching Requests to a Resource
l  URL patterns
l  Reg-Ex match
l  /test/*
l  Extension match
l  *.jsp
l  Exact match
l  /test/index.jsp
l  URI templates
l  /dictionary/{character}/{word}
l  /accounts/{accountId}/{operation}
l  HTTP Verbs (GET/PUT/POST/OPTIONS)
APIs and Resources
APIs and Resources
/people
APIs and Resources
/people
GET
/staff/*
APIs and Resources
/people
GET
/staff/*
POST
/add/{name}
Resource Examples
API Example
API Demo: Coffee Shop
Coffee Shop: URL Schemes
l  /order/{order-id}
–  GET, POST
–  Add/Update/View orders
l  /orders/
–  GET
–  Retrieve Pending Order List
Coffee Shop: Add Order
• POST /order/
<?xml version="1.0" encoding="UTF-8"?>
<order>
<drink>Caffe Misto</drink>
</order>
curl -v -d @order.xml -H "Content-type: application/xml" http://127.0.0.1:8281/order
Coffee Shop: Get Order
• GET /order/{order-id}
curl –v http://127.0.0.1:8281/order/{order-id}
Coffee Shop: List Orders
• GET /orders/
curl -v http://127.0.0.1:8281/orders
API Demo: Coffee Shop
Complete Tutorial: http://bit.ly/PZz6RZ
HTTP Endpoint
•  New in WSO2ESB 4.7.0
•  Enhances RESTful support. Can be used with SOAP WS.
•  Support for HTTP verbs and URI-Template variables
•  An example:
•  Exposing Twitter Search API
OAuth: REST security done right
•  Adheres to statelessness in REST architecture.
API Management Goals
l  Service	
  provider	
  objecBves	
  
l  Define	
  APIs	
  
l  Define	
  security	
  requirements	
  and	
  SLAs	
  
l  Monitor	
  API	
  usage	
  and	
  SLAs	
  
	
  
l  Service	
  consumer	
  objecBves	
  
l  Discover	
  and	
  browse	
  APIs	
  
l  Sign	
  up	
  and	
  obtain	
  API	
  keys	
  
l  Consume	
  APIs	
  using	
  the	
  obtained	
  keys	
  
l  Monitor	
  API	
  usage	
  and	
  SLAs	
  
Engage with WSO2
•  Helping you get the most out of your deployments
•  From project evaluation and inception to development
and going into production, WSO2 is your partner in
ensuring 100% project success
Ad

More Related Content

What's hot (20)

Domain-Driven Design
Domain-Driven DesignDomain-Driven Design
Domain-Driven Design
Andriy Buday
 
Architect your app modernization journey with containers on Microsoft Azure
Architect your app modernization journey with containers on Microsoft AzureArchitect your app modernization journey with containers on Microsoft Azure
Architect your app modernization journey with containers on Microsoft Azure
Davide Benvegnù
 
Aws migration case study_blr_meetup
Aws migration case study_blr_meetupAws migration case study_blr_meetup
Aws migration case study_blr_meetup
Madhusoodanan K Madhavan
 
Enterprise Integration with the WSO2 ESB
Enterprise Integration with the WSO2 ESB Enterprise Integration with the WSO2 ESB
Enterprise Integration with the WSO2 ESB
WSO2
 
Microservice architecture design principles
Microservice architecture design principlesMicroservice architecture design principles
Microservice architecture design principles
Sanjoy Kumar Roy
 
Event Sourcing & CQRS, Kafka, Rabbit MQ
Event Sourcing & CQRS, Kafka, Rabbit MQEvent Sourcing & CQRS, Kafka, Rabbit MQ
Event Sourcing & CQRS, Kafka, Rabbit MQ
Araf Karsh Hamid
 
Microservices
MicroservicesMicroservices
Microservices
SmartBear
 
WSO2 API microgateway introduction
WSO2 API microgateway introductionWSO2 API microgateway introduction
WSO2 API microgateway introduction
Chanaka Fernando
 
Integration Solution Patterns
Integration Solution Patterns Integration Solution Patterns
Integration Solution Patterns
WSO2
 
Enterprise Software Architecture styles
Enterprise Software Architecture stylesEnterprise Software Architecture styles
Enterprise Software Architecture styles
Araf Karsh Hamid
 
API Gateway Use Cases​ for Kubernetes​
API Gateway Use Cases​ for Kubernetes​API Gateway Use Cases​ for Kubernetes​
API Gateway Use Cases​ for Kubernetes​
NGINX, Inc.
 
REST API and CRUD
REST API and CRUDREST API and CRUD
REST API and CRUD
Prem Sanil
 
Enterprise Application Integration Technologies
Enterprise Application Integration TechnologiesEnterprise Application Integration Technologies
Enterprise Application Integration Technologies
Peter R. Egli
 
Asynchronous API in Java8, how to use CompletableFuture
Asynchronous API in Java8, how to use CompletableFutureAsynchronous API in Java8, how to use CompletableFuture
Asynchronous API in Java8, how to use CompletableFuture
José Paumard
 
WSO2 Enterprise Service Bus - Product Overview
WSO2 Enterprise Service Bus - Product OverviewWSO2 Enterprise Service Bus - Product Overview
WSO2 Enterprise Service Bus - Product Overview
WSO2
 
Domain Driven Design and Hexagonal Architecture
Domain Driven Design and Hexagonal ArchitectureDomain Driven Design and Hexagonal Architecture
Domain Driven Design and Hexagonal Architecture
Crishantha Nanayakkara
 
Openshift presentation
Openshift presentationOpenshift presentation
Openshift presentation
Armağan Ersöz
 
An introduction to Microservices
An introduction to MicroservicesAn introduction to Microservices
An introduction to Microservices
Cisco DevNet
 
Wso2 tutorial
Wso2 tutorialWso2 tutorial
Wso2 tutorial
Armando Ramirez Vila
 
Why Microservice
Why Microservice Why Microservice
Why Microservice
Kelvin Yeung
 
Domain-Driven Design
Domain-Driven DesignDomain-Driven Design
Domain-Driven Design
Andriy Buday
 
Architect your app modernization journey with containers on Microsoft Azure
Architect your app modernization journey with containers on Microsoft AzureArchitect your app modernization journey with containers on Microsoft Azure
Architect your app modernization journey with containers on Microsoft Azure
Davide Benvegnù
 
Enterprise Integration with the WSO2 ESB
Enterprise Integration with the WSO2 ESB Enterprise Integration with the WSO2 ESB
Enterprise Integration with the WSO2 ESB
WSO2
 
Microservice architecture design principles
Microservice architecture design principlesMicroservice architecture design principles
Microservice architecture design principles
Sanjoy Kumar Roy
 
Event Sourcing & CQRS, Kafka, Rabbit MQ
Event Sourcing & CQRS, Kafka, Rabbit MQEvent Sourcing & CQRS, Kafka, Rabbit MQ
Event Sourcing & CQRS, Kafka, Rabbit MQ
Araf Karsh Hamid
 
Microservices
MicroservicesMicroservices
Microservices
SmartBear
 
WSO2 API microgateway introduction
WSO2 API microgateway introductionWSO2 API microgateway introduction
WSO2 API microgateway introduction
Chanaka Fernando
 
Integration Solution Patterns
Integration Solution Patterns Integration Solution Patterns
Integration Solution Patterns
WSO2
 
Enterprise Software Architecture styles
Enterprise Software Architecture stylesEnterprise Software Architecture styles
Enterprise Software Architecture styles
Araf Karsh Hamid
 
API Gateway Use Cases​ for Kubernetes​
API Gateway Use Cases​ for Kubernetes​API Gateway Use Cases​ for Kubernetes​
API Gateway Use Cases​ for Kubernetes​
NGINX, Inc.
 
REST API and CRUD
REST API and CRUDREST API and CRUD
REST API and CRUD
Prem Sanil
 
Enterprise Application Integration Technologies
Enterprise Application Integration TechnologiesEnterprise Application Integration Technologies
Enterprise Application Integration Technologies
Peter R. Egli
 
Asynchronous API in Java8, how to use CompletableFuture
Asynchronous API in Java8, how to use CompletableFutureAsynchronous API in Java8, how to use CompletableFuture
Asynchronous API in Java8, how to use CompletableFuture
José Paumard
 
WSO2 Enterprise Service Bus - Product Overview
WSO2 Enterprise Service Bus - Product OverviewWSO2 Enterprise Service Bus - Product Overview
WSO2 Enterprise Service Bus - Product Overview
WSO2
 
Domain Driven Design and Hexagonal Architecture
Domain Driven Design and Hexagonal ArchitectureDomain Driven Design and Hexagonal Architecture
Domain Driven Design and Hexagonal Architecture
Crishantha Nanayakkara
 
An introduction to Microservices
An introduction to MicroservicesAn introduction to Microservices
An introduction to Microservices
Cisco DevNet
 

Similar to WSO2 ESB Integration with REST (20)

Role of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EIRole of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EI
WSO2
 
REST - Why, When and How? at AMIS25
REST - Why, When and How? at AMIS25REST - Why, When and How? at AMIS25
REST - Why, When and How? at AMIS25
Jon Petter Hjulstad
 
REST-API's for architects and managers
REST-API's for architects and managersREST-API's for architects and managers
REST-API's for architects and managers
Patrick Savalle
 
Exploring the WSO2 ESB 4.7
Exploring the WSO2 ESB 4.7 Exploring the WSO2 ESB 4.7
Exploring the WSO2 ESB 4.7
WSO2
 
OUGN 2016: Experiences with REST support on OSB/SOA Suite
OUGN 2016: Experiences with REST support on OSB/SOA SuiteOUGN 2016: Experiences with REST support on OSB/SOA Suite
OUGN 2016: Experiences with REST support on OSB/SOA Suite
Jon Petter Hjulstad
 
Hia 1691-using iib-to_support_api_economy
Hia 1691-using iib-to_support_api_economyHia 1691-using iib-to_support_api_economy
Hia 1691-using iib-to_support_api_economy
Andrew Coleman
 
Databasecentricapisonthecloudusingplsqlandnodejscon3153oow2016 160922021655
Databasecentricapisonthecloudusingplsqlandnodejscon3153oow2016 160922021655Databasecentricapisonthecloudusingplsqlandnodejscon3153oow2016 160922021655
Databasecentricapisonthecloudusingplsqlandnodejscon3153oow2016 160922021655
Getting value from IoT, Integration and Data Analytics
 
Mini-Training: Let's have a rest
Mini-Training: Let's have a restMini-Training: Let's have a rest
Mini-Training: Let's have a rest
Betclic Everest Group Tech Team
 
Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)
Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)
Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)
Pete Morano
 
Restful web services rule financial
Restful web services   rule financialRestful web services   rule financial
Restful web services rule financial
Rule_Financial
 
Unerstanding and Using RESTful APIs
Unerstanding and Using RESTful APIsUnerstanding and Using RESTful APIs
Unerstanding and Using RESTful APIs
SocialDevCamp Chicago
 
KaTe RESTful adapter for SAP Process Integration: Introduction
KaTe RESTful adapter for SAP Process Integration: IntroductionKaTe RESTful adapter for SAP Process Integration: Introduction
KaTe RESTful adapter for SAP Process Integration: Introduction
Kate_RESTful
 
Wso2 esb
Wso2 esbWso2 esb
Wso2 esb
Kevin Jeremy Valdez Navarrete
 
Wso2 esb
Wso2 esbWso2 esb
Wso2 esb
Kevin Jeremy Valdez Navarrete
 
Build Modern Web Apps Using ASP.NET Web API and AngularJS
Build Modern Web Apps Using ASP.NET Web API and AngularJSBuild Modern Web Apps Using ASP.NET Web API and AngularJS
Build Modern Web Apps Using ASP.NET Web API and AngularJS
Taiseer Joudeh
 
SharePoint 2013 - What's New
SharePoint 2013 - What's NewSharePoint 2013 - What's New
SharePoint 2013 - What's New
AdventosConsulting
 
Webbinar slides
Webbinar slidesWebbinar slides
Webbinar slides
WSO2
 
ASP.NET Mvc 4 web api
ASP.NET Mvc 4 web apiASP.NET Mvc 4 web api
ASP.NET Mvc 4 web api
Tiago Knoch
 
REST API Recommendations
REST API RecommendationsREST API Recommendations
REST API Recommendations
Jeelani Shaik
 
Best practices and advantages of REST APIs
Best practices and advantages of REST APIsBest practices and advantages of REST APIs
Best practices and advantages of REST APIs
Aparna Sharma
 
Role of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EIRole of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EI
WSO2
 
REST - Why, When and How? at AMIS25
REST - Why, When and How? at AMIS25REST - Why, When and How? at AMIS25
REST - Why, When and How? at AMIS25
Jon Petter Hjulstad
 
REST-API's for architects and managers
REST-API's for architects and managersREST-API's for architects and managers
REST-API's for architects and managers
Patrick Savalle
 
Exploring the WSO2 ESB 4.7
Exploring the WSO2 ESB 4.7 Exploring the WSO2 ESB 4.7
Exploring the WSO2 ESB 4.7
WSO2
 
OUGN 2016: Experiences with REST support on OSB/SOA Suite
OUGN 2016: Experiences with REST support on OSB/SOA SuiteOUGN 2016: Experiences with REST support on OSB/SOA Suite
OUGN 2016: Experiences with REST support on OSB/SOA Suite
Jon Petter Hjulstad
 
Hia 1691-using iib-to_support_api_economy
Hia 1691-using iib-to_support_api_economyHia 1691-using iib-to_support_api_economy
Hia 1691-using iib-to_support_api_economy
Andrew Coleman
 
Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)
Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)
Understanding and Using Rest APIs (SocialDevCamp Chicago 2009)
Pete Morano
 
Restful web services rule financial
Restful web services   rule financialRestful web services   rule financial
Restful web services rule financial
Rule_Financial
 
KaTe RESTful adapter for SAP Process Integration: Introduction
KaTe RESTful adapter for SAP Process Integration: IntroductionKaTe RESTful adapter for SAP Process Integration: Introduction
KaTe RESTful adapter for SAP Process Integration: Introduction
Kate_RESTful
 
Build Modern Web Apps Using ASP.NET Web API and AngularJS
Build Modern Web Apps Using ASP.NET Web API and AngularJSBuild Modern Web Apps Using ASP.NET Web API and AngularJS
Build Modern Web Apps Using ASP.NET Web API and AngularJS
Taiseer Joudeh
 
Webbinar slides
Webbinar slidesWebbinar slides
Webbinar slides
WSO2
 
ASP.NET Mvc 4 web api
ASP.NET Mvc 4 web apiASP.NET Mvc 4 web api
ASP.NET Mvc 4 web api
Tiago Knoch
 
REST API Recommendations
REST API RecommendationsREST API Recommendations
REST API Recommendations
Jeelani Shaik
 
Best practices and advantages of REST APIs
Best practices and advantages of REST APIsBest practices and advantages of REST APIs
Best practices and advantages of REST APIs
Aparna Sharma
 
Ad

More from WSO2 (20)

Platformless Modernization with Choreo.pdf
Platformless Modernization with Choreo.pdfPlatformless Modernization with Choreo.pdf
Platformless Modernization with Choreo.pdf
WSO2
 
Application Modernization with Choreo for the BFSI Sector
Application Modernization with Choreo for the BFSI SectorApplication Modernization with Choreo for the BFSI Sector
Application Modernization with Choreo for the BFSI Sector
WSO2
 
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
Choreo - The AI-Native Internal Developer Platform as a Service: OverviewChoreo - The AI-Native Internal Developer Platform as a Service: Overview
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
WSO2
 
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
WSO2
 
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2
 
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2
 
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2Con 2025 - Building Secure Customer Experience AppsWSO2Con 2025 - Building Secure Customer Experience Apps
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2
 
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2
 
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on CodeWSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2
 
WSO2Con 2025 - Architecting Cloud-Native Applications
WSO2Con 2025 - Architecting Cloud-Native ApplicationsWSO2Con 2025 - Architecting Cloud-Native Applications
WSO2Con 2025 - Architecting Cloud-Native Applications
WSO2
 
Mastering Intelligent Digital Experiences with Platformless Modernization
Mastering Intelligent Digital Experiences with Platformless ModernizationMastering Intelligent Digital Experiences with Platformless Modernization
Mastering Intelligent Digital Experiences with Platformless Modernization
WSO2
 
Accelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with PlatformlessAccelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with Platformless
WSO2
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdf
WSO2
 
Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2
WSO2
 
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data PlatformLess Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
WSO2
 
Modernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using BallerinaModernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using Ballerina
WSO2
 
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2
 
Platformless Modernization with Choreo.pdf
Platformless Modernization with Choreo.pdfPlatformless Modernization with Choreo.pdf
Platformless Modernization with Choreo.pdf
WSO2
 
Application Modernization with Choreo for the BFSI Sector
Application Modernization with Choreo for the BFSI SectorApplication Modernization with Choreo for the BFSI Sector
Application Modernization with Choreo for the BFSI Sector
WSO2
 
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
Choreo - The AI-Native Internal Developer Platform as a Service: OverviewChoreo - The AI-Native Internal Developer Platform as a Service: Overview
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
WSO2
 
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
WSO2
 
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2
 
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2
 
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2Con 2025 - Building Secure Customer Experience AppsWSO2Con 2025 - Building Secure Customer Experience Apps
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2
 
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2
 
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on CodeWSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2
 
WSO2Con 2025 - Architecting Cloud-Native Applications
WSO2Con 2025 - Architecting Cloud-Native ApplicationsWSO2Con 2025 - Architecting Cloud-Native Applications
WSO2Con 2025 - Architecting Cloud-Native Applications
WSO2
 
Mastering Intelligent Digital Experiences with Platformless Modernization
Mastering Intelligent Digital Experiences with Platformless ModernizationMastering Intelligent Digital Experiences with Platformless Modernization
Mastering Intelligent Digital Experiences with Platformless Modernization
WSO2
 
Accelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with PlatformlessAccelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with Platformless
WSO2
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdf
WSO2
 
Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2
WSO2
 
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data PlatformLess Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
WSO2
 
Modernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using BallerinaModernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using Ballerina
WSO2
 
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2
 
Ad

WSO2 ESB Integration with REST

  • 1. WSO2 ESB Integration with REST Dushan Abeyruwan Associate Tech Lead, Integration Tech Group Ravi Undupitiya Software Engineer, Integration Tech Group
  • 2. About WSO2 •  Providing the only complete open source componentized cloud platform –  Dedicated to removing all the stumbling blocks to enterprise agility –  Enabling you to focus on business logic and business value •  Recognized by leading analyst firms as visionaries and leaders –  Gartner cites WSO2 as visionaries in all 3 categories of application infrastructure –  Forrester places WSO2 in top 2 for API Management •  Global corporation with offices in USA, UK & Sri Lanka –  200+ employees and growing •  Business model of selling comprehensive support & maintenance for our products
  • 3. 150+ globally positioned support customers
  • 4. Background   •  Service  Oriented  Architecture  (SOA)   –  A  style  of  so:ware  architecture  that  is  modular,  distributed  and   loosely  coupled.   –  ComponenBzaBon  –  The  main  driver  of  SOA   –  Business  FuncBonaliBes  are  implemented  in  different  Business   Components   –  Business  Components  provide  their  funcBonality  to  its  consumers   as  a  ‘Service’  with  the  well-­‐defined  service  interfaces.    
  • 5. Background   •  Enterprise  Service  Bus  (ESB)   –  An  ESB  is  a  middleware  soluBon  that  enables  interoperability   among  heterogeneous  environments  using  a  service-­‐oriented   model.   –  Stateless  and  Seamless  IntegraBon   –  Standard  Protocols  –  SOAP,  REST,  JSON  etc.   –  Transports  –  HTTP/S,  JMS,  TCP,  VFS  etc.     Source : http://graegert.com/programming/no-soa-criticism-somewhere
  • 6. Under  the  Hood:  Apache  Synapse   •  A  lightweight,  open  source  ESB  implementaBon  from  the   ASF  :  hXp://synapse.apache.org   •  Makes  up  the  mediaBon  engine  of  WSO2  ESB   •  MulBthreaded  and  asynchronous  message  processing  core   •  Based  on  a  number  of  well  known  open  source  projects  (eg:   Axis2,  HXp  Core)  
  • 7.   •     REpresentaBonal  State  Transfer     •     An  architectural  Style  –  Not  a  Standard     •     RESTful  applicaBons  use  HTTP  requests  to     •  post  data  (create  and/or  update)     •  read  data  (e.g.,  make  queries)     •  Delete  data.     •     REST  uses  HTTP  for  CRUD  (Create/Read/Update/Delete)   operaBons.     Eg:  TwiXer  REST  API     •    hXps://dev.twiXer.com/docs/api/1.1       What  is  REST?  
  • 8. “How  OrganizaBons  thinks  RESTFul  Apps”  
  • 9. “Hang  in  There  SOAP”  
  • 10. Moral  of  the  Story…   •     Replacing  exisBng  technologies  is  not  easy   •     Every  technology  has  its  own  strengths  and   weaknesses   – Despite  its  arcane  terminology,  the  structured   descripBon  capabiliBes  of  the  WSDL  standard  is   being  praised  even  by  hard-­‐core  fans  of  REST   – No  technology  can  be  designated  “universally   superior”    
  • 11. REST API •  Exposing  RESTful  APIs     •  A  easy  way  to  expose  exisBng  SOAP  services  over  REST   •  REST  à  SOAP  conversion   •  Mainly  used  in  WSO2  API  Manager      
  • 12. HTTP Based RESTful Interactions
  • 14. REST APIs l  An API is similar to a web application hosted on the ESB l  Anchored at a specific URL path (context) l  /test l  /dictionary l  /foo/bar l  Can be bound to a specific host and a port l  Contains one or more resources
  • 15. Resources l  A RESTful resource exposed over HTTP l  Similar to a proxy service but focuses on REST l  Can be associated with l  A set of HTTP methods -  GET only, GET and POST only, All HTTP methods l  A specific content type -  application/xml, application/json l  A particular class of clients (user agents)
  • 16. Dispatching Requests to a Resource l  URL patterns l  Reg-Ex match l  /test/* l  Extension match l  *.jsp l  Exact match l  /test/index.jsp l  URI templates l  /dictionary/{character}/{word} l  /accounts/{accountId}/{operation} l  HTTP Verbs (GET/PUT/POST/OPTIONS)
  • 24. Coffee Shop: URL Schemes l  /order/{order-id} –  GET, POST –  Add/Update/View orders l  /orders/ –  GET –  Retrieve Pending Order List
  • 25. Coffee Shop: Add Order • POST /order/ <?xml version="1.0" encoding="UTF-8"?> <order> <drink>Caffe Misto</drink> </order> curl -v -d @order.xml -H "Content-type: application/xml" http://127.0.0.1:8281/order
  • 26. Coffee Shop: Get Order • GET /order/{order-id} curl –v http://127.0.0.1:8281/order/{order-id}
  • 27. Coffee Shop: List Orders • GET /orders/ curl -v http://127.0.0.1:8281/orders
  • 28. API Demo: Coffee Shop Complete Tutorial: http://bit.ly/PZz6RZ
  • 29. HTTP Endpoint •  New in WSO2ESB 4.7.0 •  Enhances RESTful support. Can be used with SOAP WS. •  Support for HTTP verbs and URI-Template variables •  An example: •  Exposing Twitter Search API
  • 30. OAuth: REST security done right •  Adheres to statelessness in REST architecture.
  • 31. API Management Goals l  Service  provider  objecBves   l  Define  APIs   l  Define  security  requirements  and  SLAs   l  Monitor  API  usage  and  SLAs     l  Service  consumer  objecBves   l  Discover  and  browse  APIs   l  Sign  up  and  obtain  API  keys   l  Consume  APIs  using  the  obtained  keys   l  Monitor  API  usage  and  SLAs  
  • 32. Engage with WSO2 •  Helping you get the most out of your deployments •  From project evaluation and inception to development and going into production, WSO2 is your partner in ensuring 100% project success