activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Perepelytsya (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AMQ-3330) Regression: durable subscriber reconnection throws javax.jms.JMSException: Durable consumer is in use for client: C1 and subscriptionName: jmsConnectorC1.broadcast
Date Thu, 19 May 2011 16:56:47 GMT

    [ https://issues.apache.org/jira/browse/AMQ-3330?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036295#comment-13036295
] 

Andrew Perepelytsya commented on AMQ-3330:
------------------------------------------

Typical log:
{noformat}
Caused by: javax.jms.JMSException: Durable consumer is in use for client: C1 and subscriptionName:
mule.jmsConnectorC1.broadcast
	at org.apache.activemq.broker.region.TopicRegion.addConsumer(TopicRegion.java:74)
	at org.apache.activemq.broker.region.RegionBroker.addConsumer(RegionBroker.java:450)
	at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
	at org.apache.activemq.advisory.AdvisoryBroker.addConsumer(AdvisoryBroker.java:79)
	at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
	at org.apache.activemq.broker.BrokerFilter.addConsumer(BrokerFilter.java:89)
	at org.apache.activemq.broker.MutableBrokerFilter.addConsumer(MutableBrokerFilter.java:95)
	at org.apache.activemq.broker.TransportConnection.processAddConsumer(TransportConnection.java:546)
	at org.apache.activemq.command.ConsumerInfo.visit(ConsumerInfo.java:349)
	at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:306)
	at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:179)
	at org.apache.activemq.transport.ResponseCorrelator.onCommand(ResponseCorrelator.java:116)
	at org.apache.activemq.transport.TransportFilter.onCommand(TransportFilter.java:69)
	at org.apache.activemq.transport.vm.VMTransport.iterate(VMTransport.java:218)
	at org.apache.activemq.thread.PooledTaskRunner.runTask(PooledTaskRunner.java:127)
	at org.apache.activemq.thread.PooledTaskRunner$1.run(PooledTaskRunner.java:48)
	... 3 more
{noformat}

> Regression: durable subscriber reconnection throws javax.jms.JMSException: Durable consumer
is in use for client: C1 and subscriptionName: jmsConnectorC1.broadcast
> -------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: AMQ-3330
>                 URL: https://issues.apache.org/jira/browse/AMQ-3330
>             Project: ActiveMQ
>          Issue Type: Bug
>          Components: Broker
>    Affects Versions: 5.5.0
>            Reporter: Andrew Perepelytsya
>
> JMS spec section clearly states reconnections rules:
> {noformat}
> 9.3.3.2 Reconnecting to a Topic using a Durable Subscription
> To re-connect to a Topic that has an existing durable subscription, the client
> program can simply call session.CreateDurableSubscriber again, using the same
> parameters that it previously used. A client program may be intermittently
> connected. Using durable subscriptions allows messages to still be available to
> a client program that consumes from a Topic, even though the client program
> was not continuously connected.
> /* Reconnect to a durable subscription */
> session.createDurableSubscriber(newsFeedTopic, "mySubscription");
> This reconnects the client program to the Topic, and any messages that arrived
> while the client was disconnected are delivered. However, there are some
> important restrictions to be aware of:
> • The client must be attached to the same Connection.
> • The Destination and subscription name must be the same.
> • If a message selector was specified, it must also be the same.
> If these conditions are not met, then the durable subscription is deleted, and a
> new subscription is created.
> {noformat}
> My program periodically polls with exactly the same connection, subscription and client
id, however, AMQ 5.5.0 now throws the JMSException, where it was compliant before (e.g. version
4.1.2)

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message