Phobos
Enterprise Application Monitoring and Management for Akka.NET OSS
Published by Petabridge
  • last updated 37 day(s) ago
  • 1976 daily downloads
  • 1171506 total downloads
  • Latest version: 2.5.1

Phobos.TestKit 2.1.0

Framework used for testing applications that have been instrumented using Phobos. Makes it feasible to test using data collected from actor traces, monitoring, and so forth.

Install-Package Phobos.TestKit -Version 2.1.0
dotnet add package Phobos.TestKit --version 2.1.0
<PackageReference Include="Phobos.TestKit" Version="2.1.0"/>
paket add Phobos.TestKit --version 2.1.0

Release Notes

Phobos 2.1 Minor Release** Phobos 2.1 is a minor release that has been in the works for a long time and introduces several major features and improvements to the existing Phobos 2.0 experience. Akka.Cluster.Sharding Metrics and Dashboards** Issue: https://github.com/petabridge/phobos-issues/issues/72 One of the things we added support for in Phobos 2.1 is automatically tracking Akka.Cluster.Sharding metrics for each `ShardRegion` for each node capable of hosting any shards - these numbers can be aggregated together to form a complete picture of total shard allocation by type and node throughout your cluster. The new built-in metrics are: `akka.cluster.sharding.shards` - keeps track of the number of shards per node per entity type. `akka.cluster.sharding.entities` - keeps track of the number of entities per node per entity type. More Accurate "Live Actor" Counts** Phobos 2.1 takes advantage of a new actor telemetry feature introduced in [Akka.NET v1.4.47](https://github.com/akkadotnet/akka.net/releases/tag/1.4.47), whihc allows us to use an OpenTelemetry `ObservableGauge` to accurately track the total number of live actors by type and node throughout each of your `ActorSystem`s. > [!IMPORTANT] > In order to use this feature, you will need to set `akka.actor.telemetry.enabled = on` (it's `off` by default.) > > If you use Phobos.Hosting to configure Phobos, this setting will be automatically enabled for you. This value is now tracked via the `akka.actor.live` metric and will show up alongside the normal `akka.actor.created|stopped|restarted` counters. We've already incorporated `akka.actor.live` into our Phobos dashboards. Updated All Phobos Dashboards** We've incorporated all Phobos dashboards to incorporate the following new metric types: `akka.cluster.sharding.shards` - keeps track of the number of shards per node per entity type. `akka.cluster.sharding.entities` - keeps track of the number of entities per node per entity type. `akka.actor.live` - keeps more accurate track of the number of live actors per node by type. Please see "[Phobos Dashboards](https://phobos.petabridge.com/articles/dashboards/index.html)" for the most recent versions of each of these. Akka.Cluster.Sharding Trace Compression** One of the largest feature areas we've worked on for Phobos 2.1 is curtailing the amount of noise produced by Phobos tracing, especially in regards to features like Akka.Cluster.Sharding - where each message to one of your actors produces 2-3 spans recorded by built-in system actors. For starters, we now have the ability to compress Cluster.Sharding traces via an [OpenTelemetry `BaseProcessor<Activity>`](https://github.com/open-telemetry/opentelemetry-dotnet/blob/main/docs/trace/extending-the-sdk/README.md#processor) - and this can be enabled when you're subscribing to Phobos telemetry in your OTel pipeline: ```csharp services.AddOpenTelemetryTracing(builder => { builder .SetResourceBuilder(resource) .AddPhobosInstrumentation(compressShardTraces:true) // eliminate sharding infrastructure from traces .AddHttpClientInstrumentation() .AddAspNetCoreInstrumentation(options => { options.Filter = context => !context. Request.Path.StartsWithSegments("/metrics"); }) .SetSampler(new TraceIdRatioBasedSampler(1.0d)) .AddJaegerExporter(opt => { opt.AgentHost = Environment.GetEnvironmentVariable(JaegerAgentHostEnvironmentVar) ?? "localhost"; }); }); ``` Calling `.AddPhobosInstrumentation(compressShardTraces:true)` will enable trace compression for sharding. This value is set to `false` by default. In addition to these changes, we've also filtered out all internal messages and Akka.DistributedData messages by default. `Ask<T>` Tracing Improvements** We've made many significant improvements to `Ask<T>` tracing in Phobos 2.1: `Ask<T>` tracing can now be disabled via the fluent C# APIs or via `phobos.tracing.trace-ask = off`; `Ask<T>` tracing can now be filtered using the same `ITraceFilter` and other filter rules as regular `akka.actor.recv` statements; `Ask<T>` tracing has been restructured such that we now accurately capture both the input and output types separately - additionally, we are much more accurate in tracking start and stop times than we were previously. [Fixed: `Ask<T>` tracing does not properly follow `Tracer.ActiveSpan`](https://github.com/petabridge/phobos-issues/issues/74) To disable `Ask<T>` tracing via Phobos.Hosting, use the following: ```csharp collection.AddAkka("LocalSys", (builder, sp) => { builder.WithPhobos(AkkaRunMode.Local, configBuilder => configBuilder.WithTracing(t => t.SetTraceAsk(false))); AddTestActors(builder); }); ``` Other General Improvements** [Fixed: Phobos `DeadLetter` logging](https://github.com/petabridge/phobos-issues/issues/73). [Fixed: `Tracer.CurrentSpan` and `PhobosActorContext.ActiveSpan` should be the same when actor is processing message, but currently are not](https://github.com/petabridge/phobos-issues/issues/71). All `IWithTimers` messages are filtered out by default.

Dependencies

.NETStandard

Versions

Version
Downloads
Last Updated
7
37 day(s) ago
7
73 day(s) ago
7
107 day(s) ago
7
142 day(s) ago
3
149 day(s) ago
2
197 day(s) ago
14
220 day(s) ago
106
280 day(s) ago
4
283 day(s) ago
127
338 day(s) ago
169
364 day(s) ago
5
367 day(s) ago
7
367 day(s) ago
16
372 day(s) ago
11
421 day(s) ago
1
422 day(s) ago
9
466 day(s) ago
1
554 day(s) ago
1
627 day(s) ago
51
686 day(s) ago
4
690 day(s) ago
3
694 day(s) ago
5
701 day(s) ago
2
715 day(s) ago
19
738 day(s) ago
2
744 day(s) ago
2
745 day(s) ago
43
745 day(s) ago
2
745 day(s) ago
1
771 day(s) ago
1
771 day(s) ago
126
780 day(s) ago
2
814 day(s) ago
1
815 day(s) ago
61
815 day(s) ago
1
821 day(s) ago
3
828 day(s) ago
49
844 day(s) ago
2
857 day(s) ago
2
869 day(s) ago
197
890 day(s) ago
23
926 day(s) ago
120
928 day(s) ago
278
961 day(s) ago
61
982 day(s) ago
3
990 day(s) ago
565
1044 day(s) ago
127
1060 day(s) ago
10
1066 day(s) ago
250
1086 day(s) ago
457
1130 day(s) ago
671
1187 day(s) ago
83
1191 day(s) ago
84
1191 day(s) ago
84
1191 day(s) ago
84
1191 day(s) ago
87
1221 day(s) ago
84
1236 day(s) ago
372
1257 day(s) ago
84
1292 day(s) ago
169
1304 day(s) ago
84
1304 day(s) ago

Info

Statistics

  • 4863 total downloads
  • 9 downloads of current version

Owners and Products

Petabridge Petabridge

Authors

Petabridge

Copyright

Copyright © 2017-2023 Petabridge

Petabridge