{"action":"created","comment":{"url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments/64480096","id":64480096,"diff_hunk":"@@ -19,63 +19,109 @@ limitations under the License.\n package volume\n \n import (\n+\t\"fmt\"\n+\t\"strings\"\n \t\"time\"\n \n \t\"github.com/golang/glog\"\n+\t\"k8s.io/kubernetes/pkg/api\"\n \t\"k8s.io/kubernetes/pkg/client/clientset_generated/internalclientset\"\n+\t\"k8s.io/kubernetes/pkg/cloudprovider\"\n \t\"k8s.io/kubernetes/pkg/controller/framework\"\n \t\"k8s.io/kubernetes/pkg/controller/framework/informers\"\n+\t\"k8s.io/kubernetes/pkg/controller/volume/attacherdetacher\"\n+\t\"k8s.io/kubernetes/pkg/controller/volume/cache\"\n+\t\"k8s.io/kubernetes/pkg/controller/volume/reconciler\"\n+\t\"k8s.io/kubernetes/pkg/types\"\n+\t\"k8s.io/kubernetes/pkg/util/io\"\n+\t\"k8s.io/kubernetes/pkg/util/mount\"\n \t\"k8s.io/kubernetes/pkg/util/runtime\"\n+\t\"k8s.io/kubernetes/pkg/volume\"\n )\n \n-// AttachDetachController defines the operations supported by this controller.\n-type AttachDetachController interface {\n-\tRun(stopCh <-chan struct{})\n-}\n+const (\n+\t// ControllerManagedAnnotation is the key of the annotation on Node objects\n+\t// that indicates attach/detach operations for the node should be managed\n+\t// by the attach/detach controller\n+\tControllerManagedAnnotation string = \"volumes.kubernetes.io/controller-managed-attach-detach\"","path":"pkg/controller/volume/attach_detach_controller.go","position":32,"original_position":32,"commit_id":"6303cf96f7e05cf57ebcdcf5585ea4db5f27ed39","original_commit_id":"6303cf96f7e05cf57ebcdcf5585ea4db5f27ed39","user":{"login":"saad-ali","id":10052848,"avatar_url":"https://avatars.githubusercontent.com/u/10052848?v=3","gravatar_id":"","url":"https://api.github.com/users/saad-ali","html_url":"https://github.com/saad-ali","followers_url":"https://api.github.com/users/saad-ali/followers","following_url":"https://api.github.com/users/saad-ali/following{/other_user}","gists_url":"https://api.github.com/users/saad-ali/gists{/gist_id}","starred_url":"https://api.github.com/users/saad-ali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saad-ali/subscriptions","organizations_url":"https://api.github.com/users/saad-ali/orgs","repos_url":"https://api.github.com/users/saad-ali/repos","events_url":"https://api.github.com/users/saad-ali/events{/privacy}","received_events_url":"https://api.github.com/users/saad-ali/received_events","type":"User","site_admin":false},"body":"Ack. Will do.","created_at":"2016-05-24T21:44:01Z","updated_at":"2016-05-24T21:44:01Z","html_url":"https://github.com/kubernetes/kubernetes/pull/25457#discussion_r64480096","pull_request_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457","_links":{"self":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments/64480096"},"html":{"href":"https://github.com/kubernetes/kubernetes/pull/25457#discussion_r64480096"},"pull_request":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457"}}},"pull_request":{"url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457","id":69616754,"html_url":"https://github.com/kubernetes/kubernetes/pull/25457","diff_url":"https://github.com/kubernetes/kubernetes/pull/25457.diff","patch_url":"https://github.com/kubernetes/kubernetes/pull/25457.patch","issue_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/25457","number":25457,"state":"open","locked":false,"title":"Attach Detach Controller Business Logic","user":{"login":"saad-ali","id":10052848,"avatar_url":"https://avatars.githubusercontent.com/u/10052848?v=3","gravatar_id":"","url":"https://api.github.com/users/saad-ali","html_url":"https://github.com/saad-ali","followers_url":"https://api.github.com/users/saad-ali/followers","following_url":"https://api.github.com/users/saad-ali/following{/other_user}","gists_url":"https://api.github.com/users/saad-ali/gists{/gist_id}","starred_url":"https://api.github.com/users/saad-ali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saad-ali/subscriptions","organizations_url":"https://api.github.com/users/saad-ali/orgs","repos_url":"https://api.github.com/users/saad-ali/repos","events_url":"https://api.github.com/users/saad-ali/events{/privacy}","received_events_url":"https://api.github.com/users/saad-ali/received_events","type":"User","site_admin":false},"body":"This PR adds the meat of the attach/detach controller proposed in #20262.\r\n\r\nThe PR splits the in-memory cache into a desired and actual state of the world.","created_at":"2016-05-11T05:25:58Z","updated_at":"2016-05-24T21:44:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6e20f2fea6d5053b4e64bfc0a3da415077a45174","assignee":{"login":"thockin","id":5595220,"avatar_url":"https://avatars.githubusercontent.com/u/5595220?v=3","gravatar_id":"","url":"https://api.github.com/users/thockin","html_url":"https://github.com/thockin","followers_url":"https://api.github.com/users/thockin/followers","following_url":"https://api.github.com/users/thockin/following{/other_user}","gists_url":"https://api.github.com/users/thockin/gists{/gist_id}","starred_url":"https://api.github.com/users/thockin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thockin/subscriptions","organizations_url":"https://api.github.com/users/thockin/orgs","repos_url":"https://api.github.com/users/thockin/repos","events_url":"https://api.github.com/users/thockin/events{/privacy}","received_events_url":"https://api.github.com/users/thockin/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/kubernetes/kubernetes/milestones/18","html_url":"https://github.com/kubernetes/kubernetes/milestones/v1.3","labels_url":"https://api.github.com/repos/kubernetes/kubernetes/milestones/18/labels","id":1638460,"number":18,"title":"v1.3","description":"https://github.com/kubernetes/kubernetes/wiki/Release-1.3","creator":{"login":"bgrant0607","id":7725777,"avatar_url":"https://avatars.githubusercontent.com/u/7725777?v=3","gravatar_id":"","url":"https://api.github.com/users/bgrant0607","html_url":"https://github.com/bgrant0607","followers_url":"https://api.github.com/users/bgrant0607/followers","following_url":"https://api.github.com/users/bgrant0607/following{/other_user}","gists_url":"https://api.github.com/users/bgrant0607/gists{/gist_id}","starred_url":"https://api.github.com/users/bgrant0607/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bgrant0607/subscriptions","organizations_url":"https://api.github.com/users/bgrant0607/orgs","repos_url":"https://api.github.com/users/bgrant0607/repos","events_url":"https://api.github.com/users/bgrant0607/events{/privacy}","received_events_url":"https://api.github.com/users/bgrant0607/received_events","type":"User","site_admin":false},"open_issues":236,"closed_issues":200,"state":"open","created_at":"2016-03-11T07:40:20Z","updated_at":"2016-05-24T21:28:49Z","due_on":"2016-06-24T07:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457/commits","review_comments_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457/comments","review_comment_url":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/25457/comments","statuses_url":"https://api.github.com/repos/kubernetes/kubernetes/statuses/6303cf96f7e05cf57ebcdcf5585ea4db5f27ed39","head":{"label":"saad-ali:expectedStateOfWorldDataStructure","ref":"expectedStateOfWorldDataStructure","sha":"6303cf96f7e05cf57ebcdcf5585ea4db5f27ed39","user":{"login":"saad-ali","id":10052848,"avatar_url":"https://avatars.githubusercontent.com/u/10052848?v=3","gravatar_id":"","url":"https://api.github.com/users/saad-ali","html_url":"https://github.com/saad-ali","followers_url":"https://api.github.com/users/saad-ali/followers","following_url":"https://api.github.com/users/saad-ali/following{/other_user}","gists_url":"https://api.github.com/users/saad-ali/gists{/gist_id}","starred_url":"https://api.github.com/users/saad-ali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saad-ali/subscriptions","organizations_url":"https://api.github.com/users/saad-ali/orgs","repos_url":"https://api.github.com/users/saad-ali/repos","events_url":"https://api.github.com/users/saad-ali/events{/privacy}","received_events_url":"https://api.github.com/users/saad-ali/received_events","type":"User","site_admin":false},"repo":{"id":27614790,"name":"kubernetes","full_name":"saad-ali/kubernetes","owner":{"login":"saad-ali","id":10052848,"avatar_url":"https://avatars.githubusercontent.com/u/10052848?v=3","gravatar_id":"","url":"https://api.github.com/users/saad-ali","html_url":"https://github.com/saad-ali","followers_url":"https://api.github.com/users/saad-ali/followers","following_url":"https://api.github.com/users/saad-ali/following{/other_user}","gists_url":"https://api.github.com/users/saad-ali/gists{/gist_id}","starred_url":"https://api.github.com/users/saad-ali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/saad-ali/subscriptions","organizations_url":"https://api.github.com/users/saad-ali/orgs","repos_url":"https://api.github.com/users/saad-ali/repos","events_url":"https://api.github.com/users/saad-ali/events{/privacy}","received_events_url":"https://api.github.com/users/saad-ali/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/saad-ali/kubernetes","description":"Container Cluster Manager","fork":true,"url":"https://api.github.com/repos/saad-ali/kubernetes","forks_url":"https://api.github.com/repos/saad-ali/kubernetes/forks","keys_url":"https://api.github.com/repos/saad-ali/kubernetes/keys{/key_id}","collaborators_url":"https://api.github.com/repos/saad-ali/kubernetes/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/saad-ali/kubernetes/teams","hooks_url":"https://api.github.com/repos/saad-ali/kubernetes/hooks","issue_events_url":"https://api.github.com/repos/saad-ali/kubernetes/issues/events{/number}","events_url":"https://api.github.com/repos/saad-ali/kubernetes/events","assignees_url":"https://api.github.com/repos/saad-ali/kubernetes/assignees{/user}","branches_url":"https://api.github.com/repos/saad-ali/kubernetes/branches{/branch}","tags_url":"https://api.github.com/repos/saad-ali/kubernetes/tags","blobs_url":"https://api.github.com/repos/saad-ali/kubernetes/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/saad-ali/kubernetes/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/saad-ali/kubernetes/git/refs{/sha}","trees_url":"https://api.github.com/repos/saad-ali/kubernetes/git/trees{/sha}","statuses_url":"https://api.github.com/repos/saad-ali/kubernetes/statuses/{sha}","languages_url":"https://api.github.com/repos/saad-ali/kubernetes/languages","stargazers_url":"https://api.github.com/repos/saad-ali/kubernetes/stargazers","contributors_url":"https://api.github.com/repos/saad-ali/kubernetes/contributors","subscribers_url":"https://api.github.com/repos/saad-ali/kubernetes/subscribers","subscription_url":"https://api.github.com/repos/saad-ali/kubernetes/subscription","commits_url":"https://api.github.com/repos/saad-ali/kubernetes/commits{/sha}","git_commits_url":"https://api.github.com/repos/saad-ali/kubernetes/git/commits{/sha}","comments_url":"https://api.github.com/repos/saad-ali/kubernetes/comments{/number}","issue_comment_url":"https://api.github.com/repos/saad-ali/kubernetes/issues/comments{/number}","contents_url":"https://api.github.com/repos/saad-ali/kubernetes/contents/{+path}","compare_url":"https://api.github.com/repos/saad-ali/kubernetes/compare/{base}...{head}","merges_url":"https://api.github.com/repos/saad-ali/kubernetes/merges","archive_url":"https://api.github.com/repos/saad-ali/kubernetes/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/saad-ali/kubernetes/downloads","issues_url":"https://api.github.com/repos/saad-ali/kubernetes/issues{/number}","pulls_url":"https://api.github.com/repos/saad-ali/kubernetes/pulls{/number}","milestones_url":"https://api.github.com/repos/saad-ali/kubernetes/milestones{/number}","notifications_url":"https://api.github.com/repos/saad-ali/kubernetes/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/saad-ali/kubernetes/labels{/name}","releases_url":"https://api.github.com/repos/saad-ali/kubernetes/releases{/id}","deployments_url":"https://api.github.com/repos/saad-ali/kubernetes/deployments","created_at":"2014-12-05T23:31:31Z","updated_at":"2016-01-22T23:53:04Z","pushed_at":"2016-05-23T20:38:06Z","git_url":"git://github.com/saad-ali/kubernetes.git","ssh_url":"git@github.com:saad-ali/kubernetes.git","clone_url":"https://github.com/saad-ali/kubernetes.git","svn_url":"https://github.com/saad-ali/kubernetes","homepage":null,"size":236070,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"kubernetes:master","ref":"master","sha":"4215fe57a539b6ce9acbc7fccbf5558dbcec4817","user":{"login":"kubernetes","id":13629408,"avatar_url":"https://avatars.githubusercontent.com/u/13629408?v=3","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://avatars.githubusercontent.com/u/13629408?v=3","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":"Container Cluster Manager from Google","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":"2016-05-24T21:40:51Z","pushed_at":"2016-05-24T21:36:26Z","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":447448,"stargazers_count":14541,"watchers_count":14541,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":4422,"mirror_url":null,"open_issues_count":3664,"forks":4422,"open_issues":3664,"watchers":14541,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457"},"html":{"href":"https://github.com/kubernetes/kubernetes/pull/25457"},"issue":{"href":"https://api.github.com/repos/kubernetes/kubernetes/issues/25457"},"comments":{"href":"https://api.github.com/repos/kubernetes/kubernetes/issues/25457/comments"},"review_comments":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457/comments"},"review_comment":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kubernetes/kubernetes/pulls/25457/commits"},"statuses":{"href":"https://api.github.com/repos/kubernetes/kubernetes/statuses/6303cf96f7e05cf57ebcdcf5585ea4db5f27ed39"}}}}
{"actor":{"display_login":"saad-ali"}}