Open eogienko opened 1 year ago
@eogienko Can you set SelfLog.Enable(Console.WriteLine); and write the output? In the master branch there is a test application for debugging sync, but with the current config - it works.
Indeed, version 3.0.1 still doesn't work. Version 2.3.0 works fine.
@whir1 I'll try it this week
any updates? i have the same issue btw i make it work with http but it fails using udp transport type.
note; i can send logs via netcat without problem. here is working command;
echo -n '{ "version": "1.1", "host": "example.org", "short_message": "A short message", "level": 5, "_some_info": "foo" }' | nc -w0 -u 127.0.0.1 12201
and this is my appsettings WriteTo section (already added to usings);
{
"Name": "Graylog",
"Args": {
"hostnameOrAddress": "127.0.0.1",
"port": "12201",
"transportType": "Udp",
"facility": "YYA"
}
}
@yyavci I can't help because current version worked on our servers on udp =\
ive come across an issue where a call to _logger.LogError
causes the application to freeze and .net ends up infinitely waiting for something (this is within our global exception handler, so everything is halted/frozen).
maybe this can help point towards some fix? our settings :
"Serilog": {
"Using": [
"Serilog.Sinks.Debug",
"Serilog.Sinks.Graylog"
],
"MinimumLevel": "Verbose",
"WriteTo": [
{
"Name": "Debug"
}
{
"Name": "Graylog",
"Args": {
"Facility": "{redacted}",
"HostnameOrAddress": "{redacted hostname}",
"Port": 12205,
"TransportType": "Udp",
"MinimumLogEventLevel": "Error",
"UseSsl": true
}
}
]
}
2.3 had no issues, so somewhere between 2.3 & 3.0.2 this started happening.
How can you not be affected by this? https://github.com/serilog-contrib/serilog-sinks-graylog/issues/97
It blows up immediatelly, during boot. Have done my own extension method that I use instead and also removed the hard coded UDP value. Then everything seem to work fine.
Code:
appsettings.json:
I had version 2.3.0 installed which worked great. Updated to 3.0.0 (3.0.1) and everything broke. Logs are not sent to Graylog. What to do?