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

Add PATCH to supported list of proxy subresource verbs #44929

Merged
merged 1 commit into from
Apr 27, 2017

Conversation

liggitt
Copy link
Member

@liggitt liggitt commented Apr 25, 2017

Follow up to #41421 for the proxy subresources

The proxy subresource APIs for nodes, services, and pods now support the HTTP PATCH method.

@k8s-reviewable
Copy link

This change is Reviewable

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Apr 25, 2017
@k8s-github-robot k8s-github-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Apr 25, 2017
@wojtek-t
Copy link
Member

@liggitt - it seems you also regenerate some docs.

@deads2k
Copy link
Contributor

deads2k commented Apr 26, 2017

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 26, 2017
@k8s-github-robot k8s-github-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 26, 2017
@k8s-github-robot k8s-github-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Apr 27, 2017
@liggitt
Copy link
Member Author

liggitt commented Apr 27, 2017

regenerated swagger

@liggitt liggitt added lgtm "Looks good to me", indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Apr 27, 2017
@wojtek-t
Copy link
Member

It seems that some more things need regeneration:

I0426 22:36:45.984] /go/src/k8s.io/kubernetes/docs/api-reference is out of date. Please run hack/update-api-reference-docs.sh
I0426 22:36:45.984] FAILED hack/make-rules/../../hack/verify-api-reference-docs.sh 97s

@k8s-github-robot k8s-github-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Apr 27, 2017
@wojtek-t
Copy link
Member

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 27, 2017
@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: deads2k, liggitt, wojtek-t

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@liggitt liggitt added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Apr 27, 2017
@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 41106, 44346, 44929, 44979, 45027)

@k8s-github-robot k8s-github-robot merged commit 6251ff4 into kubernetes:master Apr 27, 2017
@liggitt liggitt deleted the proxy-subresource-patch branch April 27, 2017 19:35
@rmanak
Copy link

rmanak commented Apr 28, 2017

I am still getting the "MethodNotAllowed" error when sending a PATCH request to the proxy subresource. Here is an example:

$~>curl http://localhost:8001/api/v1/namespaces/default/services/rel-aida-ima:80/proxy/live -X GET
{
  "status": "OK"
}
$~> curl http://localhost:8001/api/v1/namespaces/default/services/rel-aida-ima:80/proxy/live -X POST
{"status": "ERR", "error": {"message": "The method is not allowed for the requested URL.", "code": 405}}

(^^^ The error message is coming from the service, so it reaches the service)

$~>curl http://localhost:8001/api/v1/namespaces/default/services/rel-aida-ima:80/proxy/live -X PATCH
{
  "kind": "Status",
  "apiVersion": "v1",
  "metadata": {},
  "status": "Failure",
  "message": "the server does not allow this method on the requested resource",
  "reason": "MethodNotAllowed",
  "details": {},
  "code": 405
}

^^^ never reached the server!

Also, --reject-methods flag doesn't do anything, I tried all combination, didn't help.

Here is kubectl version: (I compiled it after seeing this merge)

$~/kubernetes/_output/bin> ./kubectl version
Client Version: version.Info{Major:"1", Minor:"7+", GitVersion:"v1.7.0-alpha.2.422+09747e6bee78fb", GitCommit:"09747e6bee78fb8b71356309d6ede84142aee9eb", GitTreeState:"clean", BuildDate:"2017-04-28T01:03:50Z", GoVersion:"go1.8.1", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"5", GitVersion:"v1.5.6", GitCommit:"114f8911f9597be669a747ab72787e0bd74c9359", GitTreeState:"clean", BuildDate:"2017-03-28T13:36:31Z", GoVersion:"go1.7.4", Compiler:"gc", Platform:"linux/amd64"}

@liggitt
Copy link
Member Author

liggitt commented Apr 28, 2017

You are still running against a v1.5.6 server. This fix was server side

@rmanak
Copy link

rmanak commented Apr 29, 2017

On which version of the server this would be available?

@liggitt
Copy link
Member Author

liggitt commented Apr 29, 2017

1.7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants