mirror of
https://github.com/grassrootseconomics/eth-tracker.git
synced 2026-05-20 11:21:09 +02:00
fix: mint and burn func signatures, adjustable batch size for pool and backfill buffer
This commit is contained in:
@@ -11,6 +11,7 @@ import (
|
||||
|
||||
type (
|
||||
PoolOpts struct {
|
||||
BatchSize int
|
||||
Logg *slog.Logger
|
||||
WorkerCount int
|
||||
Processor *processor.Processor
|
||||
@@ -23,14 +24,12 @@ type (
|
||||
}
|
||||
)
|
||||
|
||||
const blocksBuffer = 100
|
||||
|
||||
func New(o PoolOpts) *Pool {
|
||||
return &Pool{
|
||||
logg: o.Logg,
|
||||
workerPool: pond.New(
|
||||
o.WorkerCount,
|
||||
blocksBuffer,
|
||||
o.BatchSize,
|
||||
pond.Strategy(pond.Balanced()),
|
||||
pond.PanicHandler(panicHandler(o.Logg)),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user