From: Ansgar Burchardt Date: Sun, 4 Nov 2012 11:19:36 +0000 (+0100) Subject: dak/generate_releases.py: create worker pool before connection to database X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6d40cdb5682ebaa162d1c201b6d6065205fb38fd;p=dak dak/generate_releases.py: create worker pool before connection to database We do not want to have the file descriptor for the database connection in the worker processes. --- diff --git a/dak/generate_releases.py b/dak/generate_releases.py index 8d3635e2..798726bb 100755 --- a/dak/generate_releases.py +++ b/dak/generate_releases.py @@ -312,6 +312,7 @@ def main (): usage() Logger = daklog.Logger('generate-releases') + pool = DakProcessPool() session = DBConn().session() @@ -332,8 +333,6 @@ def main (): broken=[] - pool = DakProcessPool() - for s in suites: # Setup a multiprocessing Pool. As many workers as we have CPU cores. if s.untouchable and not Options["Force"]: