public interface ResponseRouter extends Router
ResponseRouter
is a router that handles response flow. Response
Aggregators are used to collect responses that are usually sent to replyTo
endpoints set on outbound routers. When an event is sent out via an outbound
router, the response router will block the response flow on an Service until
the Response Router resolves a reply or times out.PHASE_NAME
PHASE_NAME
Modifier and Type | Method and Description |
---|---|
MuleMessage |
getResponse(MuleMessage message)
Called by the Mule framework once the outbound router has been processed on a
service the Message passed in is the response message from the service (or
outbount router if a response was returned).
|
int |
getTimeout()
Returns the timeout delay that the response router should wait for a response
for a given event.
|
boolean |
isFailOnTimeout()
Should the router fail and throw an exception if a timeout occurs or should it return
the events received so far.
|
void |
process(MuleEvent event)
This method is invoked when an event is received via an endpoint on this
Response Router.
|
void |
setFailOnTimeout(boolean fail)
Should the router fail and throw an exception if a timeout occurs or should it return
the events received so far.
|
void |
setTimeout(int timeout)
Sets the timeout delay that the response router should wait for a response for
a given event.
|
getRouterStatistics, setRouterStatistics
initialise
dispose
void process(MuleEvent event) throws RoutingException
event
- RoutingException
MuleMessage getResponse(MuleMessage message) throws RoutingException
message
- The processed message from the ServiceRoutingException
MuleMessage
,
Service
void setTimeout(int timeout)
timeout
- the time in milliseconds to wait for a response eventint getTimeout()
void setFailOnTimeout(boolean fail)
fail
- boolean isFailOnTimeout()
Copyright © 2003–2013 MuleSource, Inc.. All rights reserved.