{"action":"created","comment":{"url":"https://api.github.com/repos/apache/kafka/pulls/comments/61806157","id":61806157,"diff_hunk":"@@ -268,11 +268,7 @@ public void updateEndOffsets(Map<TopicPartition, Long> newOffsets) {\n     @Override\n     public List<PartitionInfo> partitionsFor(String topic) {\n         ensureNotClosed();\n-        List<PartitionInfo> parts = this.partitions.get(topic);\n-        if (parts == null)\n-            return Collections.emptyList();\n-        else\n-            return parts;\n+        return this.partitions.get(topic);","path":"clients/src/main/java/org/apache/kafka/clients/consumer/MockConsumer.java","position":9,"original_position":9,"commit_id":"4f7c6dc9becb547368f5dac6d508bd071bdfec91","original_commit_id":"4f7c6dc9becb547368f5dac6d508bd071bdfec91","user":{"login":"guozhangwang","id":10729597,"avatar_url":"https://avatars.githubusercontent.com/u/10729597?v=3","gravatar_id":"","url":"https://api.github.com/users/guozhangwang","html_url":"https://github.com/guozhangwang","followers_url":"https://api.github.com/users/guozhangwang/followers","following_url":"https://api.github.com/users/guozhangwang/following{/other_user}","gists_url":"https://api.github.com/users/guozhangwang/gists{/gist_id}","starred_url":"https://api.github.com/users/guozhangwang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guozhangwang/subscriptions","organizations_url":"https://api.github.com/users/guozhangwang/orgs","repos_url":"https://api.github.com/users/guozhangwang/repos","events_url":"https://api.github.com/users/guozhangwang/events{/privacy}","received_events_url":"https://api.github.com/users/guozhangwang/received_events","type":"User","site_admin":false},"body":"Since MockConsumer is used in other cases as well, I think it would be safer to not change it here and let the unit test in Streams which is using MockConsumer to just timeout and throw the `StreamsException` in line 198.","created_at":"2016-05-02T21:17:16Z","updated_at":"2016-05-02T21:17:16Z","html_url":"https://github.com/apache/kafka/pull/1289#discussion_r61806157","pull_request_url":"https://api.github.com/repos/apache/kafka/pulls/1289","_links":{"self":{"href":"https://api.github.com/repos/apache/kafka/pulls/comments/61806157"},"html":{"href":"https://github.com/apache/kafka/pull/1289#discussion_r61806157"},"pull_request":{"href":"https://api.github.com/repos/apache/kafka/pulls/1289"}}},"pull_request":{"url":"https://api.github.com/repos/apache/kafka/pulls/1289","id":68408991,"html_url":"https://github.com/apache/kafka/pull/1289","diff_url":"https://github.com/apache/kafka/pull/1289.diff","patch_url":"https://github.com/apache/kafka/pull/1289.patch","issue_url":"https://api.github.com/repos/apache/kafka/issues/1289","number":1289,"state":"open","locked":false,"title":"KAFKA-3642: Fix NPE from ProcessorStateManager when the changelog topic not exists","user":{"login":"kawamuray","id":2255161,"avatar_url":"https://avatars.githubusercontent.com/u/2255161?v=3","gravatar_id":"","url":"https://api.github.com/users/kawamuray","html_url":"https://github.com/kawamuray","followers_url":"https://api.github.com/users/kawamuray/followers","following_url":"https://api.github.com/users/kawamuray/following{/other_user}","gists_url":"https://api.github.com/users/kawamuray/gists{/gist_id}","starred_url":"https://api.github.com/users/kawamuray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kawamuray/subscriptions","organizations_url":"https://api.github.com/users/kawamuray/orgs","repos_url":"https://api.github.com/users/kawamuray/repos","events_url":"https://api.github.com/users/kawamuray/events{/privacy}","received_events_url":"https://api.github.com/users/kawamuray/received_events","type":"User","site_admin":false},"body":"Issue: https://issues.apache.org/jira/browse/KAFKA-3642","created_at":"2016-04-29T17:53:00Z","updated_at":"2016-05-02T21:17:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2a88daa5a68b5bd002f67f6f2c3be98ec39ab9ef","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/apache/kafka/pulls/1289/commits","review_comments_url":"https://api.github.com/repos/apache/kafka/pulls/1289/comments","review_comment_url":"https://api.github.com/repos/apache/kafka/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/kafka/issues/1289/comments","statuses_url":"https://api.github.com/repos/apache/kafka/statuses/4f7c6dc9becb547368f5dac6d508bd071bdfec91","head":{"label":"kawamuray:KAFKA-3642-streams-NPE","ref":"KAFKA-3642-streams-NPE","sha":"4f7c6dc9becb547368f5dac6d508bd071bdfec91","user":{"login":"kawamuray","id":2255161,"avatar_url":"https://avatars.githubusercontent.com/u/2255161?v=3","gravatar_id":"","url":"https://api.github.com/users/kawamuray","html_url":"https://github.com/kawamuray","followers_url":"https://api.github.com/users/kawamuray/followers","following_url":"https://api.github.com/users/kawamuray/following{/other_user}","gists_url":"https://api.github.com/users/kawamuray/gists{/gist_id}","starred_url":"https://api.github.com/users/kawamuray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kawamuray/subscriptions","organizations_url":"https://api.github.com/users/kawamuray/orgs","repos_url":"https://api.github.com/users/kawamuray/repos","events_url":"https://api.github.com/users/kawamuray/events{/privacy}","received_events_url":"https://api.github.com/users/kawamuray/received_events","type":"User","site_admin":false},"repo":{"id":54791668,"name":"kafka","full_name":"kawamuray/kafka","owner":{"login":"kawamuray","id":2255161,"avatar_url":"https://avatars.githubusercontent.com/u/2255161?v=3","gravatar_id":"","url":"https://api.github.com/users/kawamuray","html_url":"https://github.com/kawamuray","followers_url":"https://api.github.com/users/kawamuray/followers","following_url":"https://api.github.com/users/kawamuray/following{/other_user}","gists_url":"https://api.github.com/users/kawamuray/gists{/gist_id}","starred_url":"https://api.github.com/users/kawamuray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kawamuray/subscriptions","organizations_url":"https://api.github.com/users/kawamuray/orgs","repos_url":"https://api.github.com/users/kawamuray/repos","events_url":"https://api.github.com/users/kawamuray/events{/privacy}","received_events_url":"https://api.github.com/users/kawamuray/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kawamuray/kafka","description":"Mirror of Apache Kafka","fork":true,"url":"https://api.github.com/repos/kawamuray/kafka","forks_url":"https://api.github.com/repos/kawamuray/kafka/forks","keys_url":"https://api.github.com/repos/kawamuray/kafka/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kawamuray/kafka/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kawamuray/kafka/teams","hooks_url":"https://api.github.com/repos/kawamuray/kafka/hooks","issue_events_url":"https://api.github.com/repos/kawamuray/kafka/issues/events{/number}","events_url":"https://api.github.com/repos/kawamuray/kafka/events","assignees_url":"https://api.github.com/repos/kawamuray/kafka/assignees{/user}","branches_url":"https://api.github.com/repos/kawamuray/kafka/branches{/branch}","tags_url":"https://api.github.com/repos/kawamuray/kafka/tags","blobs_url":"https://api.github.com/repos/kawamuray/kafka/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kawamuray/kafka/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kawamuray/kafka/git/refs{/sha}","trees_url":"https://api.github.com/repos/kawamuray/kafka/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kawamuray/kafka/statuses/{sha}","languages_url":"https://api.github.com/repos/kawamuray/kafka/languages","stargazers_url":"https://api.github.com/repos/kawamuray/kafka/stargazers","contributors_url":"https://api.github.com/repos/kawamuray/kafka/contributors","subscribers_url":"https://api.github.com/repos/kawamuray/kafka/subscribers","subscription_url":"https://api.github.com/repos/kawamuray/kafka/subscription","commits_url":"https://api.github.com/repos/kawamuray/kafka/commits{/sha}","git_commits_url":"https://api.github.com/repos/kawamuray/kafka/git/commits{/sha}","comments_url":"https://api.github.com/repos/kawamuray/kafka/comments{/number}","issue_comment_url":"https://api.github.com/repos/kawamuray/kafka/issues/comments{/number}","contents_url":"https://api.github.com/repos/kawamuray/kafka/contents/{+path}","compare_url":"https://api.github.com/repos/kawamuray/kafka/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kawamuray/kafka/merges","archive_url":"https://api.github.com/repos/kawamuray/kafka/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kawamuray/kafka/downloads","issues_url":"https://api.github.com/repos/kawamuray/kafka/issues{/number}","pulls_url":"https://api.github.com/repos/kawamuray/kafka/pulls{/number}","milestones_url":"https://api.github.com/repos/kawamuray/kafka/milestones{/number}","notifications_url":"https://api.github.com/repos/kawamuray/kafka/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kawamuray/kafka/labels{/name}","releases_url":"https://api.github.com/repos/kawamuray/kafka/releases{/id}","deployments_url":"https://api.github.com/repos/kawamuray/kafka/deployments","created_at":"2016-03-26T17:49:09Z","updated_at":"2016-03-26T17:49:13Z","pushed_at":"2016-04-29T17:50:54Z","git_url":"git://github.com/kawamuray/kafka.git","ssh_url":"git@github.com:kawamuray/kafka.git","clone_url":"https://github.com/kawamuray/kafka.git","svn_url":"https://github.com/kawamuray/kafka","homepage":null,"size":30186,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"trunk"}},"base":{"label":"apache:trunk","ref":"trunk","sha":"e29eac4bbb678aa3d5a29a75f413a7b10cc2f0b1","user":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":2211243,"name":"kafka","full_name":"apache/kafka","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars.githubusercontent.com/u/47359?v=3","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/kafka","description":"Mirror of Apache Kafka","fork":false,"url":"https://api.github.com/repos/apache/kafka","forks_url":"https://api.github.com/repos/apache/kafka/forks","keys_url":"https://api.github.com/repos/apache/kafka/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/kafka/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/kafka/teams","hooks_url":"https://api.github.com/repos/apache/kafka/hooks","issue_events_url":"https://api.github.com/repos/apache/kafka/issues/events{/number}","events_url":"https://api.github.com/repos/apache/kafka/events","assignees_url":"https://api.github.com/repos/apache/kafka/assignees{/user}","branches_url":"https://api.github.com/repos/apache/kafka/branches{/branch}","tags_url":"https://api.github.com/repos/apache/kafka/tags","blobs_url":"https://api.github.com/repos/apache/kafka/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/kafka/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/kafka/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/kafka/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/kafka/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/kafka/languages","stargazers_url":"https://api.github.com/repos/apache/kafka/stargazers","contributors_url":"https://api.github.com/repos/apache/kafka/contributors","subscribers_url":"https://api.github.com/repos/apache/kafka/subscribers","subscription_url":"https://api.github.com/repos/apache/kafka/subscription","commits_url":"https://api.github.com/repos/apache/kafka/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/kafka/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/kafka/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/kafka/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/kafka/contents/{+path}","compare_url":"https://api.github.com/repos/apache/kafka/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/kafka/merges","archive_url":"https://api.github.com/repos/apache/kafka/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/kafka/downloads","issues_url":"https://api.github.com/repos/apache/kafka/issues{/number}","pulls_url":"https://api.github.com/repos/apache/kafka/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/kafka/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/kafka/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/kafka/labels{/name}","releases_url":"https://api.github.com/repos/apache/kafka/releases{/id}","deployments_url":"https://api.github.com/repos/apache/kafka/deployments","created_at":"2011-08-15T18:06:16Z","updated_at":"2016-05-02T18:32:44Z","pushed_at":"2016-05-02T21:00:18Z","git_url":"git://github.com/apache/kafka.git","ssh_url":"git@github.com:apache/kafka.git","clone_url":"https://github.com/apache/kafka.git","svn_url":"https://github.com/apache/kafka","homepage":null,"size":40583,"stargazers_count":3040,"watchers_count":3040,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1828,"mirror_url":"git://git.apache.org/kafka.git","open_issues_count":179,"forks":1828,"open_issues":179,"watchers":3040,"default_branch":"trunk"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/kafka/pulls/1289"},"html":{"href":"https://github.com/apache/kafka/pull/1289"},"issue":{"href":"https://api.github.com/repos/apache/kafka/issues/1289"},"comments":{"href":"https://api.github.com/repos/apache/kafka/issues/1289/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/kafka/pulls/1289/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/kafka/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/kafka/pulls/1289/commits"},"statuses":{"href":"https://api.github.com/repos/apache/kafka/statuses/4f7c6dc9becb547368f5dac6d508bd071bdfec91"}}}}