This week's book giveaways are in the Jython/Python and Object-Oriented programming forums.
We're giving away four copies each of Machine Learning for Business: Using Amazon SageMaker and Jupyter and Object Design Style Guide and have the authors on-line!
See this thread and this one for details.
Win a copy of Machine Learning for Business: Using Amazon SageMaker and JupyterE this week in the Jython/Python forum
or Object Design Style Guide in the Object-Oriented programming forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
  • Knute Snortum
Sheriffs:
  • Liutauras Vilda
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Joe Ess
  • salvin francis
  • fred rosenberger

Exporting EJB Client from Visual Age for Java

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
I developed in Visual Age client for the EJB deployed on WAS ver. 4.0 AE. In the Visual Age test environment the client works fine, but outside VA (SDK 1.3.1_04 JRE) it returns "javax.naming.NamingException: Error during resolve [Root exception is java.lang.NullPointerException]". This exception is raised when client tries to look for the JNDI name at the initial context obtained with com.ibm.ejs.ns.jndi.CNInitialContextFactory. I've already exported all necessary packages from the VA to the .jar and added the appropriate entry at ClassPath variable. EJB is deployed on remote server, and I've checked the correctness of JNDI name.
Can you tell me where is my mistake?
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you using the IBM JDK or the Sun JDK? It will only work with the IBM JDK -- also, if you're using WAS 4.0 you REALLY need to build a J2EE application client and use "launchClient" to start it. Read my WebSphere workbook for more information on the topic.
Kyle
 
Vladimir Dovgalyuk
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for answer.
I'm using Sun JDK + Sun J2SDKEE version 1.3.1
Is it possible to connect EJB at WAS 4.0 from client application using only these tools (with com.sun.jndi.* e.g.)?
 
Kyle Brown
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
OK, I'd like to say that it's not possible to do so with those tools. (Well, it really is, but the way of doing it is not supported by IBM -- See the pluggable application client for details.)
My advice is to use the IBM JDK and the launchClient tool. It will work out easiest in the long run.
Kyle
 
Then YOU must do the pig's work! Read this tiny ad. READ IT!
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!