Skip to content
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

Issues when using DOTNET_SYSTEM_NET_SOCKETS_INLINE_COMPLETIONS and DangerousInlinePipeScheduling #28356

Closed
Rodrigo-Andrade opened this issue Dec 3, 2020 · 3 comments
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions

Comments

@Rodrigo-Andrade
Copy link

Giving some feedback as per @davidfowl request from twitter.

Enabling both options gave my app a ridiculous performance boost (2-3x), i think most gains come from not enqueuing in the threadpool, most of the cpu usage is now on the SocketAsyncEngine threads. (more on this issue at dotnet/runtime#44449).

The problem that i came across is that after some time, the app would die with timeouts from everything that was using a socket.
My guess is that something is deadlocking on the SocketAsyncEngine threads, killing one by one until all threads were blocked.
After chasing every line of code that could be the culprit, i managed to make it stable long enough that i saw this problem on one machine out of 100s once a week, but its still there. My guess is that now something on a third party lib (this app uses postgres) or maybe even the BCL (i think dns is still sync?) could be the culprit.

@davidfowl
Copy link
Member

Yea, if something blocks, you're kinda basically hosed, that's why there's that big doc comment about the setting 😄. Once the issue starts happening, I'd suggest capturing a dump.

@Rodrigo-Andrade
Copy link
Author

I tried a mini-dump, didn't work, next time this happens i'll try again and if it fails, ill open another issue on the dotnet-dump.

But to this app, the performance gained justifies the trouble, and most of this hangs are actually bugs.

@jkotalik
Copy link
Contributor

jkotalik commented Dec 4, 2020

@Rodrigo-Andrade sounds like you are working through your issues. Closing for now, feel free to reopen if you find an issue you believe is with the framework.

@jkotalik jkotalik closed this as completed Dec 4, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Jan 3, 2021
@amcasey amcasey added area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions and removed area-runtime labels Aug 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Projects
None yet
Development

No branches or pull requests

5 participants