Alex Vanin
20de74a505
Due to source code relocation from GitHub. Signed-off-by: Alex Vanin <a.vanin@yadro.com>
31 lines
549 B
Go
31 lines
549 B
Go
package settlement
|
|
|
|
import (
|
|
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/util/logger"
|
|
"go.uber.org/zap"
|
|
)
|
|
|
|
// Option is a Processor constructor's option.
|
|
type Option func(*options)
|
|
|
|
type options struct {
|
|
poolSize int
|
|
|
|
log *logger.Logger
|
|
}
|
|
|
|
func defaultOptions() *options {
|
|
const poolSize = 10
|
|
|
|
return &options{
|
|
poolSize: poolSize,
|
|
log: &logger.Logger{Logger: zap.L()},
|
|
}
|
|
}
|
|
|
|
// WithLogger returns option to override the component for logging.
|
|
func WithLogger(l *logger.Logger) Option {
|
|
return func(o *options) {
|
|
o.log = l
|
|
}
|
|
}
|