You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by rtselvan <rt...@gmail.com> on 2006/05/01 19:07:06 UTC

the connection is already closed

The following exception is thrown when a long running consumer completes the
task. I guessing that this also leads to
http://www.nabble.com/Messages-get-redelivered-more-than-once-t1478185.html


2006-05-01 01:14:03,917 WARN  [org.jboss.tm.TransactionImpl] XAException:
tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=ramptap02/134,
BranchQual=, localId=134] errorCode=XAER_RMFAIL
javax.transaction.xa.XAException: The connection is already closed
        at
org.apache.activemq.TransactionContext.toXAException(TransactionContext.java:589)
        at
org.apache.activemq.TransactionContext.rollback(TransactionContext.java:414)
        at
org.apache.activemq.ra.LocalAndXATransaction.rollback(LocalAndXATransaction.java:126)
        at
org.jboss.tm.TransactionImpl$Resource.rollback(TransactionImpl.java:2274)
        at
org.jboss.tm.TransactionImpl.rollbackResources(TransactionImpl.java:1834)
        at org.jboss.tm.TransactionImpl.rollback(TransactionImpl.java:409)
        at org.jboss.tm.TxManager.rollback(TxManager.java:363)
        at
org.jboss.ejb3.plugins.inflow.MessageInflowLocalProxy.endTransaction(MessageInflowLocalProxy.java:467)
        at
org.jboss.ejb3.plugins.inflow.MessageInflowLocalProxy.finish(MessageInflowLocalProxy.java:349)
        at
org.jboss.ejb3.plugins.inflow.MessageInflowLocalProxy.after(MessageInflowLocalProxy.java:271)
        at
org.jboss.ejb3.plugins.inflow.MessageInflowLocalProxy.invoke(MessageInflowLocalProxy.java:165)
        at $Proxy296.afterDelivery(Unknown Source)
        at
org.apache.activemq.ra.MessageEndpointProxy$MessageEndpointAlive.afterDelivery(MessageEndpointProxy.java:125)
        at
org.apache.activemq.ra.MessageEndpointProxy.afterDelivery(MessageEndpointProxy.java:64)
        at
org.apache.activemq.ra.ServerSessionImpl.afterDelivery(ServerSessionImpl.java:214)
        at org.apache.activemq.ActiveMQSession.run(ActiveMQSession.java:748)
        at
org.apache.activemq.ra.ServerSessionImpl.run(ServerSessionImpl.java:163)
        at org.jboss.resource.work.WorkWrapper.execute(WorkWrapper.java:204)
        at
org.jboss.util.threadpool.BasicTaskWrapper.run(BasicTaskWrapper.java:275)
        at
EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
        at java.lang.Thread.run(Thread.java:595)
Caused by: org.apache.activemq.ConnectionClosedException: The connection is
already closed
        at
org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1127)
        at
org.apache.activemq.TransactionContext.rollback(TransactionContext.java:403)
        ... 19 more

Thanks
/selvan
--
View this message in context: http://www.nabble.com/the-connection-is-already-closed-t1535647.html#a4172245
Sent from the ActiveMQ - User forum at Nabble.com.


Re: the connection is already closed

Posted by rtselvan <rt...@gmail.com>.
Yes, I am using the ActiveMQ inside the JBoss Container with MDB
Configuration
--
View this message in context: http://www.nabble.com/the-connection-is-already-closed-t1535647.html#a4241899
Sent from the ActiveMQ - User forum at Nabble.com.


Re: the connection is already closed

Posted by Hiram Chirino <hi...@hiramchirino.com>.
Are you using ActiveMQ with a container?

On 5/2/06, rtselvan <rt...@gmail.com> wrote:
>
> I am running the SNAPSHOT version as of Apr 22.
>
> It only happens when the consumer take long time to complete the processing.
> Interesting, I have configured the MDB to be TRANSACTION NOT SUPPORTED, but
> it is still trying to use the transaction manager.
> --
> View this message in context: http://www.nabble.com/the-connection-is-already-closed-t1535647.html#a4198368
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>


--
Regards,
Hiram

Re: the connection is already closed

Posted by rtselvan <rt...@gmail.com>.
I am running the SNAPSHOT version as of Apr 22. 

It only happens when the consumer take long time to complete the processing.
Interesting, I have configured the MDB to be TRANSACTION NOT SUPPORTED, but
it is still trying to use the transaction manager. 
--
View this message in context: http://www.nabble.com/the-connection-is-already-closed-t1535647.html#a4198368
Sent from the ActiveMQ - User forum at Nabble.com.


Re: the connection is already closed

Posted by James Strachan <ja...@gmail.com>.
On 5/1/06, rtselvan <rt...@gmail.com> wrote:
>
> The following exception is thrown when a long running consumer completes the
> task.

>From the stack trace its looking like the transaction is being rolled
back due to some error and the connection has been found to have
already been closed.

Which version are you using?

The real cause of the problem looks like being below this stack trace...

> Caused by: org.apache.activemq.ConnectionClosedException: The connection is
> already closed
>         at
> org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1127)
>         at
> org.apache.activemq.TransactionContext.rollback(TransactionContext.java:403)
>         ... 19 more

I don't know why the transaction is being rolled back, nor why the
connection is now closed.

--

James
-------
http://radio.weblogs.com/0112098/