aboutsummaryrefslogtreecommitdiffstats
path: root/skate/zipkey
diff options
context:
space:
mode:
authorMartin Czygan <martin.czygan@gmail.com>2021-07-09 18:08:04 +0200
committerMartin Czygan <martin.czygan@gmail.com>2021-07-09 18:08:04 +0200
commit4df87f9381ce73074abdb1b00635a342f2abadfd (patch)
tree48a43598f5231381fb08919483e992e72fa3856f /skate/zipkey
parent6fa7259028723ca4eb2d2aa62cc21032bee66e6f (diff)
downloadrefcat-4df87f9381ce73074abdb1b00635a342f2abadfd.tar.gz
refcat-4df87f9381ce73074abdb1b00635a342f2abadfd.zip
reduce: move batch size
Diffstat (limited to 'skate/zipkey')
-rw-r--r--skate/zipkey/batch.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/skate/zipkey/batch.go b/skate/zipkey/batch.go
index 9924b65..049c3b2 100644
--- a/skate/zipkey/batch.go
+++ b/skate/zipkey/batch.go
@@ -5,6 +5,8 @@ import (
"sync"
)
+const defaultBatchSize = 10000
+
// Batcher runs reducers in parallel on batches of groups.
type Batcher struct {
Size int
@@ -19,7 +21,7 @@ type Batcher struct {
// NewBatcher set ups a new Batcher with a batch size of 1000.
func NewBatcher(gf groupFunc) *Batcher {
- return NewBatcherSize(gf, 1000)
+ return NewBatcherSize(gf, defaultBatchSize)
}
// NewBatcherSize initializes a batcher with a given size.