-
Notifications
You must be signed in to change notification settings - Fork 296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support metrics using System.Diagnostics.Metrics #785
Comments
One thing we've received asks for by customers is metrics for Azure Storage, like queue length. It's obviously specific to the DurableTask.AzureStorage backend but it would be useful if the different backends could add their own metrics as part of this work. |
MetricsCore
Azure Storage
note: should we include or exclude AttributesCore
[1]: May need to think about this more. But I see value in having a more granular code for failure reason. It is valuable to differentiate in monitors between expected/transient and unexpected/important failures. Azure Storage
note: DTFx orchestration service packages SHOULD still include Core attributes when possible. |
Yeah that is definitely important. But I do wonder if that is something DTFx should implement? Or should Azure Storage be responsible for that? I guess DTFx could add one for now, but have it opt-in only via some startup value. edit: added |
The problem with reporting it from DTFx is that DTFx doesn't have any concept of queues, partitions, or even work-item latency today. If we want DTFx to be able to report this, then we'll probably need to add some optional interface that the backends can implement to surface this information to DTFx.Core. I see you added |
@cgillum each DTFx orchestration service library can emit its own metrics. In this case, Edit: I have separated example metrics and attributes between Core and AzureStorage concerns. |
With the release of .NET 6 last year, a new metrics API was introduced. This is available in System.Diagnostics.DiagnosticSource 6.0 package, which is backwards compatible with older .net runtimes (so we do not need to target .NET 6)
https://docs.microsoft.com/en-us/dotnet/core/diagnostics/metrics-instrumentation
We should use this API to emit metrics for select DTFx scenarios. Customers can then listen to these metrics themselves and export them out of process appropriately, or use an existing SDK like OpenTelemetry to export them.
We can start with building a list of metrics we want to collect, their names, value significance, and any dimensions.
Relies on #698
The text was updated successfully, but these errors were encountered: