Checking the errors trace, it appear that struts.action.RequestProcessor has no
or has loose its reference to the servlet.

  This reference is initialized by a call to init(...) which is done when servlet
is initialized. Maybe cactus calls Struts before its complete initialization ?

    Cedric

  This can be due to

"Holman, Cal" wrote:

> I am trying to test my site using Cactus and HTTPUnit and am having
> problems.  The site works fine when Tomcat is started and a human navigates
> the site.  In other words the /test/do/home/home resolves and the template
> definition for tiles is rendered.  But under Cactus I get 500 errors for any
> request I make.  The action is being triggered for the mapping and seems to
> fail in forwarding to 'success' which is a template definition.  The action
> mapping is below as is the template definition.  The Cactus and HTTPUnit
> tests worked prior to migrating to Struts 1.1 b1 and Tiles and have not been
> modified.  I was using Struts 1.0 and Components when the tests worked.   I
> am using Tomcat 4.0.3 standalone on Win2k.
>
> Any advice would be welcome.  Thanks
>
> 2002-03-25 07:07:23 StandardHost[localhost]: Mapping request URI
> '/test/do/home/home'
> 2002-03-25 07:07:23 StandardHost[localhost]:  Mapped to context '/test'
> 2002-03-25 07:07:23 StandardWrapperValve[action]: Servlet.service() for
> servlet action threw exception
> java.lang.NullPointerException
>         at
> org.apache.struts.action.RequestProcessor.getServletContext(RequestProcessor
> .java:1030)
>         at
> org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcesso
> r.java:114)
>         at
> org.apache.struts.action.RequestProcessor.processActionForward(RequestProces
> sor.java:408)
>         at
> org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:269)
>         at
> org.apache.struts.action.ActionServlet.process(ActionServlet.java:1109)
>         at
> com.holmansite.controller.MyActionServlet.process(MyActionServlet.java:65)
>         at
> org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:452)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
>         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>         at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
> FilterChain.java:247)
>         at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
> ain.java:193)
>         at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
> va:243)
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 66)
>         at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>         at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>         at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
> va:190)
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 66)
>         at
> org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase
> .java:475)
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 64)
>         at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>         at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>         at
> org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2343)
>         at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180
> )
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 66)
>         at
> org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.
> java:170)
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 64)
>         at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170
> )
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 64)
>         at
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 64)
>         at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>         at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>         at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
> :174)
>         at
> org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
> 66)
>         at
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>         at
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>         at
> org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:
> 1012)
>         at
> org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1107
> )
>         at java.lang.Thread.run(Thread.java:484)
>
> Action Mapping
>
>                 <action path="/home/home"
>                      type="com.holmansite.controller.WelcomeAction"
>                         scope="request"
>                         validate="false"
>                         input="/pages/home/homePage.jsp">
>                         <forward name="success" path="home.pagedef"/>
>                 </action>
>
> Template definition
>
>   <definition name="home.pagedef" path="/template.jsp">
>           <put name="title"  value="Holman Family Home Page" />
>           <put name="header" value="/web/includes/header.jsp" />
>           <put name="index"   value="/web/pages/home/HomeIndex.jsp" />
>           <put name="commonIndex"   value="/web/includes/index.jsp" />
>           <put name="content"   value="/web/pages/home/HomeContent.jsp" />
>           <put name="footer" value="/web/includes/footer.jsp" />
>           <put name="styleSheet" value="web/styles/Grey_StyleSheet.css" />
>   </definition>
>
> Cal
>
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to