Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-7856

Update tests to use the correct value for Context.PROVIDER_URL

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 11.0.0.Alpha1
    • None
    • Test Suite
    • None

    Description

      Some tests currently set the Context.PROVIDER_URL property to "remote://localhost:4447" in addition to setting the Context.URL_PKG_PREFIXES property to "org.jboss.ejb.client.naming" when looking up an EJB using the "ejb:" prefix. With the old version of EJB client, the Context.PROVIDER_URL property was essentially ignored in this case so it didn't matter that port 4447 isn't the right port anymore. However, with the new version of EJB client (i.e., version 4.x), the following ConnectException now occurs in RemoteEJBReceiver.getConnection() when attempting to invoke a method on the looked up EJB (since RemoteEJBReceiver.getConnection() now attempts to actually get the naming connection if the Context.PROVIDER_URL property was specified):

      java.net.ConnectException: Connection refused
      	at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
      	at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717)
      	at org.xnio.nio.WorkerThread$ConnectHandle.handleReady(WorkerThread.java:321)
      	at org.xnio.nio.WorkerThread.run(WorkerThread.java:567)
      	at ...asynchronous invocation...(Unknown Source)
      	at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:466)
      	at org.jboss.remoting3.FutureConnection.connect(FutureConnection.java:113)
      	at org.jboss.remoting3.FutureConnection.init(FutureConnection.java:75)
      	at org.jboss.remoting3.FutureConnection.get(FutureConnection.java:151)
      	at org.jboss.remoting3.EndpointImpl.getConnection(EndpointImpl.java:422)
      	at org.jboss.remoting3.UncloseableEndpoint.getConnection(UncloseableEndpoint.java:57)
      	at org.jboss.remoting3.Endpoint.getConnection(Endpoint.java:105)
      	at org.wildfly.naming.client.remote.RemoteNamingProvider.lambda$new$0(RemoteNamingProvider.java:68)
      	at org.wildfly.naming.client.remote.RemoteNamingProvider.getPeerIdentity(RemoteNamingProvider.java:126)
      	at org.jboss.ejb.protocol.remote.RemoteEJBReceiver.getConnection(RemoteEJBReceiver.java:112)
      	at org.jboss.ejb.protocol.remote.RemoteEJBReceiver.processInvocation(RemoteEJBReceiver.java:77)
      	at org.jboss.ejb.client.EJBClientInvocationContext.sendRequest(EJBClientInvocationContext.java:313)
      	at org.jboss.ejb.client.EJBInvocationHandler.lambda$invoke$0(EJBInvocationHandler.java:158)
      	at org.jboss.ejb.client.EJBClientContext.performLocatedAction(EJBClientContext.java:297)
      	at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:149)
      	at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:99)
      	at com.sun.proxy.$Proxy23.trigger(Unknown Source)
      	at org.jboss.as.test.integration.ejb.mdb.cdi.MDBRAScopeCdiIntegrationTestCase.testMe(MDBRAScopeCdiIntegrationTestCase.java:228)
      

      Attachments

        Activity

          People

            fjuma1@redhat.com Farah Juma
            fjuma1@redhat.com Farah Juma
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: