What happened: Upon upgrading to Agones 1.11, we are encountering the following error until the fleet scales: "error updating status for fleetautoscaler autoscaler-name: FleetAutoscaler.autoscaling.agones.dev \"our-name-here\" is invalid: status.lastScaleTime: Invalid value: \"null\": status.lastScaleTime in body must be of type string: \"null\""
What you expected to happen: We expected there to be no issue with the optional lastScaleTime field. Presumably this is expected to be nil until the fleet actually scales.
How to reproduce it (as minimally and precisely as possible): On Agones 1.11/Kubernetes 1.17. Warm up a fleet. Observe the above error until the fleet scales.
Anything else we need to know?:
Environment:
kubectl version): 1.17.14-gke.1600""error updating status for fleetautoscaler autoscaler-name: FleetAutoscaler.autoscaling.agones.dev \"our-name-here\" is invalid: status.lastScaleTime: Invalid value: \"null\": status.lastScaleTime in body must be of type string: \"null\""
["agones.dev/agones/pkg/fleetautoscalers.(*Controller).updateStatus\n\t/go/src/agones.dev/agones/pkg/fleetautoscalers/controller.go:271","agones.dev/agones/pkg/fleetautoscalers.(*Controller).syncFleetAutoscaler\n\t/go/src/agones.dev/agones/pkg/fleetautoscalers/controller.go:230","agones.dev/agones/pkg/util/workerqueue.(*WorkerQueue).processNextWorkItem\n\t/go/src/agones.dev/agones/pkg/util/workerqueue/workerqueue.go:153","agones.dev/agones/pkg/util/workerqueue.(*WorkerQueue).runWorker\n\t/go/src/agones.dev/agones/pkg/util/workerqueue/workerqueue.go:129","k8s.io/apimachinery/pkg/util/wait.JitterUntil.func1\n\t/go/src/agones.dev/agones/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:152","k8s.io/apimachinery/pkg/util/wait.JitterUntil\n\t/go/src/agones.dev/agones/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:153","k8s.io/apimachinery/pkg/util/wait.Until\n\t/go/src/agones.dev/agones/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:88","agones.dev/agones/pkg/util/workerqueue.(*WorkerQueue).run\n\t/go/src/agones.dev/agones/pkg/util/workerqueue/workerqueue.go:187","runtime.goexit\n\t/usr/local/go/src/runtime/asm_amd64.s:1373"]
LastScaleTime *metav1.Time field might benefit from the json:omitempty" tag.Doh! Sounds like I missed a nullable: true in the move to CRD v1 spec. I'll get a fix in today for the upcoming release.
Is it causing functionality issues, or just error messages?
Doh! Sounds like I missed a
nullable: truein the move to CRD v1 spec. I'll get a fix in today for the upcoming release.Is it causing functionality issues, or just error messages?
It seems to just be error messages, the fleets themselves appear to be scaling as expected so far after the upgrade.
That's something at least (all our e2e tests passed), but I'll still replicate and get that fixed. I've got a pretty good idea of what it is.
Aha! Needed to use kubectl apply on a yaml file to get it to fire. Fix incoming.
Most helpful comment
That's something at least (all our e2e tests passed), but I'll still replicate and get that fixed. I've got a pretty good idea of what it is.