Summary: This file, called
jms-config.xml by default, must exist on the computer running the JMS application.
Overview
This file must exist on the computer running the JMS application. By default, it is called jms-config.xml and is located at <GigaSpaces ROOT>/config/jms.
To connect to the GigaSpaces JMS interface, your application must create an administration tool object, and call
GSJMSAdmin.getInstance(). Calling this method with no arguments loads the client configuration file from its default location. If the configuration file has a different name or is in a different location, the path to the file can be passed as an argument in getinstance().
The client configuration file has four main tags, nested under <com> / <j_space> / <jms>. These are:
- <jndi-bonded-names> - the names under which the JMS Administrated Objects have been registered in the lookup service and the Space URL used to access the space (optional override setting).
- <jms-debug> and <jms-debug-date> - debug settings which enable client side debug logging.
- <durable-subscribers> - when the application creates durable subscriptions to topics, subscriber details are added here. This tag should not be edited.
Connection factory bonded names
<com>
<j_spaces>
<jms>
...
<jndi-bonded-names>
<connections>
<container-prefix>pc-avidesk</container-prefix>
<space-prefix>JavaSpaces</space-prefix>
<overwrite-space-url></overwrite-space-url>
</connections>
</jndi-bonded-names>
...
</jms>
</j_spaces>
</com>
| Tag |
Description |
| <connections> |
The JMS admin connection factories details – the container and space names which are associated to this JMS connection factory. |
| <overwrite-space-url> |
If you want to use the space URL defined in the space configuration file, leave this tag empty. If you want to override the URL defined in the space configuration file, enter a different URL here. This space URL may point to a different space, or, it may have a different protocol (e.g., java://, rmi://) and different URL query string parameters (fifo, create, etc.).An example for an embedded space url may be:java://localhost:10098/CONTAINER-NAME/SPACE-NAME?create&fifo=true. |
| <container-prefix> |
The container name which is associated to this JMS connection factory. |
| <space-prefix> |
The space name which is associated to this JMS connection factory- The combination of container and space names make each topic/queue connection factory uniquely identifiable. |
Debug Settings
<com>
<j_spaces>
<jms>
...
<jms-debug>false</jms-debug>
<jms-debug-date>false</jms-debug-date>
...
</jms>
</j_spaces>
</com>
| Tag |
Description |
| <jms-debug> |
Set to true to turn on client side debug messages logging. This can be useful when debugging scenarios, however, be aware that it can affect performance, because large numbers of debug messages are generated. Debug messages sent to application console and to <GigaSpace Root Directory>\logs. |
| <jms-debug-date> |
Set to true to specify that the debug messages should have a timestamp. This parameter has no effect if <jms-debug> is set to false. |
Durable Subscriber Settings
<com>
<j_spaces>
<jms>
...
<durable-subscribers>
<tc_1_1182584080598420442_5710168192_JavaSpaces_MyTopic>
<durable-topic-name>MyTopic</durable-topic-name>
<session-id>tc_1_1182584080598420442_5710168192_sess_1
</session-id>
<connection-id>tc_1_1182584080598420442_5710168192
</connection-id>
<durable-subscription-name>Sun
</durable-subscription-name>
</tc_1_1182584080598420442_5710168192_JavaSpaces_MyTopic>
<tc_1_1981045727115328267_5710168192_JavaSpaces_MyTopic>
<durable-topic-name>MyTopic</durable-topic-name>
<session-id>tc_1_1981045727115328267_5710168192_sess_1
</session-id>
<connection-id>tc_1_1981045727115328267_5710168192
</connection-id>
<durable-subscription-name>IBM
</durable-subscription-name>
</tc_1_1981045727115328267_5710168192_JavaSpaces_MyTopic>
</durable-subscribers>
</jms>
</j_spaces>
</com>
The <durable-subscribers> tag is created dynamically by GigaSpaces if the application creates a durable subscriber. Each tag under the <durable-subscribers> (such as <tc_1_1182584080598420442_5710168192_JavaSpaces_MyTopic> in the sample above) contains settings for one durable subscriber. These are the unique name of the subscription, the session ID, and the connection ID.
Do not edit any of the parameters under the <durable-subscribers> tag and do not erase any of the subscriber blocks under it. They will be removed automatically when the application unsubscribes.