PassSpark

AWS Certification Developer Associate 2025 past questions and answers

This 2025 AWS Certification Developer Associate set has 20 practice questions. Try these 5 free sample questions, tap a question to reveal the answer and explanation. Then practise the whole 2025 set with instant marking.

Practise the full 2025 setTimed exam mode

Sample AWS Certification Developer Associate 2025 questions

1. An order-processing Lambda function receives the same event more than once when an upstream service retries. Each order has a stable order ID, and duplicate order records must not be created in DynamoDB. Which approach is most reliable?
  1. Read the entire orders table before each write and skip the write if the order ID appears.
  2. Use PutItem with a ConditionExpression that requires the order ID key not to exist, and treat a conditional-check failure as an already-processed order.
  3. Disable retries on the upstream service and write each event with an unconditional PutItem.
  4. Keep processed order IDs in a Lambda execution environment variable.

Answer: B. Use PutItem with a ConditionExpression that requires the order ID key not to exist, and treat a conditional-check failure as an already-processed order.

A conditional write makes the uniqueness check and insertion atomic, so concurrent or repeated deliveries cannot create a second record. A separate read before writing can race, and Lambda environments are not durable idempotency stores.

2. A mobile application authenticates customers, then calls a REST API hosted by Amazon API Gateway. The API must validate customer sign-in tokens without requiring customers to hold AWS credentials. Which solution has the least operational overhead?
  1. Require each customer to sign requests with long-term IAM access keys.
  2. Use an API key as the authentication mechanism and rotate it in the mobile application.
  3. Configure an Amazon Cognito user pool authorizer on the API and pass the customer's user-pool token.
  4. Use an IAM authorizer that accepts only requests signed with SigV4.

Answer: C. Configure an Amazon Cognito user pool authorizer on the API and pass the customer's user-pool token.

A Cognito user pool authorizer validates user tokens directly at API Gateway without distributing AWS credentials to customers. API keys are for usage identification and throttling, not user authentication, while IAM authorization requires signed AWS requests.

3. A team deploys a Lambda function through AWS SAM. It wants to send 10% of production traffic to each new version for five minutes, monitor CloudWatch alarms, and automatically return traffic to the prior version if an alarm fires. Which approach meets these requirements with the least operational overhead?
  1. Configure a SAM deployment preference for a 10-percent, five-minute canary and associate CloudWatch alarms for rollback.
  2. Replace the production function with the new code in one all-at-once update and manually restore the prior package if needed.
  3. Create a second function and ask clients to alternate between the two function ARNs.
  4. Deploy the function to an EC2 Auto Scaling group and use an instance refresh.

Answer: A. Configure a SAM deployment preference for a 10-percent, five-minute canary and associate CloudWatch alarms for rollback.

SAM can use CodeDeploy traffic shifting for Lambda aliases, including canary timing and alarm-triggered rollback. An all-at-once update has no gradual exposure, and client-side traffic management adds unnecessary operational work.

4. A Lambda function processes batches from an Amazon SQS standard queue. One message in a batch is malformed, but the other messages completed successfully. The successful messages are being received and processed again whenever the batch is retried. What should the developer do?
  1. Increase the queue retention period so the successful messages remain available longer.
  2. Move the queue to FIFO and set a unique message group ID for every message.
  3. Set the Lambda timeout to zero so failed messages are immediately discarded.
  4. Enable ReportBatchItemFailures on the event source mapping and return identifiers only for messages that failed.

Answer: D. Enable ReportBatchItemFailures on the event source mapping and return identifiers only for messages that failed.

The SQS partial batch response lets Lambda delete successful messages and retry only the reported failures. Without it, a failed batch can cause all messages in that batch to be retried.

5. An application running in an Amazon ECS task on Fargate must read objects only from the s3://media-prod/customer-exports/ prefix. Credentials must not be stored in the image or application configuration. Which is the most secure solution?
  1. Put an IAM user's access key in an encrypted environment variable in the task definition.
  2. Assign a task role whose policy grants s3:GetObject only on the required customer-exports object ARN prefix.
  3. Grant the task execution role broad S3 read access because it is already used by Fargate.
  4. Make the bucket public and validate the requested prefix in application code.

Answer: B. Assign a task role whose policy grants s3:GetObject only on the required customer-exports object ARN prefix.

The ECS task role provides temporary credentials to application code and can be restricted to the required object prefix. The task execution role is for ECS operations such as image pulls and log delivery, and public access or embedded keys is less secure.

More AWS Certification Developer Associate years

2026202420232022

All AWS Certification Developer Associate years · AWS Certification subjects

PassSpark questions are original practice questions written to each exam's syllabus and format, in the style of past questions. They are not official past papers and are not affiliated with JAMB, WAEC, NECO, any university or any exam body.