Closed SingleCopy closed 1 month ago
This is a very good catch @SingleCopy . I found some mention about this here: https://learn.microsoft.com/en-us/dotnet/api/system.diagnostics.stopwatch.elapsedticks?view=net-8.0&redirectedfrom=MSDN#System_Diagnostics_Stopwatch_ElapsedTicks
@GeoK - I think this code is common with our other SDKs
CC @jennyf19 as I believe this code was copied from MISE. Also adding @pmaytak for a review
@microsoft-github-policy-service agree
@neha-bhargava - please review this PR. There may be implications in how we interpret some of our telemetry.
Fixes: #4784
Changes proposed in this request The MeasureDurationResult time calculations do not work when running in linux as the Stopwatch.Frequency is not taken into account. This change correctly calculates the Milliseconds and Microseconds by taking the Stopwatch.Frequency into account.
Testing Difficult without running the tests on different O/S
Performance impact N/A
Documentation N/A