Beispiel #1
0
            public void OnNewValue(string metric)
            {
                if (!_bufferBuilder.Add(metric))
                {
                    throw new InvalidOperationException($"The metric size exceeds the buffer capacity: {metric}");
                }

                _stopwatch = null;
            }
Beispiel #2
0
            public void OnNewValue(SerializedMetric serializedMetric)
            {
                using (serializedMetric)
                {
                    if (!_bufferBuilder.Add(serializedMetric))
                    {
                        throw new InvalidOperationException($"The metric size exceeds the buffer capacity: {serializedMetric.ToString()}");
                    }

                    _stopwatch = null;
                }
            }