Skip to content
This repository was archived by the owner on Apr 2, 2024. It is now read-only.

Conversation

@harkishen
Copy link
Member

Signed-off-by: Harkishen-Singh harkishensingh@hotmail.com

Relates: #1616

Description

This commit adds telemetry for 2 things:

  1. promscale_metrics_ingestion_path: possible values no_ingestion if Promscale is sitting idle, otherwise protobuf, json, text_plain, text_open_metrics
  2. promscale_metrics_json_endpoint_used: 0 or 1

Along with this, the commit also simplifies the Telemetry implementation for binary cases, removing the need to creating any metrics at all. This affects promscale_rules_enabled & promscale_alerting_enabled.

Merge requirements

Please take into account the following non-code changes that you may need to make with your PR:

  • CHANGELOG entry for user-facing changes
  • Updated the relevant documentation

@harkishen harkishen self-assigned this Oct 13, 2022
@harkishen harkishen requested review from a team and antekresic as code owners October 13, 2022 10:16
@harkishen
Copy link
Member Author

@VineethReddy02 for new telemetry information.

@harkishen harkishen force-pushed the more_telemetry_points branch 2 times, most recently from ec582e0 to 6eaf1fe Compare October 13, 2022 10:23
Signed-off-by: Harkishen-Singh <harkishensingh@hotmail.com>
@harkishen harkishen force-pushed the more_telemetry_points branch from 6eaf1fe to d6b1d51 Compare October 13, 2022 10:37
case "application/openmetrics-text":
telemetry.Registry.Update("metrics_ingestion_path", "text_open_metrics")
default:
telemetry.Registry.Update("metrics_ingestion_path", "none")
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: unknown seems better

func (m *Manager) updateTelemetry(cfg *Config) {
if cfg.ContainsRules() {
rulesEnabled.Set(1)
telemetry.Registry.Update("rules_enabled", "1")
Copy link
Contributor

Choose a reason for hiding this comment

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

I am not sure how I feel about these hardcoded strings in various places

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants