What does this feature do?
CountsAndLists provides generic integer counter and string-list tracking on GameServers. It enables:
- Declaring named counters (integer) and lists (up to 1000 string values) on a GameServer at creation time
- Reading/updating those values via the SDK (
GetCounter, UpdateCounter, GetList, UpdateList, AddListValue, RemoveListValue)
- Filtering GameServerAllocations based on counter/list capacity and priorities
- Fleet auto-scaling driven by available counter/list capacity
- Aggregated counter/list status rolled up to Fleet and GameServerSet
All SDK methods for this feature live in the beta SDK packages today (Go: sdks/go/beta.go, C#: sdks/csharp/sdk/Beta.cs, Rust: sdks/rust/src/beta.rs, Unity: sdks/unity/AgonesBetaSdk.cs).
Current state: Beta (enabled by default since v1.41.0)
⚠️ This is a large, cross-cutting change. It should be broken into multiple PRs to keep reviews manageable. A suggested breakdown is at the bottom of this issue.
Acceptance Criteria / Tasks
Feature gate removal
SDK promotion
Per the Agones SDK stability policy: when a Beta SDK feature graduates to Stable at release X, the Beta surface is marked deprecated at release X and removed 5 releases later.
Config & docs
Tests
Suggested PR breakdown
Given the size of this work, splitting across multiple PRs is strongly recommended:
- PR 1 — API validation + tests: Remove gates from the five validation webhook files and their unit tests
- PR 2 — Controllers, allocation, autoscaler, metrics, sorting + tests: All the controller and allocation logic gate removal
- PR 3 — SDK server gate removal: Remove
FeatureCountsAndLists checks from pkg/sdkserver/sdkserver.go and pkg/sdkserver/localsdk.go
- PR 4 — SDK proto + codegen: Copy Counter/List RPC definitions from
beta.proto into sdk.proto (leaving beta.proto intact); run make gen-all-sdk-grpc so stable stubs now exist alongside beta stubs — must land before per-language PRs
- PR 5 (Go), PR 6 (C#), PR 7 (Rust), PR 8 (Unity) — Per-language SDK promotion: Add stable implementations; mark beta methods as deprecated in each language's beta file (do not delete yet — removal comes ~5 releases later via a follow-up issue)
- PR 9 — Config & docs:
features.go, Helm, Makefile, cloudbuild, feature-stages, counters-and-lists guide, upgrading.md SDK table, versionMap (can land any time after PRs 1–3 are merged)
Verification
make lint test-go passes with no CountsAndLists-gated skips
- E2E tests
TestCounters, TestLists, and all Counter/List allocation/autoscaler tests run without skip guards
- A GameServer with counters/lists defined can be created without setting the feature gate
- Setting
CountsAndLists=true or CountsAndLists=false in the feature gate string must not cause a parse error (covered by keeping the const in featureDefaults)
make gen-all-sdk-grpc produces no unexpected diff after the proto promotion
What does this feature do?
CountsAndListsprovides generic integer counter and string-list tracking on GameServers. It enables:GetCounter,UpdateCounter,GetList,UpdateList,AddListValue,RemoveListValue)All SDK methods for this feature live in the
betaSDK packages today (Go:sdks/go/beta.go, C#:sdks/csharp/sdk/Beta.cs, Rust:sdks/rust/src/beta.rs, Unity:sdks/unity/AgonesBetaSdk.cs).Current state: Beta (enabled by default since v1.41.0)
Acceptance Criteria / Tasks
FeatureCountsAndListsandCountsAndListsto confirm all usage sites (~378 occurrences today)Feature gate removal
FeatureCountsAndListsguards; fold to always-permitted:pkg/apis/agones/v1/gameserver.go— allow Counters/Lists fields unconditionallypkg/apis/agones/v1/fleet.go— allow Priorities unconditionallypkg/apis/agones/v1/gameserverset.go— allow Priorities unconditionallypkg/apis/autoscaling/v1/fleetautoscaler.go— allow CounterPolicy/ListPolicy unconditionallypkg/apis/allocation/v1/gameserverallocation.go— allow Counters/Lists/Priorities unconditionallypkg/gameserversets/controller.gopkg/fleets/controller.gopkg/gameserverallocations/allocator.go,allocation_cache.go,find.go,converter.gopkg/fleetautoscalers/fleetautoscalers.go— remove CounterPolicy/ListPolicy gatepkg/gameserversets/gameserversets.go— remove priority-sorting gatepkg/metrics/controller.go— remove counter metric gatepkg/sdkserver/sdkserver.goandpkg/sdkserver/localsdk.goSDK promotion
Per the Agones SDK stability policy: when a Beta SDK feature graduates to Stable at release X, the Beta surface is marked deprecated at release X and removed 5 releases later.
proto/sdk/beta/beta.protointoproto/sdk/sdk.proto— do not remove them frombeta.protoyetmake gen-all-sdk-grpcto regenerate all SDK artifacts (stable stubs now exist alongside beta stubs)[Stage:Beta]/[FeatureFlag:CountsAndLists]annotations in proto and SDK files to reflect stable statusbeta.protodefinitions and beta implementations ~5 releases after this graduationConfig & docs
pkg/util/runtime/features.go— MoveFeatureCountsAndListsto// Stable features(keep infeatureDefaultsastrue)install/helm/agones/defaultfeaturegates.yaml— Move to Stable sectionbuild/Makefile— Remove fromBETA_FEATURE_GATEScloudbuild.yaml— RemoveCountsAndLists=falsefrom the inverted e2e configsite/content/en/docs/Guides/feature-stages.md— Move row from Beta → Stable tablesite/content/en/docs/Guides/counters-and-lists.md— Remove Beta stage referencessite/content/en/docs/Installation/upgrading.md— Fill in the "Stable" column forGetCounter,UpdateCounter,GetList,UpdateList,AddListValue,RemoveListValuein the SDK API stability table with the graduation release versiontest/upgrade/versionMap.yaml— Add stable-gates entry for this releaseTests
FeatureCountsAndListsskip guards from e2e tests:TestCounters,TestLists,TestCounterAndListGameServerAllocation,TestFleetAggregatedCounterStatus,TestFleetAggregatedListStatus, and all Counter/List autoscaler tests intest/e2e/pkg/gameserversets/,pkg/fleetautoscalers/,pkg/gameserverallocations/Suggested PR breakdown
Given the size of this work, splitting across multiple PRs is strongly recommended:
FeatureCountsAndListschecks frompkg/sdkserver/sdkserver.goandpkg/sdkserver/localsdk.gobeta.protointosdk.proto(leavingbeta.protointact); runmake gen-all-sdk-grpcso stable stubs now exist alongside beta stubs — must land before per-language PRsfeatures.go, Helm, Makefile, cloudbuild, feature-stages, counters-and-lists guide, upgrading.md SDK table, versionMap (can land any time after PRs 1–3 are merged)Verification
make lint test-gopasses with noCountsAndLists-gated skipsTestCounters,TestLists, and all Counter/List allocation/autoscaler tests run without skip guardsCountsAndLists=trueorCountsAndLists=falsein the feature gate string must not cause a parse error (covered by keeping the const infeatureDefaults)make gen-all-sdk-grpcproduces no unexpected diff after the proto promotion