|Summary:||Issue with IIS7+ buffered response|
|Product:||Tomcat Connectors||Reporter:||George Stanchev <stanchev>|
|Component:||isapi||Assignee:||Tomcat Developers Mailing List <dev>|
Description George Stanchev 2015-11-13 17:18:25 UTC
We have run into an issue with Tomcat Connector and IIS7+. The request to Tomcat routed via the Connector contains a number of batch requests that require batch responses which are then processed as they arrive by the client. IIS buffers the HTTP response until the buffer is full or the response is fulfilled. This is described by Microsoft in the following KB article . While IIS sits and buffers the response our client loses interactivity and just sits idle waiting for the whole result to arrive. The issue is also exacerbated by dealing with large batch responses (think of a multiple files sent back as part of the response) where the client decides the connection is dead and closes the connection. If we call lpEcb->ServerSupportFunction(lpEcb->ConnID, HSE_REQ_SET_FLUSH_FLAG, (LPVOID) TRUE, NULL, NULL); In "DWORD WINAPI HttpExtensionProc(LPEXTENSION_CONTROL_BLOCK lpEcb)" it fixes the issue. I don't have a patch to attach (though if encouraged I can look into getting one) but I propose to introduce a registry setting that controls this flag. The default value of it can be debated but at least it will give the ability to work around the problems with use case described above.  https://support.microsoft.com/en-us/kb/946086
Comment 1 Mark Thomas 2016-09-15 14:13:13 UTC
This has been fixed in trunk for 1.2.42 onwards with a new option called "flush_packets".