예제 #1
0
 public void Flush()
 {
     if (metricsCollector != null)
     {
         metricsCollector.Dispose();
     }
 }
예제 #2
0
        public void ShouldNotCrashWhenEventRecordAfterDisposed()
        {
            var sink = new DictionarySink();
            var e    = new MetricsCollector(sink, TimeSpan.FromSeconds(1), TimeSpan.FromSeconds(5));

            e.IncrementCounter("myCounter");
            e.Dispose();
            Assert.Single(sink.Counters);

            e.IncrementCounter("myCounter");
        }
예제 #3
0
 public void CleanUpForAllMetrics()
 => _metricsCollector?.Dispose();
예제 #4
0
 public void Cleanup() =>
 metrics.Dispose();
예제 #5
0
 protected override void Finished()
 {
     _collector.Dispose();
 }