Re-implement connected_client to have deterministic cardinality#950
Re-implement connected_client to have deterministic cardinality#950oliver006 merged 3 commits intooliver006:masterfrom mindw:dev/mindw/client_connection_info_reworked
Conversation
|
Quick comments (warning: I do not know any go):
|
|
Thanks @hiroshi-ishii for the review - see below:
|
|
Hey there and thanks for opening the PR! One request though: can we keep the name of the current client detail metric the same so you don't introduce backwards incompatible changes? Let me know when you're ready for code review and want comments and then I'll have a look. Oh, and one more request: can you rebase the PR please? I moved the tests over to Github Actions yesterday and I don't see that here yet. |
Tx!
It is an optional feature and I'm not sure how much it was used given it's current state also it wont have the same labels. Then again the old name doesn't really follow the Prometheus naming convention. I would suggest to duplicate it the name instead.
It's ready :)
I've rebased on the latest and greatest main/master. Thanks! |
|
@mindw |
|
Thanks @mindw, looks good. Let's see what @oliver006 says. |
Pull Request Test Coverage Report for Build 10993316969Details
💛 - Coveralls |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #950 +/- ##
==========================================
+ Coverage 80.25% 81.63% +1.38%
==========================================
Files 17 17
Lines 1980 2129 +149
==========================================
+ Hits 1589 1738 +149
Misses 306 306
Partials 85 85 ☔ View full report in Codecov by Sentry. |
|
@oliver006 this is ready for your review :) |
Sorry about the delay - having a look now. |
oliver006
left a comment
There was a problem hiding this comment.
Overall approach looks good - just a couple of smaller things
Signed-off-by: Gabi Davar <grizzly.nyo@gmail.com>
|
@oliver006 IMO all comments were addressed, anything else? |
Apologies for the delay, I didn't have much time last week, will get back to this again in the next few days. |
oliver006
left a comment
There was a problem hiding this comment.
Nice work - thanks for getting this done!
The current connected client suffers from some drawbacks rendering much less useful than it should:
idfield which uniquely identifies the client is missing from the labels.This PR attempts to ratify all that:
connected_clients_detailstoconnected_client_info(as per prometheus naming conventions) - dropping all high cardinality labels.connected_client_output_buffer_memory_usage_bytes,connected_client_total_memory_consumed,connected_client_created_at_timestamp,connected_client_idle_since_timestamp,connected_client_channel_subscriptions_count,connected_client_pattern_matching_subscriptions_count,connected_client_shard_channel_subscriptions_countandconnected_client_shard_channel_watched_keysmetrics per client.idto all metrics.I'm still running some tests on the output metrics, so please don't merge it yet :)Input, missing bits (docs?) are welcome!