metadata.Generation field is "a sequence number representing a specific generation of the desired state."
We pass desired state information via labels and annotations for crd objects. Using annotations to pass desired information is fairly common in Kubernetes. We are also using labels to pass desired state for CRDs. For example, I have defined a crd for database objects. For a database crd, my controller creates a statefulset and service. I would like to pass any labels on my crd object to these offshot statefulset and service.
Currently metadata.Generation field for crds only changes when spec changes. #55168
/kind feature
/sig api-machinery
/area custom-resources
metadata.Generationfield is "a sequence number representing a specific generation of the desired state."We pass desired state information via labels and annotations for crd objects. Using
annotationsto pass desired information is fairly common in Kubernetes. We are also using labels to pass desired state for CRDs. For example, I have defined a crd for database objects. For a database crd, my controller creates a statefulset and service. I would like to pass any labels on my crd object to these offshot statefulset and service.Currently
metadata.Generationfield for crds only changes whenspecchanges. #55168/kind feature
/sig api-machinery
/area custom-resources