Skip to content

Commit

Permalink
feat(core): add request headers in cluster comm impl
Browse files Browse the repository at this point in the history
  • Loading branch information
shivanshkc committed Jul 2, 2022
1 parent 2ef6b65 commit 1c0d1e2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/cluster/comm.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ func (c *Comm) PostMessageInternal(ctx context.Context, nodeAddr string, input *
if err != nil {
return nil, fmt.Errorf("error in http.NewRequestWithContext call: %w", err)
}
// Adding the required headers.
request.Header.Set("x-request-id", input.RequestID)
request.Header.Set("x-client-id", input.ClientID)
// Setting the cluster basic auth params.
request.SetBasicAuth(conf.Auth.ClusterUsername, conf.Auth.ClusterPassword)

Expand Down

0 comments on commit 1c0d1e2

Please sign in to comment.