You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Which version of Serilog.Sinks.Grafana.Loki are you using?
v8.3.0
Which version of .NET are you using?
net8.0
Describe the bug
While trying to find out why I couldn't see anything in grafana, I deliberately put an invalid uri in WriteTo.GrafanaLoki(). Nothing happens, everything moves forward as if nothing had happened.
To Reproduce
using Serilog;
using Serilog.Sinks.Grafana.Loki;
using ILogger = Serilog.Core.Logger;
public static class Program
{
public static async Task Main(string[] args)
{
ILogger logger = new LoggerConfiguration()
.WriteTo.Console()
//.WriteTo.GrafanaLoki("http://localhost:3100") // does not work
.WriteTo.GrafanaLoki("this is not a valid uri") // should have reported an issue!!
.CreateLogger();
logger.Information("Starting web host"); // it logs on the console but not in Loki
Expected behavior
It should have reported the issue, either logging it or throw an exception.
Log/SelfLog output or exception with stacktrace
No output, no exception, this is the problem.
Application or code sample, which could be used to reproduce a bug
No response
Additional context
using Serilog;
using Serilog.Sinks.Grafana.Loki;
using ILogger = Serilog.Core.Logger;
public static class Program
{
public static async Task Main(string[] args)
{
ILogger logger = new LoggerConfiguration()
.WriteTo.Console()
//.WriteTo.GrafanaLoki("http://localhost:3100") // does not work
.WriteTo.GrafanaLoki("this is not a valid uri") // should have reported an issue!!
.CreateLogger();
logger.Information("Starting web host"); // it logs on the console but not in Loki
What is the way to find out what is happening and why Loki is not receiving anything? Is there any configuration, or a logger to activate to understand why it is not sending to http://localhost:3100?
Which version of Serilog.Sinks.Grafana.Loki are you using?
v8.3.0
Which version of .NET are you using?
net8.0
Describe the bug
While trying to find out why I couldn't see anything in grafana, I deliberately put an invalid uri in WriteTo.GrafanaLoki(). Nothing happens, everything moves forward as if nothing had happened.
To Reproduce
Expected behavior
It should have reported the issue, either logging it or throw an exception.
Log/SelfLog output or exception with stacktrace
No output, no exception, this is the problem.
Application or code sample, which could be used to reproduce a bug
No response
Additional context
I have read the documentation
The text was updated successfully, but these errors were encountered: