Return-Path: X-Original-To: apmail-activemq-dev-archive@www.apache.org Delivered-To: apmail-activemq-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8E61E177B4 for ; Wed, 22 Oct 2014 18:11:34 +0000 (UTC) Received: (qmail 10207 invoked by uid 500); 22 Oct 2014 18:11:34 -0000 Delivered-To: apmail-activemq-dev-archive@activemq.apache.org Received: (qmail 10140 invoked by uid 500); 22 Oct 2014 18:11:34 -0000 Mailing-List: contact dev-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list dev@activemq.apache.org Received: (qmail 10129 invoked by uid 99); 22 Oct 2014 18:11:34 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 Oct 2014 18:11:34 +0000 Date: Wed, 22 Oct 2014 18:11:33 +0000 (UTC) From: "Tamas Cserveny (JIRA)" To: dev@activemq.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (AMQ-5400) Unable to keep message order using ActiveMQ-RAR MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/AMQ-5400?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tamas Cserveny updated AMQ-5400: -------------------------------- Attachment: block-session-until-redelivery.patch Hi, I've provided a patch which blocks the session for the time of the redelivery. It honours the isNonBlockingRedelivery flag of the connection so it can be turned off. As blocking redelivery is the default this should not be a problem. Cheers, Tamas > Unable to keep message order using ActiveMQ-RAR > ------------------------------------------------ > > Key: AMQ-5400 > URL: https://issues.apache.org/jira/browse/AMQ-5400 > Project: ActiveMQ > Issue Type: Bug > Affects Versions: 5.10.0 > Environment: JBoss EAP6 + ActiveMQ 5.10.0 > Reporter: Tamas Cserveny > Attachments: block-session-until-redelivery.patch > > > We have an application server which processes the messages using an MDB. We are using message grouping to keep the message processing order. > It seems that it is not possible to do this, because in case the onMessage signals rollback, then the queue does not block until the redelivery time, but keeps on dispatching. > ActiveMQSession.java method afterRollback() @938 is triggered in this case. Which will redeliver the message by scheduling it: > connection.getScheduler().executeAfterDelay(new Runnable() { > @Override > public void run() { > ((ActiveMQDispatcher)md.getConsumer()).dispatch(md); > } > }, redeliveryDelay); > The session is not blocked or otherwise stopped from processing more messages, so it does it. > Setting prefetch=1 for the consumer did not helped. > I have maxSessions=1 in the activationSpec. -- This message was sent by Atlassian JIRA (v6.3.4#6332)