diff options
author | Bryan Quigley <bryan.quigley@canonical.com> | 2019-03-26 11:56:04 +0000 |
---|---|---|
committer | Bryn M. Reeves <bmr@redhat.com> | 2019-03-26 11:56:04 +0000 |
commit | 65814887c9cf43ed9314a39576299dd6319fb53e (patch) | |
tree | 192c196bbf07d7e98a106b4a32cce51e568303cb | |
parent | 15e4dbd5aa696f0ef529732ca36b93c9da7f75df (diff) | |
download | sos-65814887c9cf43ed9314a39576299dd6319fb53e.tar.gz |
[sosreport] do not pass chunksize to ThreadPoolExecutor.map()
3.4 python also appears to be broken by an unnecessary use of the
chunksize argument when threading plugins landed. According to
the docs it defaults to 1, and has no effect for the
ThreadPoolExecutor class:
"For very long iterables, using a large value for chunksize can
significantly improve performance compared to the default size
of 1. With ThreadPoolExecutor, chunksize has no effect."
Related: #1603
Signed-off-by: Bryan Quigley <bryan.quigley@canonical.com>
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
-rw-r--r-- | sos/sosreport.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sos/sosreport.py b/sos/sosreport.py index 9bd899dc..c13142c7 100644 --- a/sos/sosreport.py +++ b/sos/sosreport.py @@ -973,7 +973,7 @@ class SoSReport(object): self.plugpool = ThreadPoolExecutor(self.opts.threads) # Pass the plugpool its own private copy of self.pluglist results = self.plugpool.map(self._collect_plugin, - list(self.pluglist), chunksize=1) + list(self.pluglist)) self.plugpool.shutdown(wait=True) for res in results: if not res: |