Adapter Development Kit 6.5 | webMethods Adapter Development Kit Documentation | webMethods Adapter Development Kit Installation and User’s Documentation | Run Time Activities | Run Time Connection Allocation for Adapter Services | Implementing Partitioned Connection Pools | Extending WmConnectionSpec
 
Extending WmConnectionSpec
A WmConnectionSpec object is used during an adapter service invocation to identify a connection node and/or to hold any contextual information from the service configuration and invocation pipeline that is needed to identify the partition of the connection. Accessors for the connection node name are provided in the base class. Contextual information need for partition definition is specific to the adapter and must be implemented in an adapter-defined subclass.
For the MegaBank example, each customer is assigned a username that allows access to all of the bank's services. This value must be cross-referenced to obtain the name by which that user is known on the specific back-end system. This cross-referencing will be delegated to the WmConnectionFactory.getConnectionRequestInfo() implementation described later in this document. For now, we simply need a container to hold the information.
public class MbConnectionSpec extends WmConnectionSpec
{
 private String mbUserName;
 public MbConnectionSpec()
 {
  super();
 }
 public String getMbUserName()
 {
  return mbUserName;
 }
 public void setMbUserName(String mbUserName)
 {
  this.mbUserName = mbUserName;
 }
}