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

Stateful Session Bean affinity URI instead of cluster

    Details

    • Steps to Reproduce:
      Hide

      Run the attached Grade reproducer and have a look at the Test result.

      1) Unzip the stateful-timeout.zip
      2) Ensure you have a directory containing two WildFly instances, named node-1 and node-2
      3) Build and run the reproduction scenario: gradlew -Denv.jboss.cluster.path=<path-to-the-directory-holding-the-instances> clean build

      The build is expecting to fail and the output should be similar to the below:

      Starting a Gradle Daemon (subsequent builds will be faster)
      
      > Task :ejb:test
      
      org.jboss.repro.stateful.timeout.StatefulTimeoutManagerTest > create FAILED
          javax.ejb.NoSuchEJBException at StatefulTimeoutManagerTest.java:150
      
      1 test completed, 1 failed
      
      > Task :ejb:test FAILED
      
      FAILURE: Build failed with an exception.
      
      * What went wrong:
      Execution failed for task ':ejb:test'.
      > There were failing tests. See the report at: file:///{some_path}/stateful-timeout/ejb/build/reports/tests/test/index.html
      

      When opening the referenced index.html and looking into the output of the Standard output, one can see the following logged message:

      2019.03.11 14:59:38 [Test worker] DEBUG org.jboss.ejb.client.invocation - Calling invoke(module = ear/ejb/StatefulTimeoutEjb, strong affinity = URI<remote+http://127.0.0.1:9080>, weak affinity = URI<remote+http://127.0.0.1:9080>): 
      
      Show
      Run the attached Grade reproducer and have a look at the Test result. 1) Unzip the stateful-timeout.zip 2) Ensure you have a directory containing two WildFly instances, named node-1 and node-2 3) Build and run the reproduction scenario: gradlew -Denv.jboss.cluster.path=<path-to-the-directory-holding-the-instances> clean build The build is expecting to fail and the output should be similar to the below: Starting a Gradle Daemon (subsequent builds will be faster) > Task :ejb:test org.jboss.repro.stateful.timeout.StatefulTimeoutManagerTest > create FAILED javax.ejb.NoSuchEJBException at StatefulTimeoutManagerTest.java:150 1 test completed, 1 failed > Task :ejb:test FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':ejb:test' . > There were failing tests. See the report at: file: ///{some_path}/stateful-timeout/ejb/build/reports/tests/test/index.html When opening the referenced index.html and looking into the output of the Standard output , one can see the following logged message: 2019.03.11 14:59:38 [Test worker] DEBUG org.jboss.ejb.client.invocation - Calling invoke(module = ear/ejb/StatefulTimeoutEjb, strong affinity = URI<remote+http: //127.0.0.1:9080>, weak affinity = URI<remote+http://127.0.0.1:9080>):

      Description

      Deployed is an application with the following setup:

      • Containing a SFSB (with passivationCapable="true")
      • A SLSB exposing a remote method to a standalone client returning an instance of the SFSB

      Scenario:

      A standalone client is invoking the remote method on the Stateless Session Bean and a new instance of the Stateful Session Bean is returned.

      The issue is that the affinity of the returned Stateful Session Bean is URI instead of Cluster.

      See the attached Gradle reproducer application

        Gliffy Diagrams

          Attachments

          1. stateful-timeout.zip
            67 kB
          2. stateful-timeout-eap7.0.zip
            1.78 MB
          3. test-debug-log.txt
            143 kB

            Issue Links

              Activity

                People

                • Assignee:
                  rachmato Richard Achmatowicz
                  Reporter:
                  jbaesner Joerg Baesner
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  8 Start watching this issue

                  Dates

                  • Created:
                    Updated: