{"action":"created","issue":{"url":"https://api.github.com/repos/Shopify/sarama/issues/312","labels_url":"https://api.github.com/repos/Shopify/sarama/issues/312/labels{/name}","comments_url":"https://api.github.com/repos/Shopify/sarama/issues/312/comments","events_url":"https://api.github.com/repos/Shopify/sarama/issues/312/events","html_url":"https://github.com/Shopify/sarama/issues/312","id":59746180,"number":312,"title":"Export MockBroker in a separate package","user":{"login":"eapache","id":1706826,"avatar_url":"https://avatars.githubusercontent.com/u/1706826?v=3","gravatar_id":"","url":"https://api.github.com/users/eapache","html_url":"https://github.com/eapache","followers_url":"https://api.github.com/users/eapache/followers","following_url":"https://api.github.com/users/eapache/following{/other_user}","gists_url":"https://api.github.com/users/eapache/gists{/gist_id}","starred_url":"https://api.github.com/users/eapache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eapache/subscriptions","organizations_url":"https://api.github.com/users/eapache/orgs","repos_url":"https://api.github.com/users/eapache/repos","events_url":"https://api.github.com/users/eapache/events{/privacy}","received_events_url":"https://api.github.com/users/eapache/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Shopify/sarama/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":15,"created_at":"2015-03-04T03:40:47Z","updated_at":"2015-03-26T14:58:08Z","closed_at":null,"body":"Per https://github.com/Shopify/sarama/pull/307#issuecomment-77089589 and https://github.com/Shopify/sarama/pull/307#issuecomment-77091338 this functionality *is* useful to other people, it just shouldn't live as part of Sarama's API.\r\n\r\nI know @wvanbergen had plans to add a bunch of functionality to it, so splitting it out will also make that easier.\r\n\r\nCurrently the only road-block is it's use of the private `encoder` type, but that can just be replaced with `[]byte` and the tests can encode the packets ahead of time. This will actually make it more flexible too, by permitting us to test what happens when the broker gives us back garbage packets.\r\n\r\n@yagnik  this is a nice not-entirely-trivial but danger-free ticket if you're looking to work on your go.\r\n\r\ncc @Shopify/kafka @schleppy"},"comment":{"url":"https://api.github.com/repos/Shopify/sarama/issues/comments/86552586","html_url":"https://github.com/Shopify/sarama/issues/312#issuecomment-86552586","issue_url":"https://api.github.com/repos/Shopify/sarama/issues/312","id":86552586,"user":{"login":"sybrandy","id":1188879,"avatar_url":"https://avatars.githubusercontent.com/u/1188879?v=3","gravatar_id":"","url":"https://api.github.com/users/sybrandy","html_url":"https://github.com/sybrandy","followers_url":"https://api.github.com/users/sybrandy/followers","following_url":"https://api.github.com/users/sybrandy/following{/other_user}","gists_url":"https://api.github.com/users/sybrandy/gists{/gist_id}","starred_url":"https://api.github.com/users/sybrandy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sybrandy/subscriptions","organizations_url":"https://api.github.com/users/sybrandy/orgs","repos_url":"https://api.github.com/users/sybrandy/repos","events_url":"https://api.github.com/users/sybrandy/events{/privacy}","received_events_url":"https://api.github.com/users/sybrandy/received_events","type":"User","site_admin":false},"created_at":"2015-03-26T14:58:08Z","updated_at":"2015-03-26T14:58:08Z","body":"As for adding topic/partition to the consumer, will they still be part of the client?  Since I instantiate both in my code, I'd rather instantiate just the client once, then create the producer and consumers from that one client.  (This reads from multiple topics.  I know, probably an odd use case.)"}}