{"action":"created","issue":{"url":"https://api.github.com/repos/felixge/node-mysql/issues/1007","labels_url":"https://api.github.com/repos/felixge/node-mysql/issues/1007/labels{/name}","comments_url":"https://api.github.com/repos/felixge/node-mysql/issues/1007/comments","events_url":"https://api.github.com/repos/felixge/node-mysql/issues/1007/events","html_url":"https://github.com/felixge/node-mysql/pull/1007","id":58461798,"number":1007,"title":"PoolCluster node remove method","user":{"login":"MalyshevDmitry","id":1517140,"avatar_url":"https://avatars.githubusercontent.com/u/1517140?v=3","gravatar_id":"","url":"https://api.github.com/users/MalyshevDmitry","html_url":"https://github.com/MalyshevDmitry","followers_url":"https://api.github.com/users/MalyshevDmitry/followers","following_url":"https://api.github.com/users/MalyshevDmitry/following{/other_user}","gists_url":"https://api.github.com/users/MalyshevDmitry/gists{/gist_id}","starred_url":"https://api.github.com/users/MalyshevDmitry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MalyshevDmitry/subscriptions","organizations_url":"https://api.github.com/users/MalyshevDmitry/orgs","repos_url":"https://api.github.com/users/MalyshevDmitry/repos","events_url":"https://api.github.com/users/MalyshevDmitry/events{/privacy}","received_events_url":"https://api.github.com/users/MalyshevDmitry/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/felixge/node-mysql/labels/patch","name":"patch","color":"ff00f7"}],"state":"open","locked":false,"assignee":{"login":"dougwilson","id":67512,"avatar_url":"https://avatars.githubusercontent.com/u/67512?v=3","gravatar_id":"","url":"https://api.github.com/users/dougwilson","html_url":"https://github.com/dougwilson","followers_url":"https://api.github.com/users/dougwilson/followers","following_url":"https://api.github.com/users/dougwilson/following{/other_user}","gists_url":"https://api.github.com/users/dougwilson/gists{/gist_id}","starred_url":"https://api.github.com/users/dougwilson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dougwilson/subscriptions","organizations_url":"https://api.github.com/users/dougwilson/orgs","repos_url":"https://api.github.com/users/dougwilson/repos","events_url":"https://api.github.com/users/dougwilson/events{/privacy}","received_events_url":"https://api.github.com/users/dougwilson/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-02-21T14:54:27Z","updated_at":"2015-02-25T19:54:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/felixge/node-mysql/pulls/1007","html_url":"https://github.com/felixge/node-mysql/pull/1007","diff_url":"https://github.com/felixge/node-mysql/pull/1007.diff","patch_url":"https://github.com/felixge/node-mysql/pull/1007.patch"},"body":"Added poolCluster.remove() method, which helps to remove nodes from cluster:\r\n\r\n```js\r\n// create\r\nvar poolCluster = mysql.createPoolCluster();\r\n\r\npoolCluster.add(config); // anonymous group\r\npoolCluster.add('MASTER', masterConfig);\r\npoolCluster.add('SLAVE1', slave1Config);\r\npoolCluster.add('SLAVE2', slave2Config);\r\n\r\n// remove manually\r\npoolCluster.remove('SLAVE2'); // By nodeId\r\npoolCluster.remove('SLAVE*'); // By target group : SLAVE1-2\r\n\r\n// event on manually removing (for each node)\r\npoolCluster.on('removeManually', function (nodeId) {\r\n  console.log('REMOVED MANUALLY NODE: ' + nodeId); // nodeId = SLAVE1\r\n});\r\n\r\n// event on auto removing (i.e. when connection was lost)\r\npoolCluster.on('remove', function (nodeId) {\r\n  console.log('REMOVED NODE : ' + nodeId); // nodeId = SLAVE1\r\n});\r\n```"},"comment":{"url":"https://api.github.com/repos/felixge/node-mysql/issues/comments/76042188","html_url":"https://github.com/felixge/node-mysql/pull/1007#issuecomment-76042188","issue_url":"https://api.github.com/repos/felixge/node-mysql/issues/1007","id":76042188,"user":{"login":"jonathandelgado","id":1841149,"avatar_url":"https://avatars.githubusercontent.com/u/1841149?v=3","gravatar_id":"","url":"https://api.github.com/users/jonathandelgado","html_url":"https://github.com/jonathandelgado","followers_url":"https://api.github.com/users/jonathandelgado/followers","following_url":"https://api.github.com/users/jonathandelgado/following{/other_user}","gists_url":"https://api.github.com/users/jonathandelgado/gists{/gist_id}","starred_url":"https://api.github.com/users/jonathandelgado/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonathandelgado/subscriptions","organizations_url":"https://api.github.com/users/jonathandelgado/orgs","repos_url":"https://api.github.com/users/jonathandelgado/repos","events_url":"https://api.github.com/users/jonathandelgado/events{/privacy}","received_events_url":"https://api.github.com/users/jonathandelgado/received_events","type":"User","site_admin":false},"created_at":"2015-02-25T19:54:06Z","updated_at":"2015-02-25T19:54:06Z","body":"Awesome feature!"}}