Advanced Method for Configuring Resource Providers

The JMS resource adapter supports the groupDefinitions property to provide an advanced method for configuring resource providers. Using this property enables you to create a compatible set of messaging objects while providing flexible address resolution of connection factories and administered objects. Using the groupDefinitions property has a dependency on the following components:

  • Group—A set of compatible messaging objects, such as connection factories and associated destination administered objects.

  • Macro—A Group component that is substituted for a rpResourceLocation configuration property in connection factories and administered objects.

To configure a groupDefinitions property in the ra.xml file, complete the following steps:

  1. Specify groupDefinitions as the value of the <config-property-name> element. For example:
    <config-property-name>groupDefinitions</config-property-name>
    
  2. Specify java.lang.String as value of the <config-property-type> element. For example:
    <config-property-type>java.lang.String</config-property-type>
    
  3. Define a Group configuration by using the following pattern:
    <config-property-value>
       GROUP_NAME: macro
    </config-property-value
    

    In the preceding pattern:

    • GROUP_NAME is a unique name that represents a Group configuration.

    • macro is a comma-separated list of name-value pairs that define a set of compatible messaging objects. The JMS resource adapter substitutes these pairs for rpResourceLocation configuration properties in connection factories and administered objects.

See Example Resource Provider Configuration for an example configuration.