Extending DefaultServlet problem
1 posts in topic
Flat View  Flat View

Posted By:   Slava_Stef
Posted On:   Tuesday, October 4, 2005 05:07 AM

I need a special behaviour of default servlet in one of my webapps. The most simple way for me would be to extend org.apache.catalina.servlets.DefaultServlet. But here problems appear.

First Tomcat does not see jar-files in --/servlet/lib
If I add these jars in CLASSPATH, I have plenty of problems.

What is the correct way to configure Tomcat for my own serrvlet extending DefaultServlet?

Re: Extending DefaultServlet problem

Posted By:   Joost_Schouten  
Posted On:   Tuesday, October 4, 2005 07:29 AM

First off, usually people extend javax.servlet.http.HttpServlet and not the catalina servlet. Second, place your servlets in /ROOT/WEB-INF/classes/ or your jars in /ROOT/WEB-INF/lib/

If you have setup your servletengine propperly you will not need to add these paths to your Classpath.



About | Sitemap | Contact