« Return to Thread: JMS plugin

JMS plugin

by Huang, Thomas (388J) :: Rate this Message:

Reply to Author | View in Thread

Hi

I am new to Grails and my first task is to implement a JMS message  
listener on an existing JMS topic.  I am using JBoss MQ and I have the  
following defined in my resources.xml

    <bean id="connectionFactory"  
class="org.springframework.jndi.JndiObjectFactoryBean">
       <property name="jndiName" value="UIL2ConnectionFactory" />
       <property name="jndiEnvironment">
          <props>
             <prop  
key
=
"java.naming.factory.initial">org.jnp.interfaces.NamingContextFactory</
prop>
             <prop key="java.naming.provider.url">localhost:1099</prop>
          </props>
       </property>
    </bean>


And I modified the SampleQueueService.groovy to listen to my topic

class SampleQueueService {

    static expose = ['jms']
    static pubSub = true
    static durable = true
    static topic = 'my/msg/topic'

    def onMessage = {
       println "GOT MESSAGE: $it"
    }

}

At this point my service is not picking up any messages.  I have a  
couple of questions

1. where do I specify user credential information to connect to the JMS?
2. if I want to do something with the message and than republish it a  
different topic, how do I do that?


please advise,

Thomas.

------------------------------------------------------------------
Thomas Huang
Jet Propulsion Laboratory
4800 Oak Grove Drive, Mail Stop 171-243D, Pasadena, CA 91109
Phone: 818.354.2747, Email: thomas.huang@...

DISCLAIMER: All personal and professional opinions presented herein  
are my own and do not, in any way, represent the opinion of policy of  
JPL, NASA or Caltech.





---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


 « Return to Thread: JMS plugin