{"action":"created","issue":{"url":"https://api.github.com/repos/airbnb/kafkat/issues/5","labels_url":"https://api.github.com/repos/airbnb/kafkat/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/airbnb/kafkat/issues/5/comments","events_url":"https://api.github.com/repos/airbnb/kafkat/issues/5/events","html_url":"https://github.com/airbnb/kafkat/pull/5","id":87566009,"number":5,"title":"Add drain command","user":{"login":"lucaluo","id":3938144,"avatar_url":"https://avatars.githubusercontent.com/u/3938144?v=3","gravatar_id":"","url":"https://api.github.com/users/lucaluo","html_url":"https://github.com/lucaluo","followers_url":"https://api.github.com/users/lucaluo/followers","following_url":"https://api.github.com/users/lucaluo/following{/other_user}","gists_url":"https://api.github.com/users/lucaluo/gists{/gist_id}","starred_url":"https://api.github.com/users/lucaluo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lucaluo/subscriptions","organizations_url":"https://api.github.com/users/lucaluo/orgs","repos_url":"https://api.github.com/users/lucaluo/repos","events_url":"https://api.github.com/users/lucaluo/events{/privacy}","received_events_url":"https://api.github.com/users/lucaluo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-06-12T01:23:56Z","updated_at":"2015-06-15T19:11:19Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/airbnb/kafkat/pulls/5","html_url":"https://github.com/airbnb/kafkat/pull/5","diff_url":"https://github.com/airbnb/kafkat/pull/5.diff","patch_url":"https://github.com/airbnb/kafkat/pull/5.patch"},"body":"to: @alexism \r\n\r\nWhen we need to reassign replicas from a broker to other brokers,\r\nsay, when the broker is dead, we used to use `reassign` command,\r\nwhich reassign all replicas randomly, whereas replicas on healthy\r\nbrokers might be moved around. This is unefficient.\r\n\r\nIn this PR, I bring into a new command `drain`, which essentially\r\nempty a specific broker and assign its replicas to a list of\r\nhealthy ones. Replicas on healthy brokers will not be moved around.\r\n\r\nUsage:\r\ndrain <broker id> [topic] [--brokers <ids>]\r\n\r\nTests are also be brought into this repo, start from covering the\r\nnew command."},"comment":{"url":"https://api.github.com/repos/airbnb/kafkat/issues/comments/112177291","html_url":"https://github.com/airbnb/kafkat/pull/5#issuecomment-112177291","issue_url":"https://api.github.com/repos/airbnb/kafkat/issues/5","id":112177291,"user":{"login":"alexism","id":5115,"avatar_url":"https://avatars.githubusercontent.com/u/5115?v=3","gravatar_id":"","url":"https://api.github.com/users/alexism","html_url":"https://github.com/alexism","followers_url":"https://api.github.com/users/alexism/followers","following_url":"https://api.github.com/users/alexism/following{/other_user}","gists_url":"https://api.github.com/users/alexism/gists{/gist_id}","starred_url":"https://api.github.com/users/alexism/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexism/subscriptions","organizations_url":"https://api.github.com/users/alexism/orgs","repos_url":"https://api.github.com/users/alexism/repos","events_url":"https://api.github.com/users/alexism/events{/privacy}","received_events_url":"https://api.github.com/users/alexism/received_events","type":"User","site_admin":false},"created_at":"2015-06-15T19:11:19Z","updated_at":"2015-06-15T19:11:19Z","body":"Looking good! Let's integrate the code review, and merge soon.\r\n\r\nthank you for this PR!"}}