Have you followed the directions at
http://www.jboss.org/business/jboss-tomcat.html or an older set? Things
I'd look at are: the interceptors in tomcat's server.xml, if you're
deploying an ear, does your application.txt have the module stanza for
the ejbs. What name are you trying to look up? It should be simply
'Security', because (as far as I know) JBoss doesn't parse web.xml to
put the right environment together for components running in Tomcat.
Dave Horner wrote:
>
> I'm currently using Tomcat 3.2.1 with Jboss 2.1 under JDK1.3.
> JBoss seems to run fine and deploy my EJBs: -
>
> [Container factory] Deploying TeamWorkspace
> [Container factory] Deploying Security
> [Container factory] Deploying Profile
> [Container factory] Deploying Preferences
> [Container factory] Deploying Nav
> [Container factory] Deploying Expertise
> [Container factory] Deploying EventService
> [Container factory] Deploying Email
> [Container factory] Deploying DocMgt
> [Container factory] Deploying Contacts
>
> However, when I run Tomcat, I'm getting the message: -
>
> Exception: Unable to create instance of EJB
>
> This is produced from code which does a lookup as follows: -
>
> env = new Hashtable();
> env.put("java.naming.factory.initial" ,
> "org.jnp.interfaces.NamingContextFactory");
> env.put("java.naming.provider.url" , "localhost:1099");
> env.put("java.naming.factory.url.pkgs", "org.jboss.naming");
>
> try
> {
> Context ctx=new InitialContext(env);
> SecurityHome home =
> (SecurityHome)ctx.lookup(Constants.get("ejb.name.security"));
> Security ejb = home.create();
> user=ejb.getUserDetails(userName);
>
> etc.....
>
> I've tried doing System.SetProperties and using a jndi.properties
> instead of using a Hashtable and it seems to make no difference.
>
> Does anyone have any ideas where I could be going wrong ?
> Thanks for any help.
> Dave
>
> Dave Horner
>
--
Dan Christopherson (danch)
nVisia Technical Architect (www.nvisia.com)
Opinions expressed are mine and do not neccessarily reflect any
position or opinion of nVISIA.
---------------------------------------------------------------------------
If you're a capitalist and you have the best goods and they're
free, you don't have to proselytize, you just have to wait.
-Eben Moglen
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user