Package org.apache.camel.spi
Interface ProducerCache.AsyncProducerCallback
-
- Enclosing interface:
- ProducerCache
public static interface ProducerCache.AsyncProducerCallbackCallback for sending a exchange message to a endpoint using anAsyncProcessorcapable producer. Using this callback as a template pattern ensures that Camel handles the resource handling and will start and stop the given producer, to avoid resource leaks.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleandoInAsyncProducer(AsyncProducer asyncProducer, Exchange exchange, AsyncCallback callback)Performs operation on the given producer to send the given exchange.
-
-
-
Method Detail
-
doInAsyncProducer
boolean doInAsyncProducer(AsyncProducer asyncProducer, Exchange exchange, AsyncCallback callback)
Performs operation on the given producer to send the given exchange.- Parameters:
asyncProducer- the async producer, is never nullexchange- the exchange to processcallback- the async callback- Returns:
- (doneSync) true to continue execute synchronously, false to continue being executed asynchronously
-
-