UnobservedTaskException in finalizer thread
kvpt opened this issue · 1 comments
Hi,
I try to migrate my code from DotNetty to SpanNetty.
The code compile without change but now errors that was not present with DotNetty are present in the logs.
The exception message is the following
No operations are allowed on void promise
This is very easy to replicate with very basic setup like the echo example.
First add the following line in the main method
TaskScheduler.UnobservedTaskException += (sender, eventArgs) => Debugger.Break();
Then
- Start the echo server with VS debugger attached
- Start the echo client
- Stop the echo client
- Restart the echo client
The exception is triggered in echo server
This not seem to cause the pipeline to halt, the messages continue to be processed but an exception like this in the finalizer thread make me think there may be a resource leak somewhere.
Morevover I don't have this exception with DotNetty.
I can trigger the same exception with any configuration that I have tested, with an empty pipeline, using libuv or not, on windows or on linux nothing seems to mater.
Thanks.
I will test this program, please wait a few days......