Merge pull request 'insert request id in context' (#100) from rq into v3
Reviewed-on: #100
This commit is contained in:
commit
f163a2de72
@ -40,10 +40,11 @@ var DefaultMetadataFunc = func(ctx context.Context) (context.Context, error) {
|
||||
}
|
||||
imd.Set(DefaultMetadataKey, v)
|
||||
omd.Set(DefaultMetadataKey, v)
|
||||
ctx = context.WithValue(ctx, XRequestIDKey, v)
|
||||
ctx = metadata.NewIncomingContext(ctx, imd)
|
||||
ctx = metadata.NewOutgoingContext(ctx, omd)
|
||||
|
||||
return context.WithValue(ctx, XRequestIDKey, v), nil
|
||||
return ctx, nil
|
||||
}
|
||||
|
||||
type wrapper struct {
|
||||
|
Loading…
Reference in New Issue
Block a user