Uploaded image for project: 'JBoss Enterprise Application Platform 4 and 5'
  1. JBoss Enterprise Application Platform 4 and 5
  2. JBPAPP-5406

UnifiedInvokerProxyHA constructor creates an invalid initial client

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • EAP_EWP 5.1.1
    • EAP_EWP 5.1.0
    • Clustering
    • None
    • Hide

      Reproducing requires taking steps to disable the normal AS functionality that directly routes requests to EJBs that are available in-vm:

      1) Deploy a clustered EJB2 session bean.
      2) In the bean's client configuration, replace the default org.jboss.invocation.InvokerInterceptor with a custom one whose hasLocalTarget() method returns false
      3) Lookup the EJB proxy in JNDI and use it from within the AS (so that no serialization/deserialization of the EJB proxy is required.)

      Show
      Reproducing requires taking steps to disable the normal AS functionality that directly routes requests to EJBs that are available in-vm: 1) Deploy a clustered EJB2 session bean. 2) In the bean's client configuration, replace the default org.jboss.invocation.InvokerInterceptor with a custom one whose hasLocalTarget() method returns false 3) Lookup the EJB proxy in JNDI and use it from within the AS (so that no serialization/deserialization of the EJB proxy is required.)
    • Release Notes
    • Hide
      An incorrect subsystem was set during remoting client creation, due to the order of superclass constructor operations. This created NullPointerExceptions and ClassCastExceptions. Constructors have been altered to initialize the client after the correct subsystem is set.
      Show
      An incorrect subsystem was set during remoting client creation, due to the order of superclass constructor operations. This created NullPointerExceptions and ClassCastExceptions. Constructors have been altered to initialize the client after the correct subsystem is set.
    • Documented as Resolved Issue

    Description

      The UnifiedInvokerProxyHA constructors call the superclass constructors and then set the subsystem to "invokerha". Problem is the superclass constructors create the remoting Client before the subsystem is set, resulting in the incorrect default "invoker" subsystem being used for that client.

      This results in problems (probably NPE or ClassCastException) when UnifiedInvokerProxyHA.invoke tries to handle response values. It expects the response to be an HARMIResponse, and it won't be because the wrong server-side invoker is used.

      This affects clients who run in the AS and have disabled the legacy client interceptors logic that directly routes calls to the locally deployed bean. This is a fairly unusual combination. See "Steps to Reproduce" for the specific recipe.

      Attachments

        Issue Links

          Activity

            People

              bstansbe@redhat.com Brian Stansberry
              bstansbe@redhat.com Brian Stansberry
              Elspeth Thorne Elspeth Thorne (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: