stabilizaiton work - projects rework for maintenanceability and ui livening
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Threading;
|
||||
|
||||
namespace StellaOps.Provcache;
|
||||
|
||||
public sealed partial class WriteBehindQueue
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public WriteBehindMetrics GetMetrics()
|
||||
{
|
||||
return new WriteBehindMetrics
|
||||
{
|
||||
TotalEnqueued = Interlocked.Read(ref _totalEnqueued),
|
||||
TotalPersisted = Interlocked.Read(ref _totalPersisted),
|
||||
TotalFailed = Interlocked.Read(ref _totalFailed),
|
||||
TotalRetries = Interlocked.Read(ref _totalRetries),
|
||||
TotalBatches = Interlocked.Read(ref _totalBatches),
|
||||
CurrentQueueDepth = Interlocked.Read(ref _currentQueueDepth),
|
||||
Timestamp = _timeProvider.GetUtcNow()
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user