tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arieh Markel <Arieh.Mar...@Central.Sun.COM>
Subject Re: Mapping servlets to other things that prefix and suffix
Date Fri, 24 Mar 2000 15:10:29 GMT

> Mailing-List: contact; run by ezmlm
> X-No-Archive: yes
> list-help: <>
> list-unsubscribe: <>
> list-post: <>
> Delivered-To: mailing list
> From: Jesper Jørgensen <>
> To:
> Subject: Mapping servlets to other things that prefix and suffix
> X-Spam-Rating: 1.6.2 0/1000/N
> How do I go about setting up a completely traditional servlet repository
> with automatic servlet reloading in tomcat BUT with one big difference:
> I want each servlet to be mapped to a query string parameter instead of
> to a path element or a suffix. Like:
> http://domain.tld/showfolder.jsp?command=openthread&thread=1 Should be
> mapped to the "command servlet" "openthread" which in this case will
> change state of a folder view.

If I understand what you want to do correctly, I would look at a
Request Interceptor to try to do what you want.

The request interceptor could perform the selection by inspection of
the request parameters.


In our implementation, although we are not using jsp, we have a 'launch'
servlet which is in essence a request redirector based on request

Also, we have a LoginInterceptor that forces users to go through a predefined
login servlet and deals with other things too.


> After the "command" servlet has been run, things should proceed as usual
> as if no servlet has serviced the request yet, so that the JSP page
> would be processed afterwards.
> In effect, I am _not_ interested in complying with a standard servlet
> container. I am interested in reusing the code already written in tomcat
> that manages reloading and servicing of servlets to implement an MVC
> controller that dispatches commands.
> Regards,
> Jesper
> -- 
> Jesper Jorgensen         Caput ApS       Tel +45 33 12 24 42             
>         Nygade 6        Fax +45 33 91 24 42
>     DK-1164 Kbh K
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

 Arieh Markel		                Sun Microsystems Inc.
 Network Storage                        500 Eldorado Blvd. MS UBRM11-194
 e-mail: arieh.markel@sun.COM           Broomfield, CO 80021
 Let's go Panthers !!!!                 Phone: (303) 272-8547 x78547
 (e-mail me with subject SEND PUBLIC KEY to get public key)

View raw message