[jboss-user] [Beginner's Corner] - Getting CacheManager via JNDI

Alessandro Novarini do-not-reply at jboss.com
Wed Nov 17 04:49:43 EST 2010

Alessandro Novarini [http://community.jboss.org/people/a.novarini] created the discussion

"Getting CacheManager via JNDI"

To view the discussion, visit: http://community.jboss.org/message/571530#571530

Hello all,

I'm working on JBoss 5.1, so I don't have Infinispan installed nor I can change the default jbosscache.

I need to retrieve the CacheManager for storing object from my code, and I tried to get the CacheManager using JNDI.
In the configuration file of the cache, inside the .SAR archive, I saw that the CacheManager is bound to the name java:CacheManager

I tried, from an external client to lookup the cache pointing to that name (java:CacheManager), but the code raised an Exception telling me that than name was not bound.

Is the CacheManager an object I can use from an external application? Or this is something usable only "inside" the application server?
Do I need to configure it in some way to enable the jndi?

Thanks in advance,

Reply to this message by going to Community

Start a new discussion in Beginner's Corner at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20101117/07613b0a/attachment.html 

More information about the jboss-user mailing list