Merge pull request #1344 from akka/wip-quarantining-in-ClusterRemoteWatcher-patriknw
Quarantine from ClusterRemoteWatcher also, see #2993
This commit is contained in:
commit
c7db89e9ab
2 changed files with 6 additions and 3 deletions
|
|
@ -82,6 +82,7 @@ private[cluster] class ClusterRemoteWatcher(
|
|||
takeOverResponsibility(m.address)
|
||||
case MemberRemoved(m) ⇒
|
||||
clusterNodes -= m.address
|
||||
quarantine(m.address, m.uniqueAddress.uid)
|
||||
publishAddressTerminated(m.address)
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -184,15 +184,17 @@ private[akka] class RemoteWatcher(
|
|||
watchingNodes foreach { a ⇒
|
||||
if (!unreachable(a) && !failureDetector.isAvailable(a)) {
|
||||
log.warning("Detected unreachable: [{}]", a)
|
||||
addressUids.get(a) foreach { uid ⇒ quarantine(a, uid) }
|
||||
publishAddressTerminated(a)
|
||||
unreachable += a
|
||||
}
|
||||
}
|
||||
|
||||
def publishAddressTerminated(address: Address): Unit = {
|
||||
addressUids.get(address) foreach { uid ⇒ remoteProvider.quarantine(address, uid) }
|
||||
def publishAddressTerminated(address: Address): Unit =
|
||||
context.system.eventStream.publish(AddressTerminated(address))
|
||||
}
|
||||
|
||||
def quarantine(address: Address, uid: Int): Unit =
|
||||
remoteProvider.quarantine(address, uid)
|
||||
|
||||
def watchRemote(watchee: ActorRef, watcher: ActorRef): Unit =
|
||||
if (watchee.path.uid == akka.actor.ActorCell.undefinedUid)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue