This content has been marked as final.
Show 2 replies
-
1. Re: DiscoveryGroupConfiguration changes from HornetQ 2.2 to HornetQ 2.4
jbertram Jul 10, 2014 4:32 PM (in response to ptenn10)Check out the "symmetric-cluster" example that ships with HornetQ. You just need to instantiate one extra class to account for the one additional layer of abstraction we needed to add to integrate JGroups. Here's a relevant snippet from org.hornetq.jms.example.SymmetricClusterExample:
UDPBroadcastGroupConfiguration udpCfg = new UDPBroadcastGroupConfiguration("231.7.7.7", 9876, null, -1); DiscoveryGroupConfiguration groupConfiguration = new DiscoveryGroupConfiguration(HornetQClient.DEFAULT_DISCOVERY_INITIAL_WAIT_TIMEOUT, HornetQClient.DEFAULT_DISCOVERY_INITIAL_WAIT_TIMEOUT, udpCfg); ConnectionFactory cf = (ConnectionFactory)HornetQJMSClient.createConnectionFactoryWithHA(groupConfiguration, JMSFactoryType.CF);
-
2. Re: DiscoveryGroupConfiguration changes from HornetQ 2.2 to HornetQ 2.4
ptenn10 Jul 10, 2014 6:18 PM (in response to jbertram)Awesome, thank you very much, Justin!
Now that you mention it, it makes sense (the refactor you did / additional layer of abstraction) in order to support JGroups alongside UDP.
Thanks,
Philip