Thank you for your input. I'm making much progress in this area and most of my application works with tomcat locally now.
I have got everything to work at this point except for one Entity Bean
(CMP 2.0). I have other Entity Beans that work fine. So this is really
tricky.
I can lookup the bean and get the Home Interface from my servlet/jsp.
Then, when I try to call findByPrimaryKey, I get a NullPointerException:
java.rmi.ServerException: null; nested exception is:
java.lang.NullPointerException
2002-04-17 11:03:33,118 ERROR [STDERR] java.lang.NullPointerException
2002-04-17 11:03:33,118 ERROR [STDERR] at
org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityContainer
.java:1107)
2002-04-17 11:03:33,119 ERROR [STDERR] at
org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java
:73)
2002-04-17 11:03:33,119 ERROR [STDERR] at
org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(EntitySynch
ronizationInterceptor.java:230)
2002-04-17 11:03:33,119 ERROR [STDERR] at
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invokeHome
etc...
This is funny because it only happens on this one bean. Other beans are
configured the same way and work fine. Also this works when I use
tomcat on a remote box (I just checked again to make sure) or in a
separate JVM.
I added some debug statements to org.jboss.ejb.EntityContainer.java I
found that The map does contain an entry for the findByPrimaryKey method
but when the homeMapping.get(mi.getMethod()) is called, it returns null.
Is this a class Loading issue like there used to be? I wish I could
submit a test cast but when I try a simple example it works fine. I
have 10-15 beans deployed/a mix of Session/SLS/Entity. The problem
occurs on this one bean every time without fail and independent of which
jsp/servlet tries to use it. Everything works great when I run tomcat
on a separate box.
In the mean time, I'll keep playing and seeing if I can find something
unique about this bean?
Again, Thanks for any input.
-Dennis
On Wed, 2002-04-17 at 02:51, Scott M Stark wrote:
> > I haven't found any Entity Bean tests in the test suite so I couldn't
> > compare. This problem may not have anything to do with Session/Entity
> > and may just be a configuration issue with the beans - I don't know.
> There are now and accessing them from a servlet works fine.
>
> > 1. Is there any big difference between:
> > a. ctx.lookup ("MyEJB" )=20
> > without adding anything to the web.xml (like <ejb-ref>)
> >
> > b. ctx.lookup ( "java:comp/env/ejb/MyEJB" );
> > after adding <ejb-ref>...name>ejb/MyEJB</name.....
> > to the web.xml
> a. requires that you embed the deployed name of the ejb home in
> your code while b. is independent of this.
>
> > 2. Because I am trying to get the app to run on both embedded and=20
> > remote tomcat configs, I pass in a properties file to InitialContext
> > when I create it. =20
> > ie ctx =3D new InitialContext(props);
> > That way I don't have to modify any tomcat scripts to get the right
> > jnp properties and all.
> >
> > Does this make any difference to the embedded tomcat on jboss? =20
>
> It should not make a difference.
>
> Look at the jbosstest-web.ear again and submit a bug report with an example
> ear that demonstrates the problem.
>
> xxxxxxxxxxxxxxxxxxxxxxxx
> Scott Stark
> Chief Technology Officer
> JBoss Group, LLC
> xxxxxxxxxxxxxxxxxxxxxxxx
>
>
>
signature.asc
Description: This is a digitally signed message part
