+

Search Tips   |   Advanced Search

JMS endpoint URL syntax

A JMS endpoint URL is used to access JAX-RPC Web services with the JMS transport. This URL specifies the JMS destination and connection factory, as well as the port component name for the Web service request. This endpoint URL is similar to the HTTP endpoint URL, which specifies the host and port as well as the context root and port component name. A JMS endpoint URL has the following general form:

jms:/[queue|topic]?<property>=<value>&<property>=<value>&...
The URL consists of the jms: transport type, followed by either /queue or /topic to indicate the JMS destination type, followed by the query string containing a list of property and value pairs that are used to specify the JMS endpoint information.

The properties supported in the URL string are described in the following tables:

Destination-related properties (required)

Property name Description
destination Specifies the Java Naming and Directory Interface (JNDI) name of the destination queue or topic.
connectionFactory Specifies the JNDI name of the connection factory.
targetService Specifies the name of the port component to which the request is dispatched.

JNDI-related properties (optional)

Property name Description
initialContextFactory Specifies the name of the initial context factory to use which is mapped to the java.naming.factory.initial property.
jndiProviderURL Specifies the JNDI provider URL, which is mapped to the java.naming.provider.url property.

JMS-related properties (optional)

Property name Description
deliveryMode Indicates whether the request message is persistent or not. The valid values are 1 for nonpersistent and 2 for persistent. The default value is 1.
timeToLive Lifetime, in milliseconds, of the request message. A value of 0 indicates an infinite lifetime.
priority Specifies the JMS priority associated with the request message. Valid values are between 0 to 9. The default value is 4. A value of 0 is the lowest priority and a value of 9 is the highest priority.
replyToDestination Specifies the JNDI name of a queue to be used to receive reply messages. Using this optional property allows the client to use a permanent queue, rather than a temporary queue, for receiving replies.

If you set values for the deliveryMode, timeToLive, and priority properties on the JMS request, these values are propagated from the JMS request message to the corresponding JMS reply message.

The required properties, destination, connectionFactory, and targetService must appear in the JMS endpoint URL string. The rest of the properties are optional.

You can set any of the properties on the client Stub object. The various properties can be specified by including them as part of the endpoint URL or they can be set programmatically by the client on the Stub object. Properties specified on the client Stub object take precedence over properties that are specified as part of a JMS endpoint URL string.


 

Related tasks


Use the JMS API to transport JAX-RPC Web services requests

 

Related information


Web services SOAP/JMS protocol

 

Reference topic