diff options
author | Dan McGee <dan@archlinux.org> | 2014-10-26 22:06:08 -0500 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2014-10-26 22:06:08 -0500 |
commit | 9c701ebba1f2ef403aab95354a8ae4efdb7df74c (patch) | |
tree | a507e957c81b94c4e4cd6aad71f6505626adeb3a | |
parent | 8e990ca945f4fc5b27c0a81a484a107c83aa69d3 (diff) |
Double batch size in BatchWritesWrapper
Signed-off-by: Dan McGee <dan@archlinux.org>
-rw-r--r-- | feeds.py | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -14,15 +14,14 @@ from releng.models import Release class BatchWritesWrapper(object): - def __init__(self, outfile, chunks=20): + def __init__(self, outfile): self.outfile = outfile - self.chunks = chunks self.buf = [] def write(self, s): buf = self.buf buf.append(s) - if len(buf) >= self.chunks: + if len(buf) >= 40: self.outfile.write(''.join(buf)) self.buf = [] |