0 Replies Latest reply on May 30, 2014 10:30 AM by belapie

    JBoss EAP 6.2 - EJB server to server call, same physical server but different instance

    belapie

      Hi,

       

      I have two apps deployed on the same physical server but on the separate JBoss EAP 6.2 instance.

       

      Both application do local EJB call (java:....) to initialize the application and get datasource. Remote client (fat-client) can call both apps using remote call (ejb:..., and java.naming.provider.url=remote://SERVER:PORT).

       

      But sometimes the second app need to call the first one using EJB (ejb:...) and i can not make this call works.

       

      Here is me Properties() for the server-to-server call :

       

          java.naming.factory.initial=org.jboss.as.naming.InitialContextFactory

          remote.connection.default.connect.options.org.xnio.Options.SASL_POLICY_NOPLAINTEXT=false

          endpoint.name=client-endpoint

          remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED=true

          remote.connection.default.connect.options.org.xnio.Options.SASL_DISALLOWED_MECHANISMS=JBOSS-LOCAL-USER

          remote.connection.default.connect.options.org.xnio.Options.SSL_STARTTLS=true

          remote.connection.default.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS=false

          java.naming.provider.url=remote://10.102.4.57:9447

          remote.connection.default.username=MY_USERNAME

          java.naming.factory.url.pkgs=org.jboss.ejb.client.naming

          remote.connections=default

          remote.connection.default.password=MY_PASSWORD

      The exception is :

       

          EJBCLIENT000025: No EJB receiver available for handling [appName:APP_NAME, moduleName:MODULE_NAME, distinctName:] combination for invocation context org.jboss.ejb.client.EJBClientInvocationContext@3102470c

       

       

      In the standalone.xml i add :

       

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

              <connector name="remoting-connector" socket-binding="remoting" security-realm="ApplicationRealm"/>

                  <outbound-connections>

                      <remote-outbound-connection name="remote-ejb-connection" outbound-socket-binding-ref="remote-ejb"/>

                  </outbound-connections>

          </subsystem>

      and in the socket-binding-group :

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

              <remote-destination host="10.102.4.57" port="9447"/>

          </outbound-socket-binding>

      I added the jboss-ejb-client.properties everywhere in the war (WEB-INF, WEB-INF/class, META-INF) (the EJB is located in the WAR)

       

          endpoint.name=client-endpoint

          remote.connections=default

      And even jboss-ejb-client.xml in the same place where jboss-ejb-client.properties is located

          <jboss-ejb-client xmlns="urn:jboss:ejb-client:1.0">

              <client-context>

                  <ejb-receivers>

                      <remoting-ejb-receiver outbound-connection-ref="remote-ejb-connection"/>

                  </ejb-receivers>

              </client-context>

          </jboss-ejb-client>

         

      I really don't know what to do... I tried everything i know.

       

      Thanks!