Skip to content

resources: Align models with upstream Agones structs#25

Merged
markmandel merged 2 commits into
agones-dev:mainfrom
NAME-ASHWANIYADAV:fix/resource-model-alignment
Jun 26, 2026
Merged

resources: Align models with upstream Agones structs#25
markmandel merged 2 commits into
agones-dev:mainfrom
NAME-ASHWANIYADAV:fix/resource-model-alignment

Conversation

@NAME-ASHWANIYADAV

Copy link
Copy Markdown
Contributor

Type of change

  • 🐛 Bug fix
  • 🚀 New feature / enhancement
  • 📖 Documentation
  • 🧹 Refactoring / cleanup
  • ⚙️ CI / tooling
  • ⚠️ Breaking change

What this PR does

Aligns the GameServer, Fleet, and FleetAutoscaler TypeScript models with the upstream Agones Go structures. This ensures that the plugin correctly parses and displays all available data from the Kubernetes API.

Specific alignments include:

  • GameServer: Added support for eviction (with correct default Never), addresses, and reservedUntil fields.
  • Fleet: Added support for allocationOverflow, priorities, counters, and lists.
  • FleetAutoscaler: Added support for wasm policies and corrected the schedule.activePeriod cron field from schedule to startCron.
  • UI Fixes: Updated Overview.tsx to include Reserved in STATE_ORDER and updated the FleetAutoscaler Detail view to correctly reference the fixed startCron field.

Screenshots / recordings

Test plan

Automated checks

  • npm ci
  • npm run build
  • npm run tsc
  • npm run lint
  • npm run format -- --check
  • npm run test

Manual verification

  • Tested in Headlamp against a cluster with Agones installed

Manually verified that the UI renders without errors when encountering the newly supported fields, and confirmed that the models successfully map data from the Agones CRDs.

RBAC considerations

N/A - No new Kubernetes permissions are required.

Notes for reviewers

This PR focuses strictly on aligning the type models. Comprehensive unit tests for these resources, along with the necessary Vitest testing infrastructure, are included in a follow-up PR (fix/test-infra-gameserver) to keep this review focused and atomic.

Signed-off-by: ashwani yadav <22ashwaniyadav@gmail.com>
@markmandel

Copy link
Copy Markdown
Member

Maybe a silly question - what should I be seeing in the UI that I wasn't seeing before? Anything? Or is this just purely a backend update?

@markmandel

Copy link
Copy Markdown
Member

Looking at the CRD structure - looks okay, just wanted to make sure I wasn't missing anything on the UX side. Otherwise LGTM.

@markmandel markmandel merged commit be714dc into agones-dev:main Jun 26, 2026
2 checks passed
@NAME-ASHWANIYADAV

Copy link
Copy Markdown
Contributor Author

thank you !! @markmandel

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.

2 participants