kcp icon indicating copy to clipboard operation
kcp copied to clipboard

Follow-up APIBindings: have more speaking names of CRDs in shadow namespace

Open sttts opened this issue 3 years ago • 5 comments

Follow-up of https://github.com/kcp-dev/kcp/issues/417.

Problem: the names of CRDs in the system:bound-crds workspace have cryptic names. For debugging it would be very helpful to have the resource and group name plus the uid there.

Also see https://github.com/kcp-dev/kcp/pull/702#discussion_r830045834 for details.

sttts avatar Apr 06 '22 11:04 sttts

cc @ncdc

sttts avatar Apr 06 '22 11:04 sttts

What about having that data in labels or annotations? Or you think a more meaningful name is needed?

ncdc avatar Apr 06 '22 12:04 ncdc

I think name is better as it shows up in controller logs for example. This is not about technically being able to find the objects, but rather as a human to understand what these 300 CRDs mean there.

sttts avatar Apr 06 '22 13:04 sttts

Makes sense. Will resource+group+uid fit within the maximum name length limit?

ncdc avatar Apr 06 '22 13:04 ncdc

Good question. Probably 63 chars for names. And that can be exhausted for a resource name alone I guess. But something like resource.group-<8-alpha-numeric-chars> is probably good enough. We can have a deterministic shortening of resource.group in case it's getting too long.

sttts avatar Apr 06 '22 13:04 sttts