Web service request does not reach IIS



I'm writing a Windows Forms application which gets data through a Web
Service. I'm trying to use the IIS HTTP 1.1 native compression. In
order to do that I've added the following methods to the proxy class
generated by Visual Studio:

protected override WebRequest GetWebRequest(Uri uri)
WebRequest request = base.GetWebRequest(uri);
request.Headers.Add("Accept-Encoding", "gzip, deflate");
return request;

protected override WebResponse GetWebResponse(WebRequest request)
HttpWebResponseDecompressed response = new
return response;

The HttpWebResponseDecompressed class receives the compressed response
and decompress it. This is what is happening: if I remove the second
line from the GetWebRequest method (which adds the header), all the 9
requisitions that I make on the program's initialization have answer.
But when the header is added, only the first 4 requisitions receive
answer (the answer is correctly compressed).

I've enabled the ASP.NET trace (which generates the trace.axd page) so
that I could see the requests received by IIS and the last 5 do not
appear. If I put a breakpoint in the GetWebRequest method, the
breakpoint is hit but they do not reach IIS.

Can anyone tell me what is happening or what can I do?


Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Latest member

Latest Threads