You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Rob Davies (JIRA)" <ji...@apache.org> on 2009/07/31 11:22:33 UTC

[jira] Resolved: (AMQ-1767) Multiple creating and closing consumers causes messages duplicated delivered

     [ https://issues.apache.org/activemq/browse/AMQ-1767?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rob Davies resolved AMQ-1767.
-----------------------------

       Resolution: Fixed
    Fix Version/s:     (was: 5.4.0)
                   5.3.0

> Multiple creating and closing consumers causes messages duplicated delivered
> ----------------------------------------------------------------------------
>
>                 Key: AMQ-1767
>                 URL: https://issues.apache.org/activemq/browse/AMQ-1767
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.1.0
>         Environment: Windows XP, Java 1.5
>            Reporter: Kevin
>            Assignee: Rob Davies
>             Fix For: 5.3.0
>
>         Attachments: JUnit.zip
>
>
> Hi *,
> I'm running AcitveMQ 5.1 in a VM. The broker is set as persistent with amq-store, the xml-configuration-file is attached (in the zip-file).
> One MessageProducer sends 10.000 messages to a queue. The producers runs in its own thread with its own session.
> The queue is set as transacted.
> Two MessageConsumers register on the queue mentioned above, each in its own thread with its own session.
> The Producer and the Consumers share one connection-object.
> Every second one Consumer is called to be canceld (by session.close - a call to consumer.close does not help), its thread is stopped and a new Consumer is created in a new thread with its own session.
> What happens?
> 1 to 10 messages are duplicated delivered from some consumers. So the 'EnqueueCount' is greater than the 'DequeueCount'. E.G. 10.002 messages are recieved, but just 10.000 messages are sent.
> I've tried to synchronized by one common-object the creating, closing or commiting in the Consumer with no success.
> Attached is a junit-test, which demonstrates the situation. Before have a look at the Config-Class and change the ip-address, where your broker runs.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.