tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Akhthar Parvez K <akht...@gmail.com>
Subject Re: Servlet with URL pattern "*.<something>" is not working.
Date Tue, 13 Dec 2005 16:46:19 GMT
Hi,

Thanks to all those of who helped me with this issue so far.

The tomcat installed in the server does support servlet definition and
mapping out of order and that's not the issue here. The issue is servlets
with URL pattern as *.do is NOT working here. All other servlets are working
fine. As far as I know. It has nothing to do with the invoker. The same
servlet works just fine, if use someother URL pattern.

On 12/13/05, Raghupathy,Gurumoorthy <gurumoorthy.raghupathy@uk.fid-intl.com>
wrote:
>
> Try to put you servlets in a package as servlets nto in a packages is a
> pain
> for tocmat.
>
>
> -----Original Message-----
> From: David Smith [mailto:dns4@cornell.edu]
> Sent: 12 December 2005 20:54
> To: Tomcat Users List
> Subject: Re: Servlet with URL pattern "*.<something>" is not working.
>
>
> That's true if the web.xml file validates against the servlet spec 2.3
> dtd instead of the servlet spec 2.4 schema.  tomcat 5.0 and up supports
> servlet spec 2.4 which allows for elements to be out of order.
>
> --David
>
> Martin Gainty wrote:
>
> > Akhthar
> > I thought the servlet / servlet-class specifications are grouped
> > together then
> > servlet-mappings follow up and are grouped together e.g.
> >
> >     <servlet>
> >                <servlet-name>test</servlet-name>
> >              <servlet-class>ServletsTestPage</servlet-class>
> >        </servlet>
> >        <servlet>
> >                <servlet-name>test2</servlet-name>
> >            <servlet-class>HelloWorldServlet</servlet-class>
> >        </servlet>
> >        <servlet-mapping>
> >                <servlet-name>test</servlet-name>
> >              <url-pattern>*.ca</url-pattern>
> >        </servlet-mapping>
> >        <servlet-mapping>
> >                <servlet-name>test2</servlet-name>
> >              <url-pattern>/test2</url-pattern>
> >        </servlet-mapping>
> >
> > ???
> > Martin-
> >
> >
> > Hello,
> >
> > I have a tomcat server (ver:- 5.5.9) installed on my server and all
> > jsps and
> > servlets are working fine except the servlet with URL pattern
> > "*.<something>". eg:- I have the following entry in my web.xml
> >
> > =====================
> >       <servlet>
> >                <servlet-name>test</servlet-name>
> >              <servlet-class>ServletsTestPage</servlet-class>
> >        </servlet>
> >
> >        <servlet-mapping>
> >                <servlet-name>test</servlet-name>
> >              <url-pattern>*.ca</url-pattern>
> >        </servlet-mapping>
> >
> >        <servlet>
> >                <servlet-name>test2</servlet-name>
> >            <servlet-class>HelloWorldServlet</servlet-class>
> >        </servlet>
> >
> >        <servlet-mapping>
> >                <servlet-name>test2</servlet-name>
> >              <url-pattern>/test2</url-pattern>
> >        </servlet-mapping>
> >
> > ======================
> >
> > I am able to access the servlet with the URL pattern /test by the link
> > http://mydomain.com/servlet/test2. But I am getting the error message
> > "The
> > requested resource (/servlet/sa.ca) is not available." when I access the
> > servlet with the URL pattern "*.ca" by the link
> > http://mydomain.com/servlet/as.ca
> >
> > I got the following message in catalina.out
> >
> > ============================
> >
> > Dec 12, 2005 10:17:53 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Marking servlet org.apache.catalina.INVOKER.sa.ca as unavailable
> > Dec 12, 2005 10:17:53 AM org.apache.catalina.core.ApplicationContext log
> > SEVERE: Error loading WebappClassLoader
> >  delegate: false
> >  repositories:
> >    /WEB-INF/classes/
> > ----------> Parent Classloader:
> > org.apache.catalina.loader.StandardClassLoader@178460d
> > sa.ca
> > java.lang.ClassNotFoundException: sa.ca
> >        at org.apache.catalina.loader.WebappClassLoader.loadClass(
> > WebappClassLoader.java:1332)
> >        at org.apache.catalina.loader.WebappClassLoader.loadClass(
> > WebappClassLoader.java:1181)
> >        at org.apache.catalina.core.StandardWrapper.loadServlet(
> > StandardWrapper.java:1027)
> >        at org.apache.catalina.core.StandardWrapper.allocate(
> > StandardWrapper.java:750)
> >        at org.apache.catalina.servlets.InvokerServlet.serveRequest(
> > InvokerServlet.java:369)
> >        at org.apache.catalina.servlets.InvokerServlet.doGet(
> > InvokerServlet.java:133)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> >        at
> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > ApplicationFilterChain.java:252)
> >        at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > ApplicationFilterChain.java:173)
> >        at org.apache.catalina.core.StandardWrapperValve.invoke(
> > StandardWrapperValve.java:213)
> >        at org.apache.catalina.core.StandardContextValve.invoke(
> > StandardContextValve.java:178)
> >        at org.apache.catalina.core.StandardHostValve.invoke(
> > StandardHostValve.java:126)
> >        at org.apache.catalina.valves.ErrorReportValve.invoke(
> > ErrorReportValve.java:105)
> >        at org.apache.catalina.core.StandardEngineValve.invoke(
> > StandardEngineValve.java:107)
> >        at org.apache.catalina.connector.CoyoteAdapter.service(
> > CoyoteAdapter.java:148)
> >        at
> > org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java
> > :307)
> >        at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java
> > :385)
> >        at
> > org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:748)
> >        at org.apache.jk.common.ChannelSocket.processConnection(
> > ChannelSocket.java:678)
> >        at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java
> > :871)
> >        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > ThreadPool.java:684)
> >        at java.lang.Thread.run(Thread.java:595)
> > Dec 12, 2005 10:17:53 AM org.apache.catalina.core.ApplicationContext log
> > SEVERE: httpservlet: Cannot allocate servlet instance for path
> > /servlet/sa.ca
> > javax.servlet.ServletException: Wrapper cannot find servlet class
> > sa.ca or a
> > class it depends on
> >        at org.apache.catalina.core.StandardWrapper.loadServlet(
> > StandardWrapper.java:1035)
> >        at org.apache.catalina.core.StandardWrapper.allocate(
> > StandardWrapper.java:750)
> >        at org.apache.catalina.servlets.InvokerServlet.serveRequest(
> > InvokerServlet.java:369)
> >        at org.apache.catalina.servlets.InvokerServlet.doGet(
> > InvokerServlet.java:133)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> >        at
> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > ApplicationFilterChain.java:252)
> >        at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > ApplicationFilterChain.java:173)
> >        at org.apache.catalina.core.StandardWrapperValve.invoke(
> > StandardWrapperValve.java:213)
> >        at org.apache.catalina.core.StandardContextValve.invoke(
> > StandardContextValve.java:178)
> >        at org.apache.catalina.core.StandardHostValve.invoke(
> > StandardHostValve.java:126)
> >        at org.apache.catalina.valves.ErrorReportValve.invoke(
> > ErrorReportValve.java:105)
> >        at org.apache.catalina.core.StandardEngineValve.invoke(
> > StandardEngineValve.java:107)
> >        at org.apache.catalina.connector.CoyoteAdapter.service(
> > CoyoteAdapter.java:148)
> >        at
> > org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java
> > :307)
> >        at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java
> > :385)
> >        at
> > org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:748)
> >        at org.apache.jk.common.ChannelSocket.processConnection(
> > ChannelSocket.java:678)
> >        at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java
> > :871)
> >        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > ThreadPool.java:684)
> >        at java.lang.Thread.run(Thread.java:595)
> > Dec 12 10:18:02 DEBUG
> > [ContainerBackgroundProcessor[StandardEngine[Catalina]]]
> > session.ManagerBase- Start expire sessions StandardManager at
> > 1134400682587 sessioncount 8
> > Dec 12 10:18:02 DEBUG
> > [ContainerBackgroundProcessor[StandardEngine[Catalina]]]
> > session.ManagerBase- End expire sessions StandardManager
> > processingTime 0 expired sessions: 0
> > 2005-12-12 10:18:02,677 DEBUG ManagerBase: Start expire sessions
> > StandardManager at 1134400682677 sessioncount 1
> > 2005-12-12 10:18:02,678 DEBUG ManagerBase: End expire sessions
> > StandardManager processingTime 1 expired sessions: 0
> > Dec 12, 2005 10:18:13 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Marking servlet org.apache.catalina.INVOKER.init.as as unavailable
> > Dec 12, 2005 10:18:13 AM org.apache.catalina.core.ApplicationContext log
> > SEVERE: Error loading WebappClassLoader
> >  delegate: false
> >  repositories:
> >    /WEB-INF/classes/
> > ----------> Parent Classloader:
> > org.apache.catalina.loader.StandardClassLoader@178460d
> > init.as
> > java.lang.ClassNotFoundException: init.as
> >        at org.apache.catalina.loader.WebappClassLoader.loadClass(
> > WebappClassLoader.java:1332)
> >        at org.apache.catalina.loader.WebappClassLoader.loadClass(
> > WebappClassLoader.java:1181)
> >        at org.apache.catalina.core.StandardWrapper.loadServlet(
> > StandardWrapper.java:1027)
> >        at org.apache.catalina.core.StandardWrapper.allocate(
> > StandardWrapper.java:750)
> >        at org.apache.catalina.servlets.InvokerServlet.serveRequest(
> > InvokerServlet.java:369)
> >        at org.apache.catalina.servlets.InvokerServlet.doGet(
> > InvokerServlet.java:133)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> >        at
> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > ApplicationFilterChain.java:252)
> >        at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > ApplicationFilterChain.java:173)
> >        at org.apache.catalina.core.StandardWrapperValve.invoke(
> > StandardWrapperValve.java:213)
> >        at org.apache.catalina.core.StandardContextValve.invoke(
> > StandardContextValve.java:178)
> >        at org.apache.catalina.core.StandardHostValve.invoke(
> > StandardHostValve.java:126)
> >        at org.apache.catalina.valves.ErrorReportValve.invoke(
> > ErrorReportValve.java:105)
> >        at org.apache.catalina.core.StandardEngineValve.invoke(
> > StandardEngineValve.java:107)
> >        at org.apache.catalina.connector.CoyoteAdapter.service(
> > CoyoteAdapter.java:148)
> >        at
> > org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java
> > :307)
> >        at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java
> > :385)
> >        at
> > org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:748)
> >        at org.apache.jk.common.ChannelSocket.processConnection(
> > ChannelSocket.java:678)
> >        at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java
> > :871)
> >        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > ThreadPool.java:684)
> >        at java.lang.Thread.run(Thread.java:595)
> > Dec 12, 2005 10:18:13 AM org.apache.catalina.core.ApplicationContext log
> > SEVERE: httpservlet: Cannot allocate servlet instance for path
> > /servlet/init.as
> > javax.servlet.ServletException: Wrapper cannot find servlet class
> > init.as or
> > a class it depends on
> >        at org.apache.catalina.core.StandardWrapper.loadServlet(
> > StandardWrapper.java:1035)
> >        at org.apache.catalina.core.StandardWrapper.allocate(
> > StandardWrapper.java:750)
> >        at org.apache.catalina.servlets.InvokerServlet.serveRequest(
> > InvokerServlet.java:369)
> >        at org.apache.catalina.servlets.InvokerServlet.doGet(
> > InvokerServlet.java:133)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> >        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> >        at
> > org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
> > ApplicationFilterChain.java:252)
> >        at org.apache.catalina.core.ApplicationFilterChain.doFilter(
> > ApplicationFilterChain.java:173)
> >        at org.apache.catalina.core.StandardWrapperValve.invoke(
> > StandardWrapperValve.java:213)
> >        at org.apache.catalina.core.StandardContextValve.invoke(
> > StandardContextValve.java:178)
> >        at org.apache.catalina.core.StandardHostValve.invoke(
> > StandardHostValve.java:126)
> >        at org.apache.catalina.valves.ErrorReportValve.invoke(
> > ErrorReportValve.java:105)
> >        at org.apache.catalina.core.StandardEngineValve.invoke(
> > StandardEngineValve.java:107)
> >        at org.apache.catalina.connector.CoyoteAdapter.service(
> > CoyoteAdapter.java:148)
> >        at
> > org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java
> > :307)
> >        at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java
> > :385)
> >        at
> > org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:748)
> >        at org.apache.jk.common.ChannelSocket.processConnection(
> > ChannelSocket.java:678)
> >        at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java
> > :871)
> >        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(
> > ThreadPool.java:684)
> >        at java.lang.Thread.run(Thread.java:595)
> >
> > =====================
> >
> > Can anyone shed some light towards this issue. Please do not hesitate
> > to ask
> > me if you have any queries.
> >
> > --
> > Regards,
> > Akhthar Parvez K
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> > For additional commands, e-mail: users-help@tomcat.apache.org
> >
>
>
> --
> =======================================
> David Smith
> Network Operations Supervisor
> Department of Entomology
> College of Agriculture & Life Sciences
> Cornell University
> 2132 Comstock Hall
> Ithaca, NY  14853
> Phone: 607.255.9571
> Fax: 607.255.0939
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


--
Regards,
Akhthar Parvez K

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message