GoogleCloudPlatform / flink-on-k8s-operator

[DEPRECATED] Kubernetes operator for managing the lifecycle of Apache Flink and Beam applications.
Apache License 2.0
659 stars 265 forks source link

Generated pods have an invalid metadata.labels #402

Closed syucream closed 3 years ago

syucream commented 3 years ago

I recently applied the update feature https://github.com/GoogleCloudPlatform/flink-on-k8s-operator/pull/245 then got such an error:

Pod “xxx-jobmanager-0” is invalid: metadata.labels: Invalid value: “xxx-jobmanager-755997f66b”: must be no more than 63 characters

It seems to be caused by controller-revision-hash=xxx-jobmanager-6588f8cbcb label of a pod. Any good resolution, for e.g. changing the label name, just disabling the update feature for now? Or don't I have any workaround aside from making the name shorter?

syucream commented 3 years ago

Or any chance to change logic which generate the label?

elanv commented 3 years ago

In “xxx-jobmanager-755997f66b”, the prefix "xxx" is the name of FlinkCluster. The name seems to be quite long. As a workaround, once possible, it would be better to shorten the name of FlinkCluster.

syucream commented 3 years ago

That should be the easiest workaround. For a long term, can we get another good way? I feel -jobmanager-755997f66b suffix part is also long.

syucream commented 3 years ago

I found the same issue https://github.com/kubernetes/kubernetes/issues/79337

syucream commented 3 years ago

That should be a known issue which we don't have any other reasonable resolution ... I will just shorten my cluster name. Thanks.