{"action":"created","comment":{"url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/comments/45816246","id":45816246,"diff_hunk":"@@ -41,6 +43,32 @@ class StreamChunker(inStream: InputStream, bufferSize: Int) extends Iterator[(By\n     }\n   }\n \n+  // Read from the input stream until the buffer is completely filled (or stream is finished)\n+  private def readToCapacity(input: InputStream, buffer: Array[Byte]): Int = {","path":"src/main/scala/com.socrata.snapshotter/StreamChunker.scala","position":35,"original_position":35,"commit_id":"7b1d84700797bfbac32e9360b25be6666110b47c","original_commit_id":"7b1d84700797bfbac32e9360b25be6666110b47c","user":{"login":"vilterp","id":7341,"avatar_url":"https://avatars.githubusercontent.com/u/7341?v=3","gravatar_id":"","url":"https://api.github.com/users/vilterp","html_url":"https://github.com/vilterp","followers_url":"https://api.github.com/users/vilterp/followers","following_url":"https://api.github.com/users/vilterp/following{/other_user}","gists_url":"https://api.github.com/users/vilterp/gists{/gist_id}","starred_url":"https://api.github.com/users/vilterp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vilterp/subscriptions","organizations_url":"https://api.github.com/users/vilterp/orgs","repos_url":"https://api.github.com/users/vilterp/repos","events_url":"https://api.github.com/users/vilterp/events{/privacy}","received_events_url":"https://api.github.com/users/vilterp/received_events","type":"User","site_admin":false},"body":"Would prefer `Option[Int]` to -1 to denote an error","created_at":"2015-11-25T00:37:25Z","updated_at":"2015-11-25T00:37:25Z","html_url":"https://github.com/socrata-platform/snapshotter/pull/4#discussion_r45816246","pull_request_url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4","_links":{"self":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/comments/45816246"},"html":{"href":"https://github.com/socrata-platform/snapshotter/pull/4#discussion_r45816246"},"pull_request":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4"}}},"pull_request":{"url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4","id":51698152,"html_url":"https://github.com/socrata-platform/snapshotter/pull/4","diff_url":"https://github.com/socrata-platform/snapshotter/pull/4.diff","patch_url":"https://github.com/socrata-platform/snapshotter/pull/4.patch","issue_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues/4","number":4,"state":"open","locked":false,"title":"Read refactor","user":{"login":"catstavi","id":3943665,"avatar_url":"https://avatars.githubusercontent.com/u/3943665?v=3","gravatar_id":"","url":"https://api.github.com/users/catstavi","html_url":"https://github.com/catstavi","followers_url":"https://api.github.com/users/catstavi/followers","following_url":"https://api.github.com/users/catstavi/following{/other_user}","gists_url":"https://api.github.com/users/catstavi/gists{/gist_id}","starred_url":"https://api.github.com/users/catstavi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/catstavi/subscriptions","organizations_url":"https://api.github.com/users/catstavi/orgs","repos_url":"https://api.github.com/users/catstavi/repos","events_url":"https://api.github.com/users/catstavi/events{/privacy}","received_events_url":"https://api.github.com/users/catstavi/received_events","type":"User","site_admin":false},"body":"Moves the logic that loops reading from input stream from gzipCompressInputStream into StreamChunker\r\n\r\nThe loop still reads to a guaranteed size (unless finished reading), but does so in blocks larger than 1 byte.","created_at":"2015-11-24T18:30:12Z","updated_at":"2015-11-25T00:37:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"03793ef12d70b64eed663e118bfea7a1c3bf35ae","assignee":{"login":"vilterp","id":7341,"avatar_url":"https://avatars.githubusercontent.com/u/7341?v=3","gravatar_id":"","url":"https://api.github.com/users/vilterp","html_url":"https://github.com/vilterp","followers_url":"https://api.github.com/users/vilterp/followers","following_url":"https://api.github.com/users/vilterp/following{/other_user}","gists_url":"https://api.github.com/users/vilterp/gists{/gist_id}","starred_url":"https://api.github.com/users/vilterp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vilterp/subscriptions","organizations_url":"https://api.github.com/users/vilterp/orgs","repos_url":"https://api.github.com/users/vilterp/repos","events_url":"https://api.github.com/users/vilterp/events{/privacy}","received_events_url":"https://api.github.com/users/vilterp/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4/commits","review_comments_url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4/comments","review_comment_url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/comments{/number}","comments_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues/4/comments","statuses_url":"https://api.github.com/repos/socrata-platform/snapshotter/statuses/7b1d84700797bfbac32e9360b25be6666110b47c","head":{"label":"socrata-platform:readRefactor","ref":"readRefactor","sha":"7b1d84700797bfbac32e9360b25be6666110b47c","user":{"login":"socrata-platform","id":12076358,"avatar_url":"https://avatars.githubusercontent.com/u/12076358?v=3","gravatar_id":"","url":"https://api.github.com/users/socrata-platform","html_url":"https://github.com/socrata-platform","followers_url":"https://api.github.com/users/socrata-platform/followers","following_url":"https://api.github.com/users/socrata-platform/following{/other_user}","gists_url":"https://api.github.com/users/socrata-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/socrata-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/socrata-platform/subscriptions","organizations_url":"https://api.github.com/users/socrata-platform/orgs","repos_url":"https://api.github.com/users/socrata-platform/repos","events_url":"https://api.github.com/users/socrata-platform/events{/privacy}","received_events_url":"https://api.github.com/users/socrata-platform/received_events","type":"Organization","site_admin":false},"repo":{"id":45220460,"name":"snapshotter","full_name":"socrata-platform/snapshotter","owner":{"login":"socrata-platform","id":12076358,"avatar_url":"https://avatars.githubusercontent.com/u/12076358?v=3","gravatar_id":"","url":"https://api.github.com/users/socrata-platform","html_url":"https://github.com/socrata-platform","followers_url":"https://api.github.com/users/socrata-platform/followers","following_url":"https://api.github.com/users/socrata-platform/following{/other_user}","gists_url":"https://api.github.com/users/socrata-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/socrata-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/socrata-platform/subscriptions","organizations_url":"https://api.github.com/users/socrata-platform/orgs","repos_url":"https://api.github.com/users/socrata-platform/repos","events_url":"https://api.github.com/users/socrata-platform/events{/privacy}","received_events_url":"https://api.github.com/users/socrata-platform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/socrata-platform/snapshotter","description":"","fork":false,"url":"https://api.github.com/repos/socrata-platform/snapshotter","forks_url":"https://api.github.com/repos/socrata-platform/snapshotter/forks","keys_url":"https://api.github.com/repos/socrata-platform/snapshotter/keys{/key_id}","collaborators_url":"https://api.github.com/repos/socrata-platform/snapshotter/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/socrata-platform/snapshotter/teams","hooks_url":"https://api.github.com/repos/socrata-platform/snapshotter/hooks","issue_events_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues/events{/number}","events_url":"https://api.github.com/repos/socrata-platform/snapshotter/events","assignees_url":"https://api.github.com/repos/socrata-platform/snapshotter/assignees{/user}","branches_url":"https://api.github.com/repos/socrata-platform/snapshotter/branches{/branch}","tags_url":"https://api.github.com/repos/socrata-platform/snapshotter/tags","blobs_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/refs{/sha}","trees_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/trees{/sha}","statuses_url":"https://api.github.com/repos/socrata-platform/snapshotter/statuses/{sha}","languages_url":"https://api.github.com/repos/socrata-platform/snapshotter/languages","stargazers_url":"https://api.github.com/repos/socrata-platform/snapshotter/stargazers","contributors_url":"https://api.github.com/repos/socrata-platform/snapshotter/contributors","subscribers_url":"https://api.github.com/repos/socrata-platform/snapshotter/subscribers","subscription_url":"https://api.github.com/repos/socrata-platform/snapshotter/subscription","commits_url":"https://api.github.com/repos/socrata-platform/snapshotter/commits{/sha}","git_commits_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/commits{/sha}","comments_url":"https://api.github.com/repos/socrata-platform/snapshotter/comments{/number}","issue_comment_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues/comments{/number}","contents_url":"https://api.github.com/repos/socrata-platform/snapshotter/contents/{+path}","compare_url":"https://api.github.com/repos/socrata-platform/snapshotter/compare/{base}...{head}","merges_url":"https://api.github.com/repos/socrata-platform/snapshotter/merges","archive_url":"https://api.github.com/repos/socrata-platform/snapshotter/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/socrata-platform/snapshotter/downloads","issues_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues{/number}","pulls_url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls{/number}","milestones_url":"https://api.github.com/repos/socrata-platform/snapshotter/milestones{/number}","notifications_url":"https://api.github.com/repos/socrata-platform/snapshotter/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/socrata-platform/snapshotter/labels{/name}","releases_url":"https://api.github.com/repos/socrata-platform/snapshotter/releases{/id}","created_at":"2015-10-30T01:01:38Z","updated_at":"2015-10-30T01:01:53Z","pushed_at":"2015-11-24T23:06:39Z","git_url":"git://github.com/socrata-platform/snapshotter.git","ssh_url":"git@github.com:socrata-platform/snapshotter.git","clone_url":"https://github.com/socrata-platform/snapshotter.git","svn_url":"https://github.com/socrata-platform/snapshotter","homepage":null,"size":38,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"socrata-platform:master","ref":"master","sha":"06cf5f3ab6e9b6579f177677f73f368da8ad7247","user":{"login":"socrata-platform","id":12076358,"avatar_url":"https://avatars.githubusercontent.com/u/12076358?v=3","gravatar_id":"","url":"https://api.github.com/users/socrata-platform","html_url":"https://github.com/socrata-platform","followers_url":"https://api.github.com/users/socrata-platform/followers","following_url":"https://api.github.com/users/socrata-platform/following{/other_user}","gists_url":"https://api.github.com/users/socrata-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/socrata-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/socrata-platform/subscriptions","organizations_url":"https://api.github.com/users/socrata-platform/orgs","repos_url":"https://api.github.com/users/socrata-platform/repos","events_url":"https://api.github.com/users/socrata-platform/events{/privacy}","received_events_url":"https://api.github.com/users/socrata-platform/received_events","type":"Organization","site_admin":false},"repo":{"id":45220460,"name":"snapshotter","full_name":"socrata-platform/snapshotter","owner":{"login":"socrata-platform","id":12076358,"avatar_url":"https://avatars.githubusercontent.com/u/12076358?v=3","gravatar_id":"","url":"https://api.github.com/users/socrata-platform","html_url":"https://github.com/socrata-platform","followers_url":"https://api.github.com/users/socrata-platform/followers","following_url":"https://api.github.com/users/socrata-platform/following{/other_user}","gists_url":"https://api.github.com/users/socrata-platform/gists{/gist_id}","starred_url":"https://api.github.com/users/socrata-platform/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/socrata-platform/subscriptions","organizations_url":"https://api.github.com/users/socrata-platform/orgs","repos_url":"https://api.github.com/users/socrata-platform/repos","events_url":"https://api.github.com/users/socrata-platform/events{/privacy}","received_events_url":"https://api.github.com/users/socrata-platform/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/socrata-platform/snapshotter","description":"","fork":false,"url":"https://api.github.com/repos/socrata-platform/snapshotter","forks_url":"https://api.github.com/repos/socrata-platform/snapshotter/forks","keys_url":"https://api.github.com/repos/socrata-platform/snapshotter/keys{/key_id}","collaborators_url":"https://api.github.com/repos/socrata-platform/snapshotter/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/socrata-platform/snapshotter/teams","hooks_url":"https://api.github.com/repos/socrata-platform/snapshotter/hooks","issue_events_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues/events{/number}","events_url":"https://api.github.com/repos/socrata-platform/snapshotter/events","assignees_url":"https://api.github.com/repos/socrata-platform/snapshotter/assignees{/user}","branches_url":"https://api.github.com/repos/socrata-platform/snapshotter/branches{/branch}","tags_url":"https://api.github.com/repos/socrata-platform/snapshotter/tags","blobs_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/refs{/sha}","trees_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/trees{/sha}","statuses_url":"https://api.github.com/repos/socrata-platform/snapshotter/statuses/{sha}","languages_url":"https://api.github.com/repos/socrata-platform/snapshotter/languages","stargazers_url":"https://api.github.com/repos/socrata-platform/snapshotter/stargazers","contributors_url":"https://api.github.com/repos/socrata-platform/snapshotter/contributors","subscribers_url":"https://api.github.com/repos/socrata-platform/snapshotter/subscribers","subscription_url":"https://api.github.com/repos/socrata-platform/snapshotter/subscription","commits_url":"https://api.github.com/repos/socrata-platform/snapshotter/commits{/sha}","git_commits_url":"https://api.github.com/repos/socrata-platform/snapshotter/git/commits{/sha}","comments_url":"https://api.github.com/repos/socrata-platform/snapshotter/comments{/number}","issue_comment_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues/comments{/number}","contents_url":"https://api.github.com/repos/socrata-platform/snapshotter/contents/{+path}","compare_url":"https://api.github.com/repos/socrata-platform/snapshotter/compare/{base}...{head}","merges_url":"https://api.github.com/repos/socrata-platform/snapshotter/merges","archive_url":"https://api.github.com/repos/socrata-platform/snapshotter/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/socrata-platform/snapshotter/downloads","issues_url":"https://api.github.com/repos/socrata-platform/snapshotter/issues{/number}","pulls_url":"https://api.github.com/repos/socrata-platform/snapshotter/pulls{/number}","milestones_url":"https://api.github.com/repos/socrata-platform/snapshotter/milestones{/number}","notifications_url":"https://api.github.com/repos/socrata-platform/snapshotter/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/socrata-platform/snapshotter/labels{/name}","releases_url":"https://api.github.com/repos/socrata-platform/snapshotter/releases{/id}","created_at":"2015-10-30T01:01:38Z","updated_at":"2015-10-30T01:01:53Z","pushed_at":"2015-11-24T23:06:39Z","git_url":"git://github.com/socrata-platform/snapshotter.git","ssh_url":"git@github.com:socrata-platform/snapshotter.git","clone_url":"https://github.com/socrata-platform/snapshotter.git","svn_url":"https://github.com/socrata-platform/snapshotter","homepage":null,"size":38,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4"},"html":{"href":"https://github.com/socrata-platform/snapshotter/pull/4"},"issue":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/issues/4"},"comments":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/socrata-platform/snapshotter/statuses/7b1d84700797bfbac32e9360b25be6666110b47c"}}}}