Connection factories

To enable JMS applications to establish connections with the message service, create queue connection factories for PTP messaging, and create topic connection factories for Pub/Sub messaging.

StepsAdding a queue or topic connection factory

  1. To add a queue connection factory, select Queue Connection Factory; to add a topic connection factory, select Topic Connection Factory.

  2. Right-click and select Add.

  3. Enter a name for the connection factory and click OK.

StepsConfiguring a connection factory’s properties

  1. Select either Queue Connection Factory or Topic Connection Factory.

  2. Highlight the connection factory you want to configure, right-click, and select Properties.

  3. Select the Configuration tab and enter the connection factory properties described in Table 8-2.

    Table 8-2: Connection factory properties

    Property

    Datatype

    Default value

    Description

    CLIENT_ID

    string

    blank

    Used for topic connection factories only. It enables EAServer to uniquely identify a client if it disconnects and later reconnects. Every connection that is created using this connection factory inherits this ID. The CLIENT_ID is ignored for queue connections.

    CONFIG_QUEUE

    string

    blank

    When you access a queue or topic, its configuration properties are copied from this named queue.

    IGNORE_DUPLICATE_KEY

    boolean

    true

    Indicates whether a message should be ignored if it is a duplicate.

    NO_IMPLICIT_CREATION

    boolean

    true

    Indicates whether a queue or topic that does not already exist should be implicitly created when a client attempts to access it.

    REQUIRES_ACKNOWLEDGE

    boolean

    false

    To optimize the performance of a JMS application, set to false. In this case, the message service does not acknowledge messages. If a connection terminates unexpectedly, messages may be lost.

    REQUIRES_TRANSACTION

    boolean

    true

    To force the methods publish, send, receive, and onMessage to participate in transactions, set to true. To improve throughput for bulk publishing, sending, or receiving transient messages, set to false.

    For information about using transactions, see Chapter 2, “Understanding Transactions and Component Lifecycles,” in the EAServer Programmer’s Guide.

    SHARED_LISTENER

    boolean

    false

    When set to true, all message consumers for a connection use the same message listener.

    A shared listener can greatly improve performance for nondurable topic subscribers by creating a single message queue for all the topic subscriptions. To use this feature, install a message listener on the first topic subscription, then each nondurable subscription that uses the connection, receives messages from this listener.

    EAServer imposes two restrictions for shared listeners:

    • Do not call setMessageListener with a null parameter. This shuts down the current listener, which may be in use by other subscribers.

    • Do not call setMessageListener with the name of another listener, which shuts down the current listener and register the new listener.

    SUPPORTS_TRANSACTION

    boolean

    true

    Determines whether JMS publish, send, receive, and onMessage calls use the SUPPORTS_TRANSACTION option.

    If you set this to false, it significantly improves throughput for transient message bulk processing.

    THREAD_POOL

    string

    blank

    The message service uses threads from this thread pool for client notification. Using a thread pool can significantly improve performance.

    TRANSPARENT_FAILOVER

    boolean

    true

    Indicates whether JMS clients should allow transparent failover for message service operations. If set to false, a pinned object is used. If set to true, carefully consider the IGNORE_DUPLICATE_KEY setting.