Fleet autoscaler threads maintain state#4277
Conversation
This is necessary refactoring pre-work for agones-dev#4080. We need somewhere to store the wasm plugin when loaded for each fleet autoscaler CRD instance that is defined. This change both provides that arbitrary state as part of `fastThread` (which now means any new autoscaling ability can have state! Someone want to do predictive math over time?), and also having a ctx pass through since anything with state will likely need to be closed (the wasm plugins need it) at shutdown time. Work on agones-dev#4080
|
Build Failed 😭 Build Id: 6f7f1a4f-eff8-49cf-bcd4-f8912d4041f7 Status: FAILURE To get permission to view the Cloud Build view, join the agones-discuss Google Group. |
|
flake - autopilot |
|
/gcbrun |
|
Build Failed 😭 Build Id: 66082f3b-5a00-4136-84e4-ede7e6b06a90 Status: FAILURE To get permission to view the Cloud Build view, join the agones-discuss Google Group. |
I'll look into this, seems legit. |
|
Ooh fun, this is a flake I think's been here for quite a while, but I can definitely fix it. |
|
Build Succeeded 🥳 Build Id: 87d9b130-6249-4324-86ac-0896c0427970 The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version: |
| c.baseLogger = runtime.NewLoggerWithType(c) | ||
| c.workerqueue = workerqueue.NewWorkerQueueWithRateLimiter(c.syncFleetAutoscaler, c.baseLogger, logfields.FleetAutoscalerKey, autoscaling.GroupName+".FleetAutoscalerController", workerqueue.FastRateLimiter(3*time.Second)) | ||
| health.AddLivenessCheck("fleetautoscaler-workerqueue", healthcheck.Check(c.workerqueue.Healthy)) | ||
| health.AddLivenessCheck("fleetautoscaler-workerqueue", c.workerqueue.Healthy) |
There was a problem hiding this comment.
A small cleanup I slipped in
|
Build Failed 😭 Build Id: 247efc9f-8667-4e79-8438-2fe39296940a Status: FAILURE To get permission to view the Cloud Build view, join the agones-discuss Google Group. |
|
Seems that the test was going without error but it reached a timeout of 10mins, not sure why 🤔 /gcbrun |
(I often post flakes in here, so if you get one, you can search the repo to see how often it happens) |
|
Build Succeeded 🥳 Build Id: 2209431c-823c-4c67-bc32-1e953d17659d The following development artifacts have been built, and will exist for the next 30 days:
A preview of the website (the last 30 builds are retained): To install this version: |
* Fleet autoscaler threads maintain state This is necessary refactoring pre-work for agones-dev#4080. We need somewhere to store the wasm plugin when loaded for each fleet autoscaler CRD instance that is defined. This change both provides that arbitrary state as part of `fastThread` (which now means any new autoscaling ability can have state! Someone want to do predictive math over time?), and also having a ctx pass through since anything with state will likely need to be closed (the wasm plugins need it) at shutdown time. Work on agones-dev#4080 * Fix for flaky unit test
What type of PR is this?
/kind feature
What this PR does / Why we need it:
This is necessary refactoring pre-work for #4080.
We need somewhere to store the wasm plugin when loaded for each fleet autoscaler CRD instance that is defined. This change both provides that arbitrary state as part of
fastThread(which now means any new autoscaling ability can have state! Someone want to do predictive math over time?), and also having a ctx pass through since anything with state will likely need to be closed (the wasm plugins need it) at shutdown time.Which issue(s) this PR fixes:
Work on #4080
Special notes for your reviewer:
N/A