Skip to content

Commit

Permalink
Update README for new Minute strategy.
Browse files Browse the repository at this point in the history
  • Loading branch information
Winfield Peterson committed May 13, 2011
1 parent 640c411 commit 1a79aca
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions README.md 100644 → 100755
Expand Up @@ -13,8 +13,8 @@ Features

* Throttles a Rack application by enforcing a minimum time interval between
subsequent HTTP requests from a particular client, as well as by defining
a maximum number of allowed HTTP requests per a given time period (hourly
or daily).
a maximum number of allowed HTTP requests per a given time period (per minute,
hourly, or daily).
* Compatible with any Rack application and any Rack-based framework.
* Stores rate-limiting counters in any key/value store implementation that
responds to `#[]`/`#[]=` (like Ruby's hashes) or to `#get`/`#set` (like
Expand Down Expand Up @@ -60,6 +60,10 @@ Examples

use Rack::Throttle::Interval, :min => 3.0

### Allowing a maximum of 60 requests per minute

use Rack::Throttle::Minute, :max => 60

### Allowing a maximum of 100 requests per hour

use Rack::Throttle::Hourly, :max => 100
Expand All @@ -72,6 +76,7 @@ Examples

use Rack::Throttle::Daily, :max => 1000 # requests
use Rack::Throttle::Hourly, :max => 100 # requests
use Rack::Throttle::Hourly, :max => 60 # requests
use Rack::Throttle::Interval, :min => 3.0 # seconds

### Storing the rate-limiting counters in a GDBM database
Expand Down

0 comments on commit 1a79aca

Please sign in to comment.