[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-03-28 Thread Timothy Bish (JIRA)

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

Timothy Bish commented on AMQ-3353:
---

{code}
wireFormat.maxInactivityDuration=0
{code}

Turns off the built in keep alive functionality and the default TCP keepalive 
is usually two hours so you'd need to tune the OS to rely on that.  Why not 
just turn on the standard inactivity monitoring instead of trying to reinvent 
the wheel?

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more inf

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-03-28 Thread Alin (JIRA)

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

Alin commented on AMQ-3353:
---

I'm seeing the exact same behavior when using a javax.jms.MessageConsumer.
Whenever I'm powering off or unplugging the master broker machine,The slave 
broker will take over the master role but the  consumers will not reconnect to 
the new master broker.
There are no logged errors or other type of messages on the consumer side. The 
consumer behaves like it is still connected to the previous master instance and 
it is waiting for the messages to arrive in the queue.  

I was thinking of implementing a thread on my consumer side which will query 
the JMS connection from time to time, hopefully this way the fail-over 
mechanism will kick in. Although I'm not convinced that this is the right 
approach.

The broker URL I'm using is: 
failover:(tcp://server1:61616?keepAlive=true&wireFormat.maxInactivityDuration=0,tcp://server2:61616?keepAlive=true&wireFormat.maxInactivityDuration=0)?randomize=false&updateURIsSupported=false&jms.prefetchPolicy.all=1


The ActiveMQ version I'm using is 5.8.0
The client side libraries are 5.4.2


> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSu

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-02-26 Thread Gary Tully (JIRA)

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

Gary Tully commented on AMQ-3353:
-

There is a test case that simulates a very flaky network by randomly closing 
the socket locally. It uses a tcpfaulty://.. transport.
see: org.apache.activemq.usecases.MulticastDiscoveryOnFaultyNetworkTest

Maybe you can use some variant of that to reproduce in a unit test.
When the network cable is unpluged, there is a delay in getting socket feedback 
that depends on the tcp stack settings for timeouts and retries. So from a java 
app perspective, connections that are half closed can appear valid for some 
period. Whatever the case, the broker should be able to deal with it though, 
and once the tcp stack reports the real state of the network, things should 
come back to normal. 

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
>  

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-02-25 Thread Noel Ady (JIRA)

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

Noel Ady commented on AMQ-3353:
---

Thanks Gary. I can confirm my results are as Andreas Calvo previously stated.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-02-25 Thread Andreas Calvo (JIRA)

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

Andreas Calvo commented on AMQ-3353:


[~gtully]
Thanks for the quick reply.
However, although when I made the test it failed (and now it doesn't), I don't 
think it captures truly the situation.
Using a proxy can throw the Inactivity Monitor (even if it's paused or closed), 
but it does not capture an abrupt stop of the broker or it's connections.
While doing more tests in the lab, throwing a socket disconnect error (that 
means, unplugging the network cable) seems to, as [~noelady] expressed, leave 
the durable subscribers in a zombie state: they seem to exists and receive 
packages, but aren't able to dequeue anything.

If there is any way to cause a socket disconnect error programmatically, it may 
give us a hint.

I may note that, while using ActiveMQ the results are really bad, using 
fuse-09-16 seems to give better results.

Thanks!

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // Tes

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-02-25 Thread Gary Tully (JIRA)

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

Gary Tully commented on AMQ-3353:
-

peek at the test case that works on trunk: 
https://github.com/apache/activemq/blob/trunk/activemq-unit-tests/src/test/java/org/apache/activemq/usecases/DurableSubscriberWithNetworkDisconnectTest.java

note how it is configured.
To demonstrate a bug, please make some changes to that test case or add some 
additional scenarios and then reopen this issue if it breaks.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was s

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2013-02-25 Thread Noel Ady (JIRA)

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

Noel Ady commented on AMQ-3353:
---

We have been experiencing this same issue on 5.7.0. When AMQ server is rebooted 
all clients reconnect as expected. However durable subscribers show as active 
but the consumer is not pulling new messages. You can see on the subscribers 
page, messages are being en-queued to the durable sub but not being de-queued. 
It has caused some expensive mistakes recently. Havng read through the above , 
I am still unclear on what the best workaround is or if a fix is in progress? 

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you t

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-09-06 Thread Antonio (JIRA)

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

Antonio commented on AMQ-3353:
--

As Andreas Calvo pointed in post: 

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

this problem is already present in activemq 5.6, it's not fixed, I don't 
understand why it's closed, I'm affected too, exactly the same situation 
Andreas is experiencing.

Andreas?, is it fixed for you?.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, embedded1.xml, 
> embedded2.xml, example.tar.gz, instructions.txt, standalone1.xml, 
> standalone2.xml, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-06-04 Thread Timothy Bish (JIRA)

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

Timothy Bish commented on AMQ-3353:
---

Tried you new test case against the latest trunk SNAPSHOT and it passes.  
There's been a couple recent fixes since 5.6.0 for issues that could affect 
durable consumers so you may want to try out a 5.7-SNAPSHOT.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-05-29 Thread Andreas Calvo (JIRA)

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

Andreas Calvo commented on AMQ-3353:


@Gary,
We're still having the same issue.
It has become critical since it affects the brokers in a newtork of brokers 
when one of them is "pulled out" of the network and reconnected back after the 
inactivity timeout.
We'll try to update our test case with the latest stable release of 5.6 and 
report back.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Fix For: 5.6.0
>
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-02-02 Thread Gary Tully (Commented) (JIRA)

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

Gary Tully commented on AMQ-3353:
-

@Andreas, so where do we stand?
Do you have a variant of the test that shows the problem you are seeing that I 
can play with? Ie: a variant of the current test from trunk that will fail? 
Please attach it to this jira if you do.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-01-30 Thread Joe Shisei Niski (Commented) (JIRA)

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

Joe Shisei Niski commented on AMQ-3353:
---

Greetings:

As of Friday, 16 December, i'm no longer working at NWEA.

If you need assistance with Web-based MAP messaging, please contact Scott 
Dietrich (scott.dietre...@nwea.org) or Aaron Zoller (aaron.zol...@nwea.org).

Kind regards,
Joe


> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-01-30 Thread Joe Shisei Niski (Commented) (JIRA)

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

Joe Shisei Niski commented on AMQ-3353:
---

Greetings:

As of Friday, 16 December, i'm no longer working at NWEA.

If you need assistance with Web-based MAP messaging, please contact Scott 
Dietrich (scott.dietre...@nwea.org) or Aaron Zoller (aaron.zol...@nwea.org).

Kind regards,
Joe


> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2012-01-30 Thread Andreas Calvo (Commented) (JIRA)

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

Andreas Calvo commented on AMQ-3353:


@Gary
We are still trying to figure out this issue.
Using the latest SNAPSHOT for 5.6 doesn't solve it.
Our main concern is that using a NoB with static connections (and creating the 
responder from the central broker with duplex from the embedded broker) seems 
to throw an error.
However, using failover does not throw an error, but does not work either.

PS: NoB architecture is hub-and-spoke using embedded brokers
broker 1 (embedded) <-> central broker <-> broker 2 (embedded)

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

 

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-07-12 Thread Gary Tully (JIRA)

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

Gary Tully commented on AMQ-3353:
-

Thinking more on this, the failover: protocol on a client is relevant here in 
that the networkConsumerId on a consumer advisory will be the same in the 
failover case, and different in the not failover case. this is distinct from 
the subscriberName:clientId pair. It may be that the networkConsumerId needs to 
be composed of the subscriberName:clientId for durable subs to properly 
implement duplicate subscription suppression.  

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-07-06 Thread Gary Tully (JIRA)

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

Gary Tully commented on AMQ-3353:
-

yes, durable subs must be unique based on their connection id and subscriber 
name. A duplicate will be suppressed. Validated with a variation on the 
duplicate suppression test.
Am going to ensure that setSuppressDuplicateTopicSubscriptions ignores 
duplicate subs, such that it does not get in the way of normal durable sub 
reconnect, where the networked durable sub is offline pending a reconnect.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-07-06 Thread Andreas Calvo (JIRA)

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

Andreas Calvo commented on AMQ-3353:


We're concerned about the cyclic topology with a network of brokers.
If a durable topic subscription is requested more than once on the same broker, 
will ignore it?
thanks!

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-07-06 Thread Gary Tully (JIRA)

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

Gary Tully commented on AMQ-3353:
-

the problem is the default value for setSuppressDuplicateTopicSubscriptions.

In the test, add 
{code}connector.setSuppressDuplicateTopicSubscriptions(false);{code} to {code} 
org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest#bridgeBrokers{code}

That option was added for cyclic network topologies, where there are more than 
one route to a broker. But it should ignore durable subscriptions as they are 
already unique based on their subscription id.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java, 
> TEST-org.apache.activemq.usecases.DurableSubscriberWithNetworkDisconnectTest.xml,
>  test-results.ods
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-07-06 Thread Andreas Calvo (JIRA)

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

Andreas Calvo commented on AMQ-3353:


Gary,
We set up a bunch of options, such as failover over static, dynamic only, 
maxInactivity on wireFormat, and so on.
It should work always, but some are failing.

Moreover, it also performs a close or pause on the socket to simulate the 
network drop. 

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>Assignee: Gary Tully
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-07-06 Thread Gary Tully (JIRA)

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

Gary Tully commented on AMQ-3353:
-

Andreas, thanks for the unit test. It has 32 tests in it (with all the 
variations), is that expected? I am giving it a run to see what it produces.

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
> Attachments: DurableSubscriberWithNetworkDisconnectTest.java
>
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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




[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-06-23 Thread Joe Shisei Niski (JIRA)

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

Joe Shisei Niski commented on AMQ-3353:
---

i also have this problem on AMQ 5.3.2 (in production), and in our AMQ 5.4.2 
test environment. 

We have a store & forward network of brokers, much like the back-office/retail 
store example in ActiveMQ in Action. i use a duplexed networkConnector on the 
subscribers, with durable topic subscriptions. Queues and topics are defined as 
 in the  configuration.

After a disconnect, i can see the brokers reconnecting in both the publisher's 
and subscribers' logs. Also, the AMQ web console on the publisher continues to 
show the durable ssubscriptions as on-line. But topic messages published 
during/after the outage aren't picked up unless i restart the subscriber broker.

Furthermore, queue messages *do* flow successfully between the two brokers 
after the reconnect.

i've added "keepAlive=true" and "useExponentialBackoff=false" to the URIs for 
my openwire and ssl transportConnectors, but neither setting has made any 
difference in the problem behavior.

Our current work-around is to monitor the message counts on publisher's and 
subscriber's topics, send an alert to our sysadmin team when they get out of 
synch, and manually restart the subscriber.

It's a relief to know that i'm not the only one...

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( m

[jira] [Commented] (AMQ-3353) Durable subscribers on durable topics don't receive messages after network disconnect

2011-06-16 Thread Andreas Calvo (JIRA)

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

Andreas Calvo commented on AMQ-3353:


same problem here.

Tried with 5.4.2, 5.5.0, 5.6.0-SNAPSHOT and still having the same issue.

I've set up an environment with two brokers, and the producer and consumer 
provided in the example directory using durable topics.

After being disconnected for more than 1m, brokers are able to reconnect but 
consumer seems to be in an offline state which don't pending messages.
However, upon restarting the consumer, it'd get all pending messages.

Is there some kind of timeout between the consumer and the broker?

> Durable subscribers on durable topics don't receive messages after network 
> disconnect
> -
>
> Key: AMQ-3353
> URL: https://issues.apache.org/jira/browse/AMQ-3353
> Project: ActiveMQ
>  Issue Type: Bug
>  Components: Broker
>Affects Versions: 5.3.1, 5.5.0
> Environment: Windows & Linux
> JDK 1.6
>Reporter: Syed Faraz Ali
>
> I've set up a durable topic with the default (persistent) delivery mode on 
> one machine that is publishing a simple text message every 5 seconds. I 
> created a durable subscriber that consumes messages published to the above 
> topic on another machine. I am using broker to broker communication between 
> the two machines.
> I start up the two programs on either machine and see the messages coming 
> through to the subscriber. If I then pull the network cable to disconnect the 
> network between the two machines, wait for a minute and then plug it back in, 
> my subscriber doesn't receive the messages any more. I can see from the 
> output that the publisher is still publishing them (Temporary topics, 
> non-durable queues all continue to sync up in our production environment, it 
> is only the durable topics that don't work after network reconnect)
> If I were to tweak a setting on the publisher's broker (that was introduced 
> only in 5.5.0), suppressDuplicateTopicSubscriptions=false, then the topics 
> work correctly after network reconnect. But this may have other unintended 
> consequences and I was hoping to get a better idea of:
> - is this a known issue ? if so, then are there any specific challenges that 
> have caused it not to be fixed?
> - are other people out there using durable topics and subscribers without a 
> failover option that have run into this problem? What have they done to work 
> around?
> Here is how my subscriber and publisher are set up:
> Topic Publisher (Machine 1)
> publisherConnection = connFactory.createConnection();
> publisherConnection.setClientID( "ProducerCliID" );
> publisherConnection.start();
> session = publisherConnection.createSession( true, -1 );
> Destination producerTopic = session.createTopic( TEST_TOPIC_NAME );
> producer = session.createProducer( (Topic)producerTopic );
> 
> 
> 
> // On a timer, keep sending this out every 5 seconds
>  String text = "HELLO " + count++;
> TextMessage msg = session.createTextMessage( text );
> System.out.println( "Sending TextMessage = " + msg.getText() 
> );
> producer.send( msg );
> session.commit();
> Subscriber ( Machine 2):
> Connection clientConnection = connFactory.createConnection();
> clientConnection.setClientID("cliID");
> clientConnection.start();
> Session session = clientConnection.createSession( false, 
> Session.AUTO_ACKNOWLEDGE );
> Destination topic = session.createTopic( topicName );
> MessageConsumer subscriber = session.createDurableSubscriber( 
> (Topic)topic, "subName" );
> TestMessageListener msgListener = new TestMessageListener( 1000 );
> subscriber.setMessageListener( msgListener );
> .
> .
>  // TestMessageListener's onMessage method simply outputs the message:
> public void onMessage(Message message)
> {
> if ( message instanceof TextMessage )
> {
> System.out.println( "Message received = " + 
> ((TextMessage)message) );
> }
> }
> I can provide the jars for you to run the program if need be.

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