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 HostAliases' json keys to be hostAlias instead of hostMapping to reflect actual feature name #47512

Merged

Conversation

evie404
Copy link
Contributor

@evie404 evie404 commented Jun 14, 2017

What this PR does / why we need it: a rename was introduce during the middle of #44641 to change from hostMappings to hostAliases. the Go structs were updated, but I neglected to update the json keys. They should be in sync.

Special notes for your reviewer: I messed up. This is an API change. I hope this is still ok to be in the 1.7 release.

Release note:

HostAliases is now parsed with `hostAliases` json keys to be in line with the feature's name.

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

Hi @rickypai. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with @k8s-bot ok to test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jun 14, 2017
@k8s-github-robot k8s-github-robot added kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Jun 14, 2017
@evie404
Copy link
Contributor Author

evie404 commented Jun 14, 2017

@kubernetes/kubernetes-release-managers this is an API change

@evie404
Copy link
Contributor Author

evie404 commented Jun 14, 2017

/assign @thockin

@evie404 evie404 changed the title update HostAliases' json keys to be hostAlias instead of hostMapping fix HostAliases' json keys to be hostAlias instead of hostMapping to reflect actual feature name Jun 15, 2017
@@ -2,7 +2,7 @@
"swagger": "2.0",
"info": {
"title": "Kubernetes",
"version": "v1.8.0"
"version": "v1.4.0"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this changing? It shouldn't.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure. i ran this on a new development environment. will manually remove the change

@@ -2,7 +2,7 @@
"swagger": "2.0",
"info": {
"title": "Generic API Server",
"version": "v1.8.0"
"version": "v1.4.0"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

@nikhiljindal
Copy link
Contributor

@k8s-bot ok to test.

Keeping actual changes and autogenerated changes in different commits makes it easier to review.
This is an API change so it will break existing users.

Will let Tim do the review.

@nikhiljindal nikhiljindal removed their assignment Jun 15, 2017
@@ -2519,7 +2519,7 @@ type PodSpec struct {
// +optional
// +patchMergeKey=IP
// +patchStrategy=merge
HostAliases []HostAlias `json:"hostMappings,omitempty" patchStrategy:"merge" patchMergeKey:"IP" protobuf:"bytes,23,rep,name=hostMappings"`
HostAliases []HostAlias `json:"hostAliases,omitempty" patchStrategy:"merge" patchMergeKey:"IP" protobuf:"bytes,23,rep,name=hostAliases"`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should the patch merge key should be lowercase ip as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for catching this also!

@evie404 evie404 force-pushed the rpai/fix_hostalias_json_key branch 3 times, most recently from 7322aac to 0ade821 Compare June 20, 2017 18:40
@k8s-ci-robot
Copy link
Contributor

Thanks for your pull request. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please follow instructions at https://github.com/kubernetes/kubernetes/wiki/CLA-FAQ to sign the CLA.

It may take a couple minutes for the CLA signature to be fully registered; after that, please reply here with a new comment and we'll verify. Thanks.


  • If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
  • If you signed the CLA as a corporation, please sign in with your organization's credentials at https://identity.linuxfoundation.org/projects/cncf to be authorized.
  • If you have done the above and are still having issues with the CLA being reported as unsigned, please email the CNCF helpdesk: [email protected]

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@k8s-ci-robot k8s-ci-robot added cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. and removed cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jun 20, 2017
@k8s-github-robot k8s-github-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 20, 2017
@evie404 evie404 force-pushed the rpai/fix_hostalias_json_key branch from 0ade821 to 59b2889 Compare June 20, 2017 19:25
@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Jun 20, 2017
@evie404 evie404 force-pushed the rpai/fix_hostalias_json_key branch from 59b2889 to 2f61d69 Compare June 20, 2017 20:22
@k8s-github-robot k8s-github-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 20, 2017
@evie404 evie404 force-pushed the rpai/fix_hostalias_json_key branch from 2f61d69 to 7e11975 Compare June 20, 2017 20:27
@cblecker
Copy link
Member

@k8s-bot ok to test

@dchen1107 dchen1107 added this to the v1.7 milestone Jun 20, 2017
@evie404
Copy link
Contributor Author

evie404 commented Jun 20, 2017

thank you!

@evie404
Copy link
Contributor Author

evie404 commented Jun 20, 2017

/test pull-kubernetes-federation-e2e-gce

@evie404
Copy link
Contributor Author

evie404 commented Jun 21, 2017

@erictune I think you need to explicitly /lgtm this PR or else it won't be picked up by submit queue.

thanks a lot!

@dchen1107
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 Jun 21, 2017
@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dchen1107, rickypai

Associated issue: 44641

The full list of commands accepted by this bot can be found here.

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 the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 21, 2017
@evie404
Copy link
Contributor Author

evie404 commented Jun 21, 2017

recent merge introduced conficts in the generated protobuf files. rebased and regenerating the files.

@k8s-github-robot k8s-github-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 21, 2017
@evie404 evie404 force-pushed the rpai/fix_hostalias_json_key branch from 7e11975 to 797dc10 Compare June 21, 2017 23:40
@caesarxuchao caesarxuchao added lgtm "Looks good to me", indicates that a PR is ready to be merged. and removed lgtm "Looks good to me", indicates that a PR is ready to be merged. labels Jun 21, 2017
@caesarxuchao
Copy link
Member

Thanks for the rebasing. lgtm.

@k8s-github-robot k8s-github-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 22, 2017
@smarterclayton
Copy link
Contributor

@caesarxuchao we should probably open an issue in 1.8 to track API changes and make sure they conform to conventions.

@caesarxuchao
Copy link
Member

we should probably open an issue in 1.8 to track API changes and make sure they conform to conventions.

@mbohlool i heard you had started an API convention checker?

@evie404
Copy link
Contributor Author

evie404 commented Jun 22, 2017

API convention checker would be nice. i was also thinking requiring e2e test for every API change to mitigate mistakes like this

@caesarxuchao
Copy link
Member

Adding queue/blocks-others because it's blocking lifting code freeze.

@evie404
Copy link
Contributor Author

evie404 commented Jun 22, 2017

thanks and sorry that this is blocking folks :(

@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 42252, 42251, 42249, 47512, 47887)

@k8s-github-robot k8s-github-robot merged commit 4d1379c into kubernetes:master Jun 22, 2017
@evie404 evie404 deleted the rpai/fix_hostalias_json_key branch June 22, 2017 05:26
@evie404
Copy link
Contributor Author

evie404 commented Jun 22, 2017

yay!

@mbohlool
Copy link
Contributor

we should probably open an issue in 1.8 to track API changes and make sure they conform to conventions.
@mbohlool i heard you had started an API convention checker?

#44005

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. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API 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.