SlideShare a Scribd company logo
1 of 40
Introduction to Open-Source ESB
Abdul Imran Khan
1
 What is Mule?
 How do you use Mule?
 What are the core Mule concepts?
 Learning mule with File endpoints
2
 Mule is an open-source Enterprise Service
Backbone (ESB)
3
 SEDA
 Staged Event-Driven Architecture
 Java NIO
 Java New Input/Output
4
 SEDA decomposes a complex, event-driven software application
into a set of stages connected by queues
 This design avoids the high overhead associated with thread-based
concurrency models, and decouples event and thread scheduling
from application logic
 By performing admission control on each event queue, the service
can be well-conditioned to load, preventing resources from being
overcommitted when demand exceeds service capacity
 SEDA employs dynamic control to automatically tune runtime
parameters (such as the scheduling parameters of each stage) as
well as to manage load, for example, by performing adaptive load
shedding
 Decomposing services into a set of stages also enables modularity
and code reuse, as well as the development of debugging tools for
complex event-driven applications
5
 NIO is a collection of Java programming language
APIs that offer advanced features for intensive
I/O operations
 NIO facilitates an implementations that can
directly use the most efficient operations of the
underlying platform
 NIO includes:
 Buffers for data of primitive types
 Character set encoders and decoders
 A pattern-matching facility based on Perl-style regular
expressions (in package java.util.regex)
 Channels, a new primitive I/O abstraction
 A file interface that supports locks and memory mapping
 A multiplexed, non-blocking I/O facility for writing
scalable servers
6
 Folder to folder
 Queue to queue
 Shared memory to shared memory
 Using different types of transports
 In a flexible way
7
 An XML pipeline is a series of operation that
are performed on one or more XML files
 Examples include:
 validate
 transform
 prune (remove nodes)
 split (break a single XML file into many files)
 merge (join two or more files together)
8
 Flow of XML document through approval
processes
9
Submit
CRV
Deed
Matched
CRV
SSN
Stripped
CRV
Income
Tax
Audit
County
Audit
County
Approval
State
Audit
State
Approval
 Example of XML Operations used on CRV
10
Validate Split
Remove
SSN
Element
Store
Modify
Value
Add
Element
Modify
Value
Add
Element
 Focus on specifying "What" not "How"
 Empower business analysis to write machine-
readable specifications
 Hide the "How" behind services with clear
interfaces (SOA)
11
 Mule Manager
 Mule Model
 Universal Message Object (UMO)
 Endpoints
 External Applications
12
 A UMO is a type of Java object that can
receive events "from anywhere"
send events
 UMO Components are usually your
business objects. They are components
that execute business logic on an
incoming event
 UMO are standard JavaBeans (containers)
 There is no Mule-specific code in your
components
 Mule handles all routing and
transformation of events to and from your
objects based on the configuration of your
component 13
 A transport or "provider", is a set of objects
that add support to Mule to handle a specific
kind of transport or protocol
 Examples
 the "Email Provider" enables Mule to send and
receive messages via the SMTP, POP and IMAP
protocols
14
 A connector is the object that sends and
receives messages on behalf of an endpoint.
 Connectors are bundled as part of specific
transports or providers.
 For example, the FileConnector can read
and write file system files.
15
 A router is the object that do something with
messages once they have been received by a
connector, or prior to being sent out by the
connector
16
 A filter optionally filters incoming or
outgoing messages that are coming into or
going out from a connector.
 For example, the File Provider comes with
a FilenameWildcardFilter that
restricts which files are read by the
connector based on file name patterns.
For example only files with the .xml
extension can be routed.
 Filters are used in conjunction with
Routers.
17
 A transformer optionally changes incoming or
outgoing messages in some way
 This is usually done to make the message
format useable by a downstream function
 Examples:
 the ByteArrayToString transformer converts byte
arrays into String objects.
18
 The nine stages of a
mule event
 first 2 – inbound
 middle 4 – component
 last 2 – outbound
19
Endpoint
(Message Receiver)
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Router
Inbound Transformer
Outbound Transformer
Interceptor
Service Invocation
Interceptor
Inbound
Component
Outbound
Optional Step
 Some event triggers a message
flow
 A file being written into a folder
 A message arriving on a message
queue
 A record in a database
 Data written to a socket
20
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Router
Inbound Transformer
Outbound Transformer
Interceptor
Service Invocation
Interceptor
Endpoint
(Message Receiver)
 The inbound router is the fist step
in a message. Functions typically
performed by an inbound router
 Filtering
 Remove duplicate messages
 Matching messages
 Aggregation (combining)
 Re-sequence data
 Forwarding
 See also
 IdempotentReceiver
 CorrolationAggregator
 CorrelationResequencer
21
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Router
Inbound Transformer
Outbound Transformer
Interceptor
Service Invocation
Interceptor
Endpoint
(Message Receiver)
 Used to intercept message
flow into your service
component
 Used trigger monitor/events or
interrupt the flow of the
message
 Example: an authorization
interceptor could ensure that
the current request has the
correct credentials to invoke
the service.
22
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Router
Inbound Transformer
Outbound Transformer
Service Invocation
Interceptor
Endpoint
(Message Receiver)
Interceptor
 If the inbound data is
not in the correct
format for the service
it must be transformed
at this point
23
Endpoint
(Message Receiver)
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Router
Outbound Transformer
Interceptor
Service Invocation
Interceptor
Inbound Transformer
 The actual service is
performed
 In mule, this is generally a
Java object
 Service invocation can also be
a "pass through"
24
Endpoint
(Message Receiver)
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Router
Outbound Transformer
Interceptor
Interceptor
Inbound Transformer
Service Invocation
 Dispatching the data to
all the relevant
endpoints
25
Endpoint
(Message Receiver)
Endpoint
(Message Dispatcher)
Inbound Router
Outbound Transformer
Interceptor
Interceptor
Inbound Transformer
Service Invocation
Outbound Router
Inbound Outbound Response
Idempotent Receiver Filtering Outbound Router Response Aggregator
Selective Consumer Recipient List
Aggregator Multicasting Router
Resequencer Chaining Router
Forwarding Consumer Message Splitter
Filtering List Message
Splitter
Filtering Xml Message
Splitter
Exception Based Router
26
 Any transformations that needs
to be done on the message after
a service has been performed on
the message can be executed
before it is put into the endpoint
 See Also
EnvelopeInterceptor
27
Endpoint
(Message Receiver)
Endpoint
(Message Dispatcher)
Inbound Router
Interceptor
Interceptor
Inbound Transformer
Service Invocation
Outbound Router
Outbound Transformer
28
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mule-configuration PUBLIC "-//MuleSource
//DTD mule-configuration XML V1.0//EN"
"http://mule.mulesource.org/dtds/mule-
configuration.dtd">
29
<mule-configuration>
<model>
<mule-descriptor>
<inbound-router>
<endpoint
address="file:///c:/mule-class/in"/>
</inbound-router>
<outbound-router>
<router>
<endpoint
address="file:///c:/mule-class/out"/>
</router>
</outbound-router>
</mule-descriptor>
</model>
</mule-configuration>
30
<mule-configuration id="Mule_File_Move" version=" 1.0">
<connector name="SystemStreamConnector"
className="org.mule.providers.stream.SystemStreamConnec
tor"/>
<model name="move-all-files">
<mule-descriptor name="move-file"
implementation="org.mule.components.simple.BridgeCompon
ent">
<inbound-router>
<endpoint address="file:///c:/tmp/in"/>
</inbound-router>
<outbound-router>
<router
className="org.mule.routing.outbound.OutboundPassThroug
hRouter">
<endpoint address="file:///c:/tmp/out"/>
</router>
</outbound-router>
</mule-descriptor>
</model>
</mule-configuration> 31
<inbound-router>
<endpoint address="file:///c:/mule-class/in">
<filter pattern="*.xml"
className=
"org.mule.providers.file.filters.FilenameWildcardFilter"/>
</endpoint>
</inbound-router>
32
Add the filter line to only move files with the extension
"*.xml". If you add a file "foobar.txt to the input folder it
will not be moved.
<outbound-router>
<router
className="org.mule.routing.outbound.OutboundPassThroughRouter">
<endpoint
address=
"file:///c:/mule-class/out?outputPattern=$[ORIGINALNAME]"
/>
</router>
</outbound-router>
33
Add the outputPattern parameter to keep the output
name the same as the input.
 By default, error free documents follow a central path
known as the "happy path"
 Documents that have errors may be handled in different
ways (rejected, warnings etc.)
34
Start StopStep 1 Step 2 Step 3
Stop Stop Stop
 Mule has a special way of handling non-happy path processing.
This is called an "Exception Strategy" but is it really just and
exception path and there is very little strategy involved.
 There are three places you can associate an exception strategy
 connector
 component
 model (set for all components in a model)
35
<exception-strategy
className=org.mule.impl.DefaultComponentExceptionStrategy">
<endpoint address="file:///c:/mule-class/error"/>
</exception-strategy>
36
We want all invalid documents to be moved into the
error folder.
<?xml version="1.0" encoding="UTF-8"?>
<Data>
<Element1>Hello World!</Element1>
<Element2>String</Element2>
<Element3>String</Element3>
<DansInvalidDataElement>This is Dans invalid data element</DansInvalidDataElement>
</Data>
37
XML Schema validation will generate an error message
when it gets to the fourth invalid data element:
Given the following XML Schema file:
<outbound-router>
<router className="org.mule.routing.outbound.FilteringXmlMessageSplitter">
<endpoint
address="file:///c:/mule-class/out?outputPattern=$[ORIGINALNAME]"/>
<properties>
<property name="validateSchema" value="true"/>
<property name="externalSchemaLocation"
value="file:///c:/mule-class/labs/07-validate/my-
schema.xsd"/>
</properties>
</router>
</outbound-router>
38
To validate the XML Schema, just add two properties:
1) tell it to validate the document
2) tell it what file to use and where to find it
document : cvc-complex-type.2.4.d: Invalid content was found
starting with element 'DansInvalidDataElement'. No child element
is expected at this point.
39
This error message is generated on the Mule console
when an invalid data element is found. But what should
we do with it? How do we redirect it to the appropriate
user?
Please contact me for more information:
 Enterprise Service Bus
 Enterprise Integration
 Metadata Management
 Metadata Registries
 Service Oriented Architectures
 Business Intelligence and Data Warehouse
 Semantic Web
40

More Related Content

What's hot

Mule ESB Tutorial Part 3
Mule ESB Tutorial Part 3Mule ESB Tutorial Part 3
Mule ESB Tutorial Part 3Srikanth N
 
Mule enterprise service introduction
Mule enterprise service introductionMule enterprise service introduction
Mule enterprise service introductionSon Nguyen
 
Mule message structure
Mule message structureMule message structure
Mule message structureSrilatha Kante
 
Mule ESB
Mule ESBMule ESB
Mule ESBniravn
 
Rabbit Mq in Mule
Rabbit Mq in MuleRabbit Mq in Mule
Rabbit Mq in MuleMohammed246
 
Introduction to mule esb
Introduction to mule esbIntroduction to mule esb
Introduction to mule esbKhasim Cise
 
File component in mule
File component in muleFile component in mule
File component in muleRajkattamuri
 
Mule message structure and varibles scopes
Mule message structure and varibles scopesMule message structure and varibles scopes
Mule message structure and varibles scopesRamakrishna kapa
 
Core concepts - mule
Core concepts - muleCore concepts - mule
Core concepts - muleSindhu VL
 
Arch andmodulesmule
Arch andmodulesmuleArch andmodulesmule
Arch andmodulesmuleJavierMarRas
 
Choice router mule
Choice router   muleChoice router   mule
Choice router muleSindhu VL
 
Concepts in mule
Concepts in muleConcepts in mule
Concepts in muleSindhu VL
 
Mule high availability
Mule high availabilityMule high availability
Mule high availabilitySon Nguyen
 

What's hot (20)

Mule ESB Tutorial Part 3
Mule ESB Tutorial Part 3Mule ESB Tutorial Part 3
Mule ESB Tutorial Part 3
 
Mule enterprise service introduction
Mule enterprise service introductionMule enterprise service introduction
Mule enterprise service introduction
 
Mule message structure
Mule message structureMule message structure
Mule message structure
 
Mule ESB
Mule ESBMule ESB
Mule ESB
 
Mule esb
Mule esbMule esb
Mule esb
 
Rabbit mq in mule
Rabbit mq in muleRabbit mq in mule
Rabbit mq in mule
 
Rabbit Mq in Mule
Rabbit Mq in MuleRabbit Mq in Mule
Rabbit Mq in Mule
 
Introduction to mule esb
Introduction to mule esbIntroduction to mule esb
Introduction to mule esb
 
File component in mule
File component in muleFile component in mule
File component in mule
 
Mule message structure and varibles scopes
Mule message structure and varibles scopesMule message structure and varibles scopes
Mule message structure and varibles scopes
 
Core concepts - mule
Core concepts - muleCore concepts - mule
Core concepts - mule
 
Arch andmodulesmule
Arch andmodulesmuleArch andmodulesmule
Arch andmodulesmule
 
Mule Complete Training
Mule Complete TrainingMule Complete Training
Mule Complete Training
 
Mule technology
Mule technologyMule technology
Mule technology
 
Routing in mule
Routing in muleRouting in mule
Routing in mule
 
Choice router mule
Choice router   muleChoice router   mule
Choice router mule
 
Mule overview
Mule overviewMule overview
Mule overview
 
Concepts in mule
Concepts in muleConcepts in mule
Concepts in mule
 
Mule high availability
Mule high availabilityMule high availability
Mule high availability
 
Mule execution
Mule executionMule execution
Mule execution
 

Viewers also liked

Mule routing and filters
Mule routing and filtersMule routing and filters
Mule routing and filtersGandham38
 
Mule deploying a cloud hub application
Mule deploying a cloud hub applicationMule deploying a cloud hub application
Mule deploying a cloud hub applicationD.Rajesh Kumar
 
Generating Documentation for Mule ESB Application
Generating Documentation for Mule ESB ApplicationGenerating Documentation for Mule ESB Application
Generating Documentation for Mule ESB ApplicationRupesh Sinha
 
Mule esb How to convert from CSV to Json in 5 minutes
Mule esb How to convert from CSV to Json in 5 minutesMule esb How to convert from CSV to Json in 5 minutes
Mule esb How to convert from CSV to Json in 5 minutesGennaro Spagnoli
 
MuleSoft ESB - CSV File to Database
MuleSoft ESB - CSV File to DatabaseMuleSoft ESB - CSV File to Database
MuleSoft ESB - CSV File to Databaseakashdprajapati
 
Demo on Mule ESB Facebook Connector
Demo on Mule ESB Facebook ConnectorDemo on Mule ESB Facebook Connector
Demo on Mule ESB Facebook ConnectorRupesh Sinha
 
Future of Integration | MuleSoft
Future of Integration | MuleSoftFuture of Integration | MuleSoft
Future of Integration | MuleSoftMuleSoft
 
Mule ESB Tutorial Part 1
Mule ESB Tutorial Part 1Mule ESB Tutorial Part 1
Mule ESB Tutorial Part 1Srikanth N
 
Microservices Best Practices
Microservices Best Practices Microservices Best Practices
Microservices Best Practices MuleSoft
 
Mule ESB - Integration Simplified
Mule ESB - Integration SimplifiedMule ESB - Integration Simplified
Mule ESB - Integration SimplifiedRich Software
 

Viewers also liked (16)

Mule routing and filters
Mule routing and filtersMule routing and filters
Mule routing and filters
 
Mule connectors
Mule  connectorsMule  connectors
Mule connectors
 
Mule deploying a cloud hub application
Mule deploying a cloud hub applicationMule deploying a cloud hub application
Mule deploying a cloud hub application
 
Generating Documentation for Mule ESB Application
Generating Documentation for Mule ESB ApplicationGenerating Documentation for Mule ESB Application
Generating Documentation for Mule ESB Application
 
Mule esb How to convert from CSV to Json in 5 minutes
Mule esb How to convert from CSV to Json in 5 minutesMule esb How to convert from CSV to Json in 5 minutes
Mule esb How to convert from CSV to Json in 5 minutes
 
MuleSoft ESB - CSV File to Database
MuleSoft ESB - CSV File to DatabaseMuleSoft ESB - CSV File to Database
MuleSoft ESB - CSV File to Database
 
Demo on Mule ESB Facebook Connector
Demo on Mule ESB Facebook ConnectorDemo on Mule ESB Facebook Connector
Demo on Mule ESB Facebook Connector
 
Timer Interceptor in Mule
Timer Interceptor in MuleTimer Interceptor in Mule
Timer Interceptor in Mule
 
Mule esb transformers
Mule esb transformersMule esb transformers
Mule esb transformers
 
Mule Expression language
Mule Expression languageMule Expression language
Mule Expression language
 
Mule ESB Training
Mule ESB TrainingMule ESB Training
Mule ESB Training
 
Future of Integration | MuleSoft
Future of Integration | MuleSoftFuture of Integration | MuleSoft
Future of Integration | MuleSoft
 
Mule ESB Tutorial Part 1
Mule ESB Tutorial Part 1Mule ESB Tutorial Part 1
Mule ESB Tutorial Part 1
 
Microservices Best Practices
Microservices Best Practices Microservices Best Practices
Microservices Best Practices
 
Mule ESB Fundamentals
Mule ESB FundamentalsMule ESB Fundamentals
Mule ESB Fundamentals
 
Mule ESB - Integration Simplified
Mule ESB - Integration SimplifiedMule ESB - Integration Simplified
Mule ESB - Integration Simplified
 

Similar to Overview of Mule (20)

Mulesoftppt
Mulesoftppt Mulesoftppt
Mulesoftppt
 
ESB introduction using Mule
ESB introduction using MuleESB introduction using Mule
ESB introduction using Mule
 
Mule enterprise service bus
Mule enterprise service busMule enterprise service bus
Mule enterprise service bus
 
Overview of Mule
Overview of MuleOverview of Mule
Overview of Mule
 
Mule overview
Mule overviewMule overview
Mule overview
 
Mule Overview
Mule OverviewMule Overview
Mule Overview
 
Mule overview
Mule overviewMule overview
Mule overview
 
Mule overview
Mule overviewMule overview
Mule overview
 
Mule overview
Mule overviewMule overview
Mule overview
 
Mule esb
Mule esbMule esb
Mule esb
 
Mule
MuleMule
Mule
 
Mule esb usecase
Mule esb usecaseMule esb usecase
Mule esb usecase
 
Mule overview
Mule overviewMule overview
Mule overview
 
Mule introduction
Mule introductionMule introduction
Mule introduction
 
Mule overview
Mule overviewMule overview
Mule overview
 
mule-overview.ppt
mule-overview.pptmule-overview.ppt
mule-overview.ppt
 
Red Hat Open Day JBoss Fuse
Red Hat Open Day JBoss FuseRed Hat Open Day JBoss Fuse
Red Hat Open Day JBoss Fuse
 
Mule core concepts
Mule core conceptsMule core concepts
Mule core concepts
 
Introduction to esbs mule
Introduction to esbs  muleIntroduction to esbs  mule
Introduction to esbs mule
 
Mule and web services
Mule and web servicesMule and web services
Mule and web services
 

More from AbdulImrankhan7

Web services Overview in depth
Web services Overview in depthWeb services Overview in depth
Web services Overview in depthAbdulImrankhan7
 
Install sonarqube plugin
Install sonarqube plugin Install sonarqube plugin
Install sonarqube plugin AbdulImrankhan7
 
Github plugin setup in anypoint studio
Github plugin setup in anypoint studio Github plugin setup in anypoint studio
Github plugin setup in anypoint studio AbdulImrankhan7
 
Mule Database component
Mule Database component Mule Database component
Mule Database component AbdulImrankhan7
 
Deploying and running in mule standalone
Deploying and running in mule standaloneDeploying and running in mule standalone
Deploying and running in mule standaloneAbdulImrankhan7
 
Webservice with vm in mule
Webservice with vm in muleWebservice with vm in mule
Webservice with vm in muleAbdulImrankhan7
 
Validating a soap request in mule
Validating a soap request in mule Validating a soap request in mule
Validating a soap request in mule AbdulImrankhan7
 
Simple groovy example in mule
Simple groovy example in muleSimple groovy example in mule
Simple groovy example in muleAbdulImrankhan7
 
Scatter gather flow control
Scatter gather flow control Scatter gather flow control
Scatter gather flow control AbdulImrankhan7
 

More from AbdulImrankhan7 (20)

Web services Overview in depth
Web services Overview in depthWeb services Overview in depth
Web services Overview in depth
 
Install sonarqube plugin
Install sonarqube plugin Install sonarqube plugin
Install sonarqube plugin
 
Junit in mule
Junit in muleJunit in mule
Junit in mule
 
commit a project in svn
commit a project in svncommit a project in svn
commit a project in svn
 
Github plugin setup in anypoint studio
Github plugin setup in anypoint studio Github plugin setup in anypoint studio
Github plugin setup in anypoint studio
 
For each component
For each component For each component
For each component
 
Filter expression
Filter expressionFilter expression
Filter expression
 
Mule File component
Mule File component Mule File component
Mule File component
 
Mule Database component
Mule Database component Mule Database component
Mule Database component
 
Mule Choice component
Mule Choice component Mule Choice component
Mule Choice component
 
Mule stored procedure
Mule stored procedureMule stored procedure
Mule stored procedure
 
Deploying and running in mule standalone
Deploying and running in mule standaloneDeploying and running in mule standalone
Deploying and running in mule standalone
 
Mule real-world
Mule real-worldMule real-world
Mule real-world
 
Webservice with vm in mule
Webservice with vm in muleWebservice with vm in mule
Webservice with vm in mule
 
Validating a soap request in mule
Validating a soap request in mule Validating a soap request in mule
Validating a soap request in mule
 
Using xslt in mule
Using xslt in mule Using xslt in mule
Using xslt in mule
 
Simple groovy example in mule
Simple groovy example in muleSimple groovy example in mule
Simple groovy example in mule
 
Scatter gather flow control
Scatter gather flow control Scatter gather flow control
Scatter gather flow control
 
Mule with velocity
Mule with velocity Mule with velocity
Mule with velocity
 
Mule with rabbit mq
Mule with rabbit mqMule with rabbit mq
Mule with rabbit mq
 

Recently uploaded

Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsPrecisely
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 

Recently uploaded (20)

Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power Systems
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 

Overview of Mule

  • 1. Introduction to Open-Source ESB Abdul Imran Khan 1
  • 2.  What is Mule?  How do you use Mule?  What are the core Mule concepts?  Learning mule with File endpoints 2
  • 3.  Mule is an open-source Enterprise Service Backbone (ESB) 3
  • 4.  SEDA  Staged Event-Driven Architecture  Java NIO  Java New Input/Output 4
  • 5.  SEDA decomposes a complex, event-driven software application into a set of stages connected by queues  This design avoids the high overhead associated with thread-based concurrency models, and decouples event and thread scheduling from application logic  By performing admission control on each event queue, the service can be well-conditioned to load, preventing resources from being overcommitted when demand exceeds service capacity  SEDA employs dynamic control to automatically tune runtime parameters (such as the scheduling parameters of each stage) as well as to manage load, for example, by performing adaptive load shedding  Decomposing services into a set of stages also enables modularity and code reuse, as well as the development of debugging tools for complex event-driven applications 5
  • 6.  NIO is a collection of Java programming language APIs that offer advanced features for intensive I/O operations  NIO facilitates an implementations that can directly use the most efficient operations of the underlying platform  NIO includes:  Buffers for data of primitive types  Character set encoders and decoders  A pattern-matching facility based on Perl-style regular expressions (in package java.util.regex)  Channels, a new primitive I/O abstraction  A file interface that supports locks and memory mapping  A multiplexed, non-blocking I/O facility for writing scalable servers 6
  • 7.  Folder to folder  Queue to queue  Shared memory to shared memory  Using different types of transports  In a flexible way 7
  • 8.  An XML pipeline is a series of operation that are performed on one or more XML files  Examples include:  validate  transform  prune (remove nodes)  split (break a single XML file into many files)  merge (join two or more files together) 8
  • 9.  Flow of XML document through approval processes 9 Submit CRV Deed Matched CRV SSN Stripped CRV Income Tax Audit County Audit County Approval State Audit State Approval
  • 10.  Example of XML Operations used on CRV 10 Validate Split Remove SSN Element Store Modify Value Add Element Modify Value Add Element
  • 11.  Focus on specifying "What" not "How"  Empower business analysis to write machine- readable specifications  Hide the "How" behind services with clear interfaces (SOA) 11
  • 12.  Mule Manager  Mule Model  Universal Message Object (UMO)  Endpoints  External Applications 12
  • 13.  A UMO is a type of Java object that can receive events "from anywhere" send events  UMO Components are usually your business objects. They are components that execute business logic on an incoming event  UMO are standard JavaBeans (containers)  There is no Mule-specific code in your components  Mule handles all routing and transformation of events to and from your objects based on the configuration of your component 13
  • 14.  A transport or "provider", is a set of objects that add support to Mule to handle a specific kind of transport or protocol  Examples  the "Email Provider" enables Mule to send and receive messages via the SMTP, POP and IMAP protocols 14
  • 15.  A connector is the object that sends and receives messages on behalf of an endpoint.  Connectors are bundled as part of specific transports or providers.  For example, the FileConnector can read and write file system files. 15
  • 16.  A router is the object that do something with messages once they have been received by a connector, or prior to being sent out by the connector 16
  • 17.  A filter optionally filters incoming or outgoing messages that are coming into or going out from a connector.  For example, the File Provider comes with a FilenameWildcardFilter that restricts which files are read by the connector based on file name patterns. For example only files with the .xml extension can be routed.  Filters are used in conjunction with Routers. 17
  • 18.  A transformer optionally changes incoming or outgoing messages in some way  This is usually done to make the message format useable by a downstream function  Examples:  the ByteArrayToString transformer converts byte arrays into String objects. 18
  • 19.  The nine stages of a mule event  first 2 – inbound  middle 4 – component  last 2 – outbound 19 Endpoint (Message Receiver) Endpoint (Message Dispatcher) Inbound Router Outbound Router Inbound Transformer Outbound Transformer Interceptor Service Invocation Interceptor Inbound Component Outbound Optional Step
  • 20.  Some event triggers a message flow  A file being written into a folder  A message arriving on a message queue  A record in a database  Data written to a socket 20 Endpoint (Message Dispatcher) Inbound Router Outbound Router Inbound Transformer Outbound Transformer Interceptor Service Invocation Interceptor Endpoint (Message Receiver)
  • 21.  The inbound router is the fist step in a message. Functions typically performed by an inbound router  Filtering  Remove duplicate messages  Matching messages  Aggregation (combining)  Re-sequence data  Forwarding  See also  IdempotentReceiver  CorrolationAggregator  CorrelationResequencer 21 Endpoint (Message Dispatcher) Inbound Router Outbound Router Inbound Transformer Outbound Transformer Interceptor Service Invocation Interceptor Endpoint (Message Receiver)
  • 22.  Used to intercept message flow into your service component  Used trigger monitor/events or interrupt the flow of the message  Example: an authorization interceptor could ensure that the current request has the correct credentials to invoke the service. 22 Endpoint (Message Dispatcher) Inbound Router Outbound Router Inbound Transformer Outbound Transformer Service Invocation Interceptor Endpoint (Message Receiver) Interceptor
  • 23.  If the inbound data is not in the correct format for the service it must be transformed at this point 23 Endpoint (Message Receiver) Endpoint (Message Dispatcher) Inbound Router Outbound Router Outbound Transformer Interceptor Service Invocation Interceptor Inbound Transformer
  • 24.  The actual service is performed  In mule, this is generally a Java object  Service invocation can also be a "pass through" 24 Endpoint (Message Receiver) Endpoint (Message Dispatcher) Inbound Router Outbound Router Outbound Transformer Interceptor Interceptor Inbound Transformer Service Invocation
  • 25.  Dispatching the data to all the relevant endpoints 25 Endpoint (Message Receiver) Endpoint (Message Dispatcher) Inbound Router Outbound Transformer Interceptor Interceptor Inbound Transformer Service Invocation Outbound Router
  • 26. Inbound Outbound Response Idempotent Receiver Filtering Outbound Router Response Aggregator Selective Consumer Recipient List Aggregator Multicasting Router Resequencer Chaining Router Forwarding Consumer Message Splitter Filtering List Message Splitter Filtering Xml Message Splitter Exception Based Router 26
  • 27.  Any transformations that needs to be done on the message after a service has been performed on the message can be executed before it is put into the endpoint  See Also EnvelopeInterceptor 27 Endpoint (Message Receiver) Endpoint (Message Dispatcher) Inbound Router Interceptor Interceptor Inbound Transformer Service Invocation Outbound Router Outbound Transformer
  • 28. 28
  • 29. <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE mule-configuration PUBLIC "-//MuleSource //DTD mule-configuration XML V1.0//EN" "http://mule.mulesource.org/dtds/mule- configuration.dtd"> 29
  • 31. <mule-configuration id="Mule_File_Move" version=" 1.0"> <connector name="SystemStreamConnector" className="org.mule.providers.stream.SystemStreamConnec tor"/> <model name="move-all-files"> <mule-descriptor name="move-file" implementation="org.mule.components.simple.BridgeCompon ent"> <inbound-router> <endpoint address="file:///c:/tmp/in"/> </inbound-router> <outbound-router> <router className="org.mule.routing.outbound.OutboundPassThroug hRouter"> <endpoint address="file:///c:/tmp/out"/> </router> </outbound-router> </mule-descriptor> </model> </mule-configuration> 31
  • 32. <inbound-router> <endpoint address="file:///c:/mule-class/in"> <filter pattern="*.xml" className= "org.mule.providers.file.filters.FilenameWildcardFilter"/> </endpoint> </inbound-router> 32 Add the filter line to only move files with the extension "*.xml". If you add a file "foobar.txt to the input folder it will not be moved.
  • 34.  By default, error free documents follow a central path known as the "happy path"  Documents that have errors may be handled in different ways (rejected, warnings etc.) 34 Start StopStep 1 Step 2 Step 3 Stop Stop Stop
  • 35.  Mule has a special way of handling non-happy path processing. This is called an "Exception Strategy" but is it really just and exception path and there is very little strategy involved.  There are three places you can associate an exception strategy  connector  component  model (set for all components in a model) 35
  • 37. <?xml version="1.0" encoding="UTF-8"?> <Data> <Element1>Hello World!</Element1> <Element2>String</Element2> <Element3>String</Element3> <DansInvalidDataElement>This is Dans invalid data element</DansInvalidDataElement> </Data> 37 XML Schema validation will generate an error message when it gets to the fourth invalid data element: Given the following XML Schema file:
  • 38. <outbound-router> <router className="org.mule.routing.outbound.FilteringXmlMessageSplitter"> <endpoint address="file:///c:/mule-class/out?outputPattern=$[ORIGINALNAME]"/> <properties> <property name="validateSchema" value="true"/> <property name="externalSchemaLocation" value="file:///c:/mule-class/labs/07-validate/my- schema.xsd"/> </properties> </router> </outbound-router> 38 To validate the XML Schema, just add two properties: 1) tell it to validate the document 2) tell it what file to use and where to find it
  • 39. document : cvc-complex-type.2.4.d: Invalid content was found starting with element 'DansInvalidDataElement'. No child element is expected at this point. 39 This error message is generated on the Mule console when an invalid data element is found. But what should we do with it? How do we redirect it to the appropriate user?
  • 40. Please contact me for more information:  Enterprise Service Bus  Enterprise Integration  Metadata Management  Metadata Registries  Service Oriented Architectures  Business Intelligence and Data Warehouse  Semantic Web 40