From 461321b14de778ca45ca90caab1d69ebb13382cc Mon Sep 17 00:00:00 2001 From: Martin Schneppenheim Date: Thu, 4 Nov 2021 17:19:03 +0100 Subject: [PATCH] Lower produce request timeout to 3s --- e2e/service.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/e2e/service.go b/e2e/service.go index d8781f4..544707f 100644 --- a/e2e/service.go +++ b/e2e/service.go @@ -56,7 +56,7 @@ func NewService(ctx context.Context, cfg Config, logger *zap.Logger, kafkaSvc *k kgoOpts = append(kgoOpts, kgo.RequiredAcks(kgo.LeaderAck())) kgoOpts = append(kgoOpts, kgo.DisableIdempotentWrite()) } - kgoOpts = append(kgoOpts, kgo.ProduceRequestTimeout(cfg.Producer.AckSla)) + kgoOpts = append(kgoOpts, kgo.ProduceRequestTimeout(3*time.Second)) // Consumer configs kgoOpts = append(kgoOpts, @@ -166,7 +166,7 @@ func (s *Service) Start(ctx context.Context) error { go s.startConsumeMessages(ctx, initCh) // Produce an init message until the consumer received at least one fetch - initTicker := time.NewTicker(1000 * time.Second) + initTicker := time.NewTicker(1 * time.Second) isInitialized := false // send first init message immediately sendInitMessage(ctx, s.client, s.config.TopicManagement.Name)