TechNuggets Academy

Troubleshooting and Optimization

Free AWS Certified Developer - Associate practice — 6 questions on Troubleshooting and Optimization, with explanations. No sign-up. Full 12-question mixed test →

Question 1 of 6 · Troubleshooting and Optimization
A Lambda function is invoked asynchronously by S3 event notifications when objects are uploaded to a bucket. Occasionally the function fails after exhausting all automatic retries, and the team needs to capture the failed event along with the invocation's response payload and error details for automated reprocessing. Which solution BEST meets this requirement?
Lambda Destinations for asynchronous invocations capture a full invocation record — including the original event, request/response context, and error details — and are the AWS-recommended replacement for legacy DLQs when richer failure context is needed for reprocessing.
Question 2 of 6 · Troubleshooting and Optimization
A DynamoDB table uses a partition key named OrderStatus that has only four possible values (NEW, PROCESSING, SHIPPED, COMPLETE). The table is experiencing ProvisionedThroughputExceededException errors even though the table's aggregate consumed capacity is well below its total provisioned capacity. Which change would BEST resolve this issue?
Each DynamoDB physical partition has a hard throughput ceiling regardless of table-level provisioning. A low-cardinality key concentrates traffic on a few partitions ('hot partition'). Redistributing writes via a high-cardinality or sharded key spreads traffic across more partitions and resolves throttling.
Question 3 of 6 · Troubleshooting and Optimization
A Lambda function connects to an Amazon RDS MySQL database, creating a new JDBC connection inside the handler method on every invocation. Under high concurrency, the database reports 'too many connections' errors and Lambda invocations show increased latency. Which combination of changes would BEST resolve this issue?
Initializing the connection in the global scope allows it to be reused across invocations that share a warm execution environment, and RDS Proxy pools and multiplexes connections so that Lambda's rapid concurrency scaling doesn't exhaust the database's native connection limit.
Question 4 of 6 · Troubleshooting and Optimization
A Lambda function is integrated with API Gateway using Lambda proxy integration. Clients intermittently receive HTTP 502 'Malformed Lambda proxy response' errors, although invoking the same function directly via the AWS CLI returns valid JSON. What is the MOST likely cause of this issue?
Lambda proxy integration requires the function to return a specific JSON structure with an integer statusCode and a body that is a JSON-stringified string. If any code path returns a malformed structure (missing statusCode, non-string body, or an unhandled exception), API Gateway cannot parse it and returns 502 'Malformed Lambda proxy response.'
Question 5 of 6 · Troubleshooting and Optimization
An application performs point lookups and query operations directly against a DynamoDB table using the DynamoDB API, and it needs microsecond-level read latency for frequently accessed items with minimal changes to existing application code. Which caching solution is BEST suited for this requirement?
DAX is a DynamoDB-API-compatible, fully managed in-memory cache purpose-built for DynamoDB. It provides microsecond read latency and requires only swapping the DynamoDB client for the DAX client, with minimal application code changes.
Question 6 of 6 · Troubleshooting and Optimization
A developer instruments a Lambda function with AWS X-Ray. They want to filter traces in the X-Ray console using a custom field called customerTier (values like 'gold' or 'silver'), and they also want to attach a large debug object containing the full request payload for offline analysis, without needing it to be searchable. How should the developer add these two pieces of data to the trace segment?
Annotations are indexed key-value pairs (string, number, or boolean) that can be used to filter and group traces in the X-Ray console or via GetTraceSummaries. Metadata stores arbitrary, larger data objects that are recorded with the trace but are not indexed or searchable — ideal for large debug payloads.
Ready for the real thing?

The full course: two full-length practice tests, video lessons for every exam domain, hands-on labs and detailed explanations.

$109.99 $34.99 with code FREETEST33 — valid through September 19.

Get my $34.99 deal →