Return-Path: Delivered-To: apmail-activemq-users-archive@www.apache.org Received: (qmail 69928 invoked from network); 19 Nov 2008 15:56:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 19 Nov 2008 15:56:17 -0000 Received: (qmail 68026 invoked by uid 500); 19 Nov 2008 15:56:24 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 68000 invoked by uid 500); 19 Nov 2008 15:56:24 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 67989 invoked by uid 99); 19 Nov 2008 15:56:24 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Nov 2008 07:56:24 -0800 X-ASF-Spam-Status: No, hits=2.6 required=10.0 tests=DNS_FROM_OPENWHOIS,SPF_HELO_PASS,SPF_PASS,WHOIS_MYPRIVREG X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of lists@nabble.com designates 216.139.236.158 as permitted sender) Received: from [216.139.236.158] (HELO kuber.nabble.com) (216.139.236.158) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 19 Nov 2008 15:55:01 +0000 Received: from isper.nabble.com ([192.168.236.156]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1L2pP7-00054R-SZ for users@activemq.apache.org; Wed, 19 Nov 2008 07:55:45 -0800 Message-ID: <20582823.post@talk.nabble.com> Date: Wed, 19 Nov 2008 07:55:45 -0800 (PST) From: sakkew To: users@activemq.apache.org Subject: Programmatically reprocessing messages from a dead letter queue MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Nabble-From: sakke.wiik@gmail.com X-Virus-Checked: Checked by ClamAV on apache.org I need to integrate functionality to an existing system so that operators can manually reprocess messages from a dead letter queue, that is to put them back into the original queue. I use the QueueViewMBean as shown below. The message is put back to the original queue and processed by the ActiveMQ server as it should, but if the message fails again, the message disappears. When I restart the server the message appears in the DLQ as it should. Here's the code (I used the Web Monitor as base): QueueViewMBean queue = broker.getQueue(dlq); queue.moveMessageTo(mapMessage.getJMSMessageID(), mapMessage.originalDestination()); Is there something in the message that should be reset to avoid confusing the reprocessing? Both client and server uses ActiveMQ 5.1 cheers, Sakke -- View this message in context: http://www.nabble.com/Programmatically-reprocessing-messages-from-a-dead-letter-queue-tp20582823p20582823.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.