please help ... I have removed whitespaces by adding
    <jsp-config>
      <jsp-property-group>
        <url-pattern>*.jsp</url-pattern>
        <trim-directive-whitespaces>true</trim-directive-whitespaces>
      </jsp-property-group>
    </jsp-config>
but still i am facing same error. I tried to increase the buffer size also
as,
<%@ page  buffer="800kb" autoFlush="false" %>
but still same error....

stuck on this issue for more than 2 weeks now and need to close it ASAP
please help.
Any help/ pointer would be highly appreciated.

one more things, we are using struts version 1 and tiles 2.2. as struts1
doesn't work with tiles2, we have used struts-tiles2-1.4.0-SNAPSHOT.jar,
can this create any problem, but this combination work with tomcat version
below 7.0.37 and giving issues from version 7.0.39.

Can anybody please tell me what are the changes in between these two
versions which can produce this errror ??

Thanks
Prashant Kadam



On Mon, Mar 3, 2014 at 11:58 AM, Prashant Kadam
<prashantkada...@gmail.com>wrote:

> On Sat, Mar 1, 2014 at 1:33 AM, Christopher Schultz <
> ch...@christopherschultz.net> wrote:
>
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA256
>>
>> Prashant,
>>
>> On 2/28/14, 7:54 AM, Prashant Kadam wrote:
>> > thanks Mark and Konstantin for your reply
>> >
>> > If you create the simplest possible JSP that demonstrates the
>> > issue (start with the one you have and remove as much as you can)
>> > and then post that JSP here, we can take a look.
>> >
>> >>> as you can see in stacktrace, there are many jsps forwarding
>> >>> request to
>> > another jsp, i am not sure how can I post jsp code. also one
>> > observation is, there is a struts action forward in between means
>> > jsp-> struts action -> jsp , If I remove this action call and
>> > include jsp directly in jsp then its working ...  whether something
>> > wrong with tiles or struts or tomcat .. ?
>>
>> If you are doing a lot of JSP forwarding, you could be generating a
>> lot of useless whitespace that is all being sent to the output buffer.
>> Once that buffer fills up, the response headers will be sent to the
>> client and and response is therefore committed.
>>
>
> thanks for your reply
> seems logical ... and will try by removing white spaces ..
> still one question ...
>
> this is how it work it flows ...
> 1. jsp1 includes jsp2,
> 2. jsp2 forwards to jsp3 (using org.apache.struts.actions.ForwardAction) ,
> 3. jsp3  forwards to strutsaction1,
> 4. strutsaction1 forwards to strutsaction2,
> 5. strutsaction2 forwards to jsp4,
> 6. and jsp4 includes jsp5 to render final view ...
>
> now if I remove 3,4,5 and directly include jsp4 into jsp3 it works.
>
> even I tried removing all business logic code in strutsaction1,
> strutsaction2, it is throwing same error .. so conclusion is whenever i am
> using struts action in between it is causing problem ...
> any thoughts ... ?
>
>
>
>
>> If my analysis is correct, the difference between the Tomcat versions
>> probably comes down to some small change in the way JSPs are compiled
>> which may generate more whitespace if you haven't been careful.
>>
>> Take a look at all the JSPs that are participating in the request --
>> you should be able to inspect them to see why they might be generating
>> whitespace. Remember, newlines are whitespace ;)
>>
>> I can see from your stack trace that you are using *includes*. Is
>> there some other error that is occurring before this one? Does it
>> happen on every request to this resource?
>>
>> yes this happen on every request for same resource ...
>
> this is exception that i can see when I put try catch in one of the jsp ,,,
> javax.servlet.jsp.
> JspException: javax.servlet.jsp.JspException:
> javax.servlet.jsp.JspException: org.apache.jasper.JasperException:
> java.lang.IllegalStateException: Exception occurred when flushing data
>
>
>
>> - -chris
>>
>> -----BEGIN PGP SIGNATURE-----
>> Version: GnuPG v1
>> Comment: GPGTools - http://gpgtools.org
>> Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
>>
>> iQIcBAEBCAAGBQJTEOt7AAoJEBzwKT+lPKRY6fYP+wWFNBtLRjUi1m6NPPpxajyp
>> NBp0SZ5TIBs9c1fwAq3oKjodMDsgGMo59HApJpzHYyQhwuKHez3VLdGPss4aeq50
>> +Yc/UNhuMor31JWkPHzy05oSEFOQeKFn8Trw//OJ8m2giZSopt/05E8NRu9MIpUw
>> +9eEsetJHs0502XCEFQ206/6MLxleGLA/sM5HTWJHg0NJczobTsHo40myy201Y1j
>> Q7tO/gsyRzwljbHf0XByTTYUQNaNCaTzH0ydLiVeWCaPfxCpF4DXzrzdBu+BrL8U
>> n5BlaizxMp9vd5DPucbRZidC0ihQpcaMjBAXnwg3OtbltX5EsMEYOfgD/TQXh5PC
>> PFTPRm21OaybgNj13hNOOfmOCDw5AAA+znyVPFl4Ao+z67w0jIgSre49HMXfzYJQ
>> a2pcDzCUuvbtXl22LJBVcnqlISLETiShulRzvAF5OiYwe2bJS4fOdWNSB8Nn7L7A
>> +x//HxvTOem1dG5CaFRkCxvnkvK30e4LNCwY0AfErt3eKahHj0rJA+w/qiodTg2U
>> bzh8kgRv+9v0fqV3RKVV/nO7WFRlyN6QIalCvLKPC+9CdajvBPUVC+gZgizs4pjT
>> osHuIcGPmXMzycj1FfXzym5ucdy/WlJPUIBtliA4XnJ/RdBu1WfdB0c6rruiNflW
>> vp1dKzQjPx5Zv58BU2l1
>> =pI9J
>> -----END PGP SIGNATURE-----
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
>> For additional commands, e-mail: users-h...@tomcat.apache.org
>>
>>
>
>
> --
> ~ Prashant Kadam
>



-- 
~ Prashant Kadam

Reply via email to