Skip to content

Commit

Permalink
Do not overwrite client span if incoming request has "uber-trace-id" …
Browse files Browse the repository at this point in the history
…header
  • Loading branch information
rafis committed Jan 23, 2023
1 parent 8a865d5 commit 8e02208
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,9 @@ public HttpHeaders filter(HttpHeaders input, ServerWebExchange exchange) {
} catch (Exception ignore) {
log.error("TraceRequestHttpHeadersFilter error", ignore);
}
headersWithInput.addAll(input);
for (Map.Entry<String, List<String>> entry : input.entrySet()) {
headersWithInput.addIfAbsent(entry.getKey(), entry.getValue().get(0));
}
addHeadersWithInput(builder, headersWithInput);
return headersWithInput;
}
Expand Down

0 comments on commit 8e02208

Please sign in to comment.