fix: pin maps concurrency fix while retaining SafeMap - #416
Conversation
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (8)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe pull request replaces ChangesSynchronized map migration
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Bug fix Merge Risk: ⚪ Minimal · up to The synchronized map migration has no confirmed merge-blocking issue. 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 27.27% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 11 functions across 7 files. (1 skipped: 1 unsupported.)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Summary:
|
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com>
|
Summary:
|
Overview
Fix the first-write data race reported in the failing CI job by pinning the maps concurrency fix from goradd/maps#22.
Keep the existing SafeMap fields and APIs. A temporary
go.modreplacement selectsgithub.com/matthyx/mapsat commite9181ad404216d4e1523d9ac2790c3c91e8bdd7c. That fix protects backing-map access and uses an atomic initialization flag to preserve empty-map fast paths. The replacement also applies to transitive uses within operator's build. Remove it and upgrade the upstream dependency once a release includes the fix.Add concurrent admission add/delete/list/refresh regression coverage. Join SBOM test handlers before restoring retry settings and verify retry entries are removed after success or exhaustion. Production Go source and the Go version are unchanged.
Validation
-race -count=20passed.CGO_ENABLED=1 go test -race ./...passed.go vet ./...,go build ./..., formatting and diff checks passed.Validated with Go 1.25.8. The separate Helm autoscaler tests (
-tags=integration) were not run locally.Follow-up
The pinned fix is currently an unmerged fork commit. Replace the temporary override with an upstream release containing goradd/maps#22 when available.
Sign-off