!--a11y-->
Closing the JMS Connection 
You perform this operation when you want to finish using the JMS connection, and the objects used must be released. This means that the Session and the Connection that are created must be closed. You can choose one of two ways: manually close the Session and then the Connection, or close the Connection object only. In the second case, the J2EE Engine JMS Provider automatically closes the Session.
When the connection is closed, the session object and all the connection objects used are released. If you are using point-to-point connection use the following code to close the Connection object:

|
// Close the queue connection queueConnection.close(); |
If you are using the publish-subscribe connection, close the Connection in the same way:

|
// Close the topic connection topicConnection.close(); |
The JMS connection is closed and the Session is automatically stopped.
