JMS remote topic question
I have a standalone server that produces and consumes JMS messages on a topic and a remote server that also consumes messages on the topic. Everything is working fine, but on my standalone application I have the outbound socket binding set to 5445 the remote server is listening on port 5645(5445 +200 port offset of the application). I verified nothing is listening on port 5445 using netstat -l | grep 5445. Ports 5645 and 6245 are listening. The outbound socket binding on the remote server is set to 6245 which is the port that the standalone server is listening to(5445+800 port offset). If I specified 5645 in the standalone server configuration file, my perception is that things don't work. So I am puzzled, is there really only one connection working here the one on 6245 or does the connection bound to jms-server-1 somehow know to apply the 200 offset for the other server?
server producing and consuming
Standalone-full-ha.xml ...
remote-
domain.xml ...
Thanks
Attachments
Responses
I must admit that I'm not sure if I understand full your setup. But I presume that your domain.xml hosts a cluster with JMS destinations and your are consuming and producing messages on your standalone-full-ha instance using the RA and your RA is configured to consume from a remote broker. I assume that your domain and standalone-full-ha are running on different machines. Normally you would have to specify the ports of the remote broker on your RA configuration there is no way that the standalone-full-ha can know about the port range of your domain unless there is a misconfiguration and some how all instance share the same discovery/broadcast address. Can you share your configuration files?
I'm sorry but I don't think your current config works. Could you tell me what is your final intention. Your standalone*.xml has a remote RA with two connectors one inVM and one remote, I suspect it actually never connects to the remote broker. It should have only remote connection. Your domain.xml defines a cluster using static connectors where server-2-connector is not defined anywhere.
org.hornetq.core.remoting.impl.netty.NettyConnectorFactory The above way of configuring has been deprecated. You should use socket-bindings instead. I don't believe you have a cluster.
If you want o configure a remote RA here's an example:
true java.naming.factory.initial=org.jboss.naming.remote.client.InitialContextFactory;java.naming.provider.url=remote://${let01.host}:${let01.jndi.port},${let02.host}:${let02.jndi.port};java.naming.security.principal=${user.name};java.naming.security.credentials=${user.password} -1 10000 ${user.name} ${user.password} 50 50
Tom
If your application is running on hte standalone-*.xml instance then all you need is the remote RA that points at the remote broker. In your RA configuration you your have at least one that points to the broker. In your specific case since you don't have cluster you need just one.
I'm note sure where your second application will be running? On the standalone or the domain (cluster).
Tom
I would find it very difficult to believe that your current set up works. But I would have to see the log files first. Lets say your domain.xml hosts a topic called appTopic. That topic is exposed on host:port (my host:5445). You standalone.xml would have to configure a remote RA that would have a connector with my host:5445. This way an application ruling on domain.xml could subscribe on appTopic and application running on standalone.xml could subscribe on appTopic hosted by domain.xml. Hope that helps - Tom
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
