public static void TrackActorStopped(string name) { if (!MonitoringSystems.IsEnabled) { return; } MonitoringSystems.TrackEvent(MetricEvents.ActorStopped, MetricProperties.For().Actor(name).Build()); MonitoringSystems.UpdateCounter(MetricCounters.ActorsStopped); MonitoringSystems.UpdateCounter(MetricCounters.ActorCounter(MetricCounters.ActorStopped, name)); }
public static void TrackActorCreated(string name, Type type, string parentName) { if (!MonitoringSystems.IsEnabled) { return; } MonitoringSystems.TrackEvent(MetricEvents.ActorCreated, MetricProperties.For().Actor(name).Type(type).ActorParent(parentName).Build()); MonitoringSystems.UpdateCounter(MetricCounters.ActorsCreated); MonitoringSystems.UpdateCounter(MetricCounters.ActorCounter(MetricCounters.ActorCreated, name)); }
public static void TrackReceivedMessage(string name, object message) { if (!MonitoringSystems.IsEnabled || !TrackReceivedMessagesEnabled) { return; } MonitoringSystems.TrackEvent(MetricEvents.ActorReceivedMessage, MetricProperties.For() .Actor(name) .Type(message.GetType()) .Message(message) .Build()); }
public static void TrackActorRestarted(string name, Exception ex) { if (!MonitoringSystems.IsEnabled) { return; } MonitoringSystems.TrackEvent(MetricEvents.ActorRestarted, MetricProperties.For() .Actor(name) .Exception(ex) .Build()); MonitoringSystems.UpdateCounter(MetricCounters.ActorsRestarted); MonitoringSystems.UpdateCounter(MetricCounters.ActorCounter(MetricCounters.ActorRestarted, name)); }
public static void TrackDeadLetter(string sender, string recipient, object message) { if (!MonitoringSystems.IsEnabled) { return; } MonitoringSystems.TrackEvent(MetricEvents.ActorDeadLetter, MetricProperties.For() .Actor(sender) .ActorRecipient(recipient) .Type(message.GetType()) .Message(message) .Build()); MonitoringSystems.UpdateCounter(MetricCounters.ActorsDeadLetters); }