java.lang.IllegalStateException: Cannot obtain Writer because OutputStream is already in use

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via Liferay Issues by Waldemar Kłaczyński, 1 year ago
Cannot obtain Writer because OutputStream is already in use
via Liferay Issues by Waldemar Kłaczyński, 1 year ago
Cannot obtain Writer because OutputStream is already in use
via liferay.com by Unknown author, 2 years ago
java.lang.IllegalStateException: Cannot obtain Writer because OutputStream is already in use
at org.apache.jasper.runtime.JspWriterImpl.initOut(JspWriterImpl.java:125)
at org.apache.jasper.runtime.JspWriterImpl.flushBuffer(JspWriterImpl.java:118)
at org.apache.jasper.runtime.PageContextImpl.release(PageContextImpl.java:180)
at org.apache.jasper.runtime.JspFactoryImpl.internalReleasePageContext(JspFactoryImpl.java:118)
at org.apache.jsp.html.common.themes.portal_jsp._jspService(portal_jsp.java:757)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:369)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:638)
at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:543)
at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:480)
at com.liferay.portal.struts.StrutsUtil.include(StrutsUtil.java:135)
at org.apache.struts.tiles.TilesRequestProcessor.processTilesDefinition(TilesRequestProcessor.java:237)
at org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:302)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)

Users with the same issue

You are the first who have seen this exception.

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.