Uploaded image for project: 'EJB Client Library (AS7+)'
  1. EJB Client Library (AS7+)
  2. EJBCLIENT-140

Avoid using stale weak affinity values for node selection in the presence of module availability updates


    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 2.1.1.Final
    • Fix Version/s: 2.1.4.Final
    • Labels:


      For a clustered SFSB, the weak affinity indicates either the node that the bean was created on or (if fail-over has already occurred) the node on which the most recent invocation completed successfully. The weak affinity is held in the EJBInvocationHandler used by the proxy for the bean.

      During an invocation, on the client side, the ReceiverInterceptor is used to identify the node to send the invocation to. In the case of a clustered SFSB (strong affinity = cluster, weak affinity = node in cluster), the weak affinity is used without further checks on its current validity.

      In the case where module unavailability updates are received from the cluster for the module in question (for example, when a node is being suspended or shut down), an invocation to a clustered SFSB will be sent to the node shutting down in any case, as the weak affinity is not checked for validity by the ReceiverInterceptor. The negative consequence is that the invocation will fail as we receive an EJBComponentUnavailableException on that invocation attempt. In the case of a deployment under heavy client load, this can result in many exceptional invocations.

      We can avoid this by checking to see that the current setting for weak affinity is valid before using it for the invocation.

        Gliffy Diagrams




              • Assignee:
                rachmato Richard Achmatowicz
                rachmato Richard Achmatowicz
              • Votes:
                0 Vote for this issue
                1 Start watching this issue


                • Created: