Mule ESB Strategy to handle Socket read timed out exceptions - mule

what is the best approach to handle exceptions that arise out from IO exceptions. I have a jms endpoint which listens to messages on a queue. i realized my error handler is not handling errors that result from message queue not being accessed due to socket time out errors.
I tried creating a defaultsystemexception strategy but that does not work on mule 3.4.
the exception trace is as follows
ERROR 2013-12-17 17:39:52,419 [Thread-2] org.mule.exception.DefaultSystemExceptionStrategy:
********************************************************************************
Message : java.sql.SQLException: Io exception: Socket read timed out (javax.jms.JMSException)
Code : MULE_ERROR--2
--------------------------------------------------------------------------------
Exception stack is:
1. java.sql.SQLException: Io exception: Socket read timed out(JMS Code: null) (javax.jms.JMSException)
oracle.jms.AQjmsExceptionListener:222 (http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/jms/JMSException.html)
2. java.sql.SQLException: Io exception: Socket read timed out (javax.jms.JMSException) (org.mule.transport.ConnectException)
org.mule.transport.jms.JmsConnector:508 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/transport/ConnectException.html)
--------------------------------------------------------------------------------
Root Exception stack trace:
javax.jms.JMSException: java.sql.SQLException: Io exception: Socket read timed out
at oracle.jms.AQjmsExceptionListener.run(AQjmsExceptionListener.java:222)
+ 1 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything)
********************************************************************************
kindly advise.
regards
Santosh

Based on the information provided in the question the following solution should be helpful
<choice-exception-strategy>
<catch-exception-strategy when="#[exception.causedBy(javax.jms.JMSException)]">
........ Processing of the Message.
....................
</catch-exception-strategy>
</choice-exception-strategy>
Hope this helps.

Related

AMQP MissedHeartbeatException

AMQP connector shuts down with MissedHeartbeatException at regular intervals. Below is the connector configuration and exception stack.I am new to AMQP connector any suggestions are appreciated.
I am using amqp transport 3.6.2 and mule server 3.7.2
AMQP Connector Config
<amqp:connector name="AMQP_Connector"
validateConnections="true" host="${amqp.host}"
doc:name="AMQP Connector" virtualHost="${amqp.vhost}"
password="${amqp.password}" port="${amqp.port}"
username="${amqp.user}" numberOfChannels="1">
Exception Details
****************************************************************************
Message : Connection shutdown detected for: AMQP_Connector
Code : MULE_ERROR--2
----------------------------------------------------------------------------
Exception stack is:
1. Heartbeat missing with heartbeat = 580 seconds (com.rabbitmq.client.MissedHeartbeatException)
com.rabbitmq.client.impl.AMQConnection:595 (null)
2. connection error (com.rabbitmq.client.ShutdownSignalException)
com.rabbitmq.client.impl.AMQConnection:715 (null)
3. Connection shutdown detected for: AMQP_Connector (org.mule.transport.ConnectException) org.mule.transport.amqp.internal.connector.AmqpConnector:321 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/transport/ConnectException.html)
---------------------------------------------------------------------------
Root Exception stack trace:
com.rabbitmq.client.MissedHeartbeatException: Heartbeat missing with heartbeat = 580 seconds
at com.rabbitmq.client.impl.AMQConnection.handleSocketTimeout(AMQConnection.java:595)
at com.rabbitmq.client.impl.AMQConnection.access$600(AMQConnection.java:65)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:558)
+ 3 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything)
****************************************************************************
23:44:54.972 03/09/2016 Worker-0 pool-18-thread-1 INFO
Exception caught is a ConnectException, attempting to reconnect...
23:44:54.981 03/09/2016 Worker-0 pool-18-thread-1 INFO
Stopping connector: AMQP_Connector
23:44:54.983 03/09/2016 Worker-0 pool-18-thread-1 INFO
Stopping: 'AMQP_Connector.dispatcher.341143089'. Object is: Dispatcher
23:44:54.984 03/09/2016 Worker-0 pool-18-thread-1 INFO
Disposing: 'AMQP_Connector.dispatcher.341143089'. Object is: Dispatcher
23:44:54.985 03/09/2016 Worker-0 pool-18-thread-1 ERROR
connection is already closed due to connection error; cause: com.rabbitmq.client.MissedHeartbeatException: Heartbeat missing with heartbeat = 580 seconds

mule ce 3.7.0 Exception when sending http-request - Timeout exceeded (java.util.concurrent.TimeoutException)

I'm trying to send a http request from my jax-ws client to my own jaw-ws service. I've generated classes from wsdl and sending an ArrayList of objects with 60 items in it. But i'm getting exception.
Exception stack is:
1. Timeout exceeded (java.util.concurrent.TimeoutException)
com.ning.http.client.providers.grizzly.GrizzlyAsyncHttpProvider:426 (null)
2. Error sending HTTP request. Message payload is of type: byte[] (org.mule.api.MessagingException)
org.mule.module.http.internal.request.DefaultHttpRequester:287 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule
/api/MessagingException.html)
Root Exception stack trace:
java.util.concurrent.TimeoutException: Timeout exceeded
at com.ning.http.client.providers.grizzly.GrizzlyAsyncHttpProvider.timeout(GrizzlyAsyncHttpProvider.java:426)
at com.ning.http.client.providers.grizzly.GrizzlyAsyncHttpProvider$3.onTimeout(GrizzlyAsyncHttpProvider.java:274)
at org.glassfish.grizzly.utils.IdleTimeoutFilter$DefaultWorker.doWork(IdleTimeoutFilter.java:398)
at org.glassfish.grizzly.utils.IdleTimeoutFilter$DefaultWorker.doWork(IdleTimeoutFilter.java:377)
at org.glassfish.grizzly.utils.DelayedExecutor$DelayedRunnable.run(DelayedExecutor.java:158)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Anyone has a solution for this?
I had the same problem and I solved using the parameter responseTimeout in the HTTP-Request configuration:
<http:request-config responseTimeout="30000" {more parameters...} />
Set the value (in ms) to the time that you think best.

Apache Camel fails after proxy when hitting the endPoint. SocketException

Can someone provide your thoughts. what is going wrong on my configuration.
This was one approach:
public CamelContext camelContext() throws Exception {
final SpringCamelContext camelContext = new SpringCamelContext();
camelContext.getProperties().put("http.proxyHost","webproxy.lon.corp.services");
camelContext.getProperties().put("http.proxyPort","80");
camelContext.addRoutes(new CortellisRouteBuilder(env));
return camelContext;
}
Second Approach
https4://xxxxxx/xxxx/ws/rs/xx-v1/match?authUsername=someUsernamexxx&authPassword=xxxxxxxxx&authMethod=Digest&proxyHost=webproxy.services.xxx.com&proxyPort=80&proxyAuthScheme=http4
both does not work. below is the exception that i receive. it does 3 retires and then fails.
Exchange[
Id ID-UC193537-TPL-A-54917-1428598980021-0-2
ExchangePattern InOut
Headers {breadcrumbId=ID-UC193537-TPL-A-54917-1428598980021-0-1,
CamelAcceptContentType=application/x-www-form-urlencoded,
CamelHttpMethod=POST,camelHttpQuery=text=Paracetamol,
camelRedelivered=false, CamelRedeliveryCounter=0}
BodyType null
Body [Body is null]]
====================================================================
I/O exception (java.net.SocketException) caught when processing request:
Software caused connection abort: recv failed
2015-04-09 18:04:36,876 - INFO [http-apr-8080-exec-
4:HttpMethodDirector.executeWithRetry#445] - Retrying request
2015-04-09 18:04:37,015 - INFO [http-apr-8080-exec-
4:HttpMethodDirector.executeWithRetry#439] - I/O exception
(java.net.SocketException) caught when processing request: Software caused
connection abort: recv failed
2015-04-09 18:04:37,015 - INFO [http-apr-8080-exec-
4:HttpMethodDirector.executeWithRetry#445] - Retrying request
2015-04-09 18:04:37,167 - INFO [http-apr-8080-exec-
4:HttpMethodDirector.executeWithRetry#439] - I/O exception
(java.net.SocketException) caught when processing request: Software caused
connection abort: recv failed
2015-04-09 18:04:37,168 - INFO [http-apr-8080-exec-
4:HttpMethodDirector.executeWithRetry#445] - Retrying request
2015-04-09 18:04:37,298 - ERROR [http-apr-8080-exec-
4:MarkerIgnoringBase.error#161] - Failed delivery for (MessageId: ID-
UC193537-TPL-A-54917-1428598980021-0-1 on ExchangeId: ID-UC193537-TPL-A-
54917-1428598980021-0-2). Exhausted after delivery attempt: 1 caught:
java.net.SocketException: Software caused connection abort: recv failed
====================================================================
java.net.SocketException: Software caused connection abort: recv failed
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:173)
at java.net.SocketInputStream.read(SocketInputStream.java:122)
at sun.security.ssl.InputRecord.readFully(InputRecord.java:442)
at sun.security.ssl.InputRecord.read(InputRecord.java:480)
at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:934)
at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1332)
at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:709)
at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:122)
at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
at
This error can occur when the local network system aborts a connection, see e.g. java.net.SocketException: Software caused connection abort: recv failed.
The proxy server may abort the connection. Can you try to connect to your service directly (= not through your proxy)?
cortellis.ontologiesNerUrl=https4://xxxx/ls-api-ws/ws/rs/xxxx-v1/ner?proxyPort=80&proxyHost=xxxxxxxx&authMethod=Basic&authUsername=TR_Internal_024&authPassword=ZTYA5S1KLF7WCDMN&**proxyAuthScheme=http4**
with addition of proxyAuthScheme=http4 it worked for rest based URL, But not for SOAP based URL
i have picked the latest camel version 2.15.1

Message Processor unable to send message from message store to endpoint in wso2 esb

I am getting the following error while my message processor trying to send the message from the message store.
content type used in proxy:
<property name="CONTENT_TYPE" value="appliaction/soap+xml" scope="axis2" />
error in esb log:
ERROR {org.apache.synapse.message.processor.impl.forwarder.ForwardingService} - BlockingMessageSender of message processor [My_Processor] failed to send message to the endpoint {org.apache.synapse.message.processor.impl.forwarder.ForwardingService}
WARN {org.apache.synapse.message.processor.impl.forwarder.ForwardingService} - Failed to send the message through the fault sequence, Sequence name null does not Exist. {org.apache.synapse.message.processor.impl.forwarder.ForwardingService}
I have changed my content type but now getting another error. Find the error log :
ERROR {org.apache.synapse.message.senders.blocking.BlockingMsgSender} - Error sending Message to url : http://localhost:9000/services/SimpleStockQuoteService {org.apache.synapse.message.senders.blocking.BlockingMsgSender}
org.apache.axis2.AxisFault: Read timed out
at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:197)
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:451)
at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:278)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:442)
at org.apache.axis2.description.OutOnlyAxisOperationClient.executeImpl(OutOnlyAxisOperation.java:297)
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:149)
at org.apache.synapse.message.senders.blocking.BlockingMsgSender.sendRobust(BlockingMsgSender.java:198)
at org.apache.synapse.message.senders.blocking.BlockingMsgSender.send(BlockingMsgSender.java:144)
at org.apache.synapse.message.processor.impl.forwarder.ForwardingService.dispatch(ForwardingService.java:288)
at org.apache.synapse.message.processor.impl.forwarder.ForwardingService.execute(ForwardingService.java:128)
at org.quartz.core.JobRunShell.run(JobRunShell.java:213)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557)
Caused by: java.net.SocketTimeoutException: Read timed out
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:129)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
at java.io.BufferedInputStream.read(BufferedInputStream.java:237)
at org.apache.commons.httpclient.HttpParser.readRawLine(HttpParser.java:78)
at org.apache.commons.httpclient.HttpParser.readLine(HttpParser.java:106)
at org.apache.commons.httpclient.HttpConnection.readLine(HttpConnection.java:1116)
at org.apache.commons.httpclient.MultiThreadedHttpConnectionManager$HttpConnectionAdapter.readLine(MultiThreadedHttpConnectionManager.java:1413)
at org.apache.commons.httpclient.HttpMethodBase.readStatusLine(HttpMethodBase.java:1973)
at org.apache.commons.httpclient.HttpMethodBase.readResponse(HttpMethodBase.java:1735)
at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1098)
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398)
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
at org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:622)
at org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:193)
... 12 more

Mule ESB: why AMQP is shutting down in-between the flow with error message (Received shutdown signal for consumer tag)

I'm using AMQP connector,and my queues are present in cluster envt. I'm not sure why this message is populated always. But this is not affecting any success running flow. But it is trying to try connections always.
I'm using Amqp transport jar: 3.4.4 ( Even I tried importing with latest jar 3.4.6 jar) same error has happening again.
Amqp client: 3.2.1.
I'm totally confused.
Because I tried the same queues which is not present in cluster it works fine.
Please suggest me where i'm doing wrong.
Using Ack( Manual) changed to 'MULE_AUTO' also. Helpless.
WARN 2015-01-29 14:47:29,639 [amqpReceiver.01] org.mule.transport.amqp.internal.endpoint.receiver.MessageReceiverConsumer: Received shutdown signal for consumer tag: amq.ctag-13inp2uTSjUnIgiNjyFYAA, the message receiver will try to restart.
com.rabbitmq.client.ShutdownSignalException: connection error; reason: java.io.EOFException
at com.rabbitmq.client.impl.AMQConnection.startShutdown(AMQConnection.java:715)
at com.rabbitmq.client.impl.AMQConnection.shutdown(AMQConnection.java:705)
atcom.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:564)
Caused by: java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
at com.rabbitmq.client.impl.Frame.readFrom(Frame.java:95)
at com.rabbitmq.client.impl.SocketFrameHandler.readFrame(SocketFrameHandler.java:131)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:533)
WARN 2015-01-29 14:47:29,642 [amqpReceiver.03] org.mule.transport.amqp.internal.endpoint.receiver.MessageReceiverConsumer: Received shutdown signal for consumer tag: amq.ctag-G-xCK-Uj-0aF7LcrYIuo3A, the message receiver will try to restart.
com.rabbitmq.client.ShutdownSignalException: connection error; reason: java.io.EOFException
at com.rabbitmq.client.impl.AMQConnection.startShutdown(AMQConnection.java:715)
at com.rabbitmq.client.impl.AMQConnection.shutdown(AMQConnection.java:705)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:564)
Caused by: java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
at com.rabbitmq.client.impl.Frame.readFrom(Frame.java:95)
at com.rabbitmq.client.impl.SocketFrameHandler.readFrame(SocketFrameHandler.java:131)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:533)
WARN 2015-01-29 14:47:29,642 [amqpReceiver.02] org.mule.transport.amqp.internal.endpoint.receiver.MessageReceiverConsumer: Received shutdown signal for consumer tag: amq.ctag-seeeDsnuB_1sSuo97C8OdQ, the message receiver will try to restart.
com.rabbitmq.client.ShutdownSignalException: connection error; reason: java.io.EOFException
at com.rabbitmq.client.impl.AMQConnection.startShutdown(AMQConnection.java:715)
at com.rabbitmq.client.impl.AMQConnection.shutdown(AMQConnection.java:705)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:564)
Caused by: java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
at com.rabbitmq.client.impl.Frame.readFrom(Frame.java:95)
at com.rabbitmq.client.impl.SocketFrameHandler.readFrame(SocketFrameHandler.java:131)
at com.rabbitmq.client.impl.AMQConnection$MainLoop.run(AMQConnection.java:533)
ERROR 2015-01-29 14:47:29,665 [AMQP Connection] org.mule.exception.DefaultSystemExceptionStrategy:
********************************************************************************
Message : Connection shutdown detected for: AMQP_Connector
Code : MULE_ERROR--2
--------------------------------------------------------------------------------
Exception stack is:
1. null (java.io.EOFException)
java.io.DataInputStream:290 (null)
2. connection error; reason: java.io.EOFException (com.rabbitmq.client.ShutdownSignalException)
com.rabbitmq.client.impl.AMQConnection:715 (null)
3. Connection shutdown detected for: AMQP_Connector (org.mule.transport.ConnectException)
org.mule.transport.amqp.internal.connector.AmqpConnector$1:296 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/transport/ConnectEx ception.html)
--------------------------------------------------------------------------------
Root Exception stack trace:
java.io.EOFException
at java.io.DataInputStream.readUnsignedByte(DataInputStream.java:290)
at com.rabbitmq.client.impl.Frame.readFrom(Frame.java:95)
at com.rabbitmq.client.impl.SocketFrameHandler.readFrame(SocketFrameHandler.java:131)
+ 3 more (set debug level logging or '-Dmule.verbose.exceptions=true' for everything)
********************************************************************************
INFO 2015-01-29 14:47:29,696 [AMQP Connection ] org.mule.exception.DefaultSystemExceptionStrategy: Exception caught is a ConnectException, attempting to reconnect...
ERROR 2015-01-29 14:47:29,698 [amqpReceiver.03] org.mule.exception.DefaultSystemExceptionStrategy:
********************************************************************************
Message : Impossible to create new channels on connection: amqp://test#11.11.2000.111:1234/
Code : MULE_ERROR--2
--------------------------------------------------------------------------------
Exception stack is:
1. clean connection shutdown; reason: Attempt to use closed connection (com.rabbitmq.client.AlreadyClosedException)
com.rabbitmq.client.impl.AMQConnection:168 (null)
2. Impossible to create new channels on connection: amqp://test#11.11.2000.111:1234/ (org.mule.transport.ConnectException)
org.mule.transport.amqp.internal.client.ChannelHandler:204 (http://www.mulesoft.org/docs/site/current3/apidocs/org/mule/transport/ConnectEx ception.html)
ERROR 2015-01-29 15:12:51,604 [amqpReceiver.34] org.mule.transport.amqp.internal.endpoint.receiver.MultiChannelMessageSubReceiver: Failed to restart: MultiChannelMessageSubReceiver(.....)
Edit:
org.mule.api.MessagingException: Failed to ack message w/deliveryTag: 1 on channel: AMQChannel(amqp://ezibuy#10.10.19.159:5672/,1) (org.mule.api.DefaultMuleException). Message payload is of type: String
at org.mule.execution.ExceptionToMessagingExceptionExecutionInterceptor.execute(ExceptionToMessagingExceptionExecutionInterceptor.java:32)
at org.mule.execution.MessageProcessorNotificationExecutionInterceptor.execute(MessageProcessorNotificationExecutionInterceptor.java:58)
at org.mule.execution.MessageProcessorExecutionTemplate.execute(MessageProcessorExecutionTemplate.java:44)
at org.mule.processor.chain.DefaultMessageProcessorChain.doProcess(DefaultMessageProcessorChain.java:94)
at org.mule.processor.chain.AbstractMessageProcessorChain.process(AbstractMessageProcessorChain.java:67)
at org.mule.processor.chain.InterceptingChainLifecycleWrapper.doProcess(InterceptingChainLifecycleWrapper.java:50)
at org.mule.processor.chain.AbstractMessageProcessorChain.process(AbstractMessageProcessorChain.java:67)
at org.mule.processor.chain.InterceptingChainLifecycleWrapper.access$001(InterceptingChainLifecycleWrapper.java:22)
at org.mule.processor.chain.InterceptingChainLifecycleWrapper$1.process(InterceptingChainLifecycleWrapper.java:66)
at org.mule.execution.ExceptionToMessagingExceptionExecutionInterceptor.execute(ExceptionToMessagingExceptionExecutionInterceptor.java:24)
at org.mule.execution.MessageProcessorNotificationExecutionInterceptor.execute(MessageProcessorNotificationExecutionInterceptor.java:58)
at org.mule.execution.MessageProcessorExecutionTemplate.execute(MessageProcessorExecutionTemplate.java:44)
at org.mule.processor.chain.InterceptingChainLifecycleWrapper.process(InterceptingChainLifecycleWrapper.java:61)
at org.mule.exception.TemplateMessagingExceptionStrategy.route(TemplateMessagingExceptionStrategy.java:139)
at org.mule.exception.TemplateMessagingExceptionStrategy.handleException(TemplateMessagingExceptionStrategy.java:45)
at org.mule.execution.HandleExceptionInterceptor.execute(HandleExceptionInterceptor.java:37)
at org.mule.execution.HandleExceptionInterceptor.execute(HandleExceptionInterceptor.java:14)
at org.mule.execution.BeginAndResolveTransactionInterceptor.execute(BeginAndResolveTransactionInterceptor.java:54)
at org.mule.execution.ResolvePreviousTransactionInterceptor.execute(ResolvePreviousTransactionInterceptor.java:44)
at org.mule.execution.SuspendXaTransactionInterceptor.execute(SuspendXaTransactionInterceptor.java:50)
at org.mule.execution.ValidateTransactionalStateInterceptor.execute(ValidateTransactionalStateInterceptor.java:40)
at org.mule.execution.IsolateCurrentTransactionInterceptor.execute(IsolateCurrentTransactionInterceptor.java:41)
at org.mule.execution.ExternalTransactionInterceptor.execute(ExternalTransactionInterceptor.java:48)
at org.mule.execution.RethrowExceptionInterceptor.execute(RethrowExceptionInterceptor.java:28)
at org.mule.execution.RethrowExceptionInterceptor.execute(RethrowExceptionInterceptor.java:13)
at org.mule.execution.TransactionalErrorHandlingExecutionTemplate.execute(TransactionalErrorHandlingExecutionTemplate.java:109)
at org.mule.execution.TransactionalErrorHandlingExecutionTemplate.execute(TransactionalErrorHandlingExecutionTemplate.java:30)
at org.mule.processor.AsyncInterceptingMessageProcessor$AsyncMessageProcessorWorker.doRun(AsyncInterceptingMessageProcessor.java:181)
at org.mule.work.AbstractMuleEventWork.run(AbstractMuleEventWork.java:39)
at org.mule.work.WorkerContext.run(WorkerContext.java:286)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:724)
Caused by: org.mule.api.DefaultMuleException: Failed to ack message w/deliveryTag: 1 on channel: AMQChannel(amqp://ezibuy#10.10.19.159:5672/,1)
at org.mule.transport.amqp.internal.processor.Acknowledger.ack(Acknowledger.java:63)
at org.mule.transport.amqp.internal.processor.Acknowledger.ack(Acknowledger.java:49)
at org.mule.transport.amqp.internal.processor.Acknowledger.process(Acknowledger.java:38)
at org.mule.execution.ExceptionToMessagingExceptionExecutionInterceptor.execute(ExceptionToMessagingExceptionExecutionInterceptor.java:24)
... 32 more
Caused by: com.rabbitmq.client.AlreadyClosedException: channel is already closed due to channel error; protocol method: #method<channel.close>(reply-code=406, reply-text=PRECONDITION_FAILED - unknown delivery tag 1, class-id=60, method-id=80)
at com.rabbitmq.client.impl.AMQChannel.ensureIsOpen(AMQChannel.java:190)
at com.rabbitmq.client.impl.AMQChannel.transmit(AMQChannel.java:291)
at com.rabbitmq.client.impl.AMQChannel.transmit(AMQChannel.java:285)
at com.rabbitmq.client.impl.ChannelN.basicAck(ChannelN.java:1012)
at org.mule.transport.amqp.internal.processor.Acknowledger.ack(Acknowledger.java:59)
There should be a delivery-tag flow variable that is used to keep track of the connection. This variable is required to be able to acknowledge the message. I suspect the flow variable is disappearing at some point. This can happen if the ACK is done in a separate thread from the one where the flow starts. The reason is that the delivery-tag variable can't be serialized/deserialized as it is moved to another thread.
Is anything being done asynchronously?
You are probably bitten a bug present when using request-response or request-reply.
Please try to use 3.6 where the bug is fixed.