{"action":"opened","number":33271,"pull_request":{"url":"https://api.github.com/repos/moby/moby/pulls/33271","id":121299973,"html_url":"https://github.com/moby/moby/pull/33271","diff_url":"https://github.com/moby/moby/pull/33271.diff","patch_url":"https://github.com/moby/moby/pull/33271.patch","issue_url":"https://api.github.com/repos/moby/moby/issues/33271","number":33271,"state":"open","locked":false,"title":"Improved poor memory efficiency of awslogs","user":{"login":"masahide","id":1309029,"avatar_url":"https://avatars2.githubusercontent.com/u/1309029?v=3","gravatar_id":"","url":"https://api.github.com/users/masahide","html_url":"https://github.com/masahide","followers_url":"https://api.github.com/users/masahide/followers","following_url":"https://api.github.com/users/masahide/following{/other_user}","gists_url":"https://api.github.com/users/masahide/gists{/gist_id}","starred_url":"https://api.github.com/users/masahide/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masahide/subscriptions","organizations_url":"https://api.github.com/users/masahide/orgs","repos_url":"https://api.github.com/users/masahide/repos","events_url":"https://api.github.com/users/masahide/events{/privacy}","received_events_url":"https://api.github.com/users/masahide/received_events","type":"User","site_admin":false},"body":"Signed-off-by: YAMASAKI Masahide <masahide.y@gmail.com>\r\n\r\n<!--\r\nPlease make sure you've read and understood our contributing guidelines;\r\nhttps://github.com/docker/docker/blob/master/CONTRIBUTING.md\r\n\r\n** Make sure all your commits include a signature generated with `git commit -s` **\r\n\r\nFor additional information on our contributing process, read our contributing\r\nguide https://docs.docker.com/opensource/code/\r\n\r\nIf this is a bug fix, make sure your description includes \"fixes #xxxx\", or\r\n\"closes #xxxx\"\r\n\r\nPlease provide the following information:\r\n-->\r\n\r\n**- What I did**\r\nI fixed it because I found an inefficient code to repeat append to slice.\r\n\r\n**- How I did it**\r\nMake slice secured by make () beforehand.\r\n\r\n**- How to verify it**\r\n\r\n```\r\n$ go test -v -bench . -benchmem\r\nBenchmarkUnwrapEvents-32                           10000            298710 ns/op          386328 B/op         21 allocs/op\r\nBenchmarkUnwrapEventsNew-32                        50000             39756 ns/op           81952 B/op          2 allocs/op\r\nPASS\r\nok      github.com/moby/moby/daemon/logger/awslogs      20.450s\r\n```\r\n\r\n**- Description for the changelog**\r\n<!--\r\nWrite a short (one line) summary that describes the changes in this\r\npull request for inclusion in the changelog:\r\n-->\r\n\r\n\r\n**- A picture of a cute animal (not mandatory but encouraged)**\r\n","created_at":"2017-05-18T14:38:52Z","updated_at":"2017-05-18T14:38:52Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/moby/moby/pulls/33271/commits","review_comments_url":"https://api.github.com/repos/moby/moby/pulls/33271/comments","review_comment_url":"https://api.github.com/repos/moby/moby/pulls/comments{/number}","comments_url":"https://api.github.com/repos/moby/moby/issues/33271/comments","statuses_url":"https://api.github.com/repos/moby/moby/statuses/524f30634018ce619da61aa0a13dad245e098226","head":{"label":"masahide:fix-append-loop-awslogs","ref":"fix-append-loop-awslogs","sha":"524f30634018ce619da61aa0a13dad245e098226","user":{"login":"masahide","id":1309029,"avatar_url":"https://avatars2.githubusercontent.com/u/1309029?v=3","gravatar_id":"","url":"https://api.github.com/users/masahide","html_url":"https://github.com/masahide","followers_url":"https://api.github.com/users/masahide/followers","following_url":"https://api.github.com/users/masahide/following{/other_user}","gists_url":"https://api.github.com/users/masahide/gists{/gist_id}","starred_url":"https://api.github.com/users/masahide/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masahide/subscriptions","organizations_url":"https://api.github.com/users/masahide/orgs","repos_url":"https://api.github.com/users/masahide/repos","events_url":"https://api.github.com/users/masahide/events{/privacy}","received_events_url":"https://api.github.com/users/masahide/received_events","type":"User","site_admin":false},"repo":{"id":91670042,"name":"moby","full_name":"masahide/moby","owner":{"login":"masahide","id":1309029,"avatar_url":"https://avatars2.githubusercontent.com/u/1309029?v=3","gravatar_id":"","url":"https://api.github.com/users/masahide","html_url":"https://github.com/masahide","followers_url":"https://api.github.com/users/masahide/followers","following_url":"https://api.github.com/users/masahide/following{/other_user}","gists_url":"https://api.github.com/users/masahide/gists{/gist_id}","starred_url":"https://api.github.com/users/masahide/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masahide/subscriptions","organizations_url":"https://api.github.com/users/masahide/orgs","repos_url":"https://api.github.com/users/masahide/repos","events_url":"https://api.github.com/users/masahide/events{/privacy}","received_events_url":"https://api.github.com/users/masahide/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/masahide/moby","description":"Moby Project - a collaborative project for the container ecosystem to assemble container-based systems","fork":true,"url":"https://api.github.com/repos/masahide/moby","forks_url":"https://api.github.com/repos/masahide/moby/forks","keys_url":"https://api.github.com/repos/masahide/moby/keys{/key_id}","collaborators_url":"https://api.github.com/repos/masahide/moby/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/masahide/moby/teams","hooks_url":"https://api.github.com/repos/masahide/moby/hooks","issue_events_url":"https://api.github.com/repos/masahide/moby/issues/events{/number}","events_url":"https://api.github.com/repos/masahide/moby/events","assignees_url":"https://api.github.com/repos/masahide/moby/assignees{/user}","branches_url":"https://api.github.com/repos/masahide/moby/branches{/branch}","tags_url":"https://api.github.com/repos/masahide/moby/tags","blobs_url":"https://api.github.com/repos/masahide/moby/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/masahide/moby/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/masahide/moby/git/refs{/sha}","trees_url":"https://api.github.com/repos/masahide/moby/git/trees{/sha}","statuses_url":"https://api.github.com/repos/masahide/moby/statuses/{sha}","languages_url":"https://api.github.com/repos/masahide/moby/languages","stargazers_url":"https://api.github.com/repos/masahide/moby/stargazers","contributors_url":"https://api.github.com/repos/masahide/moby/contributors","subscribers_url":"https://api.github.com/repos/masahide/moby/subscribers","subscription_url":"https://api.github.com/repos/masahide/moby/subscription","commits_url":"https://api.github.com/repos/masahide/moby/commits{/sha}","git_commits_url":"https://api.github.com/repos/masahide/moby/git/commits{/sha}","comments_url":"https://api.github.com/repos/masahide/moby/comments{/number}","issue_comment_url":"https://api.github.com/repos/masahide/moby/issues/comments{/number}","contents_url":"https://api.github.com/repos/masahide/moby/contents/{+path}","compare_url":"https://api.github.com/repos/masahide/moby/compare/{base}...{head}","merges_url":"https://api.github.com/repos/masahide/moby/merges","archive_url":"https://api.github.com/repos/masahide/moby/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/masahide/moby/downloads","issues_url":"https://api.github.com/repos/masahide/moby/issues{/number}","pulls_url":"https://api.github.com/repos/masahide/moby/pulls{/number}","milestones_url":"https://api.github.com/repos/masahide/moby/milestones{/number}","notifications_url":"https://api.github.com/repos/masahide/moby/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/masahide/moby/labels{/name}","releases_url":"https://api.github.com/repos/masahide/moby/releases{/id}","deployments_url":"https://api.github.com/repos/masahide/moby/deployments","created_at":"2017-05-18T08:43:28Z","updated_at":"2017-05-18T08:43:50Z","pushed_at":"2017-05-18T14:31:17Z","git_url":"git://github.com/masahide/moby.git","ssh_url":"git@github.com:masahide/moby.git","clone_url":"https://github.com/masahide/moby.git","svn_url":"https://github.com/masahide/moby","homepage":"https://mobyproject.org/","size":129758,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"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":"moby:master","ref":"master","sha":"23e857cd3de399b8894442d49efdc83570995fe4","user":{"login":"moby","id":27259197,"avatar_url":"https://avatars2.githubusercontent.com/u/27259197?v=3","gravatar_id":"","url":"https://api.github.com/users/moby","html_url":"https://github.com/moby","followers_url":"https://api.github.com/users/moby/followers","following_url":"https://api.github.com/users/moby/following{/other_user}","gists_url":"https://api.github.com/users/moby/gists{/gist_id}","starred_url":"https://api.github.com/users/moby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moby/subscriptions","organizations_url":"https://api.github.com/users/moby/orgs","repos_url":"https://api.github.com/users/moby/repos","events_url":"https://api.github.com/users/moby/events{/privacy}","received_events_url":"https://api.github.com/users/moby/received_events","type":"Organization","site_admin":false},"repo":{"id":7691631,"name":"moby","full_name":"moby/moby","owner":{"login":"moby","id":27259197,"avatar_url":"https://avatars2.githubusercontent.com/u/27259197?v=3","gravatar_id":"","url":"https://api.github.com/users/moby","html_url":"https://github.com/moby","followers_url":"https://api.github.com/users/moby/followers","following_url":"https://api.github.com/users/moby/following{/other_user}","gists_url":"https://api.github.com/users/moby/gists{/gist_id}","starred_url":"https://api.github.com/users/moby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moby/subscriptions","organizations_url":"https://api.github.com/users/moby/orgs","repos_url":"https://api.github.com/users/moby/repos","events_url":"https://api.github.com/users/moby/events{/privacy}","received_events_url":"https://api.github.com/users/moby/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/moby/moby","description":"Moby Project - a collaborative project for the container ecosystem to assemble container-based systems","fork":false,"url":"https://api.github.com/repos/moby/moby","forks_url":"https://api.github.com/repos/moby/moby/forks","keys_url":"https://api.github.com/repos/moby/moby/keys{/key_id}","collaborators_url":"https://api.github.com/repos/moby/moby/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/moby/moby/teams","hooks_url":"https://api.github.com/repos/moby/moby/hooks","issue_events_url":"https://api.github.com/repos/moby/moby/issues/events{/number}","events_url":"https://api.github.com/repos/moby/moby/events","assignees_url":"https://api.github.com/repos/moby/moby/assignees{/user}","branches_url":"https://api.github.com/repos/moby/moby/branches{/branch}","tags_url":"https://api.github.com/repos/moby/moby/tags","blobs_url":"https://api.github.com/repos/moby/moby/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/moby/moby/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/moby/moby/git/refs{/sha}","trees_url":"https://api.github.com/repos/moby/moby/git/trees{/sha}","statuses_url":"https://api.github.com/repos/moby/moby/statuses/{sha}","languages_url":"https://api.github.com/repos/moby/moby/languages","stargazers_url":"https://api.github.com/repos/moby/moby/stargazers","contributors_url":"https://api.github.com/repos/moby/moby/contributors","subscribers_url":"https://api.github.com/repos/moby/moby/subscribers","subscription_url":"https://api.github.com/repos/moby/moby/subscription","commits_url":"https://api.github.com/repos/moby/moby/commits{/sha}","git_commits_url":"https://api.github.com/repos/moby/moby/git/commits{/sha}","comments_url":"https://api.github.com/repos/moby/moby/comments{/number}","issue_comment_url":"https://api.github.com/repos/moby/moby/issues/comments{/number}","contents_url":"https://api.github.com/repos/moby/moby/contents/{+path}","compare_url":"https://api.github.com/repos/moby/moby/compare/{base}...{head}","merges_url":"https://api.github.com/repos/moby/moby/merges","archive_url":"https://api.github.com/repos/moby/moby/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/moby/moby/downloads","issues_url":"https://api.github.com/repos/moby/moby/issues{/number}","pulls_url":"https://api.github.com/repos/moby/moby/pulls{/number}","milestones_url":"https://api.github.com/repos/moby/moby/milestones{/number}","notifications_url":"https://api.github.com/repos/moby/moby/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/moby/moby/labels{/name}","releases_url":"https://api.github.com/repos/moby/moby/releases{/id}","deployments_url":"https://api.github.com/repos/moby/moby/deployments","created_at":"2013-01-18T18:10:57Z","updated_at":"2017-05-18T14:21:52Z","pushed_at":"2017-05-18T13:11:13Z","git_url":"git://github.com/moby/moby.git","ssh_url":"git@github.com:moby/moby.git","clone_url":"https://github.com/moby/moby.git","svn_url":"https://github.com/moby/moby","homepage":"https://mobyproject.org/","size":129777,"stargazers_count":43624,"watchers_count":43624,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":12939,"mirror_url":null,"open_issues_count":2624,"forks":12939,"open_issues":2624,"watchers":43624,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/moby/moby/pulls/33271"},"html":{"href":"https://github.com/moby/moby/pull/33271"},"issue":{"href":"https://api.github.com/repos/moby/moby/issues/33271"},"comments":{"href":"https://api.github.com/repos/moby/moby/issues/33271/comments"},"review_comments":{"href":"https://api.github.com/repos/moby/moby/pulls/33271/comments"},"review_comment":{"href":"https://api.github.com/repos/moby/moby/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/moby/moby/pulls/33271/commits"},"statuses":{"href":"https://api.github.com/repos/moby/moby/statuses/524f30634018ce619da61aa0a13dad245e098226"}},"merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":20,"deletions":3,"changed_files":2}}
{"actor":{"display_login":"masahide"}}