generate_request_id
does not generate x-request-id
if it is present but empty
#38445
Labels
area/tracing
help wanted
Needs help!
question
Questions that are neither investigations, bugs, nor enhancements
Title:
generate_request_id
does not generatex-request-id
if it is present but emptyDescription
I expected
generate_request_id
to generate ax-request-id
if it isn't present OR empty. But this seems to not be the case. Is this intended? If so, do you have a solution to generate it if it's empty?Repro steps
The config (found bellow) is run with the following command:
docker run --rm -v $(pwd)/envoy.yaml:/etc/envoy/envoy.yaml -p 80:80 envoyproxy/envoy:v1.31-latest
Without passing
x-request-id
In this case, the
x-request-id
header is generated.# x-request-id present in response curl http://localhost:80/ -v
Output:
Explicitly passing
x-request-id
In this case, the
x-request-id
header is forwarded in the response because ofalways_set_request_id_in_response: true
.curl -H"x-request-id: hello" http://localhost:80/ -v
Output:
Explicitly passing an empty
x-request-id
In this case, the
x-request-id
header is forwarded in the response because ofalways_set_request_id_in_response: true
. Butgenerate_request_id: true
should have generated one.curl -H"x-request-id;" http://localhost:80/ -v
Output:
Config
The text was updated successfully, but these errors were encountered: