8000 Move os.getpid() inside _MmapedValue (#130) by megabuz · Pull Request #156 · prometheus/client_python · GitHub
[go: up one dir, main page]

Skip to content

Move os.getpid() inside _MmapedValue (#130) #156

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

Closed
wants to merge 1 commit into from
Closed

Move os.getpid() inside _MmapedValue (#130) #156

wants to merge 1 commit into from

Conversation

megabuz
Copy link
@megabuz megabuz commented Apr 13, 2017

Related to issue #130
uwsgi imports all python script in master process and after that forks children, so we need move os.getpid() call inside function

@megabuz megabuz changed the title Move os.getpid() inside _MmapedValue Move os.getpid() inside _MmapedValue (#130) Apr 13, 2017
@brian-brazil
Copy link
Contributor

We don't currently support that mode of operation, each child needs to be fork+execd. So this won't work.

@megabuz
Copy link
Author
megabuz commented Apr 13, 2017

It should work in both ways

@megabuz
Copy link
Author
megabuz commented Apr 13, 2017

Do you mean that whole module will not work? Do you have some vars/classes that need to init in child and not in master process?

@brian-brazil
Copy link
Contributor

Yes, it depends on the child initting separately.

@brian-brazil
Copy link
Contributor

Closing in favour of #169

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