A remote invocation of an EJB included in an application marked as singleton-deployment is not possible without knowlege which server is current running the application in EAP 7.0
Environment
-
Red Hat JBoss Enterprise Application Platform (EAP)
- 7.0
- 7.1 Alpha/Beta
-
JavaEE application in an EAP cluster marked as singleton-deployment with a deployment-descriptor like followed
# META-INF/singleton-deployment.xml <?xml version="1.0" encoding="UTF-8"?> <singleton-deployment xmlns="urn:jboss:singleton-deployment:1.0"/>
Issue
- Why the remote client needs to know which server in the cluster has the singleton-deployment active?
I expect that remote clients are able to invoke a the EJB method even if the application is marked as a singleton-deployment. - If the client is configured with one server of a cluster neither the invocation nor the failover works seemlessly as expected.
Resolution
The issue is tracked by Content from issues.jboss.org is not included.JBEAP-12895 and is included in the 7.0.9 CP release.
For 7.1.0.GA it will be fixed as well Content from issues.jboss.org is not included.JBEAP-5422
Root Cause
The server will send only the information of the current active deployment and no cluster view to the client.
Because of this the client is not aware of any alternative
- if the EJB is not deployed on a server listed within the client configuration the invocation will fail
- if the current server driving the applicaiton goes down and the application is started on a server not listed in the client the next invocation will fail and there is no correct failover.
As workaround all cluster members can be listed within the client configuration.
Related Article
How to create a singleton deployment in EAP7
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.