Skip to content
Snippets Groups Projects
Commit 58a1938e authored by Alex Reisner's avatar Alex Reisner
Browse files

Fully document supported cache store interface.

parent 2f49f260
No related branches found
No related tags found
No related merge requests found
......@@ -470,10 +470,10 @@ It's a good idea, when relying on any external service, to cache retrieved data.
This example uses Redis, but the cache store can be any object that supports these methods:
* `store#[](key)` - retrieves a value
* `store#[]=(key, value)` - stores a value
* `store#keys` - lists all keys
* `store#del(url)` - deletes a value
* `store#[](key)` or `#get` or `#read` - retrieves a value
* `store#[]=(key, value)` or `#set` or `#write` - stores a value
* `store#keys` - lists all keys
* `store#del(url)` - deletes a value
Even a plain Ruby hash will work, though it's not a great choice (cleared out when app is restarted, not shared between app instances, etc).
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment