{"action":"created","comment":{"url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments/186964012","pull_request_review_id":118645309,"id":186964012,"diff_hunk":"@@ -53,6 +53,27 @@ func ValidateCustomResourceDefinitionUpdate(obj, oldObj *apiextensions.CustomRes\n \tallErrs := genericvalidation.ValidateObjectMetaUpdate(&obj.ObjectMeta, &oldObj.ObjectMeta, field.NewPath(\"metadata\"))\n \tallErrs = append(allErrs, ValidateCustomResourceDefinitionSpecUpdate(&obj.Spec, &oldObj.Spec, apiextensions.IsCRDConditionTrue(oldObj, apiextensions.Established), field.NewPath(\"spec\"))...)\n \tallErrs = append(allErrs, ValidateCustomResourceDefinitionStatus(&obj.Status, field.NewPath(\"status\"))...)\n+\tallErrs = append(allErrs, ValidateCustomResourceDefinitionStoredVersions(obj.Status.StoredVersions, obj.Spec.Versions, field.NewPath(\"status\").Child(\"storedVersions\"))...)\n+\treturn allErrs\n+}\n+\n+// ValidateCustomResourceDefinitionStoredVersions statically validates\n+func ValidateCustomResourceDefinitionStoredVersions(storedVersions []string, versions []apiextensions.CustomResourceDefinitionVersion, fldPath *field.Path) field.ErrorList {\n+\tallErrs := field.ErrorList{}\n+\tstoredVersionsMap := map[string]int{}","path":"staging/src/k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/validation/validation.go","position":11,"original_position":11,"commit_id":"c93b28a02d97ad096334a605fa3ed3333ed06200","original_commit_id":"c93b28a02d97ad096334a605fa3ed3333ed06200","user":{"login":"sttts","id":730123,"avatar_url":"https://avatars0.githubusercontent.com/u/730123?v=4","gravatar_id":"","url":"https://api.github.com/users/sttts","html_url":"https://github.com/sttts","followers_url":"https://api.github.com/users/sttts/followers","following_url":"https://api.github.com/users/sttts/following{/other_user}","gists_url":"https://api.github.com/users/sttts/gists{/gist_id}","starred_url":"https://api.github.com/users/sttts/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sttts/subscriptions","organizations_url":"https://api.github.com/users/sttts/orgs","repos_url":"https://api.github.com/users/sttts/repos","events_url":"https://api.github.com/users/sttts/events{/privacy}","received_events_url":"https://api.github.com/users/sttts/received_events","type":"User","site_admin":false},"body":"right, missed that one.","created_at":"2018-05-09T08:13:25Z","updated_at":"2018-05-09T08:13:25Z","html_url":"https://github.com/kubernetes/kubernetes/pull/63518#discussion_r186964012","pull_request_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments/186964012"},"html":{"href":"https://github.com/kubernetes/kubernetes/pull/63518#discussion_r186964012"},"pull_request":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518"}},"in_reply_to_id":186681499},"pull_request":{"url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518","id":186494746,"html_url":"https://github.com/kubernetes/kubernetes/pull/63518","diff_url":"https://github.com/kubernetes/kubernetes/pull/63518.diff","patch_url":"https://github.com/kubernetes/kubernetes/pull/63518.patch","issue_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/63518","number":63518,"state":"open","locked":false,"title":"CRD Versioning with no-op Conversion","user":{"login":"mbohlool","id":1613024,"avatar_url":"https://avatars3.githubusercontent.com/u/1613024?v=4","gravatar_id":"","url":"https://api.github.com/users/mbohlool","html_url":"https://github.com/mbohlool","followers_url":"https://api.github.com/users/mbohlool/followers","following_url":"https://api.github.com/users/mbohlool/following{/other_user}","gists_url":"https://api.github.com/users/mbohlool/gists{/gist_id}","starred_url":"https://api.github.com/users/mbohlool/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbohlool/subscriptions","organizations_url":"https://api.github.com/users/mbohlool/orgs","repos_url":"https://api.github.com/users/mbohlool/repos","events_url":"https://api.github.com/users/mbohlool/events{/privacy}","received_events_url":"https://api.github.com/users/mbohlool/received_events","type":"User","site_admin":false},"body":"Implements Custom Resource Definition versioning according to [design doc](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/api-machinery/customresources-versioning.md).","created_at":"2018-05-07T23:58:15Z","updated_at":"2018-05-09T08:13:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"28ab4da004d62990e5403baac7f5ac9e13f31a4d","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":477397086,"url":"https://api.github.com/repos/kubernetes/kubernetes/labels/cncf-cla:%20yes","name":"cncf-cla: yes","color":"bfe5bf","default":false},{"id":680152113,"url":"https://api.github.com/repos/kubernetes/kubernetes/labels/do-not-merge/release-note-label-needed","name":"do-not-merge/release-note-label-needed","color":"e11d21","default":false},{"id":240247879,"url":"https://api.github.com/repos/kubernetes/kubernetes/labels/needs-rebase","name":"needs-rebase","color":"BDBDBD","default":false},{"id":253451093,"url":"https://api.github.com/repos/kubernetes/kubernetes/labels/size/XXL","name":"size/XXL","color":"ee0000","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518/commits","review_comments_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518/comments","review_comment_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/63518/comments","statuses_url":"https://api.github.com/repos/kubernetes/kubernetes/statuses/c93b28a02d97ad096334a605fa3ed3333ed06200","head":{"label":"mbohlool:new_crd_versioning","ref":"new_crd_versioning","sha":"c93b28a02d97ad096334a605fa3ed3333ed06200","user":{"login":"mbohlool","id":1613024,"avatar_url":"https://avatars3.githubusercontent.com/u/1613024?v=4","gravatar_id":"","url":"https://api.github.com/users/mbohlool","html_url":"https://github.com/mbohlool","followers_url":"https://api.github.com/users/mbohlool/followers","following_url":"https://api.github.com/users/mbohlool/following{/other_user}","gists_url":"https://api.github.com/users/mbohlool/gists{/gist_id}","starred_url":"https://api.github.com/users/mbohlool/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbohlool/subscriptions","organizations_url":"https://api.github.com/users/mbohlool/orgs","repos_url":"https://api.github.com/users/mbohlool/repos","events_url":"https://api.github.com/users/mbohlool/events{/privacy}","received_events_url":"https://api.github.com/users/mbohlool/received_events","type":"User","site_admin":false},"repo":{"id":58666689,"name":"kubernetes","full_name":"mbohlool/kubernetes","owner":{"login":"mbohlool","id":1613024,"avatar_url":"https://avatars3.githubusercontent.com/u/1613024?v=4","gravatar_id":"","url":"https://api.github.com/users/mbohlool","html_url":"https://github.com/mbohlool","followers_url":"https://api.github.com/users/mbohlool/followers","following_url":"https://api.github.com/users/mbohlool/following{/other_user}","gists_url":"https://api.github.com/users/mbohlool/gists{/gist_id}","starred_url":"https://api.github.com/users/mbohlool/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbohlool/subscriptions","organizations_url":"https://api.github.com/users/mbohlool/orgs","repos_url":"https://api.github.com/users/mbohlool/repos","events_url":"https://api.github.com/users/mbohlool/events{/privacy}","received_events_url":"https://api.github.com/users/mbohlool/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mbohlool/kubernetes","description":"Container Cluster Manager from Google","fork":true,"url":"https://api.github.com/repos/mbohlool/kubernetes","forks_url":"https://api.github.com/repos/mbohlool/kubernetes/forks","keys_url":"https://api.github.com/repos/mbohlool/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mbohlool/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mbohlool/kubernetes/teams","hooks_url":"https://api.github.com/repos/mbohlool/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/mbohlool/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/mbohlool/kubernetes/events","assignees_url":"https://api.github.com/repos/mbohlool/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/mbohlool/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/mbohlool/kubernetes/tags","blobs_url":"https://api.github.com/repos/mbohlool/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mbohlool/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mbohlool/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/mbohlool/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mbohlool/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/mbohlool/kubernetes/languages","stargazers_url":"https://api.github.com/repos/mbohlool/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/mbohlool/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/mbohlool/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/mbohlool/kubernetes/subscription","commits_url":"https://api.github.com/repos/mbohlool/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/mbohlool/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/mbohlool/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/mbohlool/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/mbohlool/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/mbohlool/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mbohlool/kubernetes/merges","archive_url":"https://api.github.com/repos/mbohlool/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mbohlool/kubernetes/downloads","issues_url":"https://api.github.com/repos/mbohlool/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/mbohlool/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/mbohlool/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/mbohlool/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mbohlool/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/mbohlool/kubernetes/releases{/id}","deployments_url":"https://api.github.com/repos/mbohlool/kubernetes/deployments","created_at":"2016-05-12T18:30:33Z","updated_at":"2018-02-23T07:35:18Z","pushed_at":"2018-05-08T04:30:32Z","git_url":"git://github.com/mbohlool/kubernetes.git","ssh_url":"git@github.com:mbohlool/kubernetes.git","clone_url":"https://github.com/mbohlool/kubernetes.git","svn_url":"https://github.com/mbohlool/kubernetes","homepage":"http://kubernetes.io","size":549322,"stargazers_count":1,"watchers_count":1,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"kubernetes:master","ref":"master","sha":"940e716c0601147b7b1e2942a3938d4c3780d8a3","user":{"login":"kubernetes","id":13629408,"avatar_url":"https://avatars2.githubusercontent.com/u/13629408?v=4","gravatar_id":"","url":"https://api.github.com/users/kubernetes","html_url":"https://github.com/kubernetes","followers_url":"https://api.github.com/users/kubernetes/followers","following_url":"https://api.github.com/users/kubernetes/following{/other_user}","gists_url":"https://api.github.com/users/kubernetes/gists{/gist_id}","starred_url":"https://api.github.com/users/kubernetes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kubernetes/subscriptions","organizations_url":"https://api.github.com/users/kubernetes/orgs","repos_url":"https://api.github.com/users/kubernetes/repos","events_url":"https://api.github.com/users/kubernetes/events{/privacy}","received_events_url":"https://api.github.com/users/kubernetes/received_events","type":"Organization","site_admin":false},"repo":{"id":20580498,"name":"kubernetes","full_name":"kubernetes/kubernetes","owner":{"login":"kubernetes","id":13629408,"avatar_url":"https://avatars2.githubusercontent.com/u/13629408?v=4","gravatar_id":"","url":"https://api.github.com/users/kubernetes","html_url":"https://github.com/kubernetes","followers_url":"https://api.github.com/users/kubernetes/followers","following_url":"https://api.github.com/users/kubernetes/following{/other_user}","gists_url":"https://api.github.com/users/kubernetes/gists{/gist_id}","starred_url":"https://api.github.com/users/kubernetes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kubernetes/subscriptions","organizations_url":"https://api.github.com/users/kubernetes/orgs","repos_url":"https://api.github.com/users/kubernetes/repos","events_url":"https://api.github.com/users/kubernetes/events{/privacy}","received_events_url":"https://api.github.com/users/kubernetes/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/kubernetes/kubernetes","description":"Production-Grade Container Scheduling and Management","fork":false,"url":"https://api.github.com/repos/kubernetes/kubernetes","forks_url":"https://api.github.com/repos/kubernetes/kubernetes/forks","keys_url":"https://api.github.com/repos/kubernetes/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kubernetes/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kubernetes/kubernetes/teams","hooks_url":"https://api.github.com/repos/kubernetes/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/kubernetes/kubernetes/events","assignees_url":"https://api.github.com/repos/kubernetes/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/kubernetes/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/kubernetes/kubernetes/tags","blobs_url":"https://api.github.com/repos/kubernetes/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kubernetes/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kubernetes/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/kubernetes/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kubernetes/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/kubernetes/kubernetes/languages","stargazers_url":"https://api.github.com/repos/kubernetes/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/kubernetes/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/kubernetes/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/kubernetes/kubernetes/subscription","commits_url":"https://api.github.com/repos/kubernetes/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/kubernetes/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/kubernetes/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/kubernetes/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/kubernetes/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kubernetes/kubernetes/merges","archive_url":"https://api.github.com/repos/kubernetes/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kubernetes/kubernetes/downloads","issues_url":"https://api.github.com/repos/kubernetes/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/kubernetes/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/kubernetes/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kubernetes/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/kubernetes/kubernetes/releases{/id}","deployments_url":"https://api.github.com/repos/kubernetes/kubernetes/deployments","created_at":"2014-06-06T22:56:04Z","updated_at":"2018-05-09T07:20:48Z","pushed_at":"2018-05-09T08:09:08Z","git_url":"git://github.com/kubernetes/kubernetes.git","ssh_url":"git@github.com:kubernetes/kubernetes.git","clone_url":"https://github.com/kubernetes/kubernetes.git","svn_url":"https://github.com/kubernetes/kubernetes","homepage":"http://kubernetes.io","size":775802,"stargazers_count":36053,"watchers_count":36053,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":12715,"mirror_url":null,"archived":false,"open_issues_count":3310,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":12715,"open_issues":3310,"watchers":36053,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518"},"html":{"href":"https://github.com/kubernetes/kubernetes/pull/63518"},"issue":{"href":"https://api.github.com/repos/kubernetes/kubernetes/issues/63518"},"comments":{"href":"https://api.github.com/repos/kubernetes/kubernetes/issues/63518/comments"},"review_comments":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518/comments"},"review_comment":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/63518/commits"},"statuses":{"href":"https://api.github.com/repos/kubernetes/kubernetes/statuses/c93b28a02d97ad096334a605fa3ed3333ed06200"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"sttts"}}