Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

WriteClient() on IIS 6.0 (SP1)

20 views
Skip to first unread message

markus

unread,
Aug 14, 2005, 12:18:32 PM8/14/05
to
it looks like WriteClient() on IIS6.0 (SP1) always returns true, even if
the client has disconnected meanwhile. in IIS5 there wasn't such a
behaviour, WriteClient() returned false, everytime there was no data
connection available.

before SP1 a workaround exists using the "EnableCopySend" registry key
for "http.sys". since SP1 it is no longer working :(

did any of you experienced similar problems too ? any ideas to go around
it ?

david ? :)

regards from germany,

markus

Wade A. Hilmo [MS]

unread,
Aug 15, 2005, 5:51:05 PM8/15/05
to
Hi markus,

Synchronous WriteClient calls under a certain size are buffered by http.sys.
I don't know the size off the top of my head, but if I had to guess, I would
say probably 16k. There were some changes to this code in SP1 to correct
some performance issues (see
http://support.microsoft.com/default.aspx?scid=kb;en-us;840875.)

If you make a synchronous WriteClient call and the connection is in a closed
state, then the call will return an immediate failure. In SP1, when a call
is buffered and the underlying connection is in CLOSE_WAIT state, http.sys
sees that the connection is not fully closed and returns immediate success
to the caller. When the attempt to send the buffered data actually fails,
http.sys cause the correct logging to happen, but it is too late to notify
the caller of the status, since the return already happened.

Unfortunately, there is no way for the ISAPI extension to know that this has
happened.

Thank you,
-Wade A. Hilmo,
-Microsoft

"markus" <papie...@snafu.de> wrote in message
news:3m9940F...@uni-berlin.de...

markus

unread,
Aug 16, 2005, 10:20:05 AM8/16/05
to
hi wade, thanks for your reply. i tried a lot of buffer sizes in the
past (all between 8K and 32K) but i couldn't notice any change overall.

is there a possibility to turn of "buffered" WriteClient() in IIS 6 SP1
too ? it looks like without SP1 there is something different if the
"EnableCopySend" switch is used.

as far as i know "http.sys" recognizes a few new "hidden" registry
parameters since sp1 was introduced like "MaxBufferedSends" and
"MaxBufferedSendBytes" what about these switches ?

by the way, the "MaxCopyTreshold" parameter - how does it affect the
buffer size you mentioned for buffered calls ?

greetings form germany,

markus

Wade A. Hilmo [MS]

unread,
Aug 18, 2005, 6:27:25 PM8/18/05
to
Hi marcus,

I'm not familiar with the nuances of http.sys. I do know that there is no
way to turn off buffering, though.

If you need to pursue this, and cannot find resources online, this might be
a good issue to open with product support.

Thank you,
-Wade A. Hilmo,
-Microsoft

"markus" <papie...@snafu.de> wrote in message

news:3meattF...@uni-berlin.de...

0 new messages