tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maxime Colas des Francs <>
Subject Re: forward error
Date Fri, 05 Sep 2003 13:38:36 GMT

thks for your response, but here is my code, i don't understand where the 
response is commited !


<%@ page contentType="text/html; charset=iso-8859-1" language="java" 
<%@ taglib prefix="c" uri="" %>
<%@ taglib prefix="log" uri="" %>
<%@ taglib prefix="sql" uri="" %>

<sql:query var="ctcRow">
    SELECT DISTINCT email FROM ctc ORDER by email

<c:forEach items="${ctcRow.rows}" var="row">

         <log:info category='<%= request.getRemoteUser() %>'>
            <c:out value="${}"/>


<jsp:forward page="/index.jsp"/>


if i put a autoFlush="false" in page directive and a <% out.flush(); %> 
just before the forward i have a bufferOverflow ...

At 16:00 2003-09-04 -0400, you wrote:
>More information ...
>Shapira, Yoav wrote:
>>Both errors are fairly clear and essentially the same.  You can't
>>forward or redirect a response that's been committed, i.e. written to.
>>If you're going to forward or redirect a response, you must do so before
>>writing to the response.  You can read the JavaDoc for
>>HttpServletResponse#sendRedirect and RequestDispatcher#forward.
>>Yoav Shapira
>>Millennium ChemInformatics
>>>-----Original Message-----
>>>From: Maxime Colas des Francs []
>>>Sent: Thursday, September 04, 2003 3:37 PM
>>>Subject: forward error
>>>- If at the end of on of a jsp file, i put a <jsp:forward>, i have this
>>>java.lang.IllegalStateException: Error: Attempt to clear a buffer
>>>already been flushed
>>>         at
>>>         at org.apache.jsp.test_ps_jsp._jspService(
>>>         at
>>>         ...
>>>- if i put a <c:redirect>, i have this :
>>>         at
>>>         at
>>>         at
>>>         at org.apache.jsp.test_ps_jsp._jspService(
>>>         ...
>>>- if i put nothing, i have no error ...
>>>sombdy can help me to understand this error ?
>>>To unsubscribe, e-mail:
>>>For additional commands, e-mail:
>>This e-mail, including any attachments, is a confidential business 
>>communication, and may contain information that is confidential, 
>>proprietary and/or privileged.  This e-mail is intended only for the 
>>individual(s) to whom it is addressed, and may not be saved, copied, 
>>printed, disclosed or used by anyone else.  If you are not the(an) 
>>intended recipient, please immediately delete this e-mail from your 
>>computer system and notify the sender.  Thank you.
>>To unsubscribe, e-mail:
>>For additional commands, e-mail:
>To unsubscribe, e-mail:
>For additional commands, e-mail:

View raw message