You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Giulia Hill <gh...@library.berkeley.edu> on 2003/03/07 22:56:17 UTC

Resource not available in 4.1 - Upgrading from 3.2

I have successfully installed Tomcat4.1 on a solaris 2.8 with
j2sdk1.4.1_01 as a standalone. 

I'm running in a problem when deploying a servlet which worked correctly
under tomcat 3.2. Following the docs, I have included a Context in the
server.xml, relevant section included at the end. I have also modified the
web.xml so that the tag order would not cause errors in catalina.out log
file - web.xml is also included at the end.

In the Tomcat Manager web page I can see the link to the servlet, however
when I try to run it, I get the error 
The requested resource (/GenDBconn/servlet/Controller) is not available

I have also added permissions in the conf/catalina.policy file.

Any suggestion on why tomcat can't recognize the servlet? If I run the
same servlet on the same machine on tomcat 3.2 everything is fine.

Relevant section of server.xml
<Context path="/GenDBconn" docBase="/data/_n/GenDBconn" debug="4"
                 reloadable="true" crossContext="true">
   <Logger className="org.apache.catalina.logger.FileLogger" verbosity="4"
         prefix="localhost_GenDBconn_log." suffix=".txt"  timestamp="true"/>
</Context>

----------------------
Complete web.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application
2.2//EN' 'http://java.sun.com/j2ee/dtds/web-app_2.2.dtd'>

<web-app>
 <display-name>GenDBconn</display-name>
 <description>Test site for GenDB</description>
    <servlet>
        <servlet-name>Controller</servlet-name>
	<description>Test site for GenDB</description>

<servlet-class>edu.berkeley.library.GenDBServlets.GenDBController</servlet-class>
        <init-param>
            <param-name>allProjectsXML</param-name>

<param-value>/data/_n/GenDBconn/WEB-INF/classes/edu/berkeley/library/propertyFiles/allProjects.xml</param-value>
        </init-param>
     </servlet>
	<servlet-mapping>
           <servlet-name>Controller</servlet-name>
	   <url-pattern>/Controller*</url-pattern>
       </servlet-mapping>
  <session-config>
    <session-timeout>30</session-timeout>
  </session-config>
  <welcome-file-list>
    <welcome-file>index.html</welcome-file>
  </welcome-file-list>
</web-app>
-----------------------------------------------------------

Insights are appreciated,

Giulia



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Resource not available in 4.1 - Upgrading from 3.2

Posted by Tomcat-RND <to...@hotmail.com>.
Hi,

By default in tomcat4.1 the invoker servlet is disabled that is it will be
commented.  You have to either invoke by the servlet mapping defined or
uncomment the invoker servlet in the \conf\web.xml to access using
/servlet/ServletName

Regards,
Pratt



----- Original Message -----
From: "Giulia Hill" <gh...@library.berkeley.edu>
To: <to...@jakarta.apache.org>
Cc: "Giulia Hill" <gh...@library.berkeley.edu>
Sent: Saturday, March 08, 2003 3:26 AM
Subject: Resource not available in 4.1 - Upgrading from 3.2


>
> I have successfully installed Tomcat4.1 on a solaris 2.8 with
> j2sdk1.4.1_01 as a standalone.
>
> I'm running in a problem when deploying a servlet which worked correctly
> under tomcat 3.2. Following the docs, I have included a Context in the
> server.xml, relevant section included at the end. I have also modified the
> web.xml so that the tag order would not cause errors in catalina.out log
> file - web.xml is also included at the end.
>
> In the Tomcat Manager web page I can see the link to the servlet, however
> when I try to run it, I get the error
> The requested resource (/GenDBconn/servlet/Controller) is not available
>
> I have also added permissions in the conf/catalina.policy file.
>
> Any suggestion on why tomcat can't recognize the servlet? If I run the
> same servlet on the same machine on tomcat 3.2 everything is fine.
>
> Relevant section of server.xml
> <Context path="/GenDBconn" docBase="/data/_n/GenDBconn" debug="4"
>                  reloadable="true" crossContext="true">
>    <Logger className="org.apache.catalina.logger.FileLogger" verbosity="4"
>          prefix="localhost_GenDBconn_log." suffix=".txt"
timestamp="true"/>
> </Context>
>
> ----------------------
> Complete web.xml
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application
> 2.2//EN' 'http://java.sun.com/j2ee/dtds/web-app_2.2.dtd'>
>
> <web-app>
>  <display-name>GenDBconn</display-name>
>  <description>Test site for GenDB</description>
>     <servlet>
>         <servlet-name>Controller</servlet-name>
> <description>Test site for GenDB</description>
>
>
<servlet-class>edu.berkeley.library.GenDBServlets.GenDBController</servlet-c
lass>
>         <init-param>
>             <param-name>allProjectsXML</param-name>
>
>
<param-value>/data/_n/GenDBconn/WEB-INF/classes/edu/berkeley/library/propert
yFiles/allProjects.xml</param-value>
>         </init-param>
>      </servlet>
> <servlet-mapping>
>            <servlet-name>Controller</servlet-name>
>    <url-pattern>/Controller*</url-pattern>
>        </servlet-mapping>
>   <session-config>
>     <session-timeout>30</session-timeout>
>   </session-config>
>   <welcome-file-list>
>     <welcome-file>index.html</welcome-file>
>   </welcome-file-list>
> </web-app>
> -----------------------------------------------------------
>
> Insights are appreciated,
>
> Giulia
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org