users@glassfish.java.net

Re: How to inject a resource-env-rev using ...

From: <forums_at_java.net>
Date: Thu, 5 Jan 2012 17:52:08 -0600 (CST)

Try @Resource(name="xxx", lookup="config/injectMe") or @Resource(name="xxx",
mappedName="config/injectMe").

name is the name you give this resource reference, can be any name.  lookup
or mappedName is where to get this value.

If you don't want to have this runtime info in java code, you can specify the
jndi-name mapping in glassfish-ejb-jar.xml or glassfish-web.xml

-Cheng


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