Skip to content

Expose the reload decision API in a public package (v2)#1191

Open
msafwankarim wants to merge 10 commits into
v2from
refactor/public-config-reload-metadata
Open

Expose the reload decision API in a public package (v2)#1191
msafwankarim wants to merge 10 commits into
v2from
refactor/public-config-reload-metadata

Conversation

@msafwankarim

@msafwankarim msafwankarim commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Promotes the config, metadata, and annotation-decision types to public packages (pkg/) so a separate Go module can consume them, while keeping the workload-coupled reload engine internal. External consumers can now import the decision logic without pulling in internal/-only types.

What's public now

  • pkg/matcher the decision API: Matcher, NewMatcher, MatchInput, MatchResult, ResourceType (+ constants). Depends only on pkg/config; imports nothing from internal/.
  • pkg/config: configuration types (Config, annotations, validation, selectors).
  • pkg/metadata: build/deployment metadata + ConfigMap publisher.

Notes:

  • The public package is named matcher (not reload) to avoid a package-name collision with the internal engine no import aliases needed anywhere.
  • pkg/config and pkg/metadata do import internal/pkg/workload for an implementation-detail constant/helper, but never expose internal types in their signatures, so they remain usable externally.

@msafwankarim msafwankarim changed the title Refactor/public config reload metadata Expose the reload decision API in a public package Jul 21, 2026
@github-actions

Copy link
Copy Markdown

✅ Load Test Results (quick)

✅ Load Test Results: ALL TESTS PASSED

🚀 Quick Test (S1, S4, S6) — Use /loadtest for full suite

3/3 passed (100%)

Scenario Description Actions Errors
S1 S1: 143 burst updates, each triggers 1 dep... 142/143 0
S4 S4: 143 no-op updates, all should be skipped 0 0
S6 S6: Restart test - 142 updates during restart 142 0

📦 Download detailed results


Artifacts: Download

@msafwankarim msafwankarim changed the title Expose the reload decision API in a public package Expose the reload decision API in a public package (v2) Jul 22, 2026
@github-actions

Copy link
Copy Markdown

✅ Load Test Results (quick)

✅ Load Test Results: ALL TESTS PASSED

🚀 Quick Test (S1, S4, S6) — Use /loadtest for full suite

3/3 passed (100%)

Scenario Description Actions Errors
S1 S1: 143 burst updates, each triggers 1 dep... 143/143 0
S4 S4: 143 no-op updates, all should be skipped 0 0
S6 S6: Restart test - 142 updates during restart 136 0

📦 Download detailed results


Artifacts: Download

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