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

Compatible with gevent #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Compatible with gevent #5

wants to merge 1 commit into from

Conversation

aisk
Copy link

@aisk aisk commented Dec 10, 2021

When using start_pprof_server with gevent monkey patched threading module, server will block when someone called the pprof endpoint.

This is because thread is patched to be greenlet, which is nonpreemptive, unless some IO syscall happened. pprof is CPU bounded so this will block the main server process.

This patch will try to using original thread implmentation when gevent is avialble.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant