tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kenan Sevindik" <>
Subject Re: NullPointerException inside IvmContext.lookup
Date Sun, 25 Feb 2007 18:52:09 GMT
Hi David,

Thank you for your reply. Here is what your requested information, and
additional config. info from several files in tomcat. It is completely
same error where i sent the link in my previous post. I am ready to
provide extra information or any help if possible.

Tomcat versions: 5.0.28, 5.5.20
JDK versions: 1.4.2_10, 1.5.0_06
OpenEJB version:1.0

Best Regards.

openejb.log file:

INFO :  openejb.home = D:\work\tools\openejb-1.0
INFO :  openejb.base = D:\work\tools\openejb-1.0
DEBUG:  Instantiating assembler class
WARN :  Cannot find the configuration file [null], Trying
conf/openejb.conf instead.
INFO :  Loaded EJBs from
INFO :  Loaded EJBs from
INFO :  Loaded EJBs from
INFO :  Loaded EJBs from
INFO :  Loaded EJBs from D:\work\tools\openejb-1.0\beans\sapcache-0.1.0.jar
DEBUG:  Containers        : 4
DEBUG:  Type        Container ID
DEBUG:     ENTITY      Default BMP Container
DEBUG:     ENTITY      Default CMP Container
DEBUG:     STATEFUL    Default Stateful Container
DEBUG:     STATELESS   Default Stateless Container
DEBUG:  Deployments       : 38
DEBUG:  Type        Deployment ID
DEBUG:     STATEFUL    client/tests/stateful/EncBean
DEBUG:     CMP_ENTITY  client/tests/entity/cmp/RMI-over-IIOP/EJBHome
DEBUG:     STATEFUL    client/tests/stateful/BasicStatefulHome
DEBUG:     STATELESS   SapCacheBean
DEBUG:     STATELESS   ClientTools/ViewClass
DEBUG:     STATELESS   EJBGenerator/CreateEJB
DEBUG:     STATELESS   Webadmin/Configuration
DEBUG:     STATELESS   ClientTools/InvokeObject
DEBUG:     STATELESS   Webadmin/Properties
DEBUG:     STATEFUL    client/tests/stateful/RMI-over-IIOP/EJBHome
DEBUG:     STATELESS   Webadmin/Home
DEBUG:     BMP_ENTITY  client/tests/entity/bmp/allowed_operations/EntityHome
DEBUG:     BMP_ENTITY  CustomerBean
DEBUG:     CMP_ENTITY  client/tests/entity/cmp/EncBean
DEBUG:     STATELESS   httpd/DefaultBean
DEBUG:     STATEFUL    client/tests/stateful/BeanManagedBasicStatefulHome
DEBUG:     STATELESS   client/tools/DatabaseHome
DEBUG:     BMP_ENTITY  client/tests/entity/bmp/EncBean
DEBUG:     STATEFUL    config/webadmin/ConfigurationData
DEBUG:     STATEFUL    deploy/webadmin/Deployer
DEBUG:     STATELESS   ClientTools/ViewJndi
DEBUG:     STATELESS   Webadmin/DeploymentList
DEBUG:     STATELESS   client/tests/stateless/BeanManagedBasicStatelessHome
DEBUG:     STATELESS   Webadmin/CMPMapping
DEBUG:     STATELESS   client/tests/stateless/EncBean
DEBUG:     STATEFUL    client/tests/stateful/BeanManagedTransactionTests/EJBHome
DEBUG:     BMP_ENTITY  client/tests/entity/bmp/RMI-over-IIOP/EJBHome
DEBUG:     STATELESS   Webadmin/ListLogs
DEBUG:     STATELESS   ClientTools/ViewEjb
DEBUG:     BMP_ENTITY  client/tests/entity/bmp/BasicBmpHome
DEBUG:     STATEFUL    mapping/webadmin/CMPMappingData
DEBUG:     STATELESS   client/tests/stateless/BasicStatelessHome
DEBUG:     CMP_ENTITY  client/tests/entity/cmp/BasicCmpHome
DEBUG:     STATELESS   Webadmin/Deployment
DEBUG:     STATEFUL    httpd/session
DEBUG:     CMP_ENTITY  client/tests/entity/cmp/allowed_operations/EntityHome
DEBUG:     STATELESS   client/tests/stateless/RMI-over-IIOP/EJBHome
DEBUG:  SecurityService   : org.openejb.ri.sp.PseudoSecurityService
DEBUG:  TransactionManager: org.openejb.core.TransactionManagerWrapper
INFO :  OpenEJB ready.

this is from my test.jsp:

	javax.naming.Context initCtx = new javax.naming.InitialContext();

	Object object = initCtx.lookup("java:comp/env/ejb/SapCacheBean"); home =
		javax.rmi.PortableRemoteObject.narrow(object,; bean = home.create();
<%= bean.test() %>

This is ejb-ref definition from web.xml:

 <description> EJB Reference to the bean deployed to OpenEJB </description>

And finally this is from context.xml of my test web app:

<Ejb name="ejb/SapCacheBean"
<ResourceParams name="ejb/SapCacheBean">


On 2/23/07, David Blevins <> wrote:
> Hi Kenan, looks like your email got overlooked.  Very sorry.  Hope we
> can still help you if you need it.  See below...
> On Feb 8, 2007, at 4:30 PM, Kenan Sevindik wrote:
> > I have developed a test web application with a session bean
> > deployed on
> > tomcat. The code and configuration is the same as Hello example.
> > However,
> > when i try to run web app, I got following exception:
> >
> > java.lang.NullPointerException
> > at org.openejb.core.ivm.naming.IvmContext.lookup(
> > at javax.naming.InitialContext.lookup(
> > at org.apache.jsp.test_jsp._jspService(
> > at org.apache.jasper.runtime.HttpJspBase.service(
> >
> > I have already checked open-ejb logs, and my tomcat configuration
> > twice.
> > There isn't any problem over there. I have found same problem in
> > the net
> > after a quick googling:
> >
> > msg00053.html
> > As it was mentioned above there seems no obvious reason for this
> > error to
> > occur.
> It seems to get that error an null value has to actually be in the
> jndi namespace.  This shouldn't happen ever, but I'll definitely name
> sure we check for that in the 3x codebase.
> Can you paste the section of the openejb.log where we list the beans
> deployed and also the chunk of code you are using to lookup your ejb?
> -David

Kenan Sevindik

View raw message