docs: clarify listener metric label sources#4525
Draft
ChongZhe001025 wants to merge 1 commit into
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Clarifies the
listenerMetricsexamples in thegha-runner-scale-setchart values.Based on the current implementation, gauge metrics such as
gha_running_jobs,gha_assigned_jobs, andgha_registered_runnersare recorded from scale set statistics using scale set labels. These labels come from the configured GitHub scope.Counter and histogram metrics such as
gha_started_jobs_total,gha_completed_jobs_total, and job duration metrics are recorded from job messages, so they can include job-level metadata such as repository and workflow information.Context
Refs #4304.
While investigating the issue, I found that:
NewExporter()is called fromcmd/ghalistener/main.goExporterConfig.Repository,ExporterConfig.Organization, andExporterConfig.Enterpriseare derived fromactions.ParseGitHubConfigFromURL(config.ConfigureURL)config.ConfigureURLcomes from the listener config secret generated fromAutoscalingRunnerSet.Spec.GitHubConfigUrlParseGitHubConfigFromURL()populates scope values based on the configured URL:/org/repopopulates repository scope/orgpopulates organization scope/enterprises/foopopulates enterprise scopeBecause of this, gauge metrics appear to reflect the configured scale set scope rather than per-job metadata. This change clarifies that expectation in the chart values examples instead of deriving gauge labels from job messages.
Changes
charts/gha-runner-scale-set/values.yamlcharts/gha-runner-scale-set-experimental/values.yamlTesting
git diff --checkNo Go tests or Helm rendering tests were run because this change only updates commented examples in
values.yamland does not affect rendered manifests or Go behavior.