Hi, I've been trying to use ActiveMQ multicast transport for a couple of days, without success, so I'm posting here in hope someone already achieved this.
What I'm trying to achieve: I'm using topics, in a context where there are a lot of publishers and a lot of subscribers, with messages being sent all the time. Publishers all publish almost constantly, so the aim of using multicast would be to avoid multiplying the network traffic due to the -also important- number of subscribers. I'm using ActiveMQ 5.9.1 What I've tried: 1/ Looking at http://activemq.apache.org/multicast-transport-reference.html I thought this would be easy. I did setup a broker with a URI multicast://224.1.2.3:6255, created a subscriber (that I validated using vm:// and tcp:// urls) on the same subnet as the broker and set the subscriber to point multicast://224.1.2.3:6255 => I get this exception on the subscriber's side: javax.jms.JMSException: org.apache.activemq.transport.RequestTimedOutIOException at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:72) at org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1426) at org.apache.activemq.ActiveMQConnection.ensureConnectionInfoSent(ActiveMQConnection.java:1513) at org.apache.activemq.ActiveMQConnection.start(ActiveMQConnection.java:526) [... my classes] caused by: Caused by: org.apache.activemq.transport.RequestTimedOutIOException: null at org.apache.activemq.transport.FutureResponse.getResult(FutureResponse.java:54) at org.apache.activemq.transport.reliable.ReliableTransport.request(ReliableTransport.java:83) at org.apache.activemq.transport.TransportFilter.request(TransportFilter.java:93) at org.apache.activemq.ActiveMQConnection.syncSendPacket(ActiveMQConnection.java:1397) All my subscriber did at this point was: this.connectionFactory = new ActiveMQConnectionFactory(urlToConnect); this.connection = this.connectionFactory.createConnection(); this.connection.start(); 2/ Looking at http://mail-archives.apache.org/mod_mbox/activemq-dev/200905.mbox/%3C62792064.1243060431111.JavaMail.jira@brutus%3E gave me a little hope: my issue seemed to be related to some default value for the keepAliveInterval, so I tried change the multicast URL on subscriber to multicast://224.1.2.3:6255?keepAliveInterval=0 => Same exception 3/ So I tried capturing the outgoing traffic using wireshark, so here is what I see: Subscriber host: IGMPv3 message to 224.0.0.22 Membership Report / Join Group 224.1.2.3 UDP message to 224.1.2.3:6255 IGMPv3 message to 224.0.0.22 Membership Report / Join Group 224.1.2.3 (don't know why there's a second one) ... 2 IGMPv3 Leave Group messages Broker host: I can see those same IGMPv3 & UDP messages => Looks fine to me 4/ Looking at http://activemq.apache.org/version-5-topologies.html Peer to peer section, I thought I had misunderstood the use of multicast, and what I should have is: one embedded broker on all clients, all embedded brokers having a multicast:// connector and a vm:// connector, publishing/subscribing to the local broker on vm://, and brokers should auto-magically forward messages to one another using multicast. I couldn't get this to work either (no multicast traffic showed in wireshark). 5/ I also watched at the sources for UdpTransportFactory#doBind() and was surprised to see that UdpTransportServer class was deprecated, which led me to this ticket: https://issues.apache.org/jira/browse/AMQ-4279 stating that UDP support is deprecated except discovery from 5.8.0 on, if I got it right. So, you probably guessed, my question is: Did anybody succeed in using multicast transport in 5.9, except for discovery? What is the current status of multicast transport, is it still even working? Am I missing the obvious? Any piece of information might help :) Sorry for the somewhat bulky message (thanks if you read it!), and thanks in advance! -- Sebastien -- View this message in context: http://activemq.2283324.n4.nabble.com/Multicast-transport-tp4687852.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.