{"action":"created","comment":{"url":"https://api.github.com/repos/google/cadvisor/pulls/comments/23802841","id":23802841,"diff_hunk":"@@ -142,9 +178,52 @@ func (self *SchedReader) allowErrorLogging() bool {\n \treturn false\n }\n \n+func GetSelfCgroup() (string, error) {\n+\tout, err := ioutil.ReadFile(\"/proc/self/cgroup\")\n+\tif err != nil {\n+\t\treturn \"\", fmt.Errorf(\"failed to read cgroup path for cAdvisor: %v\", err)\n+\t}\n+\tmatches := selfCgroupRegExp.FindSubmatch(out)\n+\tif len(matches) != 2 {\n+\t\treturn \"\", fmt.Errorf(\"could not find cpu cgroup path in %q\", string(out))\n+\t}\n+\treturn string(matches[1]), nil\n+}\n+\n+func GetRootLoad() (int64, error) {","path":"utils/cpuload/scheddebug/scheddebug.go","position":119,"original_position":119,"commit_id":"55328b8ecb8a0acb4ba294b7adcf95480fd9e502","original_commit_id":"55328b8ecb8a0acb4ba294b7adcf95480fd9e502","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":"not public?","created_at":"2015-01-29T21:11:09Z","updated_at":"2015-01-29T21:11:09Z","html_url":"https://github.com/google/cadvisor/pull/477#discussion_r23802841","pull_request_url":"https://api.github.com/repos/google/cadvisor/pulls/477","_links":{"self":{"href":"https://api.github.com/repos/google/cadvisor/pulls/comments/23802841"},"html":{"href":"https://github.com/google/cadvisor/pull/477#discussion_r23802841"},"pull_request":{"href":"https://api.github.com/repos/google/cadvisor/pulls/477"}}},"pull_request":{"url":"https://api.github.com/repos/google/cadvisor/pulls/477","id":28313798,"html_url":"https://github.com/google/cadvisor/pull/477","diff_url":"https://github.com/google/cadvisor/pull/477.diff","patch_url":"https://github.com/google/cadvisor/pull/477.patch","issue_url":"https://api.github.com/repos/google/cadvisor/issues/477","number":477,"state":"open","locked":false,"title":"Set of fixes for cpuload calculations.","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":". Remove counting of taskgroups from scheddebug.\r\n. Move monitoring thread 500ms ahead of other containers housekeeping.\r\n. Rely on /proc/loadavg for root load.\r\n. Cover up for scheddebug atomicity issues (WIP)\r\n. Remove counting of monitoring thread.\r\n\r\nGetting better, but still a bit farther away from ideal load :(","created_at":"2015-01-29T20:55:17Z","updated_at":"2015-01-29T21:11:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ce0a6881dfbba5baa762a7e8b0a1c989ee9d9c56","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/google/cadvisor/pulls/477/commits","review_comments_url":"https://api.github.com/repos/google/cadvisor/pulls/477/comments","review_comment_url":"https://api.github.com/repos/google/cadvisor/pulls/comments/{number}","comments_url":"https://api.github.com/repos/google/cadvisor/issues/477/comments","statuses_url":"https://api.github.com/repos/google/cadvisor/statuses/55328b8ecb8a0acb4ba294b7adcf95480fd9e502","head":{"label":"rjnagal:cpu","ref":"cpu","sha":"55328b8ecb8a0acb4ba294b7adcf95480fd9e502","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-01-26T20:27:32Z","pushed_at":"2015-01-29T20:53:50Z","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":17848,"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":"ef2d9d1c7614f0e44c3bbc0be783ee1ec77fa11b","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-01-29T20:05:48Z","pushed_at":"2015-01-28T07:14:54Z","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":19712,"stargazers_count":1764,"watchers_count":1764,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":170,"mirror_url":null,"open_issues_count":31,"forks":170,"open_issues":31,"watchers":1764,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/cadvisor/pulls/477"},"html":{"href":"https://github.com/google/cadvisor/pull/477"},"issue":{"href":"https://api.github.com/repos/google/cadvisor/issues/477"},"comments":{"href":"https://api.github.com/repos/google/cadvisor/issues/477/comments"},"review_comments":{"href":"https://api.github.com/repos/google/cadvisor/pulls/477/comments"},"review_comment":{"href":"https://api.github.com/repos/google/cadvisor/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/google/cadvisor/pulls/477/commits"},"statuses":{"href":"https://api.github.com/repos/google/cadvisor/statuses/55328b8ecb8a0acb4ba294b7adcf95480fd9e502"}}}}