• Post Reply Bookmark Topic Watch Topic
  • New Topic

JNDI Lookup and Threads

 
Kash Mhai
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
I have a weird problem. I am using JNDI lookups to access my JDBC connection. There is one such situation in the app where i have to use threads for background scheduling. When this thread tries to invoke a JNDI lookup, I get NameNotFound Exception. But this lookup works from everywhere excepting when called through a thread. Where could I have gone wrong?
--
Server is Websphere
JDBC Version 2
--
Can anybody please help me with this?
 
Mudi Appu
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Using threads within EJB container is not recommended. Invoke an MDB (message driven bean) instead of plain java thread.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!