SlideShare a Scribd company logo
Enterprise Integration Patterns
&
Apache Camel
Milos Zubal
Waterford Tech. Meetup 26.09.2018
Who’s this?!
@MilosZubal
Software Engineer at
(we’re hiring! ;) )
11+ years of backend Java happiness
https://www.linkedin.com/in/miloszubal/
https://github.com/mzubal
https://twitter.com/MilosZubal
(if you think the accent is very strange I am
from Czech Republic :) )
What are you
going to hear
today?
● Enterprise Integration Patterns
(EIPs)
● Apache Camel
Some of the challenges of application integration
● Spaghetti integration (point-to-point)
● Unreliable/slow transport medium
● Many different data formats
● Performance/Throughput
● On-going change
Integrate apps? Why?
● Real-time data integration
● Process automation
● Improved flexibility
● “WTF? We do microservices!”
There is a fancy urban legend of a company where “Orders” department printed (physically!) all the
new customer details every week and passed that to the “Accounting” department so they can manually
type all the info into their system.
Integrate apps? How?
● File Transfer
● Shared DB
● RPC
● Messages
File Transfer
● Pros
○ Location decoupling
○ Temporal decoupling
○ Language agnostic
○ Works everywhere
● Cons
○ Delay in transfer
○ Large amount of data
○ Write/Read at the same time
Shared DB
● Pros
○ Consistency/Transactions
○ Reporting
● Cons
○ Purely data integration
○ No Process integration
○ No isolation
○ Performance/Locking
RPC
● Pros
○ Integration on demand
○ Also Process/Function integration
● Cons
○ Easily evolves into spaghetti
○ Tight coupling (location, temporal)
○ Performance problems (the call is
blocking resources)
Messaging (Async)
● Pros
○ Any type of integration
○ Decoupling (location/temporal)
○ Performance/Throttling
○ “Honest” approach to model the communication
● Cons
○ It is a different programming model
○ Usually need for a Message Broker
We have just covered Integration Styles of EIP
Enterprise Integration Patterns (EIPs)
● EIPs == GoF of application integration
● Set of 65 patterns to describe/design scalable
and maintainable integration solutions
● Published 10.10.2003
● 700 pages
● Authors: Gregor Hohpe
/ Bobby Woolf
Enterprise Integration Patterns
● Model integration as asynchronous messages
● Focus mainly on the communication of the apps and their edge
components
● Focus on stateless communication
● Usually one-way communication (not Request-Reply)
● Assumes using Message Broker to deliver messages (but there
are some architectures without MB)
● “Wider bridges, not faster cars.”
● Please make sure you don’t fall into the trap of applying integration
patterns to everything! (Keep things simple!)
Main EIP groups
Channel Patterns
(how to transport the Message)
Message Patterns
(how to design the Message)
Routing Patterns
(how to route the Message to its destination)
Transformation Patterns
(how to transform the Message to needed format)
Endpoint Patterns
(how to produce/consume the Message with
non-messaging systems)
Management Patterns
(how to monitor, test and manage the system
EIP Game: Guess the Pattern Name!
“Use a Splitter to break out the composite message into
a series of individual messages, each containing data
related to one item.”
????
EIP Game: Guess the Pattern Name!
????
“Use a stateful filter, an Aggregator, to collect and store
individual messages until a complete set of related messages
has been received. Then, the Aggregator publishes a single
message distilled from the individual messages.”
EIP Game: Guess the Pattern Name!
????
“Insert a special filter, a Message Router, which consumes a
Message from one Message Channel and republishes it to a
different Message Channel channel depending on a set of
conditions.”
Claim Check
The are a lot more EIPs
● All of them can be combined
or composed into “higher-
level” patterns
● Just like with GoF, you might
be using some of them
already
● All of them can be found on
enterpriseintegrationpatterns.com
Pipes and Filters
Loan Broker example
EIPs do not focus on
● Data modelling
● Stateful
communication/processes
(conversations)
● Correct modularisation or
application boundaries
○ Check Domain Driven
Desing (DDD)
EIPs - key benefits
● Robust Patterns to implement scalable and maintainable
integrations
● Common vocabulary
● Simple and expressive Graphical Notation
Implementing EIPs
Small
(frameworks)
Apache Camel
Spring Integration
NServiceBus (.NET)
Medium
(ESBs, Brokers)
JBoss Fuse
Mule
WSO2
TIBCO
Oracle ESB
IBM WebSphere ESB
Large
(SOA Suites)
Oracle SOA Suite
Service Works
(other major vendors)
Apache Camel
“Apache Camel is a powerful open source integration framework based on
known Enterprise Integration Patterns with powerful bean integration.”
● Open-source implementation of EIPs
● Backed by RedHat (it is part of JBoss Fuse)
● First release - summer 2007
Camel: basic architecture
Content Based Router - the Camel way
from newOrder
choice
when isWidget to widget
otherwise to gadget
Content Based Router - the Camel way
from(newOrder)
choice
when(isWidget)to(widget)
otherwise to(gadget)
Content Based Router - the Camel way
from(newOrder)
.choice()
.when(isWidget).to(widget)
.otherwise().to(gadget);
Content Based Router - the Camel way
from(newOrder)
.choice()
.when(isWidget).to(widget)
.otherwise().to(gadget);
Endpoint newOrder = endpoint(“amqp:queue:newOrder”);
Predicate isWidget = xpath(“/order/product = ‘widget’”);
Endpoint widget = endpoint(“amqp:queue:widget”);
Endpoint gadget = endpoint(“amqp:queue:gadget”);
Content Based Router - the Camel way
public class MyRouteBuilder extends RouteBuilder {
@Override
public void configure() throws Exception {
Endpoint newOrder = endpoint(“amqp:queue:newOrder”);
Predicate isWidget = xpath(“/order/product = ‘widget’”);
Endpoint widget = endpoint(“amqp:queue:widget”);
Endpoint gadget = endpoint(“amqp:queue:gadget”);
from(newOrder)
.choice()
.when(isWidget).to(widget)
.otherwise().to(gadget);
}}
Content Based Router - the Camel way
public class MyRouteBuilder extends RouteBuilder {
@Override
public void configure() throws Exception {
from(“amqp:queue:newOrder”)
.choice()
.when(xpath(“/order/product=‘widget’”).to(“amqp:queue:widget”)
.otherwise().to(“amqp:queue:gadget”);
}}
public void configure() throws Exception {
from(“amqp:queue:newOrder”)
.choice()
.when(xpath(“/order/product=‘widget’”)).to(“amqp:queue:widget”)
.otherwise().to(“amqp:queue:gadget”);
}}
Component - technology or transport, 300+ existing components!
Endpoint - particular “instance” of Component with concrete configuration/params
Predicate - supports also JSONPath, OGNL and others
Route - DSL (chained methods) defining the message flow
Content Based Router - the Camel way
Component
Predicate Endpoint
Route
Camel - other concepts
● Integration with Spring
● Expression Languages
● Support for Spring Transactions (JDBC, JMS, 2PC)
● Data formats (XML, JSON, EDI, ...)
● Error handling / retry strategies
● Throttling
● Bean integration
● Graceful Shutdowns
● Excellent support for unit tests
Camel - deployment options
● Standalone Java JAR (camel-core is 4.5M)
● Embedded in Tomcat, Karaf (OSGi)
● As part of JBoss Fuse
● Spring-boot - my favorite!
● Basically just put it on classpath and use it!
Resources
● EIP Book: on Amazon
● https://www.enterpriseintegrationpatterns.com
● http://camel.apache.org/
● https://github.com/apache/camel/tree/master/examples
● Existing stencils for many modelling tools!
Thanks!
Any Questions?
I am a proud Camel Rider™ - feel
free to get in touch later or via DM!
See you later!
Later Gator!

More Related Content

What's hot

MuleSoft Meetup Warsaw Group #1
MuleSoft  Meetup Warsaw Group #1MuleSoft  Meetup Warsaw Group #1
MuleSoft Meetup Warsaw Group #1
Patryk Bandurski
 
What is SSL/TLS, 1-way and 2-way SSL?
What is SSL/TLS, 1-way and 2-way SSL?What is SSL/TLS, 1-way and 2-way SSL?
What is SSL/TLS, 1-way and 2-way SSL?
pqrs1234
 
Virtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and LoggingVirtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and Logging
Jimmy Attia
 
MuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLB
MuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLBMuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLB
MuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLB
Jitendra Bafna
 
MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...
MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...
MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...
Jitendra Bafna
 
Mulesoftmeetup20th mar final
Mulesoftmeetup20th mar finalMulesoftmeetup20th mar final
Mulesoftmeetup20th mar final
Anurag Dwivedi
 
West Yorkshire Mulesoft Meetup #5
West Yorkshire Mulesoft Meetup #5West Yorkshire Mulesoft Meetup #5
West Yorkshire Mulesoft Meetup #5
Francis Edwards
 
MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...
MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...
MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...
Jitendra Bafna
 
Mule soft meetup__official__feb-27_2021
Mule soft meetup__official__feb-27_2021Mule soft meetup__official__feb-27_2021
Mule soft meetup__official__feb-27_2021
sumitahuja94
 
Mumbai MuleSoft Meetup 13
Mumbai MuleSoft Meetup 13Mumbai MuleSoft Meetup 13
Mumbai MuleSoft Meetup 13
Akshata Sawant
 
Ahmedabad MuleSoft Meetup #1
Ahmedabad MuleSoft Meetup #1Ahmedabad MuleSoft Meetup #1
Ahmedabad MuleSoft Meetup #1
Tejas Purohit
 
MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...
MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...
MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...
Jitendra Bafna
 
Surat MuleSoft Meetup#2 - Anypoint Runtime Fabric
Surat MuleSoft Meetup#2 - Anypoint Runtime FabricSurat MuleSoft Meetup#2 - Anypoint Runtime Fabric
Surat MuleSoft Meetup#2 - Anypoint Runtime Fabric
Jitendra Bafna
 
MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...
MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...
MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...
Jitendra Bafna
 
Troubleshooting and Best Practices with WSO2 Enterprise Integrator
Troubleshooting and Best Practices with WSO2 Enterprise IntegratorTroubleshooting and Best Practices with WSO2 Enterprise Integrator
Troubleshooting and Best Practices with WSO2 Enterprise Integrator
WSO2
 
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
Jitendra Bafna
 
Power of Transformation with DataWeave 2.X Engine
Power of Transformation with DataWeave 2.X EnginePower of Transformation with DataWeave 2.X Engine
Power of Transformation with DataWeave 2.X Engine
Manish Kumar Yadav
 
Flow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECT
Flow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECTFlow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECT
Flow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECT
Sabrina Marechal
 
Baltimore july2021 final
Baltimore july2021 finalBaltimore july2021 final
Baltimore july2021 final
ManjuKumara GH
 

What's hot (19)

MuleSoft Meetup Warsaw Group #1
MuleSoft  Meetup Warsaw Group #1MuleSoft  Meetup Warsaw Group #1
MuleSoft Meetup Warsaw Group #1
 
What is SSL/TLS, 1-way and 2-way SSL?
What is SSL/TLS, 1-way and 2-way SSL?What is SSL/TLS, 1-way and 2-way SSL?
What is SSL/TLS, 1-way and 2-way SSL?
 
Virtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and LoggingVirtual Meetup: Mule 4 Error Handling and Logging
Virtual Meetup: Mule 4 Error Handling and Logging
 
MuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLB
MuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLBMuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLB
MuleSoft Surat Live Demonstration Virtual Meetup#1 - Anypoint VPC VPN and DLB
 
MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...
MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...
MuleSoft Surat Virtual Meetup#7 - JSON Logger and Common Error Handling With ...
 
Mulesoftmeetup20th mar final
Mulesoftmeetup20th mar finalMulesoftmeetup20th mar final
Mulesoftmeetup20th mar final
 
West Yorkshire Mulesoft Meetup #5
West Yorkshire Mulesoft Meetup #5West Yorkshire Mulesoft Meetup #5
West Yorkshire Mulesoft Meetup #5
 
MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...
MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...
MuleSoft Surat Virtual Meetup#21 - MuleSoft API and RAML Design Best Practice...
 
Mule soft meetup__official__feb-27_2021
Mule soft meetup__official__feb-27_2021Mule soft meetup__official__feb-27_2021
Mule soft meetup__official__feb-27_2021
 
Mumbai MuleSoft Meetup 13
Mumbai MuleSoft Meetup 13Mumbai MuleSoft Meetup 13
Mumbai MuleSoft Meetup 13
 
Ahmedabad MuleSoft Meetup #1
Ahmedabad MuleSoft Meetup #1Ahmedabad MuleSoft Meetup #1
Ahmedabad MuleSoft Meetup #1
 
MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...
MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...
MuleSoft Surat Virtual Meetup#6 - MuleSoft API Led Connectivity, SEDA and MUn...
 
Surat MuleSoft Meetup#2 - Anypoint Runtime Fabric
Surat MuleSoft Meetup#2 - Anypoint Runtime FabricSurat MuleSoft Meetup#2 - Anypoint Runtime Fabric
Surat MuleSoft Meetup#2 - Anypoint Runtime Fabric
 
MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...
MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...
MuleSoft Surat Virtual Meetup#26 - Implementing Hybrid MuleSoft Runtime - Any...
 
Troubleshooting and Best Practices with WSO2 Enterprise Integrator
Troubleshooting and Best Practices with WSO2 Enterprise IntegratorTroubleshooting and Best Practices with WSO2 Enterprise Integrator
Troubleshooting and Best Practices with WSO2 Enterprise Integrator
 
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
MuleSoft Surat Virtual Meetup#28 - Exposing and Consuming SOAP Service - SOAP...
 
Power of Transformation with DataWeave 2.X Engine
Power of Transformation with DataWeave 2.X EnginePower of Transformation with DataWeave 2.X Engine
Power of Transformation with DataWeave 2.X Engine
 
Flow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECT
Flow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECTFlow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECT
Flow Tuning: Mule 3 vs. Mule 4 - MuleSoft Chicago CONNECT
 
Baltimore july2021 final
Baltimore july2021 finalBaltimore july2021 final
Baltimore july2021 final
 

Similar to Enterprise Integration Patterns and Apache Camel

Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...
Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...
Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...
Jimmy DeadcOde
 
Viktor Turskyi "Effective NodeJS Application Development"
Viktor Turskyi "Effective NodeJS Application Development"Viktor Turskyi "Effective NodeJS Application Development"
Viktor Turskyi "Effective NodeJS Application Development"
Fwdays
 
Introduction To Apache Camel
Introduction To Apache CamelIntroduction To Apache Camel
Introduction To Apache Camel
Knoldus Inc.
 
TS 4839 - Enterprise Integration Patterns in Practice
TS 4839 - Enterprise Integration Patterns in PracticeTS 4839 - Enterprise Integration Patterns in Practice
TS 4839 - Enterprise Integration Patterns in Practice
aegloff
 
EclipseCon Eu 2015 - Breathe life into your Designer!
EclipseCon Eu 2015 - Breathe life into your Designer!EclipseCon Eu 2015 - Breathe life into your Designer!
EclipseCon Eu 2015 - Breathe life into your Designer!
melbats
 
Advanced web application architecture Way2Web
Advanced web application architecture Way2WebAdvanced web application architecture Way2Web
Advanced web application architecture Way2Web
Matthias Noback
 
Stateful mock servers to the rescue on REST ecosystems
Stateful mock servers to the rescue on REST ecosystemsStateful mock servers to the rescue on REST ecosystems
Stateful mock servers to the rescue on REST ecosystems
Nuno Caneco
 
Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...
Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...
Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...
Kai Wähner
 
Google App Engine
Google App EngineGoogle App Engine
Google App Engine
cloudcampnigeria
 
Enterprise Integration Patterns with Apache Camel
Enterprise Integration Patterns with Apache CamelEnterprise Integration Patterns with Apache Camel
Enterprise Integration Patterns with Apache Camel
Ioan Eugen Stan
 
Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011
Opevel
 
Microservice Workshop Hands On
Microservice Workshop Hands On Microservice Workshop Hands On
Microservice Workshop Hands On
Ram G Suri
 
Beginning MEAN Stack
Beginning MEAN StackBeginning MEAN Stack
Beginning MEAN StackRob Davarnia
 
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure FunctionsEuropean Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
Sébastien Levert
 
A SOA approximation on symfony
A SOA approximation on symfonyA SOA approximation on symfony
A SOA approximation on symfony
Joseluis Laso
 
A soa approximation on symfony
A soa approximation on symfonyA soa approximation on symfony
A soa approximation on symfony
Carlos Agudo Belloso
 
Building Custom Connectors Using XML SDK in Mule 4
Building Custom Connectors Using XML SDK in Mule 4Building Custom Connectors Using XML SDK in Mule 4
Building Custom Connectors Using XML SDK in Mule 4
Manish Kumar Yadav
 
Integration Monday - BizTalk Migrator Deep Dive
Integration Monday - BizTalk Migrator Deep DiveIntegration Monday - BizTalk Migrator Deep Dive
Integration Monday - BizTalk Migrator Deep Dive
BizTalk360
 
Challenges of angular in production (Tasos Bekos) - GreeceJS #17
Challenges of angular in production (Tasos Bekos) - GreeceJS #17Challenges of angular in production (Tasos Bekos) - GreeceJS #17
Challenges of angular in production (Tasos Bekos) - GreeceJS #17
GreeceJS
 

Similar to Enterprise Integration Patterns and Apache Camel (20)

EIP In Practice
EIP In PracticeEIP In Practice
EIP In Practice
 
Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...
Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...
Website Monitoring with Distributed Messages/Tasks Processing (AMQP & RabbitM...
 
Viktor Turskyi "Effective NodeJS Application Development"
Viktor Turskyi "Effective NodeJS Application Development"Viktor Turskyi "Effective NodeJS Application Development"
Viktor Turskyi "Effective NodeJS Application Development"
 
Introduction To Apache Camel
Introduction To Apache CamelIntroduction To Apache Camel
Introduction To Apache Camel
 
TS 4839 - Enterprise Integration Patterns in Practice
TS 4839 - Enterprise Integration Patterns in PracticeTS 4839 - Enterprise Integration Patterns in Practice
TS 4839 - Enterprise Integration Patterns in Practice
 
EclipseCon Eu 2015 - Breathe life into your Designer!
EclipseCon Eu 2015 - Breathe life into your Designer!EclipseCon Eu 2015 - Breathe life into your Designer!
EclipseCon Eu 2015 - Breathe life into your Designer!
 
Advanced web application architecture Way2Web
Advanced web application architecture Way2WebAdvanced web application architecture Way2Web
Advanced web application architecture Way2Web
 
Stateful mock servers to the rescue on REST ecosystems
Stateful mock servers to the rescue on REST ecosystemsStateful mock servers to the rescue on REST ecosystems
Stateful mock servers to the rescue on REST ecosystems
 
Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...
Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...
Enterprise Integration Patterns Revisited (again) for the Era of Big Data, In...
 
Google App Engine
Google App EngineGoogle App Engine
Google App Engine
 
Enterprise Integration Patterns with Apache Camel
Enterprise Integration Patterns with Apache CamelEnterprise Integration Patterns with Apache Camel
Enterprise Integration Patterns with Apache Camel
 
Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011
 
Microservice Workshop Hands On
Microservice Workshop Hands On Microservice Workshop Hands On
Microservice Workshop Hands On
 
Beginning MEAN Stack
Beginning MEAN StackBeginning MEAN Stack
Beginning MEAN Stack
 
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure FunctionsEuropean Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
 
A SOA approximation on symfony
A SOA approximation on symfonyA SOA approximation on symfony
A SOA approximation on symfony
 
A soa approximation on symfony
A soa approximation on symfonyA soa approximation on symfony
A soa approximation on symfony
 
Building Custom Connectors Using XML SDK in Mule 4
Building Custom Connectors Using XML SDK in Mule 4Building Custom Connectors Using XML SDK in Mule 4
Building Custom Connectors Using XML SDK in Mule 4
 
Integration Monday - BizTalk Migrator Deep Dive
Integration Monday - BizTalk Migrator Deep DiveIntegration Monday - BizTalk Migrator Deep Dive
Integration Monday - BizTalk Migrator Deep Dive
 
Challenges of angular in production (Tasos Bekos) - GreeceJS #17
Challenges of angular in production (Tasos Bekos) - GreeceJS #17Challenges of angular in production (Tasos Bekos) - GreeceJS #17
Challenges of angular in production (Tasos Bekos) - GreeceJS #17
 

Recently uploaded

Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Shahin Sheidaei
 
Enterprise Resource Planning System in Telangana
Enterprise Resource Planning System in TelanganaEnterprise Resource Planning System in Telangana
Enterprise Resource Planning System in Telangana
NYGGS Automation Suite
 
Enterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptxEnterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptx
QuickwayInfoSystems3
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate
 
May Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdfMay Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdf
Adele Miller
 
Webinar: Salesforce Document Management 2.0 - Smarter, Faster, Better
Webinar: Salesforce Document Management 2.0 - Smarter, Faster, BetterWebinar: Salesforce Document Management 2.0 - Smarter, Faster, Better
Webinar: Salesforce Document Management 2.0 - Smarter, Faster, Better
XfilesPro
 
GlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote sessionGlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote session
Globus
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
e20449
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
rickgrimesss22
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
Globus
 
Quarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden ExtensionsQuarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden Extensions
Max Andersen
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Natan Silnitsky
 
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...
Mind IT Systems
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke
 
APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)
Boni García
 
Lecture 1 Introduction to games development
Lecture 1 Introduction to games developmentLecture 1 Introduction to games development
Lecture 1 Introduction to games development
abdulrafaychaudhry
 
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing SuiteAI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
Google
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
Globus
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus
 

Recently uploaded (20)

Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
 
Enterprise Resource Planning System in Telangana
Enterprise Resource Planning System in TelanganaEnterprise Resource Planning System in Telangana
Enterprise Resource Planning System in Telangana
 
Enterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptxEnterprise Software Development with No Code Solutions.pptx
Enterprise Software Development with No Code Solutions.pptx
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket ManagementUtilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
Utilocate provides Smarter, Better, Faster, Safer Locate Ticket Management
 
May Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdfMay Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdf
 
Webinar: Salesforce Document Management 2.0 - Smarter, Faster, Better
Webinar: Salesforce Document Management 2.0 - Smarter, Faster, BetterWebinar: Salesforce Document Management 2.0 - Smarter, Faster, Better
Webinar: Salesforce Document Management 2.0 - Smarter, Faster, Better
 
GlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote sessionGlobusWorld 2024 Opening Keynote session
GlobusWorld 2024 Opening Keynote session
 
Graphic Design Crash Course for beginners
Graphic Design Crash Course for beginnersGraphic Design Crash Course for beginners
Graphic Design Crash Course for beginners
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
 
Quarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden ExtensionsQuarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden Extensions
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
 
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...
Custom Healthcare Software for Managing Chronic Conditions and Remote Patient...
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
 
APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)APIs for Browser Automation (MoT Meetup 2024)
APIs for Browser Automation (MoT Meetup 2024)
 
Lecture 1 Introduction to games development
Lecture 1 Introduction to games developmentLecture 1 Introduction to games development
Lecture 1 Introduction to games development
 
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing SuiteAI Pilot Review: The World’s First Virtual Assistant Marketing Suite
AI Pilot Review: The World’s First Virtual Assistant Marketing Suite
 
Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024Globus Compute Introduction - GlobusWorld 2024
Globus Compute Introduction - GlobusWorld 2024
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
 

Enterprise Integration Patterns and Apache Camel

  • 1. Enterprise Integration Patterns & Apache Camel Milos Zubal Waterford Tech. Meetup 26.09.2018
  • 2. Who’s this?! @MilosZubal Software Engineer at (we’re hiring! ;) ) 11+ years of backend Java happiness https://www.linkedin.com/in/miloszubal/ https://github.com/mzubal https://twitter.com/MilosZubal (if you think the accent is very strange I am from Czech Republic :) )
  • 3. What are you going to hear today? ● Enterprise Integration Patterns (EIPs) ● Apache Camel
  • 4. Some of the challenges of application integration ● Spaghetti integration (point-to-point) ● Unreliable/slow transport medium ● Many different data formats ● Performance/Throughput ● On-going change
  • 5. Integrate apps? Why? ● Real-time data integration ● Process automation ● Improved flexibility ● “WTF? We do microservices!” There is a fancy urban legend of a company where “Orders” department printed (physically!) all the new customer details every week and passed that to the “Accounting” department so they can manually type all the info into their system.
  • 6. Integrate apps? How? ● File Transfer ● Shared DB ● RPC ● Messages
  • 7. File Transfer ● Pros ○ Location decoupling ○ Temporal decoupling ○ Language agnostic ○ Works everywhere ● Cons ○ Delay in transfer ○ Large amount of data ○ Write/Read at the same time
  • 8. Shared DB ● Pros ○ Consistency/Transactions ○ Reporting ● Cons ○ Purely data integration ○ No Process integration ○ No isolation ○ Performance/Locking
  • 9. RPC ● Pros ○ Integration on demand ○ Also Process/Function integration ● Cons ○ Easily evolves into spaghetti ○ Tight coupling (location, temporal) ○ Performance problems (the call is blocking resources)
  • 10. Messaging (Async) ● Pros ○ Any type of integration ○ Decoupling (location/temporal) ○ Performance/Throttling ○ “Honest” approach to model the communication ● Cons ○ It is a different programming model ○ Usually need for a Message Broker
  • 11. We have just covered Integration Styles of EIP
  • 12. Enterprise Integration Patterns (EIPs) ● EIPs == GoF of application integration ● Set of 65 patterns to describe/design scalable and maintainable integration solutions ● Published 10.10.2003 ● 700 pages ● Authors: Gregor Hohpe / Bobby Woolf
  • 13. Enterprise Integration Patterns ● Model integration as asynchronous messages ● Focus mainly on the communication of the apps and their edge components ● Focus on stateless communication ● Usually one-way communication (not Request-Reply) ● Assumes using Message Broker to deliver messages (but there are some architectures without MB) ● “Wider bridges, not faster cars.” ● Please make sure you don’t fall into the trap of applying integration patterns to everything! (Keep things simple!)
  • 14. Main EIP groups Channel Patterns (how to transport the Message) Message Patterns (how to design the Message) Routing Patterns (how to route the Message to its destination) Transformation Patterns (how to transform the Message to needed format) Endpoint Patterns (how to produce/consume the Message with non-messaging systems) Management Patterns (how to monitor, test and manage the system
  • 15. EIP Game: Guess the Pattern Name! “Use a Splitter to break out the composite message into a series of individual messages, each containing data related to one item.” ????
  • 16. EIP Game: Guess the Pattern Name! ???? “Use a stateful filter, an Aggregator, to collect and store individual messages until a complete set of related messages has been received. Then, the Aggregator publishes a single message distilled from the individual messages.”
  • 17. EIP Game: Guess the Pattern Name! ???? “Insert a special filter, a Message Router, which consumes a Message from one Message Channel and republishes it to a different Message Channel channel depending on a set of conditions.”
  • 19. The are a lot more EIPs ● All of them can be combined or composed into “higher- level” patterns ● Just like with GoF, you might be using some of them already ● All of them can be found on enterpriseintegrationpatterns.com
  • 22. EIPs do not focus on ● Data modelling ● Stateful communication/processes (conversations) ● Correct modularisation or application boundaries ○ Check Domain Driven Desing (DDD)
  • 23. EIPs - key benefits ● Robust Patterns to implement scalable and maintainable integrations ● Common vocabulary ● Simple and expressive Graphical Notation
  • 24. Implementing EIPs Small (frameworks) Apache Camel Spring Integration NServiceBus (.NET) Medium (ESBs, Brokers) JBoss Fuse Mule WSO2 TIBCO Oracle ESB IBM WebSphere ESB Large (SOA Suites) Oracle SOA Suite Service Works (other major vendors)
  • 25. Apache Camel “Apache Camel is a powerful open source integration framework based on known Enterprise Integration Patterns with powerful bean integration.” ● Open-source implementation of EIPs ● Backed by RedHat (it is part of JBoss Fuse) ● First release - summer 2007
  • 27. Content Based Router - the Camel way from newOrder choice when isWidget to widget otherwise to gadget
  • 28. Content Based Router - the Camel way from(newOrder) choice when(isWidget)to(widget) otherwise to(gadget)
  • 29. Content Based Router - the Camel way from(newOrder) .choice() .when(isWidget).to(widget) .otherwise().to(gadget);
  • 30. Content Based Router - the Camel way from(newOrder) .choice() .when(isWidget).to(widget) .otherwise().to(gadget); Endpoint newOrder = endpoint(“amqp:queue:newOrder”); Predicate isWidget = xpath(“/order/product = ‘widget’”); Endpoint widget = endpoint(“amqp:queue:widget”); Endpoint gadget = endpoint(“amqp:queue:gadget”);
  • 31. Content Based Router - the Camel way public class MyRouteBuilder extends RouteBuilder { @Override public void configure() throws Exception { Endpoint newOrder = endpoint(“amqp:queue:newOrder”); Predicate isWidget = xpath(“/order/product = ‘widget’”); Endpoint widget = endpoint(“amqp:queue:widget”); Endpoint gadget = endpoint(“amqp:queue:gadget”); from(newOrder) .choice() .when(isWidget).to(widget) .otherwise().to(gadget); }}
  • 32. Content Based Router - the Camel way public class MyRouteBuilder extends RouteBuilder { @Override public void configure() throws Exception { from(“amqp:queue:newOrder”) .choice() .when(xpath(“/order/product=‘widget’”).to(“amqp:queue:widget”) .otherwise().to(“amqp:queue:gadget”); }}
  • 33. public void configure() throws Exception { from(“amqp:queue:newOrder”) .choice() .when(xpath(“/order/product=‘widget’”)).to(“amqp:queue:widget”) .otherwise().to(“amqp:queue:gadget”); }} Component - technology or transport, 300+ existing components! Endpoint - particular “instance” of Component with concrete configuration/params Predicate - supports also JSONPath, OGNL and others Route - DSL (chained methods) defining the message flow Content Based Router - the Camel way Component Predicate Endpoint Route
  • 34. Camel - other concepts ● Integration with Spring ● Expression Languages ● Support for Spring Transactions (JDBC, JMS, 2PC) ● Data formats (XML, JSON, EDI, ...) ● Error handling / retry strategies ● Throttling ● Bean integration ● Graceful Shutdowns ● Excellent support for unit tests
  • 35. Camel - deployment options ● Standalone Java JAR (camel-core is 4.5M) ● Embedded in Tomcat, Karaf (OSGi) ● As part of JBoss Fuse ● Spring-boot - my favorite! ● Basically just put it on classpath and use it!
  • 36. Resources ● EIP Book: on Amazon ● https://www.enterpriseintegrationpatterns.com ● http://camel.apache.org/ ● https://github.com/apache/camel/tree/master/examples ● Existing stencils for many modelling tools!
  • 37.
  • 38. Thanks! Any Questions? I am a proud Camel Rider™ - feel free to get in touch later or via DM! See you later! Later Gator!

Editor's Notes

  1. Thanks to - Dara for his GraphQL talk, Marco for the chance to talk (wildcard), all the sponsors - BoxWorks, RedHat, BlueFin, MetalMan,...
  2. Application integration is hard. Only Arnie can handle the spaghetti.
  3. Lower the cost of manual synchronisation, increase the effectiveness
  4. File locking strategies. Good decoupling. Cannot effectively do competing consumers.
  5. Hard to evolve schema and do impact analysis. Long running transactions and locks. Imagine the second app to fetch data ‘for update’ and then sending them (while the tx still open) to some very slow WS.
  6. Scenario of one app creating transaction, do write locks, then calling another, which does the same. Current REST is RPC.
  7. “Honest” in terms of unreliable/slow network, small amount of data, asynchronous. You have to think in terms of correlation IDs, timeouts, etc. Everything in our lives is synchronous - Postman (waiting at your door, even sender waiting at the post). You better be synchronous when your wife calls you! :) (or be good at error handling and reconciliation). Network packets/datagrams, async ACKs.
  8. GoF and their reflection in frameworks. EIPs and their reflection in systems. EIP and EDAs are foundation of current Reactive activities. SW engineering is quite similar to usual way the people have to learn the history over and over, but SW engineering has shorter cycles :)
  9. GoF and their reflection in frameworks. EIPs and their reflection in systems. EIP and EDAs are foundation of current Reactive activities. SW engineering is quite similar to usual way the people have to learn the history over and over, but SW engineering has shorter cycles :)
  10. GoF and their reflection in frameworks. EIPs and their reflection in systems. EIP and EDAs are foundation of current Reactive activities. SW engineering is quite similar to usual way the people have to learn the history over and over, but SW engineering has shorter cycles :)
  11. GoF and their reflection in frameworks. EIPs and their reflection in systems. EIP and EDAs are foundation of current Reactive activities. SW engineering is quite similar to usual way the people have to learn the history over and over, but SW engineering has shorter cycles :)
  12. Mention about draw
  13. Recipient list is dynamic - banks can be stored in configuration, might make sense to send the request to same banks based on credit score, might make sense to include bank filter in the loan request. Aggregator might implement different strategies to determine the winner request (APR).