Skip to content

Clean up handling of target namespaces #302

Closed
@metacosm

Description

@metacosm

We need to settle how we configure which namespace(s) a controller targets and how we configure this. Right now, there are conflicting versions, in particular when it comes to interpreting what no passed namespaces means. ControllerConfiguration assumes that the current namespace is the target if the controller doesn't specify any, using the WATCH_ALL_NAMESPACES_MARKER to decide whether the controller watches all namespaces, while other parts of the code assume that if target namespaces is empty then that means that the controller should watch all namespaces.

That historic behavior is problematic, in my opinion, because the default behavior for a controller should be to watch the namespace it is deployed on as it might not have privileges outside of that particular namespace.

We should also remove all the register methods on Operator apart from this one which uses the controller's configuration to appropriately register the controller accordingly.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions