IBM WebSphere Adapters Network Card User Manual


 
7. The ConnectionManager may call getConnection(Subject,
ConnectionRequestInfo) on a ManagedConnection where the passed
ConnectionRequestInfo does not match the ConnectionRequestInfo already
associated with the ManagedConnection. The default implementation of this
method performs a property-for-property comparison between the two
ConnectionRequestInfo instances. It returns true if an exact match is found,
otherwise false. If the match criteria is something different, the resource
adapter developer may override this method with a suitable implementation.
8. Return true if the WBIConnectionRequestInfo is deemed a match with the
WBIConnectionRequestInfo already associated with this ManagedConnection;
otherwise return false.
Implementing outbound support
You enable outbound support by providing an EIS-specific implementation of a
resource adapter. This requires extending the Adapter Foundation Class
implementations of common client interfaces (Connection, Interaction, and
Metadata) and the ManagedConnection and ManagedConnectionFactory interfaces.
WBIManagedConnectionFactory:
A javax.resource.spi.ManagedConnectionFactory instance manages the creation and
configuration of physical connections to the underlying EIS. Specifically,
WBIManagedConnectionFactory implements theManagedConnectionFactory and
javax.resource.spi.ResourceAdapterAssiociation interfaces.
Configuration Properties
EIS-specific subclasses should specify boxed JavaBean-compliant accessor pairs
(e.g., setValue(Integer i) rather than setValue(int i)). The accessor pairs get
and set EIS-specific outbound configuration properties and logic. This is the means
by which property change events reach property change listeners with
corresponding updates to the ResourceAdapter (RA) deployment descriptor,
thereby making the JCA container aware of available properties. Properties defined
in this class are generally intended for use by the WBIManagedConnection
implementation when connecting to the EIS.
Note: Support for the ResourceAdapterAssociation interface, which cannot be used
in unmanaged environments, is optional for the JCA container. Accordingly, when
defining properties, assume that ManagedConnectionFactory will not have access
to the ResourceAdapter bean or any properties defined at the ResourceAdapter
level. While the ManagedConnectionFactory can check for and use properties at
the ResourceAdapter level as defaults when available, any properties defined at
the ResourceAdapter level and used by the ManagedConnectionFactory should be
optional, contain default values embedded in the ManagedConnectionFactory, or
exposed in the ManagedConnectionFactory so that users can specify values if the
ResourceAdapter bean is not available.
Subclass methods to implement
1. Object createConnectionFactory(ConnectionManager)
This method is called by the JCA container to enable the CCI clients to generate
handles to the physical EIS connection. EIS-specific subclasses should
implement this method to return an EIS-specific factory instance which is a
subclass of WBIManagedConnectionFactory.
WebSphere Adapter development overview 99