Pass request ID to Coredor's exec call

This commit is contained in:
Denis Arh
2020-01-18 07:05:34 +01:00
parent c0d1594eb3
commit ce69229816
+7
View File
@@ -3,6 +3,7 @@ package corredor
import (
"context"
"github.com/go-chi/chi/middleware"
"github.com/pkg/errors"
"go.uber.org/zap"
"google.golang.org/grpc"
@@ -402,6 +403,12 @@ func (svc service) exec(ctx context.Context, script string, runAs string, event
// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// ////
ctx = metadata.NewOutgoingContext(ctx, metadata.MD{
"x-request-id": []string{middleware.GetReqID(ctx)},
})
// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// //// ////
var header, trailer metadata.MD
rsp, err = svc.ssClient.Exec(
ctx,