Hello lovely AWS community!
So, when using an ALB (Application Load Balancer), the ALB adds a header to the request before forwarding it to an origin server. The header is called X-Amzn-Trace-Id. It looks like this:
X-Amzn-Trace-Id: Root=1-67891233-abcdef012345678912345678
Source: https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-request-tracing.html
There's a timestamp with one second granularity between the two "-" characters in the header value. I have some questions:
- Can the ALB be configured not to add this header at all?
- If it cannot be prevented, can the ALB be modified/configured to have different content?
- If it can be modified, can the ALB be configured to add this header but with more granularity in the timestamp?
For example, I would like to have the timestamp in DateTime.ticks format, which has microsecond granularity. And finally:
- If this header cannot be modified, can the ALB configured to add another header with the required timestamp?
I think this might be possible by adding an additional AWS component to modify the headers - I'm not sure which one - but I really don't want to do that. I just want to configure the ALB to do this itself.
Thanks in advance for your help, and have a lovely day!
Thanks so much for replying! I really appreciate it!
If the Short answer is "no", what's the long answer (i.e. why not), pretty please? Is it that there is no way to configure this aspect of ALB functionality at all?
In answer to your question, I would like to know what time the requests reached the ALB with microsecond accuracy. That matters for my application. I feel confident that you would agree that I can't find that out by adding headers in my back-end application. Thanks again!