Exemple #1
0
        /// <summary>
        /// Configures the HttpClient pipeline to collect Prometheus metrics.
        /// </summary>
        public static IHttpClientBuilder UseHttpClientMetrics(this IHttpClientBuilder builder, Action <HttpClientExporterOptions> configure)
        {
            var options = new HttpClientExporterOptions();

            configure?.Invoke(options);

            builder.UseHttpClientMetrics(options);

            return(builder);
        }