users@glassfish.java.net

MessageEndpoint per thread pooling?

From: Henrik Olsson <henriko_at_wip.se>
Date: Tue, 23 Jun 2009 14:59:56 +0200

Hello,

We've implemented a Resource Adapter and seeing some suprising behaviour
with MessageEndpoints. The MessageEndpoint proxy object returned from
the MessageEndpointFactory seems to invoke different instances of the
actual endpoint-object depending on which thread access the proxy
object. Is this correct, and intended behaviour?

This is kind of problematic since our RA retrieves a MessageEndpoint
from the Factory, initializes some state on that instance, and then
shares it with another Work instance (aka Thread), this causes calls to
the ME-instance from the other Work instance to arrive in another
(unitialized) instance of the MessageEndpoint.

Regards,
Henrik Olsson