mirror of
https://github.com/jimeh/redistat.git
synced 2026-02-19 13:26:39 +00:00
Allow for configurable group separator
This commit is contained in:
@@ -149,7 +149,12 @@ is the label that you're storing to, or fetching from.
|
||||
Labels support multiple grouping levels by splitting the label string with `/`
|
||||
and storing the same stats for each level. For example, when storing data to a
|
||||
label called `views/product/44`, the data is stored for the label you specify,
|
||||
and also for `views/product` and `views`.
|
||||
and also for `views/product` and `views`. You may also configure a different
|
||||
group separator using the `Redistat.group_separator` option. For example:
|
||||
|
||||
```ruby
|
||||
Redistat.group_separator = '|'
|
||||
```
|
||||
|
||||
A word of caution: Don't use a crazy number of group levels. As two levels
|
||||
causes twice as many `hincrby` calls to Redis as not using the grouping
|
||||
|
||||
Reference in New Issue
Block a user