forked from importers/git-importer
Limit the workers to 8
This is hard coding the limit, we may want to make this configurable but for now the machines supposed to run this code are very similiar
This commit is contained in:
parent
60ced896a3
commit
a457a16a50
@ -113,7 +113,7 @@ def main():
|
||||
|
||||
importer = Importer(URL_OBS, "openSUSE:Factory", args.packages)
|
||||
importer.import_into_db()
|
||||
with concurrent.futures.ProcessPoolExecutor() as executor:
|
||||
with concurrent.futures.ProcessPoolExecutor(max_workers=8) as executor:
|
||||
fs = [
|
||||
executor.submit(
|
||||
export_package, package, args.repodir, args.cachedir, args.gc
|
||||
|
@ -196,7 +196,7 @@ class Importer:
|
||||
self.find_linked_revs()
|
||||
|
||||
self.find_fake_revisions()
|
||||
with concurrent.futures.ThreadPoolExecutor() as executor:
|
||||
with concurrent.futures.ThreadPoolExecutor(max_workers=8) as executor:
|
||||
fs = [
|
||||
executor.submit(import_rev, self, rev)
|
||||
for rev in self.revisions_without_files()
|
||||
@ -215,7 +215,7 @@ class Importer:
|
||||
|
||||
def import_into_db(self):
|
||||
|
||||
with concurrent.futures.ThreadPoolExecutor() as executor:
|
||||
with concurrent.futures.ThreadPoolExecutor(max_workers=8) as executor:
|
||||
fs = [
|
||||
executor.submit(refresh_package, self, self.project, package)
|
||||
for package in self.packages
|
||||
|
Loading…
Reference in New Issue
Block a user