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

feat(outputs.stackdriver): Enable histogram support #14275

Merged
merged 4 commits into from
Dec 7, 2023

Conversation

powersj
Copy link
Contributor

@powersj powersj commented Nov 10, 2023

This adds the ability to send Histograms to stackdriver. Telegraf will check if the metric type is histogram, if so, the single metric is required to have the sum and count fields and then all the various buckets. We take the buckets and counts and transform them into a Stackdriver distribution.

Telegraf's Prometheus metric version type 2 is not supported as the metric is sparse.

While writing this, discovered that our labels per metric limit of 10 was lower than the official limit of 30. That was increased and test updated.

fixes: #14258

@telegraf-tiger telegraf-tiger bot added feat Improvement on an existing feature such as adding a new setting/mode to an existing plugin plugin/output 1. Request for new output plugins 2. Issues/PRs that are related to out plugins labels Nov 10, 2023
@influxdata influxdata deleted a comment from telegraf-tiger bot Nov 10, 2023
@powersj powersj self-assigned this Nov 10, 2023
@powersj powersj force-pushed the feat/stackdriver-histogram branch 4 times, most recently from 5ca2869 to 9d74d4c Compare November 17, 2023 00:03
@powersj powersj force-pushed the feat/stackdriver-histogram branch 2 times, most recently from 03b74d8 to c80eed1 Compare November 29, 2023 18:56
This enables the stackdriver output to send histogram metrics. These
metrics are required to have a sum field and all other fields should
include the buckets and counts in a single metric. Prometheus parser
metric version 2 is not supported given the sparse nature of the
metrics.

This also increases the label limit to 30 per the stackdriver published
limits. As histograms could have even more labels than other types of
metrics.

fixes: influxdata#14258
@powersj powersj force-pushed the feat/stackdriver-histogram branch from 26dc5ad to 92aac0e Compare December 5, 2023 15:29
@powersj powersj marked this pull request as ready for review December 5, 2023 15:32
@powersj powersj added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Dec 5, 2023
@powersj powersj assigned srebhan and unassigned powersj Dec 5, 2023
@powersj powersj removed the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Dec 5, 2023
@powersj powersj assigned powersj and unassigned srebhan Dec 5, 2023
@powersj powersj added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Dec 6, 2023
@powersj powersj assigned srebhan and unassigned powersj Dec 6, 2023
Copy link
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. Just one question about the source for the QuotaLabelsPerMetricDescriptor value...

plugins/outputs/stackdriver/stackdriver.go Show resolved Hide resolved
@telegraf-tiger
Copy link
Contributor

telegraf-tiger bot commented Dec 7, 2023

Copy link
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @powersj!

@srebhan srebhan merged commit 3172fd5 into influxdata:master Dec 7, 2023
23 checks passed
@github-actions github-actions bot added this to the v1.29.0 milestone Dec 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat Improvement on an existing feature such as adding a new setting/mode to an existing plugin plugin/output 1. Request for new output plugins 2. Issues/PRs that are related to out plugins ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Support to outputs.stackdriver to Transmit Histograms
2 participants