Skip to content

Tracking: Align autodiscovery matching rule behavior across plugins #7628

@railgun-0402

Description

@railgun-0402

Context:

  • In fix(autodiscovery/helmfile): error on invalid ignore spec #7620 we fixed Helmfile autodiscovery matching rules so that an empty rule (no selectors defined) does not accidentally match / silently result in 0 discoveries.
  • A follow-up suggestion was to apply the same behavior to other autodiscovery plugins for consistency.

This is a proposal / tracking issue. If this is not desired, feel free to close it.

Goal

Align autodiscovery matching rule behavior across plugins:

  • A rule with no selectors defined (all fields empty/zero values) MUST NOT match.
  • Invalid specs should fail fast with a clear error when applicable.
  • Add/adjust unit tests to prevent regressions.

Proposed approach

  • Audit other autodiscovery plugins’ matching-rule implementations.
  • Prefer small PRs (one plugin per PR) to keep reviews easy.
  • Keep behavior unchanged for non-empty rules.

Checklist (draft)

  • Identify affected autodiscovery plugins and list them here (matchingRule.go / equivalent).
  • Add empty-rule guard / validation for plugin:
  • Add/adjust unit tests for plugin:
  • Repeat for remaining plugins

How to claim (help wanted)

Comment on this issue with the plugin/item you’ll take, e.g. “I’ll take ”.
To leave room for other contributors, I’ll wait a bit for volunteers, and if nobody picks it up I’m happy to start with the first item.

Related:

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions