You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Je...@dbv-winterthur.de on 2004/06/23 14:18:07 UTC

Migration 4.1.27 to 4.1.30 -> Servlet-Configuration won't work

Hi all,

I want to migrate a single webapplication from Tomcat 4.1.27 to Tomcat
4.1.30.
So I installed the new version on my server.
After configuration I copied my webapplication from 4.1.27 to 4.1.30. It is
a ROOT-webapp.

In this application there a 3 servlets with the follwing mapping configured:

        <servlet-mapping>
                <servlet-name>login</servlet-name>
                <url-pattern>/login/</url-pattern>
        </servlet-mapping>

        <servlet-mapping>
                <servlet-name>appmanager</servlet-name>
                <url-pattern>/lappmanager</url-pattern>
        </servlet-mapping>

        <servlet-mapping>
                <servlet-name>app</servlet-name>
                <url-pattern>/*</url-pattern>
        </servlet-mapping>

In 4.1.27 I can call http://xxx/login and http://xxx/appmanager without any
problems. Every other request goes to the app-servlet.
In 4.1.30 every request goes to the app-servlet. Even http://xxx/login and
http://xxx/appmanager.

And also the method request.getPathInfo() return null. I don't know why.

What's goin' wrong?

  - Jens


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


Re: Migration 4.1.27 to 4.1.30 -> Servlet-Configuration won't work

Posted by Veniamin Fichin <3c...@mail.ru>.
Jens.Mueller@dbv-winterthur.de wrote:

> Hi all,
> 
> I want to migrate a single webapplication from Tomcat 4.1.27 to Tomcat
> 4.1.30.
> So I installed the new version on my server.
> After configuration I copied my webapplication from 4.1.27 to 4.1.30. It is
> a ROOT-webapp.
> 
> In this application there a 3 servlets with the follwing mapping configured:
> 
>         <servlet-mapping>
>                 <servlet-name>login</servlet-name>
>                 <url-pattern>/login/</url-pattern>
>         </servlet-mapping>
> 
>         <servlet-mapping>
>                 <servlet-name>appmanager</servlet-name>
>                 <url-pattern>/lappmanager</url-pattern>
>         </servlet-mapping>
> 
>         <servlet-mapping>
>                 <servlet-name>app</servlet-name>
>                 <url-pattern>/*</url-pattern>
>         </servlet-mapping>
> 
> In 4.1.27 I can call http://xxx/login and http://xxx/appmanager without any
> problems. Every other request goes to the app-servlet.
> In 4.1.30 every request goes to the app-servlet. Even http://xxx/login and
> http://xxx/appmanager.

    Is this a typo or not?
* You have "/lappmanager" URL pattern (see first "l" letter), but 
request for "http://xxx/appmanager".
* Second, you have "/login/" URL pattern (see suffix slash), but request 
for "http://xxx/login".

    So none of your mappings triggered, what leads to default app-server 
invocation.

> And also the method request.getPathInfo() return null. I don't know why.

    As of request.getPathInfo() method, please read J2EE's specs, it says:

<cut>
     Returns:
         a String, decoded by the web container, specifying extra path 
information that comes after the servlet path but before the query 
string in the request URL; or null if the URL does not have any extra 
path information
</cut>

    So for example you'd have request URL like 
"http://servername/webapp/mappedname/and/this/fake/path", getPathInfo() 
would return "/and/this/fake/path", I guess. In your case it's null.

>   - Jens

-- 
Veniamin Fichin


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