3 Replies Latest reply on Sep 5, 2013 4:22 AM by Jorge Gomes

    EJB invocations from a remote server instance

    Jorge Gomes Newbie

      Wirth Jboss As 7.1 I flollow this doc EJB invocations from a remote server instance - JBoss AS 7.1 - Project Documentation Editor to connect differents instances of Jboss, but with WildFly this instrucctions don't work

      I have EJB in an instance of WildFly (destination server) and a web client for this EJB in other WildFly, but I can't connect both WildFly. Somebody can help me

       

      WildFly Alpha 4, There isn`t an stracktrace error, the only error message is that not found my EJB project

       

      The WildFly destination is started wirh -b to accpet remote connections

       

      Stack Trace

      javax.servlet.ServletException: java.lang.IllegalStateException: EJBCLIENT000025: No EJB receiver available for handling [appName:, moduleName:RemCo5EJB, distinctName:] combination for invocation context org.jboss.ejb.client.EJBClientInvocationContext@33c2e95c

      javax.faces.webapp.FacesServlet.service(FacesServlet.java:659)

      io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:87)

      io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130)

      io.undertow.websockets.jsr.JsrWebSocketFilter.doFilter(JsrWebSocketFilter.java:136)

      io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:56)

      io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)

      io.undertow.websockets.jsr.JsrWebSocketFilter.doFilter(JsrWebSocketFilter.java:136)

      io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:56)

      io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)

      io.undertow.servlet.handlers.FilterHandler.handleRequest(FilterHandler.java:85)

      io.undertow.servlet.handlers.security.ServletSecurityRoleHandler.handleRequest(ServletSecurityRoleHandler.java:56)

      io.undertow.servlet.handlers.ServletDispatchingHandler.handleRequest(ServletDispatchingHandler.java:36)

      org.wildfly.extension.undertow.security.SecurityContextAssociationHandler.handleRequest(SecurityContextAssociationHandler.java:78)

      io.undertow.servlet.handlers.security.SSLInformationAssociationHandler.handleRequest(SSLInformationAssociationHandler.java:113)

      io.undertow.security.handlers.AuthenticationCallHandler.handleRequest(AuthenticationCallHandler.java:52)

      io.undertow.security.handlers.AbstractConfidentialityHandler.handleRequest(AbstractConfidentialityHandler.java:45)

      io.undertow.servlet.handlers.security.CachedAuthenticatedSessionHandler.handleRequest(CachedAuthenticatedSessionHandler.java:65)

      io.undertow.security.handlers.SecurityInitialHandler.handleRequest(SecurityInitialHandler.java:70)

      io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)

      org.wildfly.extension.undertow.security.SecurityContextCreationHandler.handleRequest(SecurityContextCreationHandler.java:54)

      io.undertow.server.handlers.PredicateHandler.handleRequest(PredicateHandler.java:25)

      io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:207)

      io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:194)

      io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:72)

      io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:128)

      io.undertow.server.HttpHandlers.executeRootHandler(HttpHandlers.java:36)

      io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:628)

      java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)

      java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)

      java.lang.Thread.run(Thread.java:724)

        • 1. Re: EJB invocations from a remote server instance
          jaikiran pai Master

          Please post relevant details including the exact version of WildFly and the exact exception stacktraces. Also post relevant code and configurations.

          • 2. Re: EJB invocations from a remote server instance
            Jorge Gomes Newbie

            In my proves I found this observations, The connections with destination server is established (this line on standalone_full.xml :

            <outbound-socket-binding name="remote-ejb">

                        <remote-destination host="destination_ip" port="8081"/>

                    </outbound-socket-binding>

            )

            because if the destination server is closed in client appear this error JBREM000200: Remote connection failed: java.io.IOException: JBREM000202: Abrupt close on Remoting connection 657a82e5 to destination_ip/destination_ip:8081.

             

            I think that the problem is in this lines (bold):

            <subsystem xmlns="urn:jboss:domain:remoting:2.0">

                        <http-connector name="http-remoting-connector" connector-ref="default" security-realm="ApplicationRealm"/>

                        <outbound-connections>

                            <remote-outbound-connection name="remote-ejb-connection" outbound-socket-binding-ref="remote-ejb" username="remco5" security-realm="ejb-security-realm">

                                <properties>

                                    <property name="SASL_POLICY_NOANONYMOUS" value="false"/>

                                    <property name="SSL_ENABLED" value="false"/>

                                </properties>

                            </remote-outbound-connection>

                        </outbound-connections>

                    </subsystem>

             

            I think that the line security-real is not used by this line because I can put any value and I don't have any error, with Jboss AS 7.1.1 if i put a bad password I have an error.

            • 3. Re: EJB invocations from a remote server instance
              Jorge Gomes Newbie

              I think taht I found the solution. In thsi post How can an EJB from one WildFly server call another one with remoting and SSL? i found a new attribute in connection, I don'y use SSL.

              I add new atribute(bold) to this lines.

              <outbound-connections>

                              <remote-outbound-connection name="remote-ejb-connection" outbound-socket-binding-ref="remote-ejb" username="remco5" security-realm="ejb-security-realm" protocol="http-remoting">

                                  <properties>

                                      <property name="SASL_POLICY_NOANONYMOUS" value="false"/>

                                      <property name="SSL_ENABLED" value="false"/>

                                  </properties>

                              </remote-outbound-connection>

                          </outbound-connections>