I am trying to create a test program that will have failover feature. I am using and following this document. https://access.redhat.com/documentation/en-us/red_hat_amq/7.0/html/using_the_amq_jms_client/configuration#logging According document failover URI format is following. failover:(amqp://host1:port[,amqp://host2:port...])[?option=value[&option2=value...]] Do you have any sample example that uses URI using above format? I looked examples, but those are not using this URI scheme.
Asked
Active
Viewed 259 times
1 Answers
0
If you are looking for an example connection URI, there are two here:
If you are looking for an example JMS program, any example that uses that connection URI will work. The docs have one for sending messages and one for receiving them. Either will do.
https://access.redhat.com/documentation/en-us/red_hat_amq/7.0/html/using_the_amq_jms_client/examples
To inject a connection URI into a JMS program:
- Set the
connectionfactory.<lookup-name>
attribute in your JNDI properties to your chosen URI. - Use a matching
<lookup-name>
to perform the lookup in your JMS program.
The examples use myFactoryLookup
as the <lookup-name>
.

Justin Ross
- 126
- 2