public interface AsyncProducerCallback
AsyncProcessorcapable 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.
boolean doInAsyncProducer(Producer producer, AsyncProcessor asyncProducer, Exchange exchange, ExchangePattern exchangePattern, AsyncCallback callback)
producer- the producer, is newer null
asyncProducer- the async producer, is newer null
exchange- the exchange, can be null if so then create a new exchange from the producer
exchangePattern- the exchange pattern, can be null
callback- the async callback