on 02-05-2014 7:46 AM
Hi Guru's
I need your help to fix my first EJB programme
I have created a DC project for EJB 3.0. (SampleClass & SampleClassRemote)
I have created DC Java project for calling the session class.
But I think the lookup string is wrong. When I checked "ejb-j2ee-engine.xml" not shown any JNDI property like old EJB project.
String lookupString = "ejb:/interfaceName=com.test.ejb01.SampleClass";
and getting error " javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial "
I have attached the two projects with this.If possible can you please check that code and correct me?
below is the project structure of my programme
Thanks in Advance:
Jacob
Hi,
One more thing
You can verify it in NWA
Troubleshooting>Java>JNDI Browser
and select your application it will give the details
Regards,
Ram
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Jacob,
usually it will be <package>.<remote>
for you, com.test.ejb01.SampleClassRemote
Object obj = ctx.lookup("ejb:/interfaceName=com.test.ejb01.SampleClassRemote");
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.