-
1. Re: Bean not bound in Tomcat 4.1. / JBoss 2.4 combination
jonlee Aug 12, 2003 7:20 AM (in response to detla)Did you put the following in the Tomcat 4.1.x shared/lib directory:
jboss-client.jar
jboss-j2ee.jar
jbosssx-client.jar
jnp-client.jar
We've always done this and it works. Some people have reported that placing these jars (or the jbossall-client.jar in later JBoss distributions) in any other place does not work - such as in the WAR.
Normally your JNDI properties should be:
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
java.naming.provider.url=jnp://localhost:1099
I haven't tried Tomcat with a jndi.properties configuration for JBoss. Normally, we would explicitly define properties in the InitialContext and that does work. -
2. Re: Bean not bound in Tomcat 4.1. / JBoss 2.4 combination
detla Aug 12, 2003 7:50 AM (in response to detla)I managed to get around the problem by not using System.getProperties but defining the properties manually, the question remaining is, are those namingfactories incompatible or did I something wrong configuring Tomcat/Jboss?
js -
3. Re: Bean not bound in Tomcat 4.1. / JBoss 2.4 combination
jonlee Aug 12, 2003 8:02 AM (in response to detla)Obviously nothing wrong in JBoss since you haven't changed anything on the JBoss system.
The jndi.properties could be a problem. Certainly the definitions aren't completely standard but you'd need to experiment with it to see the effect. It works in your other example so probabilities would say that this isn't exactly the problem either.
Possibly Tomcat isn't picking up your JNDI properties. You would need to have picked up and printed the values the System was using to determine if this was the cause. By way of your anecdotal evidence, this is the most likely issue. -
4. Re: Bean not bound in Tomcat 4.1. / JBoss 2.4 combination
detla Aug 13, 2003 12:11 AM (in response to detla)Interesting enough, changing the URI from 127.0.0.1:1099 to localhost:1099 actually is noted by Tomcat, so it reads the jndi properties but seems to ignore the namingfactory settings.
Anyway, I got working code and am therefore curious but satisfied. Thanks for Your help,
js