3 Replies Latest reply on Jul 2, 2014 8:52 AM by Wolf-Dieter Fink

    Remote Server for EJB Access

    G Antony Newbie

      Hi All,

               I have developed using Wildfly 8 and am able to run successfully in my local machine using the below configuration.

       

                java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory

                java.naming.provider.url=jnp://10.0.0.15:1099

                java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces

       

             Now I would like to run my application using the same EJBs deployed in a remote machine. How do I do that???

       

      Please help.

       

      Thanks in advance.

      Antony.

        • 1. Re: Remote Server for EJB Access
          Wolf-Dieter Fink Master

          You can not use the jnp protocoll for WildFly.

          You should read the documentation how to use the ejb-client invocation,

          see EJB invocations from a remote client using JNDI

          • 2. Re: Remote Server for EJB Access
            G Antony Newbie

            Hello,

             

                     When I run my client I get the following error.

             

            Could not register a EJB receiver for connection to HOSTNAME:8080

            java.lang.RuntimeException: Operation failed with status WAITING

              at org.jboss.ejb.client.remoting.IoFutureHelper.get(IoFutureHelper.java:94)

              at org.jboss.ejb.client.remoting.ConnectionPool.getConnection(ConnectionPool.java:77)

              at org.jboss.ejb.client.remoting.RemotingConnectionManager.getConnection(RemotingConnectionManager.java:51)

              at org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector.setupEJBReceivers(ConfigBasedEJBClientContextSelector.java:155)

              at org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector.getCurrent(ConfigBasedEJBClientContextSelector.java:115)

              at org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector.getCurrent(ConfigBasedEJBClientContextSelector.java:47)

              at org.jboss.ejb.client.EJBClientContext.getCurrent(EJBClientContext.java:271)

              at org.jboss.ejb.client.EJBClientContext.requireCurrent(EJBClientContext.java:281)

              at org.jboss.ejb.client.EJBInvocationHandler.doInvoke(EJBInvocationHandler.java:176)

              at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:144)

              at com.sun.proxy.$Proxy0.hello(Unknown Source)

              at SampleClient.main(SampleClient.java:26)

             

             

            java.lang.IllegalStateException: EJBCLIENT000025: No EJB receiver available for handling [appName:JBossEJB, moduleName:, distinctName:] combination for invocation context org.jboss.ejb.client.EJBClientInvocationContext@1341cac

              at org.jboss.ejb.client.EJBClientContext.requireEJBReceiver(EJBClientContext.java:749)

              at org.jboss.ejb.client.ReceiverInterceptor.handleInvocation(ReceiverInterceptor.java:116)

              at org.jboss.ejb.client.EJBClientInvocationContext.sendRequest(EJBClientInvocationContext.java:183)

              at org.jboss.ejb.client.EJBInvocationHandler.sendRequestWithPossibleRetries(EJBInvocationHandler.java:253)

              at org.jboss.ejb.client.EJBInvocationHandler.doInvoke(EJBInvocationHandler.java:198)

              at org.jboss.ejb.client.EJBInvocationHandler.doInvoke(EJBInvocationHandler.java:181)

              at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:144)

              at com.sun.proxy.$Proxy0.hello(Unknown Source)

              at SampleClient.main(SampleClient.java:26)

             

            Please help.

            • 3. Re: Remote Server for EJB Access
              Wolf-Dieter Fink Master

              You need to elaborate a bit on this, otherwise we can only provide general hints.

               

              The first thing you should do is have a look to the Documentation.

              And you might try the quickstarts, i.e. quickstart/ejb-remote