Comments (3)
Apply Default
I like the approach. But you would want to ApplyDefaults()
here:
agones/pkg/gameservers/controller.go
Lines 389 to 396 in 4bb6731
Rather than where you specified, as enqueing only enque's the namespace/name
of the object, not the object itself - giving the best opportunity to get the latest Object at the time of syncronisation.
Everything else.
LGTM! I like the approach ๐๐ป
from agones.
Apply Default
I like the approach. But you would want to
ApplyDefaults()
here:
You're right. It might be nice if we had a helper function here that's basically "Get and Default" (for the case of inline changes like you just did for the migration controller), but agreed on the placement.
from agones.
A couple of proposed changes on this:
We should create a new policy that any new required CRD fields must be non-nullable, and have a default specified in the CRD itself. This means on install all custom resources will immediately have the new field with the default.
- This covers the case of a new controller requiring a field to be non-nil.
- Any new non-required fields may be marked nullable: true in the CRD. The expectation here is that a controller will not panic when a non-required field is nil.
- Reiterating from the main comment that any fields removed in the CRD on upgrade will immediately be pruned (deleted) from all objects by Kubernetes.
I donโt think we need to update the ApplyDefaults()
for Game Servers. As Game Servers are inherently ephemeral, there is no need to make changes to the Game Servers. By design we allow for skew between the controller and SDK version, and any field changes can be managed by the CRD itself.
- The Game Server state is maintained in memory, and is only written back to the kube-apiserver (
.GameServers().Update()
) during creation, starting, allocation, unhealthy states, and deletion. - Any Ready and Allocated Game Servers pods have the existing configuration (with the exception of any new non-nullable and defaulted CRD fields), and will work with the existing SDK image.
- A side note here that on a Fleet rollout after an Agones upgrade the Fleet will create a new Game Server Set at the new configuration, and all existing Game Servers will eventually be deleted and recreated on the new Game Server Set per the Fleetโs rollout strategy.
- As new Game Servers are created they will be at the new configuration. This includes all configuration relevant to rendering the Game Server, such as the version, the feature flags, and the
sdk-server
configuration.
And a few additional comments:
- The user can initiate a rollout of the Fleet via a label update to change over all Ready Game Servers to the new configuration.
- The Fleet spec and Game Server Set configuration should upgrade to the new configuration on user initiated Fleet rollout.
- On update, Fleet annotation should be updated to the most recent SDK version. This is for logging purposes.
- The Fleet status and Game Server Set status should reflect the new configuration regardless of whether or not a Fleet upgrade rollout has begun.
- For example, downgrading from an Agones version with CountsAndLists in Beta (on by default) to an Agones version with CountsAndLists in Alpha (off by default) will turn off the feature gate CountsAndLists. The Fleet will drop any status relating to CountsAndLists as the feature is no longer on. This is a clear indication to the user that the feature flag is turned off.
from agones.
Related Issues (20)
- Kubernetes-Native Service Load Balancer Support for GameServer
- Cron Job to restart the game server in-place
- Release 1.42.0 HOT 1
- Docs: Add Option for Extensions Components to use Host Network and Configure Ports HOT 3
- Update Supported Kubernetes to 1.28, 1.29, 1.30
- Allocator metrics missing in Agones 1.42.0
- Refactor metrics register exporter setup
- Unit test to check if metrics endpoint is scraping metrics
- [Agones Unity SDK] Add instructions to run tests using a Container Image(s) HOT 9
- Move Feature GKEAutopilotExtendedDurationPods to Beta HOT 6
- Migration from pterodactyl to agones | Egg like solution | More real steamserver examples
- Issue with Agones Game Server Connectivity Using Cilium CNI HOT 8
- Fleet autoscaler with "List" policy throws an error if configured with a fleet with no replicas HOT 3
- CORS enabled on ping service
- Upgrade to Golang 1.22.6 HOT 2
- Extend Webhook autoscaler to send fleet metadata with the request HOT 4
- Add chain ID status to fleetautoscaler event logger
- FleetAutoscaler with Counter policy trying to scale Fleet to negative replicas count HOT 2
- Add logging to webhook failure and schedule parsing errors for Schedule/Chain policies
- Game servers are having some delays until getting external IPs from agones SDK
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from agones.