I am trying to figure out the secret code to get a pool connection for an Oracle database. I can't seem to get the JNDI name right.
The startup log code says:
[INFO,Jams] XA Connection pool Jams bound to java:/Jams
but the following code:
DataSource ds=(DataSource) ctx.lookup("java:/Jams");
gives the error message:
javax.naming.NameNotFoundException: Jams not bound
I've also tried about 10 variations with comp env jdbc with no luck.
TIA for any help.
Reading through other posts, it would seem that the call you are trying to make will only work within the JBoss VM, not from a client running in its own VM. It seems to be a part of the spec and a security thing.