A small number of API requests to your microservices-based application take a very long time. You know that each request to the API can traverse many services. You want to know which service takes the longest in those cases. What should you do?
A.
Set timeouts on your application so that you can fail requests faster
B.
Send custom metrics for each of your requests to Stackdriver Monitoring
C.
Use Stackdriver Monitoring to look for insights that show when your API latencies are high
D.
Instrument your application with Stackdriver Trace in order to break down the request latencies at each microservice
D. Instrument your application with Stackdriver Trace in order to break down the request latencies at each microservice
Stackdriver Trace is a distributed tracing system that allows you to understand the relationships between requests and the various microservices that they touch as they pass through your application. By instrumenting your application with Stackdriver Trace, you can get a detailed breakdown of the latencies at each microservice, which can help you identify which service is taking the longest in those cases where a small number of API requests take a very long time.
Setting timeouts on your application or sending custom metrics to Stackdriver Monitoring may not provide the level of detail that you need to identify the specific service that is causing the latency issues. Looking for insights in Stackdriver Monitoring may also not provide the necessary level of detail, as it may not show the individual latencies at each microservice.
1. Distributed Tracing: Stackdriver Trace (now called Cloud Trace) is specifically designed to analyze the performance of requests as they travel through multiple services in a microservices architecture. It helps you pinpoint exactly where latency is occurring.
2. Detailed Breakdown: Cloud Trace will provide a detailed breakdown of how long each microservice takes to process the request, allowing you to identify the bottleneck quickly.
3. Visualization: Cloud Trace provides visualizations like flame graphs and waterfall diagrams that make it easy to see the flow of the request and identify slow services.
D should be correct, the headline in GC trace documentation says it all: "Cloud Trace is a distributed tracing system for Google Cloud that collects latency data from applications and displays it in near real-time in the Google Cloud Console."
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
euclid
Highly Voted 4 years, 11 months agotartar
4 years, 3 months agonitinz
3 years, 8 months agoomermahgoub
Highly Voted 1 year, 11 months agoEkramy_Elnaggar
Most Recent 1 week, 4 days agoHungdv
3 months, 2 weeks agoRobert0
6 months agoRobert0
6 months agoeka_nostra
1 year, 4 months agoLaxmanTiwari
1 year, 5 months agoLaxmanTiwari
1 year, 5 months agoalekonko
1 year, 8 months agoMestreCholas
1 year, 8 months agosurajkrishnamurthy
1 year, 11 months agoAniketD
2 years agokchandank
2 years agoMahmoud_E
2 years, 1 month agominmin2020
2 years, 1 month agoAzureDP900
2 years, 1 month agoabirroy
2 years, 3 months ago[Removed]
2 years, 3 months ago