mirror of
https://github.com/jimeh/redistat.git
synced 2026-02-19 05:16:39 +00:00
updated reverse label hash lookup storage format, which might be a pain if you have been using the hashed_label option
This commit is contained in:
@@ -35,7 +35,7 @@ module Redistat
|
||||
|
||||
KEY_NEXT_ID = ".next_id"
|
||||
KEY_EVENT = ".event:"
|
||||
KEY_LEBELS = "Redistat.lables:" # TODO: Fix this typo, at some point. Might brack backwards compatability ^_^
|
||||
KEY_LEBELS = "Redistat.labels:" # used for reverse label hash lookup
|
||||
KEY_EVENT_IDS = ".event_ids"
|
||||
LABEL_INDEX = ".label_index:"
|
||||
GROUP_SEPARATOR = "/"
|
||||
|
||||
@@ -29,7 +29,7 @@ module Redistat
|
||||
end
|
||||
|
||||
def save
|
||||
@saved = (db.set("#{KEY_LEBELS}#{hash}", self.to_s) == "OK") if @options[:hashed_label]
|
||||
@saved = db.hset(KEY_LEBELS, hash, self.to_s) if @options[:hashed_label]
|
||||
self
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user