hello.. <resource-refs> may be any resource being used/referenced by the bean..like a connection pool or a topicconnection/queueconnection factory on the other hand.. <resource env ref> can be any string or data format that u look up via jndi context ...like a string u place in the java:comp/env/ namespace this occurs when u would like to create a well known string with a given value and then look up that value from ur bean....instaed of declaring it inside ur code, u look it up from JNDI... hope it helps.. :roll:
Joined: Aug 02, 2004
How is the <resource-env-ref> different from the <env-entry> then?
Joined: Apr 02, 2004
sorry what i meant for <resource -env entry> is actually meant for <env entry>.. the real defn for resource env refs is that they provide a way of accessing, via JNDI lookups, administered objects associated with a resource. For example, an application may need to access a JMS Destination object. The <resource-env-ref> element, defined in the standard deployment descriptors lets applications declare the resource requirements.
The main difference between <resource-env-ref> and <resource-ref> element is the absence of specific resource authentication requirement; both these elements have to be backed up by a resource factory descriptor.