Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NoClassDefFoundError: javax.naming.InitialContext

 
Ja Roel
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I�m trying to connect to a session bean. I�m using VAJ, when I run a test-client everything goes fine. But when I�m trying to get the InitialContext from a java class file I get the following error: "NoClassDefFoundError: javax.naming.InitialContext". The EJB server runs on a different machine, but as I mentioned before the Test Client runs fine. ???
 
Ja Roel
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Already solved the problem. It appears I had to add ujc.jar to the classpath.
:-)
 
Ja Roel
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK, problem not solved. Now I have a javax.naming.CommunicationException Root exception is org.omg.CORBA.COMM_FAILURE: minor code: 3 completed: No.
When I use a hashtable everything works, but when I use the jndi.properties file I get this exception
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic