Class TimeoutStatistics
Provides timeout statistics for adaptive timeout calculations. Statistical tracking for timeout optimization.
public sealed class TimeoutStatistics
- Inheritance
-
TimeoutStatistics
- Inherited Members
- Extension Methods
Properties
AverageDuration
Gets the average duration of successful operations.
public TimeSpan AverageDuration { get; init; }
Property Value
- TimeSpan
The arithmetic mean duration.
LastUpdated
Gets the timestamp when these statistics were last updated.
public DateTimeOffset LastUpdated { get; init; }
Property Value
- DateTimeOffset
The timestamp of the most recent update.
MaxDuration
Gets the maximum duration recorded.
public TimeSpan MaxDuration { get; init; }
Property Value
- TimeSpan
The longest observed duration.
MedianDuration
Gets the median duration of successful operations.
public TimeSpan MedianDuration { get; init; }
Property Value
- TimeSpan
The median duration value.
MinDuration
Gets the minimum duration recorded.
public TimeSpan MinDuration { get; init; }
Property Value
- TimeSpan
The shortest observed duration.
OperationType
Gets the operation type these statistics apply to.
public TimeoutOperationType OperationType { get; init; }
Property Value
- TimeoutOperationType
The operation classification that produced the data.
P95Duration
Gets the 95th percentile duration of successful operations.
public TimeSpan P95Duration { get; init; }
Property Value
- TimeSpan
The duration at the 95th percentile.
P99Duration
Gets the 99th percentile duration of successful operations.
public TimeSpan P99Duration { get; init; }
Property Value
- TimeSpan
The duration at the 99th percentile.
SuccessRate
Gets the success rate as a percentage (0-100).
public double SuccessRate { get; }
Property Value
- double
The percentage of operations that succeeded.
SuccessfulOperations
Gets the number of operations that completed successfully.
public int SuccessfulOperations { get; init; }
Property Value
- int
The count of successful operations.
TimedOutOperations
Gets the number of operations that timed out.
public int TimedOutOperations { get; init; }
Property Value
- int
The count of timed-out operations.
TimeoutRate
Gets the timeout rate as a percentage (0-100).
public double TimeoutRate { get; }
Property Value
- double
The percentage of operations that timed out.
TotalOperations
Gets the total number of operations recorded.
public int TotalOperations { get; init; }
Property Value
- int
The total sample size.
Methods
GetPercentileDuration(int)
Gets the duration for the specified percentile.
public TimeSpan GetPercentileDuration(int percentile)
Parameters
percentileintThe percentile (50-99).
Returns
- TimeSpan
The duration at the specified percentile.
HasSufficientData(int)
Determines if the statistics contain sufficient data for reliable calculations.
public bool HasSufficientData(int minimumSamples = 100)
Parameters
minimumSamplesintThe minimum number of samples required.