Akka.Cluster.Utility.ClusterActorDiscovery.Handle C# (CSharp) Метод

Handle() приватный Метод

private Handle ( Terminated m ) : void
m Akka.Actor.Terminated
Результат void
        private void Handle(Terminated m)
        {
            _log.Debug($"Terminated: Actor={m.ActorRef.Path}");

            int[] counts;
            if (_actorWatchCountMap.TryGetValue(m.ActorRef, out counts) == false)
                return;

            if (counts[1] > 0)
            {
                _monitorItems.RemoveAll(w => w.Actor.Equals(Sender));
                counts[1] = 0;
            }

            if (counts[0] > 0)
            {
                var index = _actorItems.FindIndex(a => a.Actor.Equals(m.ActorRef));
                if (index != -1)
                {
                    var tag = _actorItems[index].Tag;
                    _actorItems.RemoveAt(index);

                    // tell monitors & other discovery actors that local actor down

                    NotifyActorDownToMonitor(m.ActorRef, tag);
                    foreach (var discoveryActor in _nodeMap.Keys)
                        discoveryActor.Tell(new ClusterActorDiscoveryMessage.ClusterActorDown(m.ActorRef));
                }
            }
        }

Same methods

ClusterActorDiscovery::Handle ( ClusterActorDiscoveryMessage m ) : void
ClusterActorDiscovery::Handle ( ClusterEvent m ) : void