{"action":"created","issue":{"url":"https://api.github.com/repos/olivere/elastic/issues/586","repository_url":"https://api.github.com/repos/olivere/elastic","labels_url":"https://api.github.com/repos/olivere/elastic/issues/586/labels{/name}","comments_url":"https://api.github.com/repos/olivere/elastic/issues/586/comments","events_url":"https://api.github.com/repos/olivere/elastic/issues/586/events","html_url":"https://github.com/olivere/elastic/pull/586","id":251223668,"number":586,"title":"Bind client to specific cluster name","user":{"login":"utrack","id":3862920,"avatar_url":"https://avatars1.githubusercontent.com/u/3862920?v=4","gravatar_id":"","url":"https://api.github.com/users/utrack","html_url":"https://github.com/utrack","followers_url":"https://api.github.com/users/utrack/followers","following_url":"https://api.github.com/users/utrack/following{/other_user}","gists_url":"https://api.github.com/users/utrack/gists{/gist_id}","starred_url":"https://api.github.com/users/utrack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/utrack/subscriptions","organizations_url":"https://api.github.com/users/utrack/orgs","repos_url":"https://api.github.com/users/utrack/repos","events_url":"https://api.github.com/users/utrack/events{/privacy}","received_events_url":"https://api.github.com/users/utrack/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2017-08-18T11:58:12Z","updated_at":"2017-08-19T10:34:32Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/olivere/elastic/pulls/586","html_url":"https://github.com/olivere/elastic/pull/586","diff_url":"https://github.com/olivere/elastic/pull/586.diff","patch_url":"https://github.com/olivere/elastic/pull/586.patch"},"body":"This PR makes client check the node's ClusterName before using it to sniff nodes and/or marking it as healthy.\r\n\r\nCurrently it's possible that one node might go down and get up as a node from different cluster, respond to the sniffer faster than everyone else and effectively take over the client, making it query different cluster. Same can happen on startup if one of seed nodes had been moved to the different cluster."},"comment":{"url":"https://api.github.com/repos/olivere/elastic/issues/comments/323515339","html_url":"https://github.com/olivere/elastic/pull/586#issuecomment-323515339","issue_url":"https://api.github.com/repos/olivere/elastic/issues/586","id":323515339,"user":{"login":"utrack","id":3862920,"avatar_url":"https://avatars1.githubusercontent.com/u/3862920?v=4","gravatar_id":"","url":"https://api.github.com/users/utrack","html_url":"https://github.com/utrack","followers_url":"https://api.github.com/users/utrack/followers","following_url":"https://api.github.com/users/utrack/following{/other_user}","gists_url":"https://api.github.com/users/utrack/gists{/gist_id}","starred_url":"https://api.github.com/users/utrack/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/utrack/subscriptions","organizations_url":"https://api.github.com/users/utrack/orgs","repos_url":"https://api.github.com/users/utrack/repos","events_url":"https://api.github.com/users/utrack/events{/privacy}","received_events_url":"https://api.github.com/users/utrack/received_events","type":"User","site_admin":false},"created_at":"2017-08-19T10:34:32Z","updated_at":"2017-08-19T10:34:32Z","body":"Well, we've hit this on prod when switching to new major version of Elastic. Since it had to be zero-downtime op we were using same physical nodes (nA) to build up a new cluster (cB) that is identical to current setup (cA) power-wise, gradually switch load to the new cluster cB while moving old machines from cA to new cluster as load moves to cB and then removing stand-in nodes nA to do the same later with remaining clusters running old version of Elastic.\r\n\r\nWhile nodes nA were down for ~2min before forming new cluster after transition was completed - client still picked them up somehow and sniffed nodes of completely foreign cluster.\r\n\r\nBesides, it's possible that someone somewhere would want to juggle nodes between clusters if there's high load expected for one of them.\r\n\r\nThis PR doesn't make the cluster binding mandatory, but it would create an additional safeguard for those who want it."}}
{"actor":{"display_login":"utrack"}}