]
David Lloyd commented on WFLY-3431:
-----------------------------------
This should have been fixed as of WildFly 11; I'll leave this open for now until it
can be verified.
outbound connection to remote ejbs attempts to use http upgrade even
if protocol="remote" is specified.
-------------------------------------------------------------------------------------------------------
Key: WFLY-3431
URL:
https://issues.jboss.org/browse/WFLY-3431
Project: WildFly
Issue Type: Bug
Components: Remoting
Affects Versions: 8.0.0.Final
Reporter: Jason Essington
Assignee: David Lloyd
When attempting to connect to remote EJBs running on JBoss AS 7.2.0.Final from WildFly
8.0.0.Final, WildFly chooses to use http upgrade even though the outbound connection
specifies protocol="remote"
Outbound remoting connections in the wildfly config are defined like:
{code:xml}
<remote-outbound-connection name="remote-ds-connection"
outbound-socket-binding-ref="remote-dataserver"
username="calypso_user" security-realm="engine-security-realm"
protocol="remote">
<properties>
<property name="SASL_POLICY_NOANONYMOUS"
value="false"/>
<property name="SSL_ENABLED" value="false"/>
</properties>
</remote-outbound-connection>
{code}
Yet, when attempting to connect to remote EJBs located on the JBoss AS 7.2.0.Final
server, the jboss log shows:
{noformat}
11:10:21,581 ERROR [org.jboss.remoting.remote.connection] (Remoting
"standalone-dataserver" read-1) JBREM000200: Remote connection failed:
java.io.IOException: Received an invalid message length of 1195725856
{noformat}
and the stacktrace on wildfly shows:
{noformat}
2014-06-02 11:10:21,506 WARN
[org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector] (ServerService Thread
Pool -- 67) Could not register a EJB receiver for connection to localhost:4447:
java.lang.RuntimeException: java.io.EOFException: XNIO000812: Connection closed
unexpectedly
at org.jboss.ejb.client.remoting.IoFutureHelper.get(IoFutureHelper.java:92)
[jboss-ejb-client-2.0.0.Final.jar:2.0.0.Final]
... clipped ...
Caused by: java.io.EOFException: XNIO000812: Connection closed unexpectedly
at
org.xnio.http.HttpUpgrade$HttpUpgradeState$UpgradeResultListener.handleEvent(HttpUpgrade.java:298)
[xnio-api-3.2.0.Final.jar:3.2.0.Final]
at
org.xnio.http.HttpUpgrade$HttpUpgradeState$UpgradeResultListener.handleEvent(HttpUpgrade.java:281)
[xnio-api-3.2.0.Final.jar:3.2.0.Final]
at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)
[xnio-api-3.2.0.Final.jar:3.2.0.Final]
at
org.xnio.conduits.ReadReadyHandler$ChannelListenerHandler.readReady(ReadReadyHandler.java:66)
[xnio-api-3.2.0.Final.jar:3.2.0.Final]
at org.xnio.nio.NioSocketConduit.handleReady(NioSocketConduit.java:87)
at org.xnio.nio.WorkerThread.run(WorkerThread.java:531)
at ...asynchronous invocation...(Unknown Source)
at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:272)
[jboss-remoting-4.0.0.Final.jar:4.0.0.Final]
at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:388)
[jboss-remoting-4.0.0.Final.jar:4.0.0.Final]
at
org.jboss.ejb.client.remoting.EndpointPool$PooledEndpoint.connect(EndpointPool.java:187)
[jboss-ejb-client-2.0.0.Final.jar:2.0.0.Final]
at org.jboss.ejb.client.remoting.NetworkUtil.connect(NetworkUtil.java:153)
[jboss-ejb-client-2.0.0.Final.jar:2.0.0.Final]
at org.jboss.ejb.client.remoting.NetworkUtil.connect(NetworkUtil.java:133)
[jboss-ejb-client-2.0.0.Final.jar:2.0.0.Final]
at org.jboss.ejb.client.remoting.ConnectionPool.getConnection(ConnectionPool.java:75)
[jboss-ejb-client-2.0.0.Final.jar:2.0.0.Final]
... 110 more
{noformat}
and ultimately shows:
{noformat}
Caused by: java.lang.RuntimeException: Unable to connect to
ejb:/dataserver//com.xxxx.yy.service.SomeService!com.xxxx.yy.service.SomeService at
remote://localhost:4447
.... clipped ...
{noformat}
Which shows that it should be using a remote URL (as well as remote protocol rather than
http-remoting) and is the same host/port on the connection defined in configuration. Yet
the errors seem to indicate that WildFly is attempting to use http upgrade.