users@glassfish.java.net

Re: Glassfish JMS - No object bound to name java:comp/env/jms

From: <forums_at_java.net>
Date: Thu, 22 Mar 2012 12:36:51 -0500 (CDT)

If you want to look up by its global jndi name:

lookup("jms/TopicConnectionFactory"); //use the jndi-name you assigned to it
when creating this resource, see domain.xml

 

If you want to look up a resource reference in the webapp's component
environment:

lookup("java:comp/env/jms/TopicConnectionFactory");

you will also need to declare a <resource-ref> or <message-destination-ref>,
depends on the type of jms resources, in your web.xml

-cheng


--
[Message sent by forum member 'cf126330']
View Post: http://forums.java.net/node/884469