users@jms-spec.java.net

[jms-spec users] [jsr368-experts] Re: JMS 2.0 Errata: JMS_SPEC-167: Session javadoc should mention consumer.close is allowed outside thread of control

From: Nigel Deakin <nigel.deakin_at_oracle.com>
Date: Thu, 12 Feb 2015 16:18:28 +0000

On 12/02/2015 16:01, Nigel Deakin wrote:
> On 22nd January, EG member Chris Harrow logged the following issue

Apologies for the careless typing, Chris *Barrow*...

> https://java.net/jira/browse/JMS_SPEC-167
> (JMS 2.0: Session javadoc should mention consumer.close is allowed outside thread of control)
>

Proposed changes to the class javadoc for Session:
--------------------------------------------------

Existing text:

Once a connection has been started, any session with one or more registered message listeners is dedicated to the thread
of control that delivers messages to it. It is erroneous for client code to use this session or any of its constituent
objects from another thread of control. The only exception to this rule is the use of the session or connection close
method.

Replacement text:

Once a connection has been started, any session with one or more registered message listeners is dedicated to the thread
of control that delivers messages to it. It is erroneous for client code to use this session or any of its constituent
objects from another thread of control. The only exception to this rule is the use of the session or message consumer
close method.

Updated source
--------------

The draft JMS 2.0 javadocs can be viewed at
https://jms-spec.java.net/2.0RevA-SNAPSHOT/apidocs/index.html

Updated source for javax.jms.JMSContext can be viewed at, and downloaded from,
https://java.net/projects/jms-spec/sources/repository/content/jms2.0a/src/main/java/javax/jms/Session.java?rev=328

Diffs can be viewed at
https://java.net/projects/jms-spec/sources/repository/diff/jms2.0a/src/main/java/javax/jms/Session.java?rev1=327&rev2=328

Nigel