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
Make replica controllers return current state. #1248
Conversation
@@ -104,6 +105,7 @@ func (rs *REST) List(selector labels.Selector) (runtime.Object, error) { | |||
filtered := []api.ReplicationController{} | |||
for _, controller := range controllers.Items { | |||
if selector.Matches(labels.Set(controller.Labels)) { | |||
rs.fillCurrentState(&controller) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
O(N * M) scaling.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, do we care? This is all pretty local.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we care at the moment, but stuff like this will keep us from scaling out of the 100's of pods and rep. controllers.
I'd prefer to get this in as-is. We can always improve the implementation later to make it watch-able and improve performance. Your call, though, about how perfect you want this to be before we submit. |
4734b28
to
e7625c8
Compare
Added the fillCurrentState behavior to the Watch function as well. (clearly changes don't actually trigger a watch event, so it's imperfect) |
LGTM. I'll let this go until we have @erictune's indexing thingy available. |
Make replica controllers return current state.
No description provided.