users@jms-spec.java.net

[jms-spec users] [jsr343-experts] Re: (JMS_SPEC-94) Define what characters are valid in a durable (or shared subscription) name

From: Nigel Deakin <nigel.deakin_at_oracle.com>
Date: Thu, 19 Apr 2012 15:48:21 +0100

Please see below:

On 17/04/2012 17:58, Nigel Deakin wrote:
> I have created this JIRA issue:
> http://java.net/jira/browse/JMS_SPEC-94
>
> Define what characters are valid in a durable (or shared subscription) name
> ---------------------------------------------------------------------------
>
> The JMS 1.1 specification does not specify what characters are valid in a durable subscription name.
> It is proposed that the JMS 2.0 specification defines a minimum set of characters which are valid in a durable or
> non-durable subscription name.
>
> This is needed to allow portable applications to be created. It is also needed because EJB_SPEC-41 states that if a MDB
> is defined with {{subscriptionDurability}} set to {{Durable}} but {{subscriptionName}} is not set then the container
> will automatically set {{subscriptionName}} to a suitably unique global name of the MDB, and the container vendor needs
> to be sure that the name it generates will always be a legal subscription name.
>
> ---------------------------------------------------------------------------
>
> Over on the EJB expert group they're discussing how to construct the default durable subscription name used for a MDB,
> and one suggestion included "/" characters.
>
> Does anyone know of any existing JMS providers which impose restrictions on what characters are valid?

So far I've discovered that
1. Oracle GlassFish Message Queue has no restrictions
2. Oracle Weblogic JMS does not allow the use of comma, equals, colon, asterisk, percent and question mark.

It has been suggested to me that we could specify that characters that satisfy
java.lang.Character.isJavaIdentifierPart(char ch) would be permitted.

Any views?

Nigel