Skip to content
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

Find portalIP automatically while updating a service #5907

Closed
hurf opened this issue Mar 25, 2015 · 9 comments
Closed

Find portalIP automatically while updating a service #5907

hurf opened this issue Mar 25, 2015 · 9 comments
Assignees
Labels
sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery.

Comments

@hurf
Copy link
Contributor

hurf commented Mar 25, 2015

When I tried to update a service to change its port. Kubectl said spec.portalIp: invalid error ""

I viewed detailed information of the service and added portalIp with the same value as current service in the template and solved the problem.

But since the portalIp is automatically allocated when the service is created. Why users must provide portalIp explicitly while updating? And also the portalIp can not be changed while updating.

@bgrant0607
Copy link
Member

Please see https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/api-conventions.md. PUT doesn't support partial updates. In general, you need to do a GET, change just what you want to update, and then PUT.

You could try PATCH, which was recently added. You may also be interested in a new merge strategy being implemented -- see #6027.

@bgrant0607 bgrant0607 added sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. and removed team/cluster labels Apr 1, 2015
@bgrant0607 bgrant0607 self-assigned this Apr 1, 2015
@bgrant0607
Copy link
Member

And, yes, the description string on the field should say that the field "cannot be updated" -- @thockin.

@hurf
Copy link
Contributor Author

hurf commented Apr 1, 2015

@bgrant0607 - Thanks Brian, I'm not asking to allow portalIp be changed while updating, but allow users not giving portalIp explicitly in the template. I write a small patch to do so and will submit it soon.

@bgrant0607
Copy link
Member

@hurf Thank you for offering to make a change, but the change will not be accepted. If you just want to update certain fields in the object, please use PATCH.

@bgrant0607
Copy link
Member

@thockin
Copy link
Member

thockin commented Apr 1, 2015

The description does say "cannot be updated".

@thockin thockin closed this as completed Apr 1, 2015
@bgrant0607
Copy link
Member

So it does.

@hurf
Copy link
Contributor Author

hurf commented Apr 2, 2015

@thockin @bgrant0607 - Sorry for the description mentioned "can not be updated" and not expressed myself clearly.

What I want to say is when I'm creating the pod, I didn't provide the portalIP in the template. But when I want to update the pod, I'm not going to change portalIP and it is not allowed to change it, why should I address it explicitly? I just feel inconvenient about this.

Anyway thanks you can discuss with this issue.

@bgrant0607
Copy link
Member

@hurf I understand. The solution underway is #1702.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants