Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

servlet exception

0 views
Skip to first unread message

Nag

unread,
Jun 30, 2005, 7:32:21 PM6/30/05
to
Hi
I am getting following exception, could any one tell me assist me in
solving the problem.

ApplicationDispatcher[/Webstore]: Servlet.service() for servlet
batchcategorydisplay threw exception
org.apache.jasper.JasperException
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:254)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:432)
at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:356)
at
com.redenvelope.webstore.BatchCategoryDisplayController.process(BatchCategoryDisplayController.java:139)
at
com.redenvelope.webstore.ReControllerServlet.doPost(ReControllerServlet.java:85)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
at
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at
org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:594)
at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:392)
at
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:565)
at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
at java.lang.Thread.run(Thread.java:536)

Wendy Smoak

unread,
Jun 30, 2005, 7:56:03 PM6/30/05
to
"Nag" <Nagaraj...@gmail.com> wrote:

> I am getting following exception, could any one tell me assist me in
> solving the problem.
>
> ApplicationDispatcher[/Webstore]: Servlet.service() for servlet
> batchcategorydisplay threw exception
> org.apache.jasper.JasperException

...
>
com.redenvelope.webstore.BatchCategoryDisplayController.process(BatchCategor
yDisplayController.java:139)
> at
>
com.redenvelope.webstore.ReControllerServlet.doPost(ReControllerServlet.java
:85)

What's happening on those two lines? Was there a "root cause" in the logs
below the stack trace that you posted?

--
Wendy Smoak


Nag

unread,
Jun 30, 2005, 8:31:29 PM6/30/05
to
At line 139, I am forwarding the control to my jsp page(
batchcategorydisplay.jsp).
the code is something like this:

getServletContext().getNamedDispatcher("batchcategorydisplay").forward(req,
resp);
return;

I found out the unusual thing, when i remove the jsp:usebean tags i am
able to display the jsp page with static content. but when i use the
jsp:usebean tags
i am getting this error.
I ran the controller class(BatchCategoryDisplayController.java) in
debug mode, all the objects that are setting in request are holding
some values. they are not nulls.
i dont know what is the problem?

thanks for your inputs.

Wendy Smoak

unread,
Jun 30, 2005, 10:13:59 PM6/30/05
to
"Nag" <Nagaraj...@gmail.com> wrote:
> At line 139, I am forwarding the control to my jsp page(
> batchcategorydisplay.jsp).
> the code is something like this:
>
> getServletContext().getNamedDispatcher("batchcategorydisplay").forward(req,
> resp);
> return;
>
> I found out the unusual thing, when i remove the jsp:usebean tags i am
> able to display the jsp page with static content. but when i use the
> jsp:usebean tags
> i am getting this error.

Sounds like you have a good start on debugging it, you know it's in the JSP
and can make it go away. Since you have a debugger, figure out how to point
it at the source code generated from the JSP, and step through that as well
as the Servlet code.

--
Wendy Smoak

Nag

unread,
Jul 1, 2005, 12:14:13 AM7/1/05
to
yeah..I fixed it. the problem was in my servlet.

I used Hashmap.keySet(), which intrun returns the Set
implementation..This set was passed to the jsp without making a Treeset
object. my jsp:usebean was expecting a Treeset object. thats where the
problem was.
I modified the returned set into Treeset object and passed to the jsp.

But the error is not at all relevant to the exception thrown in the
stacktrace. Does it problem with my settings ??

thanks,
nag.

Wendy Smoak

unread,
Jul 1, 2005, 8:53:38 AM7/1/05
to
"Nag" <Nagaraj...@gmail.com> wrote

>
> But the error is not at all relevant to the exception thrown in the
> stacktrace. Does it problem with my settings ??
>

I still think there was more to that stack trace. There's usually a 'Root
Cause' which in this case might have been a ClassCastException (depending on
the code...) The JasperException only tells you where it happened, not
(usually) exactly what it was.

I haven't figured out the pattern, but I always check catalina.out (or the
console), the 'localhost_log' file in Tomcat _and_ the log for the webapp
itself. Different things show up in different places.

--
Wendy Smoak


0 new messages