SamSaffron/MiniProfiler — pull request #139 by gmcnaughton (2013-03-22 21:46:46+00:00)
Title: Adds ':expires_in' option for all storage engines

Adds ```:expires_in``` option to all storage subclasses. ```:xpires_in``` controls how long MiniProfiler will cache results (defaults is still 24 hours).

Example:
```ruby
Rack::MiniProfiler.config.storage_options = { :expires_in => 5.minutes }
Rack::MiniProfiler.config.storage = Rack::MiniProfiler::RedisStore
```

Also fixes #103 (MemcacheStore has wrong defaults for Dalli client).

**WARNING**: this is a breaking change for anyone initializing MemcacheStore manually, because the signature for the initializer changed (to make it consistent with other storage subclasses).

```ruby
# old way: manually initialize store instance
Rack::MiniProfiler.config.storage_instance = Rack::MiniProfiler::MemcacheStore.new(Dalli::Client.new)

# new way
Rack::MiniProfiler.config.storage = Rack::MiniProfiler::MemcacheStore
```