Skip to content

Record the metric-filter cleanup in the as-built notes and document the attach signal#222

Merged
pambrose merged 1 commit into
masterfrom
docs/metric-filter-as-built
Jul 20, 2026
Merged

Record the metric-filter cleanup in the as-built notes and document the attach signal#222
pambrose merged 1 commit into
masterfrom
docs/metric-filter-as-built

Conversation

@pambrose

Copy link
Copy Markdown
Owner

Docs-only follow-up to #221. The Feature 4 as-built notes described the first cut of the feature, before the post-merge quality pass moved things around.

docs/FEATURE_PROPOSALS_JULY_2026.md

  • FilesMetricFilter now owns filterBytes() (the content-type gate, strict UTF-8 decode, fail-open branches, and warn latches); AgentHttpService is reduced to calling it. AgentPathManager reports filter attachment in the registration log.
  • Matching — corrected "once-per-path warning" to once per filter instance, and added that a fail-open scrape records no filter metrics at all, which is deliberately distinguishable from a filter that ran and dropped nothing.
  • New "Post-merge cleanup" subsection recording the three divergences from the first cut and why each was made: the policy move (including why the path-keyed warn sets grew without bound under Feature 1's reconcile loop), the switch to index-based scanning in filterText(), and the deletion of the startup filter/path cross-check.
  • Tests — replaced the now-inaccurate "path-typo-warning cases" with the registration-log attachment cases, and flagged that the isFilterableContentType tests still live in AgentHttpServiceTest though the function moved to MetricFilter.

website/prometheus-proxy/docs/configuration/agent.md

Added a "Confirming a filter attached" tip — the operator-facing consequence of deleting the startup cross-check. A filter whose path doesn't match a registered path is otherwise silent, so the doc shows the exact registration log line and explains what its absence means. The example string was verified against the source.

Unchanged on purpose

README and the agent.md fail-open note describe user-visible behavior, which did not change — "logs a warning once per path" still holds, since the filter instance the latch moved onto is 1:1 with a path. CHANGELOG and RELEASE_NOTES describe config surface and matching semantics, both untouched.

🤖 Generated with Claude Code

…he attach signal

The Feature 4 as-built notes described the first cut, where the content-type
gate and fail-open handling lived in AgentHttpService. They moved into
MetricFilter.filterBytes() during the post-merge quality pass, along with the
warn latches; the notes now match, and a new subsection records the three
divergences and why each was made.

Also documents the operator-facing consequence of deleting the startup
filter/path cross-check: a filter whose path does not match a registered path is
otherwise silent, so agent.md now shows the registration log line that reports
attachment and says what its absence means.

README and the agent.md fail-open note are unchanged -- they describe behavior
that did not change.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@pambrose
pambrose merged commit 2db344a into master Jul 20, 2026
5 checks passed
@pambrose
pambrose deleted the docs/metric-filter-as-built branch July 20, 2026 19:18
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