This content has been marked as final.
Show 3 replies
-
1. Re: Initial durable subscription setup
npujol Dec 6, 2006 8:38 PM (in response to npujol)Ok I am one step further as I found a way to make the association between the user and his connection thought I still have a problem with the message selector being nulled out. The trick is simply to make the association in the JMS_USERS tables by adding an entry in the mysql-jdbc-state-service.xml. So now that file looks like this:
<attribute name="SqlProperties"> .... POPULATE.TABLES.01 = INSERT INTO JMS_USERS (USERID, PASSWD, CLIENTID) VALUES ('ds_user', 'changeit', '_ownsubscriber') POPULATE.TABLES.02 = INSERT INTO JMS_SUBSCRIPTIONS (CLIENTID, SUBNAME, TOPIC, SELECTOR) VALUES ("_ownsubscriber", "_emailSender0","IDMNotificationDurableTopic","subscribers like '%email%'") .... </attribute>
Note that for some reason the SELECTOR column does get cleared upon a call totopicSession.createDurableSubscriber(topic,"_emailSend0");
Does anybody know why? I don't believe this is correct! thoughts? -
2. Re: Initial durable subscription setup
npujol Dec 6, 2006 8:45 PM (in response to npujol)Ok I am one step further as I found a way to make the association between the user and his connection thought I still have a problem with the message selector being nulled out. The trick is simply to make the association in the JMS_USERS tables by adding an entry in the mysql-jdbc-state-service.xml. So now that file looks like this:
<attribute name="SqlProperties"> .... POPULATE.TABLES.01 = INSERT INTO JMS_USERS (USERID, PASSWD, CLIENTID) VALUES ('ds_user', 'changeit', '_ownsubscriber') POPULATE.TABLES.02 = INSERT INTO JMS_SUBSCRIPTIONS (CLIENTID, SUBNAME, TOPIC, SELECTOR) VALUES ("_ownsubscriber", "_emailSender0","IDMNotificationDurableTopic","subscribers like '%email%'") .... </attribute>
Note that for some reason the SELECTOR column does get cleared upon a call totopicSession.createDurableSubscriber(topic,"_emailSend0");
Does anybody know why? I don't believe this is correct! thoughts? -
3. Re: Initial durable subscription setup
npujol Dec 6, 2006 8:48 PM (in response to npujol)According to the JMS 1.1 spec in section 6.3 towards the end:
All JMS providers must be able to run JMS applications that dynamically create
and delete durable subscriptions. Some JMS providers may, in addition,
provide facilities to administratively configure durable subscriptions. If a
durable subscription has been administratively configured, it is valid for it to
silently override the subscription specified by the client.
Shouldn't JbossMQ make sure that a call to topicSession.createDurableSubscriber(topic,subname) does not override what may have been setup in JMS_USERS? Or does this problem arise because the JMS_USERS approach to adding a subscription is trully not an "administered" way of dealing with a topic?