An application uses a connection factory to create a connection.
For a list of the XMS defined properties of a ConnectionFactory object, see Properties of ConnectionFactory.
Function | Description |
---|---|
xmsConnFactCreate | Create a connection factory with the default properties. |
xmsConnFactCreateConnection | Create a connection using the default user identity. |
xmsConnFactCreateConnectionForUser | Create a connection using a specified user identity. |
xmsConnFactDispose | Delete the connection factory. |
xmsRC xmsConnFactCreate(xmsHConnFact *factory, xmsHErrorBlock errorBlock);
Create a connection factory with the default properties.
xmsRC xmsConnFactCreateConnection(xmsHConnFact factory, xmsHConn *connection, xmsHErrorBlock errorBlock);
Create a connection using the default user identity.
The connection factory properties XMSC_USERID and XMSC_PASSWORD, if they are set, are used to authenticate the application. If these properties are not set, the connection is created without authenticating the application, provided the messaging server permits a connection without authentication. The properties are ignored if the application connects to a WebSphere MQ queue manager in bindings mode.
The connection is created in stopped mode. No messages are delivered until the application calls xmsConnStart().
xmsRC xmsConnFactCreateConnectionForUser(xmsHConnFact factory, xmsCHAR *userID, xmsCHAR *password, xmsHConn *connection, xmsHErrorBock errorBlock);
Create a connection using a specified user identity.
The specified user identifier and password are used to authenticate the application. The connection factory properties XMSC_USERID and XMSC_PASSWORD, if they are set, are ignored. The user identifier and password are ignored if the application connects to a WebSphere MQ queue manager in bindings mode.
The connection is created in stopped mode. No messages are delivered until the application calls xmsConnStart().
xmsRC xmsConnFactDispose(xmsHConnFact *factory, xmsHErrorBlock errorBlock);
Delete the connection factory.
If an application tries to delete a connection factory that is already deleted, the call is ignored.