{"action":"created","comment":{"url":"https://api.github.com/repos/google/cadvisor/pulls/comments/30092592","id":30092592,"diff_hunk":"@@ -640,6 +643,27 @@ func (m *manager) Exists(containerName string) bool {\n \treturn false\n }\n \n+func (m *manager) GetProcessList(containerName string, options v2.RequestOptions) ([]v2.ProcessInfo, error) {\n+\t// override recursive. Only support single container listing.\n+\toptions.Recursive = false\n+\tconts, err := m.getRequestedContainers(containerName, options)\n+\tif err != nil {\n+\t\treturn nil, err\n+\t}\n+\tif len(conts) != 1 {\n+\t\treturn nil, fmt.Errorf(\"Expected the request to match only one container\")\n+\t}\n+\t// TODO(rjnagal): handle count? Only if we can do count by type (eg. top 5 cpu users)\n+\tps := []v2.ProcessInfo{}\n+\tfor _, cont := range conts {","path":"manager/manager.go","position":26,"original_position":26,"commit_id":"6ee6fd4d8004d73f104f97d80ad988b3f2d8d482","original_commit_id":"6ee6fd4d8004d73f104f97d80ad988b3f2d8d482","user":{"login":"vmarmol","id":985208,"avatar_url":"https://avatars.githubusercontent.com/u/985208?v=3","gravatar_id":"","url":"https://api.github.com/users/vmarmol","html_url":"https://github.com/vmarmol","followers_url":"https://api.github.com/users/vmarmol/followers","following_url":"https://api.github.com/users/vmarmol/following{/other_user}","gists_url":"https://api.github.com/users/vmarmol/gists{/gist_id}","starred_url":"https://api.github.com/users/vmarmol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmarmol/subscriptions","organizations_url":"https://api.github.com/users/vmarmol/orgs","repos_url":"https://api.github.com/users/vmarmol/repos","events_url":"https://api.github.com/users/vmarmol/events{/privacy}","received_events_url":"https://api.github.com/users/vmarmol/received_events","type":"User","site_admin":false},"body":"aaah I didn't realize it was a map.","created_at":"2015-05-11T23:26:56Z","updated_at":"2015-05-11T23:26:56Z","html_url":"https://github.com/google/cadvisor/pull/707#discussion_r30092592","pull_request_url":"https://api.github.com/repos/google/cadvisor/pulls/707","_links":{"self":{"href":"https://api.github.com/repos/google/cadvisor/pulls/comments/30092592"},"html":{"href":"https://github.com/google/cadvisor/pull/707#discussion_r30092592"},"pull_request":{"href":"https://api.github.com/repos/google/cadvisor/pulls/707"}}},"pull_request":{"url":"https://api.github.com/repos/google/cadvisor/pulls/707","id":35178192,"html_url":"https://github.com/google/cadvisor/pull/707","diff_url":"https://github.com/google/cadvisor/pull/707.diff","patch_url":"https://github.com/google/cadvisor/pull/707.patch","issue_url":"https://api.github.com/repos/google/cadvisor/issues/707","number":707,"state":"open","locked":false,"title":"Add an api to support ps/top.","user":{"login":"rjnagal","id":5420489,"avatar_url":"https://avatars.githubusercontent.com/u/5420489?v=3","gravatar_id":"","url":"https://api.github.com/users/rjnagal","html_url":"https://github.com/rjnagal","followers_url":"https://api.github.com/users/rjnagal/followers","following_url":"https://api.github.com/users/rjnagal/following{/other_user}","gists_url":"https://api.github.com/users/rjnagal/gists{/gist_id}","starred_url":"https://api.github.com/users/rjnagal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rjnagal/subscriptions","organizations_url":"https://api.github.com/users/rjnagal/orgs","repos_url":"https://api.github.com/users/rjnagal/repos","events_url":"https://api.github.com/users/rjnagal/events{/privacy}","received_events_url":"https://api.github.com/users/rjnagal/received_events","type":"User","site_admin":false},"body":"\r\nI need the ps/top output for the UI. Not sure if we should be adding it as an API. WDYT?\r\n\r\nAlso check the fields that I selected to show. Do we have any issues showing the full command. My guess is that we don't care.","created_at":"2015-05-11T22:53:08Z","updated_at":"2015-05-11T23:26:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0f05b101d5d3adb0b7b923adf75d6e3878742ada","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/google/cadvisor/pulls/707/commits","review_comments_url":"https://api.github.com/repos/google/cadvisor/pulls/707/comments","review_comment_url":"https://api.github.com/repos/google/cadvisor/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/cadvisor/issues/707/comments","statuses_url":"https://api.github.com/repos/google/cadvisor/statuses/6ee6fd4d8004d73f104f97d80ad988b3f2d8d482","head":{"label":"rjnagal:docker","ref":"docker","sha":"6ee6fd4d8004d73f104f97d80ad988b3f2d8d482","user":{"login":"rjnagal","id":5420489,"avatar_url":"https://avatars.githubusercontent.com/u/5420489?v=3","gravatar_id":"","url":"https://api.github.com/users/rjnagal","html_url":"https://github.com/rjnagal","followers_url":"https://api.github.com/users/rjnagal/followers","following_url":"https://api.github.com/users/rjnagal/following{/other_user}","gists_url":"https://api.github.com/users/rjnagal/gists{/gist_id}","starred_url":"https://api.github.com/users/rjnagal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rjnagal/subscriptions","organizations_url":"https://api.github.com/users/rjnagal/orgs","repos_url":"https://api.github.com/users/rjnagal/repos","events_url":"https://api.github.com/users/rjnagal/events{/privacy}","received_events_url":"https://api.github.com/users/rjnagal/received_events","type":"User","site_admin":false},"repo":{"id":20703159,"name":"cadvisor","full_name":"rjnagal/cadvisor","owner":{"login":"rjnagal","id":5420489,"avatar_url":"https://avatars.githubusercontent.com/u/5420489?v=3","gravatar_id":"","url":"https://api.github.com/users/rjnagal","html_url":"https://github.com/rjnagal","followers_url":"https://api.github.com/users/rjnagal/followers","following_url":"https://api.github.com/users/rjnagal/following{/other_user}","gists_url":"https://api.github.com/users/rjnagal/gists{/gist_id}","starred_url":"https://api.github.com/users/rjnagal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rjnagal/subscriptions","organizations_url":"https://api.github.com/users/rjnagal/orgs","repos_url":"https://api.github.com/users/rjnagal/repos","events_url":"https://api.github.com/users/rjnagal/events{/privacy}","received_events_url":"https://api.github.com/users/rjnagal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rjnagal/cadvisor","description":"cAdvisor provides provides information about the resource usage and performance characteristics of running containers.","fork":true,"url":"https://api.github.com/repos/rjnagal/cadvisor","forks_url":"https://api.github.com/repos/rjnagal/cadvisor/forks","keys_url":"https://api.github.com/repos/rjnagal/cadvisor/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rjnagal/cadvisor/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rjnagal/cadvisor/teams","hooks_url":"https://api.github.com/repos/rjnagal/cadvisor/hooks","issue_events_url":"https://api.github.com/repos/rjnagal/cadvisor/issues/events{/number}","events_url":"https://api.github.com/repos/rjnagal/cadvisor/events","assignees_url":"https://api.github.com/repos/rjnagal/cadvisor/assignees{/user}","branches_url":"https://api.github.com/repos/rjnagal/cadvisor/branches{/branch}","tags_url":"https://api.github.com/repos/rjnagal/cadvisor/tags","blobs_url":"https://api.github.com/repos/rjnagal/cadvisor/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rjnagal/cadvisor/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rjnagal/cadvisor/git/refs{/sha}","trees_url":"https://api.github.com/repos/rjnagal/cadvisor/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rjnagal/cadvisor/statuses/{sha}","languages_url":"https://api.github.com/repos/rjnagal/cadvisor/languages","stargazers_url":"https://api.github.com/repos/rjnagal/cadvisor/stargazers","contributors_url":"https://api.github.com/repos/rjnagal/cadvisor/contributors","subscribers_url":"https://api.github.com/repos/rjnagal/cadvisor/subscribers","subscription_url":"https://api.github.com/repos/rjnagal/cadvisor/subscription","commits_url":"https://api.github.com/repos/rjnagal/cadvisor/commits{/sha}","git_commits_url":"https://api.github.com/repos/rjnagal/cadvisor/git/commits{/sha}","comments_url":"https://api.github.com/repos/rjnagal/cadvisor/comments{/number}","issue_comment_url":"https://api.github.com/repos/rjnagal/cadvisor/issues/comments{/number}","contents_url":"https://api.github.com/repos/rjnagal/cadvisor/contents/{+path}","compare_url":"https://api.github.com/repos/rjnagal/cadvisor/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rjnagal/cadvisor/merges","archive_url":"https://api.github.com/repos/rjnagal/cadvisor/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rjnagal/cadvisor/downloads","issues_url":"https://api.github.com/repos/rjnagal/cadvisor/issues{/number}","pulls_url":"https://api.github.com/repos/rjnagal/cadvisor/pulls{/number}","milestones_url":"https://api.github.com/repos/rjnagal/cadvisor/milestones{/number}","notifications_url":"https://api.github.com/repos/rjnagal/cadvisor/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rjnagal/cadvisor/labels{/name}","releases_url":"https://api.github.com/repos/rjnagal/cadvisor/releases{/id}","created_at":"2014-06-10T21:57:28Z","updated_at":"2015-03-24T18:19:12Z","pushed_at":"2015-05-11T22:51:32Z","git_url":"git://github.com/rjnagal/cadvisor.git","ssh_url":"git@github.com:rjnagal/cadvisor.git","clone_url":"https://github.com/rjnagal/cadvisor.git","svn_url":"https://github.com/rjnagal/cadvisor","homepage":"","size":19198,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"google:master","ref":"master","sha":"86dd6cc99d7fc008b22d4ba8c2edb213854d1a9e","user":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":20653934,"name":"cadvisor","full_name":"google/cadvisor","owner":{"login":"google","id":1342004,"avatar_url":"https://avatars.githubusercontent.com/u/1342004?v=3","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/google/cadvisor","description":"Analyzes resource usage and performance characteristics of running containers.","fork":false,"url":"https://api.github.com/repos/google/cadvisor","forks_url":"https://api.github.com/repos/google/cadvisor/forks","keys_url":"https://api.github.com/repos/google/cadvisor/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/cadvisor/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/cadvisor/teams","hooks_url":"https://api.github.com/repos/google/cadvisor/hooks","issue_events_url":"https://api.github.com/repos/google/cadvisor/issues/events{/number}","events_url":"https://api.github.com/repos/google/cadvisor/events","assignees_url":"https://api.github.com/repos/google/cadvisor/assignees{/user}","branches_url":"https://api.github.com/repos/google/cadvisor/branches{/branch}","tags_url":"https://api.github.com/repos/google/cadvisor/tags","blobs_url":"https://api.github.com/repos/google/cadvisor/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/cadvisor/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/cadvisor/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/cadvisor/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/cadvisor/statuses/{sha}","languages_url":"https://api.github.com/repos/google/cadvisor/languages","stargazers_url":"https://api.github.com/repos/google/cadvisor/stargazers","contributors_url":"https://api.github.com/repos/google/cadvisor/contributors","subscribers_url":"https://api.github.com/repos/google/cadvisor/subscribers","subscription_url":"https://api.github.com/repos/google/cadvisor/subscription","commits_url":"https://api.github.com/repos/google/cadvisor/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/cadvisor/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/cadvisor/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/cadvisor/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/cadvisor/contents/{+path}","compare_url":"https://api.github.com/repos/google/cadvisor/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/cadvisor/merges","archive_url":"https://api.github.com/repos/google/cadvisor/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/cadvisor/downloads","issues_url":"https://api.github.com/repos/google/cadvisor/issues{/number}","pulls_url":"https://api.github.com/repos/google/cadvisor/pulls{/number}","milestones_url":"https://api.github.com/repos/google/cadvisor/milestones{/number}","notifications_url":"https://api.github.com/repos/google/cadvisor/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/cadvisor/labels{/name}","releases_url":"https://api.github.com/repos/google/cadvisor/releases{/id}","created_at":"2014-06-09T16:36:33Z","updated_at":"2015-05-11T14:11:16Z","pushed_at":"2015-05-11T22:53:08Z","git_url":"git://github.com/google/cadvisor.git","ssh_url":"git@github.com:google/cadvisor.git","clone_url":"https://github.com/google/cadvisor.git","svn_url":"https://github.com/google/cadvisor","homepage":"","size":25877,"stargazers_count":2298,"watchers_count":2298,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":245,"mirror_url":null,"open_issues_count":46,"forks":245,"open_issues":46,"watchers":2298,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/cadvisor/pulls/707"},"html":{"href":"https://github.com/google/cadvisor/pull/707"},"issue":{"href":"https://api.github.com/repos/google/cadvisor/issues/707"},"comments":{"href":"https://api.github.com/repos/google/cadvisor/issues/707/comments"},"review_comments":{"href":"https://api.github.com/repos/google/cadvisor/pulls/707/comments"},"review_comment":{"href":"https://api.github.com/repos/google/cadvisor/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/cadvisor/pulls/707/commits"},"statuses":{"href":"https://api.github.com/repos/google/cadvisor/statuses/6ee6fd4d8004d73f104f97d80ad988b3f2d8d482"}}}}