File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB and Other Java EE Technologies and the fly likes Getting error while deploying EJB Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » EJB and Other Java EE Technologies
Reply Bookmark "Getting error while deploying EJB" Watch "Getting error while deploying EJB" New topic
Author

Getting error while deploying EJB

Kamal Kumawat
Greenhorn

Joined: Mar 08, 2010
Posts: 1
Initially i was getting JNDI Naming Lookup Exception
nut when I added jars I am getting error shown below :

java.lang.NullPointerException
at com.sun.enterprise.naming.impl.SerialContext.getRemoteProvider(SerialContext.java:297)
at com.sun.enterprise.naming.impl.SerialContext.getProvider(SerialContext.java:271)
at com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:430)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at app.test.SimpleBeanClient.runTest(SimpleBeanClient.java:11)
at app.test.SimpleBeanClient.main(SimpleBeanClient.java:19)
javax.naming.NamingException: Lookup failed for 'ejb/SimpleBeanJNDI' in SerialContext [Root exception is javax.naming.NamingException: Unable to acquire SerialContextProvider for SerialContext [Root exception is java.lang.NullPointerException]]
at com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:442)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at app.test.SimpleBeanClient.runTest(SimpleBeanClient.java:11)
at app.test.SimpleBeanClient.main(SimpleBeanClient.java:19)
Caused by: javax.naming.NamingException: Unable to acquire SerialContextProvider for SerialContext [Root exception is java.lang.NullPointerException]
at com.sun.enterprise.naming.impl.SerialContext.getProvider(SerialContext.java:276)
at com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:430)
... 3 more
Caused by: java.lang.NullPointerException
at com.sun.enterprise.naming.impl.SerialContext.getRemoteProvider(SerialContext.java:297)
at com.sun.enterprise.naming.impl.SerialContext.getProvider(SerialContext.java:271)
... 4 more


I am GlasFish Tool bundel v3/EJBv3.0
Assuming that EJBv3.0 need no Entry in EJB-jar.xml





[devaka: added code tags]
Ravi Kiran Va
Ranch Hand

Joined: Apr 18, 2009
Posts: 2231

The better option is toprovide the same name for the bean and the MappedName and made a lookup with that .

It works that way .


Save India From Corruption - Anna Hazare.
 
 
subject: Getting error while deploying EJB
 
Threads others viewed
Had an issue while accessing JMS remotely
Problem with jndi lookup for remote bean in EJB 3.x
JNDI and initial context lookup problems with glass fish three
Error while running Ejb client with netbeans
Problems with a simple jms test application
WebSphere development made easy
without the weight of IBM tools
http://www.myeclipseide.com