Skip to content
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

[NBS, Filestore] Support suitable for Grafana data format for histograms counters #2001

Open
dvrazumov opened this issue Sep 11, 2024 · 0 comments · May be fixed by #2007
Open

[NBS, Filestore] Support suitable for Grafana data format for histograms counters #2001

dvrazumov opened this issue Sep 11, 2024 · 0 comments · May be fixed by #2007
Assignees

Comments

@dvrazumov
Copy link
Collaborator

dvrazumov commented Sep 11, 2024

Problem

Currently histograms are reported using a bunch of manually created counters with names like __1ms, __2ms, __10ms and a label histogram="ExecutionTime" by which you can identify the bucket. This format is supported only in Solomon. Example (prometheus format):

__001ms{component="server", request="ReadBlocks", histogram="ExecutionTime", } 1
__1ms{component="server", request="ReadBlocks", histogram="ExecutionTime", } 0
__2ms{component="server", request="ReadBlocks", histogram="ExecutionTime", } 4
__3ms{component="server", request="ReadBlocks", histogram="ExecutionTime", } 1

The grafana is waiting for histogram in the following format (with "le" label that means "less or equal" bucket):

ExecutionTime_bucket{component="server", request="ReadBlocks", le="0.001", } 1
ExecutionTime_bucket{component="server", request="ReadBlocks", le="1", } 1
ExecutionTime_bucket{component="server", request="ReadBlocks", le="2", } 5
ExecutionTime_bucket{component="server", request="ReadBlocks", le="3", } 6

Solution

monlib already has all that we need - special class THistogram that can report histogram in format supported both in Solomon and Grafana. One need to support reporting histogram using this class. To provide backward compatibility it is proposed to leave the old format (with multiple counters). It would be useful to add two new parameters in diagnostics config that will manage histogram report mode:

  • ReportHistogramAsSingleCounter, with default false value
  • ReportHistogramAsMultipleCounters, with default true value
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant