tibemsSession_Close

Function

Purpose

Close a session; reclaim resources.

C Declaration

tibems_status tibemsSession_Close(
    tibemsSession session );

COBOL Call

CALL "tibemsSession_Close"
     USING BY VALUE session,
           RETURNING tibems-status
END-CALL.
Note: session has usage pointer.

Remarks

Closing a session automatically closes its consumers (except for durable subscribers), producers and browsers.

Blocking

If any message listener or receive call associated with the session is processing a message when the program calls this function, all facilities of the connection and its sessions remain available to those listeners until they return. In the meantime, this function blocks until that processing completes—that is, until all message listeners and receive calls have returned.

Transactions

Closing a session rolls back the open transaction in the session.