Satori should provide a way to override Popen
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| satori |
Undecided
|
Ryan Walker |
Bug Description
Currently smb.py and bash.py both use subprocess.Popen. subprocess.Popen utilizes os.fork() to spawn child processes. If the process calling smb.py or bash.py has a large memory footprint, os.fork() performs very slowly due to memory allocation. It would be better for Satori to call Popen in a way that allowed a calling application to override the underlying Popen process to use something like posix_spawn instead for better performance.
Changed in satori: | |
status: | New → In Progress |
Reviewed: https:/
Committed: https:/
Submitter: Jenkins
Branch: master
commit fd350f7f1c4da7c
Author: Ryan Walker <email address hidden>
Date: Mon Jan 19 11:28:04 2015 -0600
Refactor Popen usage to allow overrides
* Add subprocess.Popen wrapper in common
* Change bash.py and smb.py to use wrapper.
Because subprocess.Popen uses os.fork() to spawn child processes, it may
be desirable for a calling application to override subprocess.Popen with
a custom class that implements a different spawning method - such as
posix_spawn. With large-memory applications, posix_spawn may be more
desirable than os.fork() due to memory allocation behavior. This change
allows Satori to be compatible with such a workflow.
Change-Id: Ia60adea27d1a6c
Closes-Bug: #1412485
Changed in satori: | |
status: | In Progress → Fix Committed |
Fix proposed to branch: master /review. openstack. org/148714
Review: https:/