{"action":"created","issue":{"url":"https://api.github.com/repos/akka/akka/issues/17202","labels_url":"https://api.github.com/repos/akka/akka/issues/17202/labels{/name}","comments_url":"https://api.github.com/repos/akka/akka/issues/17202/comments","events_url":"https://api.github.com/repos/akka/akka/issues/17202/events","html_url":"https://github.com/akka/akka/pull/17202","id":68621552,"number":17202,"title":"=str #17200 Stop shard region when MemberRemoved","user":{"login":"patriknw","id":336161,"avatar_url":"https://avatars.githubusercontent.com/u/336161?v=3","gravatar_id":"","url":"https://api.github.com/users/patriknw","html_url":"https://github.com/patriknw","followers_url":"https://api.github.com/users/patriknw/followers","following_url":"https://api.github.com/users/patriknw/following{/other_user}","gists_url":"https://api.github.com/users/patriknw/gists{/gist_id}","starred_url":"https://api.github.com/users/patriknw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patriknw/subscriptions","organizations_url":"https://api.github.com/users/patriknw/orgs","repos_url":"https://api.github.com/users/patriknw/repos","events_url":"https://api.github.com/users/patriknw/events{/privacy}","received_events_url":"https://api.github.com/users/patriknw/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/akka/akka/labels/tested","name":"tested","color":"d7e102"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-04-15T09:08:33Z","updated_at":"2015-04-15T18:03:35Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/akka/akka/pulls/17202","html_url":"https://github.com/akka/akka/pull/17202","diff_url":"https://github.com/akka/akka/pull/17202.diff","patch_url":"https://github.com/akka/akka/pull/17202.patch"},"body":""},"comment":{"url":"https://api.github.com/repos/akka/akka/issues/comments/93506159","html_url":"https://github.com/akka/akka/pull/17202#issuecomment-93506159","issue_url":"https://api.github.com/repos/akka/akka/issues/17202","id":93506159,"user":{"login":"patriknw","id":336161,"avatar_url":"https://avatars.githubusercontent.com/u/336161?v=3","gravatar_id":"","url":"https://api.github.com/users/patriknw","html_url":"https://github.com/patriknw","followers_url":"https://api.github.com/users/patriknw/followers","following_url":"https://api.github.com/users/patriknw/following{/other_user}","gists_url":"https://api.github.com/users/patriknw/gists{/gist_id}","starred_url":"https://api.github.com/users/patriknw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/patriknw/subscriptions","organizations_url":"https://api.github.com/users/patriknw/orgs","repos_url":"https://api.github.com/users/patriknw/repos","events_url":"https://api.github.com/users/patriknw/events{/privacy}","received_events_url":"https://api.github.com/users/patriknw/received_events","type":"User","site_admin":false},"created_at":"2015-04-15T18:03:35Z","updated_at":"2015-04-15T18:03:35Z","body":"Updated with new solution. Two issues:\r\n\r\n1) ShardRegion actor must stop itself when the node is shutting down,\r\n   ie. when receiving MemberRemoved(selfAddress)\r\n\r\n2) ShardCoordinator must not persist anything when the node is shutting\r\n   down. MemberRemoved of other shard regions will trigger Terminated,\r\n   which must not be persisted, because then the next coordinator will\r\n   replay those events and end up in wrong state. This is a problem\r\n   announced itself when using leaving as illustrated in the new test.\r\n\r\nTo solve the second issue I have added a new ClusterShuttingDown event\r\nthat is published before the MemberRemoved events. Note that Terminated\r\nis triggered by MemberRemoved."}}