-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Document that PUT doesn't support partial updates #3112
Comments
similar issue happens when creating a service:
POST fails with :
|
Internal names are not converted to external during rendering of the status message. Name is the newer api version field name for what used to be called id |
@smarterclayton but the input json contains "id", so why does it fail in the first place? |
I'm referring to the first comment, where update failed because you omitted the ID of the service you were updating |
Update requires the full resource to be specified. GET the resource, modify the fields you want to change, and do a PUT. |
Using #3084 for the field name conversion problem. |
As mentioned, PUT should not accept partial updates - PATCH should, and the issue for that is #4578. This is documented in api-conventions.md: "Otherwise, PUT expects the whole object to be specified." Where else does it need to be documented? |
sending the following json to update a service:
"{"apiVersion":"v1beta1","port":6380,"containerPort":6379}"
fails with 422 and message: "service "" is invalid: name: required value ''"
It's not clear from the message what is exactly the problem.
is the "name" field missing? isn't it called "id" at the moment?
if yes, another issue (#3085) points on the fact that including the id fails the request with another error.
The text was updated successfully, but these errors were encountered: