-
Notifications
You must be signed in to change notification settings - Fork 747
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Track store metrics by DB column #6041
Conversation
leveldb_batch.put(BytesKey::from_vec(key), &value); | ||
} | ||
|
||
KeyValueStoreOp::DeleteKey(key) => { | ||
let col = get_col_from_key(&key).unwrap_or("unknown".to_owned()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
get_col_from_key
should never error as we define the DBColumn enum variants. The use of col is purely informational on metrics, so unwrapping to unknown to have something
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
@mergify queue |
✅ The pull request has been merged automaticallyThe pull request has been merged automatically at b0b142c |
Issue Addressed
When adding metrics for
Noted that the DB metrics are already there but we don't track them by column. I would like to be able to tell:
Proposed Changes
IntCounter
toIntCounterVec
and label by column enum 3 letter string.do_atomically
calls, optimistically assuming success