public interface ProducerCallback<T>
T doInProducer(Producer producer, Exchange exchange, ExchangePattern exchangePattern) throws Exception
producer- the producer, is never null
exchange- the exchange, can be null if so then create a new exchange from the producer
exchangePattern- the exchange pattern, can be null
Exception- if an internal processing error has occurred.