Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-16069

[GSS](7.2.z) WEJBHTTP-20 - EJB over HTTP using Apache httpd via AJP does not work

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Verified (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 7.2.0.GA
    • Fix Version/s: 7.2.1.CR1, 7.2.1.GA
    • Component/s: EJB
    • Labels:
      None
    • Target Release:
    • Steps to Reproduce:
      Hide
      1. Start a JBoss EAP 7.2.0.GA with the standalone-ha.xml profile and an application containing a session bean
      2. Start an Apache httpd with the following mod_proxy configuration:
        ProxyPass "/wildfly-services" "ajp://localhost:8009/wildfly-services" keepalive=on
      3. Invoke the session bean from a standalone Java client using the following configuration in the wildfly-config.xml:
        <configuration>
        	<authentication-client xmlns="urn:elytron:1.0">
        		<authentication-rules>
        			<rule use-configuration="all" />
        		</authentication-rules>
        		<authentication-configurations>
        			<configuration name="all">
        				<set-user-name name="{username}" />
        				<credentials>
        					<clear-password password="{password}" />
        				</credentials>
        			</configuration>
        		</authentication-configurations>
        	</authentication-client>
        	<discovery xmlns="urn:wildfly-discovery:1.0">
        		<discovery-provider>
        			<static>
        				<service uri="http://{host-on-httpd}:{port-on-httpd}/wildfly-services" abstract-type="ejb" abstract-type-authority="jboss">
        					<attribute name="ejb-module" value="{application-name}/{ejb-jar-name}" />
        				</service>
        			</static>
        		</discovery-provider>
        	</discovery>
        	<jboss-ejb-client
        		xmlns="urn:jboss:wildfly-client-ejb:3.0">
        		<invocation-timeout seconds="10" />
        	</jboss-ejb-client>
        </configuration>
        
      Show
      Start a JBoss EAP 7.2.0.GA with the standalone-ha.xml profile and an application containing a session bean Start an Apache httpd with the following mod_proxy configuration: ProxyPass "/wildfly-services" "ajp://localhost:8009/wildfly-services" keepalive=on Invoke the session bean from a standalone Java client using the following configuration in the wildfly-config.xml : <configuration> <authentication-client xmlns= "urn:elytron:1.0" > <authentication-rules> <rule use-configuration= "all" /> </authentication-rules> <authentication-configurations> <configuration name= "all" > <set-user-name name= "{username}" /> <credentials> <clear-password password= "{password}" /> </credentials> </configuration> </authentication-configurations> </authentication-client> <discovery xmlns= "urn:wildfly-discovery:1.0" > <discovery-provider> < static > <service uri= "http: //{host-on-httpd}:{port-on-httpd}/wildfly-services" abstract -type= "ejb" abstract -type-authority= "jboss" > <attribute name= "ejb-module" value= "{application-name}/{ejb-jar-name}" /> </service> </ static > </discovery-provider> </discovery> <jboss-ejb-client xmlns= "urn:jboss:wildfly-client-ejb:3.0" > <invocation-timeout seconds= "10" /> </jboss-ejb-client> </configuration>

      Description

      An EJB over HTTP invocation from a standalone Java client to a JBoss EAP server through an Apache httpd connected to JBoss EAP via AJP does not work and result in the following Exception:

      Exception in thread "main" javax.ejb.EJBException: java.io.IOException: UT001033: Invalid connection state
      	at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:207)
      	at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:112)
      	at com.sun.proxy.$Proxy0.logMessageAndReturnJBossNodeNameWithDelay(Unknown Source)
      	at org.jboss.playground.client.CommonClient.invokeSimpleRemote(CommonClient.java:52)
      	at org.jboss.playground.client.EjbOverHttpWithWildflyConfigXmlEjbClient.main(EjbOverHttpWithWildflyConfigXmlEjbClient.java:54)
      Caused by: java.io.IOException: UT001033: Invalid connection state
      	at io.undertow.client.http.HttpClientConnection.sendRequest(HttpClientConnection.java:336)
      	at org.wildfly.httpclient.common.HttpTargetContext.sendRequestInternal(HttpTargetContext.java:165)
      	at org.wildfly.httpclient.common.HttpTargetContext$1$1.lambda$null$0(HttpTargetContext.java:183)
      	at org.wildfly.httpclient.common.HttpConnectionPool$1.completed(HttpConnectionPool.java:157)
      	at org.wildfly.httpclient.common.HttpConnectionPool$1.completed(HttpConnectionPool.java:151)
      	at io.undertow.client.http.HttpClientProvider.handleConnected(HttpClientProvider.java:156)
      	at io.undertow.client.http.HttpClientProvider.access$000(HttpClientProvider.java:51)
      	at io.undertow.client.http.HttpClientProvider$2.handleEvent(HttpClientProvider.java:127)
      	at io.undertow.client.http.HttpClientProvider$2.handleEvent(HttpClientProvider.java:124)
      	at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
      	at org.xnio.nio.WorkerThread$ConnectHandle.handleReady(WorkerThread.java:333)
      	at org.xnio.nio.WorkerThread.run(WorkerThread.java:591)
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              tmiyar Teresa Miyar Gil (Inactive)
              Reporter:
              jbaesner Joerg Baesner
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: