-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using Serilog format specifier for ints makes buffer file invalid #156
Comments
Thanks for the report! The default (non-durable) sink already handles this situation; I think it makes sense now to carry this across to the durable option. We might also start recording dropped events to the stream itself, so that the situation is easier to detect on the Seq side 👍 |
Fixed now in 5.0.2-dev-00203 on NuGet; will queue up a stable/main build once we're happy we haven't broken anything :-) |
Hi @DavidLievrouw - did you have a chance to check out the fixed build? Thanks! |
Awesome, thanks for the follow-up, David. |
Symptom
I accidentally used an invalid Serilog format specifier in a message template. Although it was my mistake, it kind of had severe consequences.
No logs of this application ever arrive in Seq when using durable log shipping. It works fine when setting
bufferBaseFilename
tonull
.Cause
When using the
:l
format specifier, and passing anint
as property value, the durable buffer file is corrupted. It contains invalid json. This causes theHttpLogShipper
to receive 500 response from Seq.Even after fixing the incorrect format specifier, the logs never arrived in Seq. I needed to delete the buffer file, causing loss of log entries.
Replay
Causes the following text in the buffer file (notice that it's invalid json):
And the Seq server-side error:
Expected behaviour
Imho, making such a trivial mistake in a message template, should not make all logging to Seq fail (until you delete the buffer file).
Any pointers to where to start looking, would be nice.
The text was updated successfully, but these errors were encountered: