3 Replies Latest reply: Dec 26, 2012 11:41 AM by Tom B RSS

    setClientId equivalent in JMS foreign provider?

    893849
      Hello,

      I am using a MDB, a JMS foreign server and a durable subscription. I need something equivalent to setClientId(String clientID) to set the client id for the connection, preferably using deployment descriptors. All I could find was jms-connection-id which appears to set the id for the topic, not the connection. I don't see a way to set the client ID on the JMS foreign server Connection Factory.

      Thanks.
        • 1. Re: setClientId equivalent in JMS foreign provider?
          Tom B
          I assume your referring to the subscription(s) setup by the MDB container for incoming messages. The MDB programmer's guide provides a good amount of material about this area:

          http://docs.oracle.com/cd/E21764_01/web.1111/e15493/toc.htm

          10 Configuring and Deploying MDBs Using JMS Topics
          11 Deployment Elements and Annotations for MDBs
          B Topic Subscription Identifiers

          Hope this helps,

          Tom
          • 2. Re: setClientId equivalent in JMS foreign provider?
            893849
            Tom,
            Thanks for your response. Yes, I am referring to the subscription(s) setup by the MDB container for incoming messages. I read the sections I thought were relevant but I'm still missing what I need to do, or maybe it is not possible because the container controls it.

            Since I am using a foreign topic, I assume this is what I get based on "Table B-1 How Subscription IDs are Generated":
            topicMessagesDistributionMode = Compatibility
            generateUniqueClientID = false
            subscriptionDurability = Durable
            - ClientID = jmsClientIDBase
            - Subscription Name for the Durable Subscription Case = Same as the ClientId
            - Client ID Policy for WebLogic Topics = Restricted

            From what I've read, I believe ClientID is set by the jms-connection-id. I would like to set Subscription Name, but it looks like it sets it for me automatically to the same as the ClientId.

            Is there a way to configure the subscription name or is that controlled by the container as implied by Table B-1?
            Thanks.
            • 3. Re: setClientId equivalent in JMS foreign provider?
              Tom B
              Client ID Policy for WebLogic Topics = Restricted
              The Client ID Policy doesn't apply unless you're using WebLogic as the JMS provider. If you are using WebLogic JMS, then I recommend using one of the new "one-copy" per app modes.
              Is there a way to configure the subscription name or is that controlled by the container as implied by Table B-1?
              I don't think there's a way to set the subscription name directly - only indirectly as per B-1, where it can be the same as teh client-id or the same as the ejb-name, depending on the use case...