Skip to content

Commit

Permalink
Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
mhmtszr committed Mar 20, 2023
1 parent c2eb5d8 commit 0958e75
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
8 changes: 7 additions & 1 deletion kafka/producer/producer.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,13 @@ func NewProducer(config *config.Kafka, logger logger.Logger, errorLogger logger.
writer.Transport = transport
}
return &producer{
producerBatch: newProducerBatch(config.ProducerBatchTickerDuration, writer, config.ProducerBatchSize, logger, errorLogger, dcpCheckpointCommit),
producerBatch: newProducerBatch(
config.ProducerBatchTickerDuration,
writer,
config.ProducerBatchSize,
logger,
errorLogger,
dcpCheckpointCommit),
}
}

Expand Down
9 changes: 8 additions & 1 deletion kafka/producer/producer_batch.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,14 @@ type producerBatch struct {
flushLock sync.Mutex
}

func newProducerBatch(batchTime time.Duration, writer *kafka.Writer, batchLimit int, logger logger.Logger, errorLogger logger.Logger, dcpCheckpointCommit func()) *producerBatch {
func newProducerBatch(
batchTime time.Duration,
writer *kafka.Writer,
batchLimit int,
logger logger.Logger,
errorLogger logger.Logger,
dcpCheckpointCommit func(),
) *producerBatch {
batch := &producerBatch{
batchTickerDuration: batchTime,
batchTicker: time.NewTicker(batchTime),
Expand Down

0 comments on commit 0958e75

Please sign in to comment.