public class InterceptSendToEndpointProcessor extends DefaultAsyncProducer
Processor used to interceptor and detour the routing
when using the InterceptSendToEndpoint functionality.logshutdown, shuttingdown, started, starting, stopped, stopping, suspended, suspending| Constructor and Description |
|---|
InterceptSendToEndpointProcessor(InterceptSendToEndpoint endpoint,
Endpoint delegate,
Producer producer,
boolean skip) |
| Modifier and Type | Method and Description |
|---|---|
Exchange |
createExchange()
Creates a new exchange to send to this endpoint
|
Exchange |
createExchange(Exchange exchange)
Deprecated.
|
Exchange |
createExchange(ExchangePattern pattern)
Creates a new exchange of the given pattern to send to this endpoint
|
Endpoint |
getEndpoint()
Gets the endpoint associated with an object.
|
boolean |
isSingleton()
This implementation will delegate to the endpoint
IsSingleton.isSingleton() |
boolean |
process(Exchange exchange,
AsyncCallback callback)
Processes the message exchange.
|
void |
start()
Important: You should override the lifecycle methods that start with do, eg
ServiceSupport.doStart(),
ServiceSupport.doStop(), etc. |
void |
stop()
Important: You should override the lifecycle methods that start with do, eg
ServiceSupport.doStart(),
ServiceSupport.doStop(), etc. |
processdoStart, doStop, toStringdoResume, doShutdown, doSuspend, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, suspendpublic InterceptSendToEndpointProcessor(InterceptSendToEndpoint endpoint, Endpoint delegate, Producer producer, boolean skip) throws Exception
Exceptionpublic Endpoint getEndpoint()
EndpointAwareProducer
or for consuming from for components like Consumer or RoutegetEndpoint in interface EndpointAwaregetEndpoint in class DefaultProducerpublic Exchange createExchange()
ProducercreateExchange in interface ProducercreateExchange in class DefaultProducerpublic Exchange createExchange(ExchangePattern pattern)
ProducercreateExchange in interface ProducercreateExchange in class DefaultProducerpattern - the exchange pattern@Deprecated public Exchange createExchange(Exchange exchange)
ProducercreateExchange in interface ProducercreateExchange in class DefaultProducerexchange - the existing exchangepublic boolean process(Exchange exchange, AsyncCallback callback)
AsyncProcessorProcessor.process(org.apache.camel.Exchange), but the caller supports having the exchange asynchronously processed.
If there was a failure processing then the caused Exception would be set on the Exchange.exchange - the message exchangecallback - the AsyncCallback will be invoked when the processing of the exchange is completed.
If the exchange is completed synchronously, then the callback is also invoked synchronously.
The callback should therefore be careful of starting recursive loop.public boolean isSingleton()
DefaultProducerIsSingleton.isSingleton()isSingleton in interface IsSingletonisSingleton in class DefaultProducerpublic void start() throws Exception
ServiceSupportServiceSupport.doStart(),
ServiceSupport.doStop(), etc. where you implement your logic. The methods ServiceSupport.start(), ServiceSupport.stop() should
NOT be overriden as they are used internally to keep track of the state of this service and properly
invoke the operation in a safe manner.start in interface Servicestart in class ServiceSupportException - is thrown if starting failedpublic void stop() throws Exception
ServiceSupportServiceSupport.doStart(),
ServiceSupport.doStop(), etc. where you implement your logic. The methods ServiceSupport.start(), ServiceSupport.stop() should
NOT be overriden as they are used internally to keep track of the state of this service and properly
invoke the operation in a safe manner.stop in interface Servicestop in class ServiceSupportException - is thrown if stopping failedApache Camel