-
Notifications
You must be signed in to change notification settings - Fork 51
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
Log.CloseAndFlush()
deadlock on AWS Lambda
#167
Comments
Thanks for the report, we'll dig in 👍 |
Log.CloseAndFlush()
deadlock on AWS Lambda
We're affected by the same problem. This only happens with a config in which the seq sink is added, the others we use (console, eventlog) are unaffected. |
Hi @DarkMio - thanks for reaching out. Starting work on a proper fix for this now via serilog/serilog#1750. |
Very cool, that was just in time. Thanks @nblumhardt! |
Hi @DarkMio; v5.2.0 is out now and includes this fix. I'll close the ticket as completed but if you notice any ongoing issues please let us know! |
Ah sorry, also, for this to work you'll need to asynchronously dispose the Serilog If you're on Serilog.AspNetCore and configuring Serilog in the |
Log.CloseAndFlush()
seems to be deadlocking when run in AWS Lambda and my Seq server instance goes down for some (irrelevant) reason making Seq a single point of failure for the whole microservice gang. This is how it looks like in the logs:This only happens when running in AWS Lambda environment. In a console app execution continues after a graceful timeout of ~4 seconds.
I suspect it might be related to this and followed this advice to make it behave better:
It works but still looks like a hack.
The text was updated successfully, but these errors were encountered: