-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support adding new watches dynamically at runtime #540
Comments
cc @vincepri |
We're trending towards not adding more injectors when they're not strictly needed by internals -- most cases are more obviously solved by structuring your application so that you can pass them to your reconcilers directly (like we do in KB v2). Thus, I'd prefer to see a solution to this that makes it possible to get a handle to the underlying controller with the builder somehow. If we can't figure out how to do that cleanly, an injector is fine, but I'd prefer the more direct approach. |
Ok, I'll do some brainstorming to see what I can come up with. |
@DirectXMan12 what if we modify |
Or expose a |
+1 On having either a method to get the controller or |
I'd prefer not |
I don't think we'd want 2 different ways to complete/build - 1 that returns a controller, and 1 that doesn't - would we? |
Summarizing our discussion from Slack yesterday (https://kubernetes.slack.com/archives/CAR30FCJZ/p1564433195123400), we're going to un-deprecate |
This feature was added before (and requested in #246), but the updated Manager & Builder patterns don't support this any more because they take care of creating a Controller instead of having user-written code do it, and the Controller isn't accessible to your reconciler.
There was a discussion about this in Slack (https://kubernetes.slack.com/archives/CAR30FCJZ/p1561759175084100). I'm thinking we could modify the inject package like so (names TBD - I know they don't follow the current pattern 100% but we need to scope down the Controller interface to avoid import cycles):
Do you think something like this would work @DirectXMan12?
The text was updated successfully, but these errors were encountered: