aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Johnson <benbjohnson@yahoo.com>2015-06-10 10:59:56 -0600
committerBen Johnson <benbjohnson@yahoo.com>2015-06-10 10:59:56 -0600
commit696f3a3ada8d748baa5719106e9b20b0fa716561 (patch)
tree3aa91f2cd1525808010d8a7aa1abf91ddd4619fc
parentMerge pull request #384 from benbjohnson/drone (diff)
downloaddedo-696f3a3ada8d748baa5719106e9b20b0fa716561.tar.gz
dedo-696f3a3ada8d748baa5719106e9b20b0fa716561.tar.xz
Add batch size and delay docs
This commit adds documentation for batch size and delay to the DB.Batch() call. Previously there was no reference to these properties from the Batch() call so it was nearly impossible for anyone to know to adjust these settings. Thanks to Kelly Sommers for bringing the doc issue to my attention.
-rw-r--r--batch.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/batch.go b/batch.go
index bef1f4a..84acae6 100644
--- a/batch.go
+++ b/batch.go
@@ -20,6 +20,9 @@ import (
// take permanent effect only after a successful return is seen in
// caller.
//
+// The maximum batch size and delay can be adjusted with DB.MaxBatchSize
+// and DB.MaxBatchDelay, respectively.
+//
// Batch is only useful when there are multiple goroutines calling it.
func (db *DB) Batch(fn func(*Tx) error) error {
errCh := make(chan error, 1)