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

fix cluster scoped self-link #44462

Merged
merged 1 commit into from
Apr 25, 2017

Conversation

deads2k
Copy link
Contributor

@deads2k deads2k commented Apr 13, 2017

Might fix #37622, definitely fixes the cluster-scoped resource problem. Looks like it was just a typo when compared against https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apiserver/pkg/endpoints/installer.go#L451

@adohe @DirectXMan12

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Apr 13, 2017
@k8s-reviewable
Copy link

This change is Reviewable

@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: deads2k

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

@k8s-github-robot k8s-github-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. release-note-label-needed labels Apr 13, 2017
@CaoShuFeng
Copy link
Contributor

There is a related change: #44489

@krousey
Copy link
Contributor

krousey commented Apr 18, 2017

Wouldn't it be better just to make https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apiserver/pkg/endpoints/handlers/namer.go#L93 use path.Join instead of string concatenation?

@DirectXMan12
Copy link
Contributor

@deads2k
Copy link
Contributor Author

deads2k commented Apr 21, 2017

Wouldn't it be better just to make https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apiserver/pkg/endpoints/handlers/namer.go#L93 use path.Join instead of string concatenation?

I seem to recall some kind of performance problem with path.Join in hot paths and this is called for every resource from the server.

@liggitt @derekwaynecarr am I remembering correctly?

@liggitt
Copy link
Member

liggitt commented Apr 21, 2017

path.Join is really bad, performance wise

@liggitt
Copy link
Member

liggitt commented Apr 22, 2017

see #16384 (comment)

@liggitt
Copy link
Member

liggitt commented Apr 22, 2017

LGTM, test would be good

@CaoShuFeng
Copy link
Contributor

a related change:
#44489

@deads2k deads2k added lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note. and removed release-note-label-needed labels Apr 25, 2017
@k8s-github-robot k8s-github-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Apr 25, 2017
@deads2k
Copy link
Contributor Author

deads2k commented Apr 25, 2017

LGTM, test would be good

test added. tagging.

@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 42477, 44462)

@k8s-github-robot k8s-github-robot merged commit cd380b5 into kubernetes:master Apr 25, 2017
@cberner
Copy link

cberner commented Apr 28, 2017

Will this be in the 1.6.3 release?

@deads2k deads2k added this to the v1.6 milestone Apr 28, 2017
k8s-github-robot pushed a commit that referenced this pull request Apr 28, 2017
Automatic merge from submit-queue

Fix PathPrefix for subresources

before this change:
$ curl -s http://172.16.116.128:8080/api/v1/nodes/kubenet-02/status | grep selfLink
    "selfLink": "/api/v1/nodes/{name}/status/kubenet-02/status",
after this change:
$ curl -s http://172.16.116.128:8080/api/v1/nodes/kubenet-02/status | grep selfLink
    "selfLink": "/api/v1/nodes/kubenet-02/status",

related to:
#44462

**Release note**:

```NONE
```
@k8s-cherrypick-bot
Copy link

Commit found in the "release-1.6" branch appears to be this PR. Removing the "cherrypick-candidate" label. If this is an error find help to get your PR picked.

@deads2k deads2k deleted the server-21-selflink branch August 3, 2017 20:08
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-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

third party resources api selflinks missing forward slash