You are viewing a plain text version of this content. The canonical link for it is here.
Posted to httpclient-users@hc.apache.org by Jordi Domingo Borràs <jo...@gmail.com> on 2011/10/14 16:06:58 UTC

Setting up a delay between requests to a host

Hi all,

I'm using the latest version of HttpClient.

I've set it up with ccm.setDefaultMaxPerRoute(1)  but I also need to
establish a delay between requests for some hosts.

Is there any fast way to do so? If not, your suggestions are greatly
appreciated.


thanks a lot!

Jordi

Re: Setting up a delay between requests to a host

Posted by Oleg Kalnichevski <ol...@apache.org>.
On Fri, 2011-10-14 at 16:06 +0200, Jordi Domingo Borràs wrote:
> Hi all,
> 
> I'm using the latest version of HttpClient.
> 
> I've set it up with ccm.setDefaultMaxPerRoute(1)  but I also need to
> establish a delay between requests for some hosts.
> 
> Is there any fast way to do so? If not, your suggestions are greatly
> appreciated.
> 
> 
> thanks a lot!
> 
> Jordi

Thread#sleep is your friend. Seriously.

Oleg


---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org