10000 Use only a single global lock for multiproc. by brian-brazil · Pull Request #167 · prometheus/client_python · GitHub
[go: up one dir, main page]

Skip to content

Use only a single global lock for multiproc. #167

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

Merged
merged 1 commit into from
Jun 7, 2017
Merged

Conversation

brian-brazil
Copy link
Contributor

This cuts ~350ns off the time for an operation, bringing it to
~1700ns.

In multi process mode it's a reasonable assumption that there
isn't any threading going on, so a single lock is faster than
more granular locks.

Fixed #112

This cuts ~350ns off the time for an operation, bringing it to
~1700ns.

In multi process mode it's a reasonable assumption that there
isn't any threading going on, so a single lock is faster than
more granular locks.
@brian-brazil brian-brazil merged commit cc852a9 into master Jun 7, 2017
@brian-brazil brian-brazil deleted the multi-lock branch June 7, 2017 14:18
@vad
Copy link
Contributor
vad commented Sep 7, 2017

@brian-brazil you assume multiproc means no threads, right? Is it still like this? Looks a strong assumption to me (I'm in production with multiproc and multithread, pretty common thing for uWSGI users). Thank you

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.

2 participants
0