I am working under Windows Vista Home Premium, Glassfish v2ur2 and developing on NetBeans 6.5. I have been visiting the threads in the forum and some pages googling over there. I have found some answers but no one solve my problem.
The furthest I have got is the following code,
I am trying to call JNDI EJB 2.x but this code gives me a NamingException. It is possible that I do not include the necessaries jar into the project, or that the code should be wrong.
This is the server log,
Does it mean that I need any jar or maybe the code is wrong?
You need to add the following file to your project classpath and I think you should use com.sun.appserv.naming.S1ASCtxFactory instead of the com.sun.enterprise.naming.SerialInitContextFactory, honestly I do not remember the difference right now.
Can you explain what you are going to do? you need to initialize the context factory when you are outside a preconfigured container, for example when you want to access the container managed objects from outside the container. You can take a look at this blog entry to understand how we can use the contextfactory to access container managed resources.
My application is a web application. I have the EJBs in a jar file and the client is the web application. I have got thi InitialContext but I have not the lookup JNDI of the EJBs. It is because the descriptors. I do not know how to declare the EJBs in ejb-jar.xml and sun-ejb-jar.xml This is what I have done,
Excuse me if I do not know enought but I am trying to learn.
On this descriptors, how do I have to call the EJBs home interface?
Because just reach this point I think I can go on alone.