Description of problem: java cannot parse ipv6 literals. That is crucial when failing over, because client is unable to parse IPv6 literal from Cluter-url option supplied by broker. Version-Release number of selected component (if applicable): qpid-java-example-0.14-1.el6. qpid-java-common-0.14-1.el6. qpid-java-client-0.14-1.el6. How reproducible: 100% Steps to Reproduce: 1. start up cluster with --cluster-url with IPv6 able broker (ex. amqp:tcp:[IPv6]) 2. run java failover-able client with failover_exchange policy 3. shut down broker to which that client is connected 4. observe that client cannot failover Actual results: javax.jms.JMSException: Exception while receiving:Command was interrupted because of failover, before being sent at org.apache.qpid.client.AMQSession.toJMSException(AMQSession.java:3536) at org.apache.qpid.client.BasicMessageConsumer.receive(BasicMessageConsumer.java:392) at Hello.runTest(Hello.java:126) at Hello.main(Hello.java:41) Caused by: org.apache.qpid.transport.SessionException: Command was interrupted because of failover, before being sent at org.apache.qpid.transport.Session.checkFailoverRequired(Session.java:775) at org.apache.qpid.transport.Session.invoke(Session.java:607) at org.apache.qpid.transport.Session.invoke(Session.java:576) at org.apache.qpid.transport.SessionInvoker.executionSync(SessionInvoker.java:84) at org.apache.qpid.transport.Session.sync(Session.java:798) at org.apache.qpid.transport.Session.sync(Session.java:786) at org.apache.qpid.client.BasicMessageConsumer_0_10.getMessageFromQueue(BasicMessageConsumer_0_10.java:425) at org.apache.qpid.client.BasicMessageConsumer.receive(BasicMessageConsumer.java:375) ... 2 more Expected results: client do failover. Additional info: when cluster-url consist only of ipv4 addresses, client do failover
When I shut down the broker, the client prints out Exception: Exception in thread "IoReceiver - localhost/127.0.0.1:5672" java.lang.StackOverflowError org.apache.qpid.jms.failover.FailoverExchangeMethod.getNextBrokerDetails(FailoverExchangeMethod.java:202) org.apache.qpid.jms.failover.FailoverExchangeMethod.getNextBrokerDetails(FailoverExchangeMethod.java:221) org.apache.qpid.jms.failover.FailoverExchangeMethod.getNextBrokerDetails(FailoverExchangeMethod.java:221) org.apache.qpid.jms.failover.FailoverExchangeMethod.getNextBrokerDetails(FailoverExchangeMethod.java:221) ... and so on maybe it'll help identifying the problem.