This commit is contained in:
ryan
2026-07-13 15:08:40 +08:00
parent 08e8eea932
commit 1eff7878a1
441 changed files with 26491 additions and 18405 deletions
+5 -5
View File
@@ -9,10 +9,10 @@ import (
)
const (
defaultQueueSize = 10_000
defaultMaxBatchSize = 1_000
defaultMinBatchSize = 50
defaultFlushEvery = time.Second
defaultQueueSize = 10_000
defaultMaxBatchSize = 1_000
defaultMinBatchSize = 50
defaultFlushEvery = time.Second
)
// Config controls queue capacity and flush thresholds for a Writer instance.
@@ -66,4 +66,4 @@ func (c Config) validate() error {
return fmt.Errorf("batchwriter: max flush wait must be non-negative")
}
return nil
}
}
+1 -1
View File
@@ -5,4 +5,4 @@ package batchwriter
import "errors"
var errNilFlushFunc = errors.New("batchwriter: flush func is required")
var errNilFlushFunc = errors.New("batchwriter: flush func is required")
+1 -1
View File
@@ -99,4 +99,4 @@ func ChConnReady() bool {
// SetChConnForTest sets the package-level native ClickHouse connection for testing.
func SetChConnForTest(c driver.Conn) {
ChConn = c
}
}
+1 -1
View File
@@ -52,4 +52,4 @@ func TestMigrateClickHouseSkipsWhenDisabled(t *testing.T) {
})
MigrateClickHouse()
}
}