0
Answer

Slow response while running a screen scraper through a public proxy

Ask a question
Hatim

Hatim

17y
1.7k
1

Hi,

 

I’ve written a screen scraper in C# that routes all http requests through a public proxy. While the code works, it takes quite a long time to retrieve each response. The relevant portion of the code is pasted below. Could someone tell me why it takes so long before a response is returned?

 

Thanks in advance.

 

 

HttpWebRequest request = (HttpWebRequest)WebRequest.Create(url);

WebProxy wp = new WebProxy("http://255.255.1.1:8080"); //of course, this is not the actual public proxy that I’m using

request.Proxy = wp;           

 

wp.UseDefaultCredentials = true;

 

HttpWebResponse oWebResponse = (HttpWebResponse)request.GetResponse();