Skip to content

Make CanopyMetricsHandler configurable with domain selection + prefix - #27

Merged
noha merged 1 commit into
mainfrom
add-metrics-handler-domain-config
Jul 27, 2026
Merged

Make CanopyMetricsHandler configurable with domain selection + prefix#27
noha merged 1 commit into
mainfrom
add-metrics-handler-domain-config

Conversation

@noha

@noha noha commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Builds on the visitor's addDomain:/addDomain:prefix: API. The handler now lets a caller choose which domains the scrape endpoint exports and optionally prefix a domain's metric names (e.g. #virtualMachine prefix: 'pharo').

  • addDomain: / addDomain:prefix: configure the selection (domain names as symbols).
  • prometheusText resolves each configured domain fresh per request (values stay live), then exports via the visitor.
  • Default is unchanged: with no domains configured, the whole Canopy tree is exported (all domains, unprefixed) exactly as before.

Canopy-Metrics-Tests 20/20, Canopy-Core-Tests 73/73 green.

Builds on the visitor's addDomain:/addDomain:prefix: API. The handler now lets a
caller choose which domains the scrape endpoint exports and optionally prefix a
domain's metric names (e.g. #virtualMachine prefix: 'pharo').

- addDomain: / addDomain:prefix: configure the selection (domain names as symbols).
- prometheusText resolves each configured domain fresh per request (values stay
  live), then exports via the visitor.
- Default is unchanged: with no domains configured, the whole Canopy tree is
  exported (all domains, unprefixed) exactly as before.

Canopy-Metrics-Tests 20/20, Canopy-Core-Tests 73/73 green.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@noha
noha merged commit c193643 into main Jul 27, 2026
4 checks passed
@noha
noha deleted the add-metrics-handler-domain-config branch July 27, 2026 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant