You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Deepika Pinnoju <dp...@xtria.com> on 2005/01/07 15:26:37 UTC
Error: java:comp is no bound in this context
Hi,
I have tomcat 5.0.19 and j2sdk1.4.2_03. I am trying to run my web
application. When I try to connect to
the database from my web application. It gives this error
org.apache.jasper.JasperException: Name java:comp is not bound in this
Context
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:248)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:289)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:240)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
I also configured my server.XML, this is my server.xml file
<Context path="/hsrc" docBase="hsrc" debug="0" reloadable="true
crossContext="true">
<Logger className="org.apache.catalina.logger.FileLogger"
prefix="localhost_hsrc_log." suffix=".txt" timestamp="true"/>
<Resource name="jdbc/ears" auth="Container"
type="javax.sql.DataSource"/>
<ResourceParams name="jdbc/ears">
<parameter>
<name>factory</name>
<value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
</parameter>
<parameter>
<name>driverClassName</name>
<value>oracle.jdbc.driver.OracleDriver</value>
:
:
:
:
And my web.xml looks
<servlet>
<servlet-name>ServletRoot</servlet-name>
<servlet-class>com.xtria.hsrc.servlet.ServletRoot</servlet-class>
<init-param>
<param-name>datasource</param-name>
<param-value>java:comp/env/jdbc/ears</param-value>
<!-- tomcat -->
</init-param>
Any idea, Please help me out
Thanks
Deepika
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org