コード例 #1
0
        public static void Enqueue(this Reporter reporter, string alias, Dictionary <string, object> data = null)
        {
            var builder = new MetricBuilder();

            builder.WithTimestamp()
            .WithAlias(alias)
            .WithPath(GeneratePath(alias));

            if (data != null && data.Any())
            {
                foreach (var pair in data)
                {
                    builder.WithData(pair.Key, pair.Value);
                }
            }

            reporter.Enqueue(builder.Build());
        }