kubectl-status icon indicating copy to clipboard operation
kubectl-status copied to clipboard

Rollout order is misleading

Open bergerx opened this issue 2 years ago • 1 comments

When debugging a case with a Deployment I figured a case where the last ReplicaSet is not the one with the current pods.

I feel like this is the case (to-be-verified):

  • When the deployment controller creates a replicaset it stores a pod-template-hash annotation
  • Further updates on the deployment check these hashes and don't create a new ReplicaSet if the pod-template-hash for the new spec happens to match one of the existing ReplicaSets. It just scales it rather than creating a new one.

An example case: image

In this case, when we are looking at the status of a Deployment, the output becomes misleading as it prints the Rollouts with the time of their "creation order" rather than their actual "rollout order". Users expect to see "rollout order", but that data is not really available (stored) in a way that we can represent. It may be better just to add the current replica count next to the items in the rollout list like this: image

bergerx avatar Oct 03 '22 10:10 bergerx

If the last rollout has no existing instances, we should also highlight that with a possible rollback.

bergerx avatar Oct 04 '22 07:10 bergerx