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

[GSS](7.2.0) violation of call-by-value if a outbound connection is configured

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Blocker Blocker
    • 7.2.0.GA
    • 7.1.0.GA, 7.1.1.GA, 7.1.2.GA, 7.1.3.GA, 7.1.4.GA
    • EJB
    • +
    • Hide

      Code is available here https://github.com/wfink/jboss-eap7.1-playground/tree/serverWithMultiAppEar

      use the sub project "server" to build the ear and deploy it
      use runInitialContextClient script or the class
      clients/InitialContext/src SimpleClient
      to invoke the EJB, this EJB will invoke another via @Remote

      You need to add the remote-outbound-configuration like this

      <outbound-connections>
      <remote-outbound-connection name="remote-ejb-connection" outbound-socket-binding-ref="remote-ejb">
      <properties>
      <property name="SASL_POLICY_NOANONYMOUS" value="false"/>
      <property name="SSL_ENABLED" value="false"/>
      </properties>
      </remote-outbound-connection>
      </outbound-connections>
      ....
      <outbound-socket-binding name="remote-ejb">
      <remote-destination host="localhost" port="8180"/>
      </outbound-socket-binding>

      Note the target must not exist.

      As a result the invocation show "call-by-reference"
      If the jboss-ejb-client.xml is removed from the application the invocation show "call-by-value"

      Show
      Code is available here https://github.com/wfink/jboss-eap7.1-playground/tree/serverWithMultiAppEar use the sub project "server" to build the ear and deploy it use runInitialContextClient script or the class clients/InitialContext/src SimpleClient to invoke the EJB, this EJB will invoke another via @Remote You need to add the remote-outbound-configuration like this <outbound-connections> <remote-outbound-connection name="remote-ejb-connection" outbound-socket-binding-ref="remote-ejb"> <properties> <property name="SASL_POLICY_NOANONYMOUS" value="false"/> <property name="SSL_ENABLED" value="false"/> </properties> </remote-outbound-connection> </outbound-connections> .... <outbound-socket-binding name="remote-ejb"> <remote-destination host="localhost" port="8180"/> </outbound-socket-binding> Note the target must not exist. As a result the invocation show "call-by-reference" If the jboss-ejb-client.xml is removed from the application the invocation show "call-by-value"

      If the server default configuration is used an EJB invocation via @Remote interface is, according to the specification, with call-by-value.
      But if the application is configured with jboss-ejb-client.xml to have a remote-outbound-connection the EJB invocation via @Remote is done as call-by-reference no matter whether the configuration is default or
      <in-vm-remote-interface-invocation pass-by-value="true"/>
      is used.

      This is a violation of the specification and can cause serious unexpected issues at runtime for the application if the parameters or return values are mutable

              flaviarnn Flavia Rainone
              rhn-support-bmaxwell Brad Maxwell
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: