Пример #1
0
 /// <summary>
 ///     Creates a new meter metric and registers it under the given type and name
 /// </summary>
 /// <param name="name">The metric name</param>
 /// <param name="eventType">The plural name of the type of events the meter is measuring (e.g., <code>"requests"</code>)</param>
 /// <param name="rateUnit">The rate unit of the new meter</param>
 /// <returns></returns>
 public MeterMetric Meter(string name, string eventType, TimeUnit rateUnit)
 {
     return(_host.Meter(typeof(TOwner), name, eventType, rateUnit));
 }
Пример #2
0
 private static void BytesPerSecond(IMetricsHost metrics, int length)
 {
     metrics?.Meter(typeof(LineReader), "bytes_read_per_second", "bytes", TimeUnit.Seconds).Mark(length);
 }