From 514b574c1a04c85b697864a44b4f30f474f9dbe1 Mon Sep 17 00:00:00 2001 From: JP Dillingham Date: Mon, 18 Jan 2021 08:44:56 -0600 Subject: add metrics server and http metric capture --- src/slskd/Startup.cs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src') diff --git a/src/slskd/Startup.cs b/src/slskd/Startup.cs index 61993997..5e43a196 100644 --- a/src/slskd/Startup.cs +++ b/src/slskd/Startup.cs @@ -30,6 +30,7 @@ using Serilog; using Serilog.Events; using Microsoft.Extensions.Logging; + using Prometheus; public class Startup { @@ -197,6 +198,7 @@ app.UseSerilogRequestLogging(); app.UseRouting(); + app.UseHttpMetrics(); app.UsePathBase(BasePath); // remove any errant double forward slashes which may have been introduced @@ -227,6 +229,7 @@ app.UseEndpoints(endpoints => { endpoints.MapControllers(); + endpoints.MapMetrics(); }); if (EnableSwagger) -- cgit v1.2.3