in reply to Re: How do I prevent more than one request (to some URL) per second with CGI?
in thread How do I prevent more than one request (to some URL) per second with CGI?

That's what I was looking for. I didn't even consider locking a file. Thanks for the help perlplexer.
  • Comment on Re: Re: How do I prevent more than one request (to some URL) per second with CGI?

Replies are listed 'Best First'.
Re: Re: Re: How do I prevent more than one request (to some URL) per second with CGI?
by rob_au (Abbot) on Nov 27, 2002 at 23:35 UTC
    With that in mind, it may be worth your looking at merlyn's Highlander - allow only one invocation at a time of an expensive CGI script which allows only a single simultaneous invocation of a CGI script. If you combine this with a sleep function within your script such that execution time is greater than a second, this will effectively achieve your goal.

     

    perl -e 'print+unpack("N",pack("B32","00000000000000000000000111101100")),"\n"'