[jboss-dev-forums] [Design of Messaging on JBoss (Messaging/JBoss)] - Redelivery caused by System.exit()?

longfangq@hotmail.com do-not-reply at jboss.com
Mon Jan 8 16:41:11 EST 2007


Hi,

When our program receives a JMS message which instructs it to shut down, it calls System.exit(0). It works well with another application server. When we try to migrate to JBoss, we found that JMS message will not be consumed, which means the program does receive the message and exit but when it restarts, that JMS message will be redelievered and cause it to exit again and therefor an infinite loop. 

We use non-transactional messaging and auto acknolowledge:
        QueueSession qSession = qCon.createQueueSession(false,
            Session.AUTO_ACKNOWLEDGE);

Can anyone kindly help? many thanks!

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3999212#3999212

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3999212



More information about the jboss-dev-forums mailing list