-
1. Re: Clustered EJB Lookup using JGroups
wdfink May 22, 2013 6:45 AM (in response to mautner.adam)I suppose I understand your question, correct me if I'm wrong.
You need to have the cluster information in the jboss-ejb-client.properties, see this example project.
By default add
# Declare the cluster(s)
remote.clusters=ejb
notice that you need to add connect option, credentials etc for the cluster also.
the cluster name ejb is from the cluster bean configuration, if there are no changes in the config the default is ejb
There is this EJBCLIENT-47 request, you may vote for it, to simplify the configuration and have the same automatic behaviour as in former releases,
-
2. Re: Clustered EJB Lookup using JGroups
mautner.adam May 22, 2013 4:35 PM (in response to wdfink)Hi,
First of all thank you for the quick reply.
I think we are on the same page. I am trying to build a load balanced/high availability cluster of stateless session beans. I actual managed test both load balance and high availability using the following config:
remote.connections=node1, node2
remote.connection.node1.host=localhost
remote.connection.node1.port = 4457
remote.connection.node1.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS=false
remote.connection.node2.host=localhost
remote.connection.node2.port = 4557
remote.connection.node2.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS=false
I didn't need to use "remote.clusters=ejb" for it.
What I'm actually looking for is how to discover nodes from the cluster (node1, node2) using JGroups, so I don't need to specify host connection information explicitly. I have found some reference about UDP lookup, but I would like to use other JGroups protocols like FILE_PING or JDBC_PING. JBoss itself seems to be able to use any of these JGroups protocols. I thought it would be nice to use the same method to lookup hosts in the client.
Regards,
Adam
-
3. Re: Clustered EJB Lookup using JGroups
wdfink May 23, 2013 4:34 AM (in response to mautner.adam)You need to set at minimum one connection for the ejb-client, if you set "remote.clusters" this will add all nodes of this cluster to your client view.
At the moment there is no multicast autodiscovery option for the client to discover a cluster as this was in former JBoss version with the jnp protocoll.
-
4. Re: Clustered EJB Lookup using JGroups
mautner.adam May 23, 2013 4:59 PM (in response to wdfink)Hi,
Thank you. Is there any plan to add autodiscovery option (with JGroups) in the next few versions?
Regards,
Adam
-
5. Re: Clustered EJB Lookup using JGroups
wdfink May 24, 2013 2:40 AM (in response to mautner.adam)I'm not aware of.
But you might file a JIRA enhancement request to reintroduce this feature.
-
6. Re: Clustered EJB Lookup using JGroups
mautner.adam May 27, 2013 4:37 PM (in response to wdfink)Hi,
OK, sure. I'm just evaluating JBoss at the moment. I may file a Jira later.
Thanks for the information.
Regards,
Adam