From the course: Node.js: Debugging and Performance Tuning

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Cross-application request correlation

Cross-application request correlation

From the course: Node.js: Debugging and Performance Tuning

Start my 1-month free trial

Cross-application request correlation

- [Instructor] The problem of correlating logs for a request is compounded when working with multiple services. A single request can potentially call multiple microservices in order to build a single response. How can you track a single request without having each service create unique identifiers? This solution is known as cross-application request correlation. It sounds complex, but, honestly, it's more about extending what we've already been doing. When making your request to another application or system, include the request ID. Practically, this means setting an X-Request-Id header in any requests made. The system receiving the request with the request ID then uses the provided request ID it's given for its logging. This is a great technique, but it does have some practical drawbacks. To fully take advantage of this technique can take a lot of work, especially if the application wasn't designed to include them from the beginning. Every system needs to be able to generate and/or…

Contents