You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2017/10/24 13:04:48 UTC

[Bug 61660] New: Calling flush() on servlet response print writer while compression is enabled produces corrupted response

https://bz.apache.org/bugzilla/show_bug.cgi?id=61660

            Bug ID: 61660
           Summary: Calling flush() on servlet response print writer while
                    compression is enabled produces corrupted response
           Product: Tomcat 7
           Version: 7.0.82
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: major
          Priority: P2
         Component: Catalina
          Assignee: dev@tomcat.apache.org
          Reporter: ayman.madkour@incorta.com
  Target Milestone: ---

Created attachment 35453
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=35453&action=edit
A sample servlet code to reproduce the issue

The issue happens only on Oracle JDK 8 update 151/152, not before.

Calling flush() on servlet response print writer while compression is enabled
produces corrupted response.

See attached servlet.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 61660] Calling flush() on servlet response print writer while compression is enabled produces corrupted response

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=61660

--- Comment #1 from Remy Maucherat <re...@apache.org> ---
As a side note, without looking at the merits of the BZ, I'd like to point out
that the very common habit of doing flush and/or close at the end of a servlet
is a bad idea, it may impair better error processing and will always degrade
performance.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 61660] Calling flush() on servlet response print writer while compression is enabled produces corrupted response

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=61660

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |maarten@vanhulsentop.nl

--- Comment #3 from Mark Thomas <ma...@apache.org> ---
*** Bug 61866 has been marked as a duplicate of this bug. ***

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 61660] Calling flush() on servlet response print writer while compression is enabled produces corrupted response

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=61660

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |INVALID

--- Comment #2 from Mark Thomas <ma...@apache.org> ---
This is a know issue with the JRE and will fixed in the next JRE release.

https://bugs.openjdk.java.net/browse/JDK-8189788

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org