Steve, did you set up a jboss-web file? This is required to make the 
java:/comp/env namespace work.

Search the archive for jboss-web.xml. I'll also paste one of mine below for 
you.

Good luck!

Jim

<jboss-web>
   <ejb-ref>
      <ejb-ref-name>ejb/Sample20Entity</ejb-ref-name>
      <jndi-name>Sample20Entity</jndi-name>
   </ejb-ref>
</jboss-web>


--On Thursday, March 01, 2001 3:13 AM -0500 Steve Salkin <[EMAIL PROTECTED]> 
wrote:

> Hi-
> I have added the following entry:
>    <env-entry>
>        <description>Path to the JSP pages for redirect</description>
>        <env-entry-name>jsppath</env-entry-name>
>        <env-entry-value>/web/jsp</env-entry-value>
>        <env-entry-type>java.lang.String</env-entry-type>
>    </env-entry>
> to the WEB-INF/web.xml of the .war file.
>
> Subsequently, I try to look it up (from a servlet) using
> (String)ctx.lookup("java:comp/env/jsppath");
>
> I receive a NamingException:
> [EmbeddedTomcat] Naming Exception looking up "java:comp/env/jsppath"
> [EmbeddedTomcat] javax.naming.NameNotFoundException: comp not bound
>
> Am I missing something? I haven't used ENC before but this is how it
> appears  to me that it is supposed to work. The Tomcat list archives
> indicate that they  don't provide any naming service, but that the app
> server should understand  this reference.
>
> Hints welcome :)
>
> Steve
>
> full exception stack trace below:
>
> [EmbeddedTomcat] javax.naming.NameNotFoundException: comp not bound
> [EmbeddedTomcat]        at
> sun.rmi.transport.StreamRemoteCall.exceptionReceived
> FromServer(StreamRemoteCall.java:245)
> [EmbeddedTomcat]        at
> sun.rmi.transport.StreamRemoteCall.executeCall(Strea mRemoteCall.java:220)
> [EmbeddedTomcat]        at
> sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122 )
> [EmbeddedTomcat]        at
> org.jnp.server.NamingServer_Stub.lookup(Unknown  Source)
> [EmbeddedTomcat]        at
> org.jnp.interfaces.NamingContext.lookup(NamingContex t.java:295)
> [EmbeddedTomcat]        at
> org.jnp.interfaces.NamingContext.lookup(NamingContex t.java:279)
> [EmbeddedTomcat]        at
> javax.naming.InitialContext.lookup(InitialContext.ja va:350)
> [EmbeddedTomcat]        at
> com.ums.servlet.UMSServlet.getJSPPath(UMSServlet.jav a:45)
> [EmbeddedTomcat]        at
> com.ums.servlet.LoginServlet.doPost(LoginServlet.jav a:81)
> [EmbeddedTomcat]        at
> javax.servlet.http.HttpServlet.service(HttpServlet.j ava:760)
> [EmbeddedTomcat]        at
> javax.servlet.http.HttpServlet.service(HttpServlet.j ava:853)
> [EmbeddedTomcat]        at
> org.apache.tomcat.core.ServletWrapper.doService(Serv letWrapper.java:404)
> [EmbeddedTomcat]        at
> org.apache.tomcat.core.Handler.service(Handler.java: 286)
> [EmbeddedTomcat]        at
> org.apache.tomcat.core.ServletWrapper.service(Servle tWrapper.java:372)
> [EmbeddedTomcat]        at
> org.apache.tomcat.core.ContextManager.internalServic
> e(ContextManager.java:799)
> [EmbeddedTomcat]        at
> org.apache.tomcat.core.ContextManager.service(Contex tManager.java:745)
> [EmbeddedTomcat]        at
> org.apache.tomcat.service.http.HttpConnectionHandler
> .processConnection(HttpConnectionHandler.java:210)
> [EmbeddedTomcat]        at
> org.apache.tomcat.service.TcpWorkerThread.runIt(Pool TcpEndpoint.java:407)
> [EmbeddedTomcat]        at
> org.apache.tomcat.util.ThreadPool$ControlRunnable.ru
> n(ThreadPool.java:498)
> [EmbeddedTomcat]        at java.lang.Thread.run(Thread.java:484)
>
>
>
>
> --
> --------------------------------------------------------------
> To subscribe:        [EMAIL PROTECTED]
> To unsubscribe:      [EMAIL PROTECTED]
> List Help?:          [EMAIL PROTECTED]



********************************************
I shall be telling this with a sigh
Somewhere ages and ages hence:
Two roads diverged in a wood, and I -
I took the one less traveled by,
And that has made all the difference.

- Robert Frost, 1916



--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
List Help?:          [EMAIL PROTECTED]

Reply via email to