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.