[Developer] X-Ray Flashcards

(13 cards)

1
Q

What is AWS X-Ray?

A

A service used to analyze and debug distributed applications, providing a visual map of the application’s components and the flow of requests.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are the three main components of X-Ray?

A
  1. SDK (for instrumentation)
  2. Daemon (for collecting/buffering data)
  3. API (for sending data and retrieving traces)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the primary role of the X-Ray SDK?

A

To instrument your application code, generate trace data (segments), and provide easy-to-use middleware for common frameworks.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the primary role of the X-Ray Daemon?

A

A software agent that listens for UDP traffic, buffers raw segment data, and relays it to the X-Ray API.

It must be run on your compute resource (e.g., EC2, ECS, Lambda).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is a “Segment” in X-Ray?

A

A unit of work recorded by a single component (e.g., a single EC2 instance, a Lambda function) containing details about the request, work done, and downstream calls.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is a “Trace” in X-Ray?

A

The complete path of a request as it travels through your entire application (combining multiple segments into one logical unit).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is “Sampling” in X-Ray, and why is it used?

A

The process of deciding which requests to record to manage costs and data volume.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is X-Ray’s default sampling rule?

A

Record the first request each second and 5% of any additional requests.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

When X-Ray integrates with an API Gateway endpoint or Lambda function, where is the Daemon component run?

A

AWS manages the Daemon component for you in these serverless services; you only need to use the X-Ray SDK.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Which visualization tool should you use to see the connections, latency, and errors between services?

A

The X-Ray Service Map.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How can you ensure X-Ray data is sent even if your service encounters an error?

A

Configure the X-Ray Daemon/SDK to use an appropriate logging level and ensure the segment is sent before the application terminates.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

In X-Ray, what is the key difference between Annotations and Metadata?

A

Searchability

Annotations CAN be searched on
Metadata CANNOT

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

A developer wants to use AWS X-Ray to monitor a Lambda function invoked by an SQS queue. Where must the developer explicitly ensure tracing is activated to see the full trace from SQS to Lambda?

A

In the Event Source Mapping configuration for SQS and Lambda

How well did you know this?
1
Not at all
2
3
4
5
Perfectly