0 Replies Latest reply on Jun 7, 2005 12:27 PM by Vipin Dube

    java.lang.IllegalStateException: getOutputStream()

    Vipin Dube Newbie

      Hello,


      I am using application with Struts framework on JBoss 4.0, and getting following error :


      java.lang.IllegalStateException: getOutputStream() has already been called for this response
      at

      org.apache.coyote.tomcat5.CoyoteResponse.getWriter(CoyoteResponse.java:599)
      at

      org.apache.coyote.tomcat5.CoyoteResponseFacade.getWriter(CoyoteResponseFacade.java:163)
      at

      javax.servlet.ServletResponseWrapper.getWriter(ServletResponseWrapper.java:111)
      at

      org.apache.jasper.runtime.JspWriterImpl.initOut(JspWriterImpl.java:122)
      at

      org.apache.jasper.runtime.JspWriterImpl.flushBuffer(JspWriterImpl.java:115)
      at

      org.apache.jasper.runtime.PageContextImpl.release(PageContextImpl.java:182)
      at

      org.apache.jasper.runtime.JspFactoryImpl.internalReleasePageContext(JspFactoryImpl.java:115)
      at

      org.apache.jasper.runtime.JspFactoryImpl.releasePageContext(JspFactoryImpl.java:75)
      at

      org.apache.jsp.jsp.common.layout_jsp._jspService(layout_jsp.java:364)
      at

      org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
      at

      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at

      org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
      at

      org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
      at

      org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
      at

      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at

      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
      at

      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
      at

      org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:704)
      at

      org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:590)
      at

      org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:510)
      at

      org.apache.struts.action.RequestProcessor.doInclude(RequestProcessor.java:1099)
      at

      org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:272)
      at

      org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(TilesRequestProcessor.java:254)
      at

      org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:309)
      at

      com.ge.corporate.tmsadmin.request.TMSAdminRequestProcessor.processForwardConfig(TMSAdminRequestProcessor.java:362)
      at

      org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
      at

      org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
      at

      com.ge.corporate.tmsadmin.common.action.TMSAdminActionServlet.process(TMSAdminActionServlet.java:60)
      at

      com.ge.corporate.tmsadmin.common.action.TMSAdminActionServlet.doPost(TMSAdminActionServlet.java:43)
      at

      javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
      at

      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at

      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
      at

      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
      at

      org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)
      at

      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
      at

      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
      at

      org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
      at

      org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:44)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      at

      org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:169)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
      at

      org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
      at

      org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
      at

      org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
      at

      org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
      at

      org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
      at

      org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
      at

      org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
      at

      java.lang.Thread.run(Thread.java:534)
      04:37:45,812 ERROR [Engine] StandardWrapperValve[action]: Servlet.service() for servlet

      action threw exception
      java.lang.IllegalStateException: Cannot forward after response has been committed
      at

      org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:324)
      at

      org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312)
      at

      com.ge.corporate.tmsadmin.common.action.TMSAdminActionServlet.process(TMSAdminActionServlet.java:65)
      at

      com.ge.corporate.tmsadmin.common.action.TMSAdminActionServlet.doPost(TMSAdminActionServlet.java:43)
      at

      javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
      at

      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at

      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
      at

      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
      at

      org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:75)
      at

      org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
      at

      org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
      at

      org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
      at

      org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:44)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      at

      org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:169)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      at

      org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      at

      org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      at

      org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
      at

      org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
      at

      org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
      at

      org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
      at

      org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
      at

      org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
      at

      org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
      at

      org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
      at



      Can anybody help me to resolve the issue.

      Thanks in advance.

      Vipin