SlideShare a Scribd company logo
Mule Request Reply
By Ram Bavireddi
• Sometimes we want response from an asynchronous Mule
flow .
• For example, we want response from a one-way VM or JMS
flow .
• How is it possible?
• Mule’s Request Reply scope makes is possible
Mule Request Reply
• The Request Reply enables us to receive a response from an
asynchronous flow without hard coding the destination of the
response
• We can convert a one-way VM or JMS flow to a request-
response flow without having to change it’s configuration
Let us get response from this one-way VM flow
Using Request Reply
Testing
• Test the flow by hitting this url http://localhost:8081/test
• We can see below logger on the console
org.mule.api.processor.LoggerMessageProcessor: one -
way VM payload
• So the Request Reply waits for the response from the one-
way VM flow
• How it works?
How it works?
• When Mule asynchronously sends a request via the VM
outbound-endpoint in the Request-Reply scope, it implicitly
sets the message’s outbound property – MULE_REPLYTO
• The value of this MULE_REPLYTO property would refer to path
of inbound-endpoint in the Request-Reply scope
When an Exception occurs in the one-way VM flow
• When an Exception occurs in the one-way VM flow, Mule is
unable to call the inbound-endpoint in the Request-Reply
scope.
• In such a case we need to explicitly call the inbound-endpoint
by handling the exception. Otherwise the caller flow where
Request-Reply is configured waits infinitely for the response
from the one-way VM flow
When an Exception occurs in the one-way VM flow
Let us suppose the component org.ram.BusinessComponent
throws an exception
Mule Request Reply

More Related Content

PPTX
Mule JMS Transport
PPT
Simple VM in Mule
PPT
Mule overview
 
PPTX
Mule: Java Component
PPTX
Mule rabbitmq
PPTX
What is the difference between using private flow
PPTX
Mule Amazon SNS Connector
PPT
Overview of Mule
Mule JMS Transport
Simple VM in Mule
Mule overview
 
Mule: Java Component
Mule rabbitmq
What is the difference between using private flow
Mule Amazon SNS Connector
Overview of Mule

What's hot (18)

PPTX
JMS Backchannel
PPTX
Mule concepts components
PPTX
PPTX
Mule esb usecase
PPTX
Jms queue
PPTX
Mule java part-1
PPTX
Introduction java messaging services
PPTX
Vm transport
PPT
Mule overview-ppt
PPT
Mule overview
PPTX
Muletransformers
PPT
Mule esb introduction
PPTX
Mule jms-topics
PPTX
Mule threading profile & processing strategy
PPT
Mule overview
PPTX
Rabbit Mq in Mule
PPTX
Mule servlet connector
PPTX
Message structure
JMS Backchannel
Mule concepts components
Mule esb usecase
Jms queue
Mule java part-1
Introduction java messaging services
Vm transport
Mule overview-ppt
Mule overview
Muletransformers
Mule esb introduction
Mule jms-topics
Mule threading profile & processing strategy
Mule overview
Rabbit Mq in Mule
Mule servlet connector
Message structure
Ad

Similar to Mule Request Reply (13)

PPTX
Mule scopes request_response_scope
PPTX
How to use Request Reply scope
PPTX
PPTX
Mule integration
PPTX
Mule esb mule message
PPTX
Mule message
PPT
Rest Service In Mule
PPT
Rest service in mule
PPTX
Mule requesterdemo
ODP
Mule scopes&error handling
PPTX
Mule esb overview
PPTX
Mule requester
PPT
Introduction to es bs mule
Mule scopes request_response_scope
How to use Request Reply scope
Mule integration
Mule esb mule message
Mule message
Rest Service In Mule
Rest service in mule
Mule requesterdemo
Mule scopes&error handling
Mule esb overview
Mule requester
Introduction to es bs mule
Ad

Recently uploaded (20)

PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
Empathic Computing: Creating Shared Understanding
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Approach and Philosophy of On baking technology
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
A Presentation on Artificial Intelligence
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
Cloud computing and distributed systems.
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Building Integrated photovoltaic BIPV_UPV.pdf
Empathic Computing: Creating Shared Understanding
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Mobile App Security Testing_ A Comprehensive Guide.pdf
Approach and Philosophy of On baking technology
Dropbox Q2 2025 Financial Results & Investor Presentation
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Reach Out and Touch Someone: Haptics and Empathic Computing
Unlocking AI with Model Context Protocol (MCP)
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
A Presentation on Artificial Intelligence
The AUB Centre for AI in Media Proposal.docx
Cloud computing and distributed systems.
Diabetes mellitus diagnosis method based random forest with bat algorithm
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx

Mule Request Reply

  • 1. Mule Request Reply By Ram Bavireddi
  • 2. • Sometimes we want response from an asynchronous Mule flow . • For example, we want response from a one-way VM or JMS flow . • How is it possible? • Mule’s Request Reply scope makes is possible
  • 3. Mule Request Reply • The Request Reply enables us to receive a response from an asynchronous flow without hard coding the destination of the response • We can convert a one-way VM or JMS flow to a request- response flow without having to change it’s configuration
  • 4. Let us get response from this one-way VM flow
  • 6. Testing • Test the flow by hitting this url http://localhost:8081/test • We can see below logger on the console org.mule.api.processor.LoggerMessageProcessor: one - way VM payload • So the Request Reply waits for the response from the one- way VM flow • How it works?
  • 7. How it works? • When Mule asynchronously sends a request via the VM outbound-endpoint in the Request-Reply scope, it implicitly sets the message’s outbound property – MULE_REPLYTO • The value of this MULE_REPLYTO property would refer to path of inbound-endpoint in the Request-Reply scope
  • 8. When an Exception occurs in the one-way VM flow • When an Exception occurs in the one-way VM flow, Mule is unable to call the inbound-endpoint in the Request-Reply scope. • In such a case we need to explicitly call the inbound-endpoint by handling the exception. Otherwise the caller flow where Request-Reply is configured waits infinitely for the response from the one-way VM flow
  • 9. When an Exception occurs in the one-way VM flow Let us suppose the component org.ram.BusinessComponent throws an exception