WebLogic Messaging API Class Library

IMessageProducer.Close Method 

Closes the message producer.

Since JMS allocates some resources on behalf of a IMessageProducer outside the .NET CLR, clients should Close them when they are not needed. Relying on garbage collection to eventually reclaim these resources may not be timely enough.

There is no need to close a message producer if the producer's parent session or connection is closed, or if its parent context has been closed with CloseAll.

void Close();

Exceptions

Exception TypeCondition
MessageExceptionif JMS fails to Close the producer due to some internal error.

See Also

IMessageProducer Interface | WebLogic.Messaging Namespace