From a89f66bebd57f15f6559b422bfa74d351fd387ad Mon Sep 17 00:00:00 2001 From: Nico Franzeck Date: Thu, 23 May 2024 09:25:33 +0200 Subject: [PATCH] use parent context without cancel --- packages/logging/service.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/logging/service.go b/packages/logging/service.go index b66d122..6e143dd 100644 --- a/packages/logging/service.go +++ b/packages/logging/service.go @@ -139,8 +139,7 @@ func (s *loggingService) ApplyLogLevelWithRestart(ctx context.Context, req *pb.L return &emptypb.Empty{}, nil } - // Decouple grpc-request context from RestartDogu context by creating a new context - if lErr := s.doguRestarter.RestartDogu(context.Background(), doguName); lErr != nil { + if lErr := s.doguRestarter.RestartDogu(context.WithoutCancel(ctx), doguName); lErr != nil { return nil, createInternalErrWithCtx(fmt.Errorf("unable to restart dogu %s after setting new log level: %w", doguName, lErr), codes.Internal) }