{"action":"reopened","number":724,"pull_request":{"url":"https://api.github.com/repos/docker-java/docker-java/pulls/724","id":88816341,"html_url":"https://github.com/docker-java/docker-java/pull/724","diff_url":"https://github.com/docker-java/docker-java/pull/724.diff","patch_url":"https://github.com/docker-java/docker-java/pull/724.patch","issue_url":"https://api.github.com/repos/docker-java/docker-java/issues/724","number":724,"state":"open","locked":false,"title":"Added getter for previous cpu stats","user":{"login":"freva","id":3785505,"avatar_url":"https://avatars.githubusercontent.com/u/3785505?v=3","gravatar_id":"","url":"https://api.github.com/users/freva","html_url":"https://github.com/freva","followers_url":"https://api.github.com/users/freva/followers","following_url":"https://api.github.com/users/freva/following{/other_user}","gists_url":"https://api.github.com/users/freva/gists{/gist_id}","starred_url":"https://api.github.com/users/freva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/freva/subscriptions","organizations_url":"https://api.github.com/users/freva/orgs","repos_url":"https://api.github.com/users/freva/repos","events_url":"https://api.github.com/users/freva/events{/privacy}","received_events_url":"https://api.github.com/users/freva/received_events","type":"User","site_admin":false},"body":"This PR adds a getter to the existing field `precpu_stats` that has existed since remote API v1.19 (https://docs.docker.com/engine/reference/api/docker_remote_api_v1.19/#/get-container-stats-based-on-resource-usage and https://github.com/docker/docker/pull/13320). This field is used to calculate the CPU usage without keeping state, using formula: `(cpu_stats.cpu_usage.total_usage - precpu_stats.cpu_usage.total_usage) / (cpu_stats.system_cpu_usage - precpu_stats.system_cpu_usage)`\n\n<!-- Reviewable:start -->\n\n---\n\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"34\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/docker-java/docker-java/724)\n\n<!-- Reviewable:end -->\n","created_at":"2016-10-11T11:37:54Z","updated_at":"2017-02-15T16:58:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f3ecf73014b71015476b0363afe579da923239a5","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/docker-java/docker-java/pulls/724/commits","review_comments_url":"https://api.github.com/repos/docker-java/docker-java/pulls/724/comments","review_comment_url":"https://api.github.com/repos/docker-java/docker-java/pulls/comments{/number}","comments_url":"https://api.github.com/repos/docker-java/docker-java/issues/724/comments","statuses_url":"https://api.github.com/repos/docker-java/docker-java/statuses/9d2c93e5eacf4807f5368d28c3277d85aa6bd546","head":{"label":"freva:getter-for-previous-cpu-stats","ref":"getter-for-previous-cpu-stats","sha":"9d2c93e5eacf4807f5368d28c3277d85aa6bd546","user":{"login":"freva","id":3785505,"avatar_url":"https://avatars.githubusercontent.com/u/3785505?v=3","gravatar_id":"","url":"https://api.github.com/users/freva","html_url":"https://github.com/freva","followers_url":"https://api.github.com/users/freva/followers","following_url":"https://api.github.com/users/freva/following{/other_user}","gists_url":"https://api.github.com/users/freva/gists{/gist_id}","starred_url":"https://api.github.com/users/freva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/freva/subscriptions","organizations_url":"https://api.github.com/users/freva/orgs","repos_url":"https://api.github.com/users/freva/repos","events_url":"https://api.github.com/users/freva/events{/privacy}","received_events_url":"https://api.github.com/users/freva/received_events","type":"User","site_admin":false},"repo":{"id":70586707,"name":"docker-java","full_name":"freva/docker-java","owner":{"login":"freva","id":3785505,"avatar_url":"https://avatars.githubusercontent.com/u/3785505?v=3","gravatar_id":"","url":"https://api.github.com/users/freva","html_url":"https://github.com/freva","followers_url":"https://api.github.com/users/freva/followers","following_url":"https://api.github.com/users/freva/following{/other_user}","gists_url":"https://api.github.com/users/freva/gists{/gist_id}","starred_url":"https://api.github.com/users/freva/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/freva/subscriptions","organizations_url":"https://api.github.com/users/freva/orgs","repos_url":"https://api.github.com/users/freva/repos","events_url":"https://api.github.com/users/freva/events{/privacy}","received_events_url":"https://api.github.com/users/freva/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/freva/docker-java","description":"Java Docker API Client","fork":true,"url":"https://api.github.com/repos/freva/docker-java","forks_url":"https://api.github.com/repos/freva/docker-java/forks","keys_url":"https://api.github.com/repos/freva/docker-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/freva/docker-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/freva/docker-java/teams","hooks_url":"https://api.github.com/repos/freva/docker-java/hooks","issue_events_url":"https://api.github.com/repos/freva/docker-java/issues/events{/number}","events_url":"https://api.github.com/repos/freva/docker-java/events","assignees_url":"https://api.github.com/repos/freva/docker-java/assignees{/user}","branches_url":"https://api.github.com/repos/freva/docker-java/branches{/branch}","tags_url":"https://api.github.com/repos/freva/docker-java/tags","blobs_url":"https://api.github.com/repos/freva/docker-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/freva/docker-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/freva/docker-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/freva/docker-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/freva/docker-java/statuses/{sha}","languages_url":"https://api.github.com/repos/freva/docker-java/languages","stargazers_url":"https://api.github.com/repos/freva/docker-java/stargazers","contributors_url":"https://api.github.com/repos/freva/docker-java/contributors","subscribers_url":"https://api.github.com/repos/freva/docker-java/subscribers","subscription_url":"https://api.github.com/repos/freva/docker-java/subscription","commits_url":"https://api.github.com/repos/freva/docker-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/freva/docker-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/freva/docker-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/freva/docker-java/issues/comments{/number}","contents_url":"https://api.github.com/repos/freva/docker-java/contents/{+path}","compare_url":"https://api.github.com/repos/freva/docker-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/freva/docker-java/merges","archive_url":"https://api.github.com/repos/freva/docker-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/freva/docker-java/downloads","issues_url":"https://api.github.com/repos/freva/docker-java/issues{/number}","pulls_url":"https://api.github.com/repos/freva/docker-java/pulls{/number}","milestones_url":"https://api.github.com/repos/freva/docker-java/milestones{/number}","notifications_url":"https://api.github.com/repos/freva/docker-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/freva/docker-java/labels{/name}","releases_url":"https://api.github.com/repos/freva/docker-java/releases{/id}","deployments_url":"https://api.github.com/repos/freva/docker-java/deployments","created_at":"2016-10-11T11:31:02Z","updated_at":"2016-10-11T11:31:04Z","pushed_at":"2016-10-14T07:49:08Z","git_url":"git://github.com/freva/docker-java.git","ssh_url":"git@github.com:freva/docker-java.git","clone_url":"https://github.com/freva/docker-java.git","svn_url":"https://github.com/freva/docker-java","homepage":"","size":3665,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"docker-java:master","ref":"master","sha":"5736b4bb235afab960866b0d0f18bb7aa7a3e527","user":{"login":"docker-java","id":7772003,"avatar_url":"https://avatars.githubusercontent.com/u/7772003?v=3","gravatar_id":"","url":"https://api.github.com/users/docker-java","html_url":"https://github.com/docker-java","followers_url":"https://api.github.com/users/docker-java/followers","following_url":"https://api.github.com/users/docker-java/following{/other_user}","gists_url":"https://api.github.com/users/docker-java/gists{/gist_id}","starred_url":"https://api.github.com/users/docker-java/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/docker-java/subscriptions","organizations_url":"https://api.github.com/users/docker-java/orgs","repos_url":"https://api.github.com/users/docker-java/repos","events_url":"https://api.github.com/users/docker-java/events{/privacy}","received_events_url":"https://api.github.com/users/docker-java/received_events","type":"Organization","site_admin":false},"repo":{"id":20415251,"name":"docker-java","full_name":"docker-java/docker-java","owner":{"login":"docker-java","id":7772003,"avatar_url":"https://avatars.githubusercontent.com/u/7772003?v=3","gravatar_id":"","url":"https://api.github.com/users/docker-java","html_url":"https://github.com/docker-java","followers_url":"https://api.github.com/users/docker-java/followers","following_url":"https://api.github.com/users/docker-java/following{/other_user}","gists_url":"https://api.github.com/users/docker-java/gists{/gist_id}","starred_url":"https://api.github.com/users/docker-java/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/docker-java/subscriptions","organizations_url":"https://api.github.com/users/docker-java/orgs","repos_url":"https://api.github.com/users/docker-java/repos","events_url":"https://api.github.com/users/docker-java/events{/privacy}","received_events_url":"https://api.github.com/users/docker-java/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/docker-java/docker-java","description":"Java Docker API Client","fork":false,"url":"https://api.github.com/repos/docker-java/docker-java","forks_url":"https://api.github.com/repos/docker-java/docker-java/forks","keys_url":"https://api.github.com/repos/docker-java/docker-java/keys{/key_id}","collaborators_url":"https://api.github.com/repos/docker-java/docker-java/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/docker-java/docker-java/teams","hooks_url":"https://api.github.com/repos/docker-java/docker-java/hooks","issue_events_url":"https://api.github.com/repos/docker-java/docker-java/issues/events{/number}","events_url":"https://api.github.com/repos/docker-java/docker-java/events","assignees_url":"https://api.github.com/repos/docker-java/docker-java/assignees{/user}","branches_url":"https://api.github.com/repos/docker-java/docker-java/branches{/branch}","tags_url":"https://api.github.com/repos/docker-java/docker-java/tags","blobs_url":"https://api.github.com/repos/docker-java/docker-java/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/docker-java/docker-java/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/docker-java/docker-java/git/refs{/sha}","trees_url":"https://api.github.com/repos/docker-java/docker-java/git/trees{/sha}","statuses_url":"https://api.github.com/repos/docker-java/docker-java/statuses/{sha}","languages_url":"https://api.github.com/repos/docker-java/docker-java/languages","stargazers_url":"https://api.github.com/repos/docker-java/docker-java/stargazers","contributors_url":"https://api.github.com/repos/docker-java/docker-java/contributors","subscribers_url":"https://api.github.com/repos/docker-java/docker-java/subscribers","subscription_url":"https://api.github.com/repos/docker-java/docker-java/subscription","commits_url":"https://api.github.com/repos/docker-java/docker-java/commits{/sha}","git_commits_url":"https://api.github.com/repos/docker-java/docker-java/git/commits{/sha}","comments_url":"https://api.github.com/repos/docker-java/docker-java/comments{/number}","issue_comment_url":"https://api.github.com/repos/docker-java/docker-java/issues/comments{/number}","contents_url":"https://api.github.com/repos/docker-java/docker-java/contents/{+path}","compare_url":"https://api.github.com/repos/docker-java/docker-java/compare/{base}...{head}","merges_url":"https://api.github.com/repos/docker-java/docker-java/merges","archive_url":"https://api.github.com/repos/docker-java/docker-java/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/docker-java/docker-java/downloads","issues_url":"https://api.github.com/repos/docker-java/docker-java/issues{/number}","pulls_url":"https://api.github.com/repos/docker-java/docker-java/pulls{/number}","milestones_url":"https://api.github.com/repos/docker-java/docker-java/milestones{/number}","notifications_url":"https://api.github.com/repos/docker-java/docker-java/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/docker-java/docker-java/labels{/name}","releases_url":"https://api.github.com/repos/docker-java/docker-java/releases{/id}","deployments_url":"https://api.github.com/repos/docker-java/docker-java/deployments","created_at":"2014-06-02T18:47:31Z","updated_at":"2017-02-14T07:10:47Z","pushed_at":"2017-02-14T22:30:44Z","git_url":"git://github.com/docker-java/docker-java.git","ssh_url":"git@github.com:docker-java/docker-java.git","clone_url":"https://github.com/docker-java/docker-java.git","svn_url":"https://github.com/docker-java/docker-java","homepage":"","size":4916,"stargazers_count":637,"watchers_count":637,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":413,"mirror_url":null,"open_issues_count":107,"forks":413,"open_issues":107,"watchers":637,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/docker-java/docker-java/pulls/724"},"html":{"href":"https://github.com/docker-java/docker-java/pull/724"},"issue":{"href":"https://api.github.com/repos/docker-java/docker-java/issues/724"},"comments":{"href":"https://api.github.com/repos/docker-java/docker-java/issues/724/comments"},"review_comments":{"href":"https://api.github.com/repos/docker-java/docker-java/pulls/724/comments"},"review_comment":{"href":"https://api.github.com/repos/docker-java/docker-java/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/docker-java/docker-java/pulls/724/commits"},"statuses":{"href":"https://api.github.com/repos/docker-java/docker-java/statuses/9d2c93e5eacf4807f5368d28c3277d85aa6bd546"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":2,"review_comments":2,"maintainer_can_modify":true,"commits":2,"additions":14,"deletions":0,"changed_files":1}}
{"actor":{"display_login":"KostyaSha"}}