strimzi / kafka-kubernetes-config-provider

Kubernetes Configuration Provider for Apache Kafka®
Apache License 2.0
25 stars 12 forks source link

Should the namespace be optional? #6

Closed cosimomeli closed 2 years ago

cosimomeli commented 3 years ago

To share Kustomize manifests and to avoid intensive copy/pasting I would use a common Kafka Connect Connector configuration which has references to configmaps and secrets, but is namespace agnostic. I expect every namespace where it will be deployed has corresponding secrets and configmaps. The provider should so use the current namespace if not specified in the path (the / should be optional and default to serviceaccount namespace).

Does this make sense to you?

Thanks

scholzj commented 3 years ago

I'm not sure I follow. The secrets or config maps always belong to some namespace. The Kubernetes client might have a default namespace, but that might not be stable. So I do not think it should be optional.

cosimomeli commented 3 years ago

I found the fabric8 client already has a property kubernetes.tryNamespacePath described as: Configure client namespace from Kubernetes service account namespace path. But this feature is blocked by the provider rules.

scholzj commented 3 years ago

But the configuration provider is not used only with service accounts.