add reason param to quarantine method

This commit is contained in:
Patrik Nordwall 2016-09-07 16:07:29 +02:00
parent 9a7d79c882
commit 3b7a7dfa59
16 changed files with 28 additions and 23 deletions

View file

@ -158,7 +158,7 @@ private[akka] class RemoteWatcher(
watchingNodes foreach { a
if (!unreachable(a) && !failureDetector.isAvailable(a)) {
log.warning("Detected unreachable: [{}]", a)
quarantine(a, addressUids.get(a))
quarantine(a, addressUids.get(a), "Deemed unreachable by remote failure detector")
publishAddressTerminated(a)
unreachable += a
}
@ -167,8 +167,8 @@ private[akka] class RemoteWatcher(
def publishAddressTerminated(address: Address): Unit =
AddressTerminatedTopic(context.system).publish(AddressTerminated(address))
def quarantine(address: Address, uid: Option[Int]): Unit =
remoteProvider.quarantine(address, uid)
def quarantine(address: Address, uid: Option[Int], reason: String): Unit =
remoteProvider.quarantine(address, uid, reason)
def addWatch(watchee: InternalActorRef, watcher: InternalActorRef): Unit = {
assert(watcher != self)
@ -282,4 +282,4 @@ private[akka] class RemoteWatcher(
log.debug("Re-watch [{} -> {}]", watcher.path, watchee.path)
watchee.sendSystemMessage(Watch(watchee, watcher)) // ➡➡➡ NEVER SEND THE SAME SYSTEM MESSAGE OBJECT TO TWO ACTORS ⬅⬅⬅
}
}
}