1 Reply Latest reply on Feb 12, 2015 2:56 AM by valsaraj viswanathan

    IllegalStateException: EJBCLIENT000027: No EJBReceiver available for node name

    valsaraj viswanathan Master

      Caused by: java.lang.IllegalStateException: EJBCLIENT000027: No EJBReceiver available for node name node1

              at org.jboss.ejb.client.EJBClientContext.requireNodeEJBReceiver(EJBClientContext.java:844)

              at org.jboss.ejb.client.EJBClientContext.requireNodeEJBReceiverContext(EJBClientContext.java:885)

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

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

              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 $Proxy16.findProperties(Unknown Source)

      I got this exception when I called SLSB from client:

      getLoadServerProperties().beginTransaction();

      getLoadServerProperties().importAndUploadProperties(properties);

      getLoadServerProperties().commitTransaction();

       

      public void beginTransaction() {

              try {

             ut = EJBClient.getUserTransaction("node1");

                  // ut = (UserTransaction) getCtx().lookup("UserTransaction");

                  ut.begin();

              } catch (Exception ex) {

                  throw new RuntimeException("Failed to begin UserTransactiion", ex);

              }

          }

       

      Added system property, jboss.node.name=node1

      I followed this guide, Remote EJB invocations via JNDI - EJB client API or remote-naming project - WildFly 8 - Project Documentation Editor

       

      Created jndi.properties file:

      java.naming.factory.initial=org.jboss.naming.remote.client.InitialContextFactory

      java.naming.provider.url=http-remoting://localhost:8080

       

      What may be wrong?

        • 1. Re: IllegalStateException: EJBCLIENT000027: No EJBReceiver available for node name
          valsaraj viswanathan Master

          This error vanished when I added the following in jndi.properties:

          java.naming.security.principal=appAdmin

          java.naming.security.credentials=appAdmin

          jboss.naming.client.ejb.context=true

           

          For this, I created an ApplicationRealm user appAdmin.

           

          After this change it worked and shown in log:

          12:48:10,920 INFO  [remoting] EJBCLIENT000017: Received server version 2 and marshalling strategies [river]

          12:48:10,959 INFO  [remoting] EJBCLIENT000013: Successful version handshake completed for receiver context EJBReceiverContext{clientContext=org.jboss.ejb.client.EJBClientContext@51d253b7, receiver=Remoting connection EJB receiver [connection=Remoting connection <6696f8ea>,channel=jboss.ejb,nodename=node1]} on channel Channel ID f700b5c5 (outbound) of Remoting connection 59fc982f to localhost/127.0.0.1:8080

           

          But I got the following error during method access:

          Caused by: javax.ejb.EJBAccessException: JBAS013323: Invalid User

                  at org.jboss.as.ejb3.security.SecurityContextInterceptor$1.run(SecurityContextInterceptor.java:66)

                  at org.jboss.as.ejb3.security.SecurityContextInterceptor$1.run(SecurityContextInterceptor.java:46)

                  at org.jboss.as.ejb3.security.SecurityContextInterceptor.processInvocation(SecurityContextInterceptor.java:92)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.as.ejb3.component.interceptors.ShutDownInterceptorFactory$1.processInvocation(ShutDownInterceptorFactory.java:64)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.as.ejb3.component.interceptors.LoggingInterceptor.processInvocation(LoggingInterceptor.java:59)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.as.ee.component.NamespaceContextInterceptor.processInvocation(NamespaceContextInterceptor.java:50)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.as.ejb3.component.interceptors.AdditionalSetupInterceptor.processInvocation(AdditionalSetupInterceptor.java:55)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.invocation.ContextClassLoaderInterceptor.processInvocation(ContextClassLoaderInterceptor.java:64)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.invocation.InterceptorContext.run(InterceptorContext.java:326)

                  at org.wildfly.security.manager.WildFlySecurityManager.doChecked(WildFlySecurityManager.java:448)

                  at org.jboss.invocation.AccessCheckingInterceptor.processInvocation(AccessCheckingInterceptor.java:61)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.invocation.InterceptorContext.run(InterceptorContext.java:326)

                  at org.jboss.invocation.PrivilegedWithCombinerInterceptor.processInvocation(PrivilegedWithCombinerInterceptor.java:80)

                  at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:309)

                  at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61)

                  at org.jboss.as.ee.component.ViewService$View.invoke(ViewService.java:185)

                  at org.jboss.as.ejb3.remote.protocol.versionone.MethodInvocationMessageHandler.invokeMethod(MethodInvocationMessageHandler.java:330)

                  at org.jboss.as.ejb3.remote.protocol.versionone.MethodInvocationMessageHandler.access$100(MethodInvocationMessageHandler.java:70)

                  at org.jboss.as.ejb3.remote.protocol.versionone.MethodInvocationMessageHandler$1.run(MethodInvocationMessageHandler.java:203)

                  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)

                  at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)

                  at java.util.concurrent.FutureTask.run(FutureTask.java:166)

                  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)

                  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)

                  at java.lang.Thread.run(Thread.java:722)

                  at org.jboss.threads.JBossThread.run(JBossThread.java:122)

                  at ...asynchronous invocation...(Unknown Source)

                  at org.jboss.ejb.client.remoting.InvocationExceptionResponseHandler$MethodInvocationExceptionResultProducer.getResult(InvocationExceptionResponseHandler.java:96)

                  at org.jboss.ejb.client.EJBClientInvocationContext.getResult(EJBClientInvocationContext.java:276)

                  at org.jboss.ejb.client.EJBObjectInterceptor.handleInvocationResult(EJBObjectInterceptor.java:64)

                  at org.jboss.ejb.client.EJBClientInvocationContext.getResult(EJBClientInvocationContext.java:290)

                  at org.jboss.ejb.client.EJBHomeInterceptor.handleInvocationResult(EJBHomeInterceptor.java:88)

                  at org.jboss.ejb.client.EJBClientInvocationContext.getResult(EJBClientInvocationContext.java:290)

                  at org.jboss.ejb.client.TransactionInterceptor.handleInvocationResult(TransactionInterceptor.java:46)

                  at org.jboss.ejb.client.EJBClientInvocationContext.getResult(EJBClientInvocationContext.java:290)

                  at org.jboss.ejb.client.ReceiverInterceptor.handleInvocationResult(ReceiverInterceptor.java:129)

                  at org.jboss.ejb.client.EJBClientInvocationContext.getResult(EJBClientInvocationContext.java:265)

                  at org.jboss.ejb.client.EJBClientInvocationContext.awaitResponse(EJBClientInvocationContext.java:453)

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

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

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

                  at $Proxy16.findProperties(Unknown Source)

            .....

          12:48:14,175 INFO  [remoting] EJBCLIENT000016: Channel Channel ID f700b5c5 (outbound) of Remoting connection 59fc982f to localhost/127.0.0.1:8080 can no longer process messages

          1 of 1 people found this helpful