Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
Lee Wright authored and Lee Wright committed Jul 4, 2024
1 parent 414faa6 commit 3c6491f
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions backend/ISLInterfaces/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ namespace ISLInterfaces;
using OpenTelemetry.Resources;
using Prometheus;
using Serilog;
using Serilog.Events;
using Serilog.Sinks.SystemConsole.Themes;

public class Program
Expand Down Expand Up @@ -63,8 +64,6 @@ public static void Main(string[] args)
builder.Services.AddHealthChecks()
.AddCheck("liveness", () => HealthCheckResult.Healthy()).ForwardToPrometheus();

builder.Services.AddTransient<SerilogHandler>();

var app = builder.Build();

// Configure the HTTP request pipeline.
Expand Down Expand Up @@ -104,13 +103,13 @@ public static void Main(string[] args)

Log.Information($"Logging to splunk host {splunkHost}");
loggerConfig
.MinimumLevel.Debug()
.WriteTo.EventCollector("https://hec.monitoring.ag.gov.bc.ca:8088/services/collector", "d7811b9d-8079-4555-959e-81b547830c4d");
.MinimumLevel.Information()
.WriteTo.EventCollector(splunkHost, splunkToken, restrictedToMinimumLevel: LogEventLevel.Information);


Log.Logger = loggerConfiguration.CreateLogger();


builder.Services.AddTransient<SerilogHandler>();

Log.Information($"Logging to splunk host {splunkHost}");

Expand Down

0 comments on commit 3c6491f

Please sign in to comment.