users@glassfish.java.net

How to achieve the dynamic topic selection in MDB(ejb3) -

From: <glassfish_at_javadesktop.org>
Date: Mon, 29 Dec 2008 11:07:53 PST

Hello Everybody,


we are working on publish, subscribe JMS for my Glassfish server.I am in a situation where I am forced to have a hostname as topic.

I am using EJB 3.0 so I have access to the annotations. I am using the following annotation

@MessageDriven(mappedName = "jms/testtrigger1_com", activationConfig =
{
      activationConfig =
      {
                    @ActivationConfigProperty( propertyName = "acknowledgeMode",
                                    propertyValue = "Auto-acknowledge"),
                    @ActivationConfigProperty( propertyName = "destinationType",
                                    propertyValue = "javax.jms.Topic"),
                    @ActivationConfigProperty( propertyName = "subscriptionDurability",
                                    propertyValue = "Durable"),
                    @ActivationConfigProperty( propertyName = "clientId",
                                    propertyValue = "AshishReceiverBean"),
                    @ActivationConfigProperty( propertyName = "subscriptionName",
                                    propertyValue = "AshishReceiverBean")
          }
)

My question now is how can I achieve the dynamic, topic selection (Dynamic is based on server's IP or host name).


the same question was asked in the experts-exchange but there is no answer for it.

Any help would be appreciated..

Thanks
Bhanu
[Message sent by forum member 'bharas' (bharas)]

http://forums.java.net/jive/thread.jspa?messageID=323549