For developers who build, test, deploy and troubleshoot applications on AWS. Covers developing with AWS services and Lambda, securing applications and data (including the security risks of AI services), testing and deploying with CI/CD, and troubleshooting and optimizing applications. Compared with DVA-C02, it adds AI-assisted development tools and container topics.
Example practice questions
Topic: Development with AWS Servicesservices: lambda, rds-aurora, vpcconcepts: serverlessquestionTypes: configuration
A developer is building a serverless application using AWS Lambda. The Lambda function needs to access a private Amazon RDS database in a VPC. What must the developer configure to allow the Lambda function to connect to the database?
- AEnable public accessibility on the RDS database and open its security group to all addresses
- BCreate an internet gateway and route all Lambda traffic through it to reach the database endpoint
- CUse AWS Direct Connect to establish a dedicated connection between Lambda and the VPC
- DAttach the Lambda function to the database's VPC subnets with appropriate security groups
Show answer
Correct answer: D
Explanation: To access resources in a VPC, a Lambda function must be configured to connect to the VPC. You specify the VPC, subnets, and security groups. The security groups must allow traffic between Lambda and RDS.
Topic: Testing and Deploymentservices: lambda, dynamodb, snsconcepts: testingquestionTypes: architecture-decision
A developer is building a CI/CD pipeline for a Lambda function that queries DynamoDB and publishes to SNS. The team requires: unit tests that run in milliseconds without network calls, integration tests that verify DynamoDB query logic with realistic data, and end-to-end tests in a staging environment. Which testing strategy correctly addresses ALL requirements?
- AUse DynamoDB Local for all test types, including E2E, to ensure consistency, with different seeded data sets for each test level
- BMock all AWS calls in unit tests, use LocalStack for integration tests, and skip E2E tests because integration tests already cover the same functionality
- CCreate dedicated test tables in the production DynamoDB account for all testing levels to ensure realistic performance and data characteristics
- DMock AWS calls with moto for unit tests, use DynamoDB Local with seeded data for integration tests, and deploy to a staging account for E2E
Show answer
Correct answer: D
Explanation: Unit tests should use mocking (moto) for speed and isolation. Integration tests need DynamoDB Local with seeded data to verify query logic without AWS costs. E2E tests require actual AWS environment (staging) to test real service integrations including SNS. Option A uses DynamoDB Local for E2E which misses SNS testing. Option B skips essential E2E validation. Option C risks production data and incurs costs.
Topic: Troubleshooting and Optimizationservices: dynamodb, elasticacheconcepts: cachingquestionTypes: most-performant, most-cost-effective
A developer's application reads the same 50 items from DynamoDB thousands of times per second. The items rarely change (once per day). The current implementation causes read throttling and high costs. The developer needs sub-millisecond read latency. Which solution minimizes latency AND cost?
- ACache items in ElastiCache Redis with a 24-hour TTL
- BSwitch to DynamoDB On-Demand capacity mode
- CEnable DynamoDB Auto Scaling to handle the read capacity
- DImplement DAX (DynamoDB Accelerator) cluster in front of DynamoDB
Show answer
Correct answer: D
Explanation: DAX is an in-memory, write-through cache built for DynamoDB that serves cached reads in microseconds through the same DynamoDB API, so the hot items are no longer read from the table thousands of times per second. Writes made through DAX update its cache. ElastiCache (A) would also work but needs your own caching and invalidation code. Auto Scaling (C) and on-demand capacity (B) add read capacity but keep paying for every repeated read and do not reach sub-millisecond latency.
Topic: Securityservices: sam, secrets-manager, lambda, iamconcepts: least-privilege, secrets-management, iacquestionTypes: most-secure
A developer is deploying a Lambda function using AWS SAM. The function needs to access secrets from Secrets Manager and must follow least-privilege principles. The SAM template should not hardcode the secret ARN. Which SAM template configuration is correct?
- AUse AWS::Serverless::Function with Policies: SecretsManagerReadWrite and pass the secret ARN as an environment variable
- BCreate a custom IAM role with full Secrets Manager access and reference it in the Role property
- CUse AWS::Serverless::Function with Policies: - AWSSecretsManagerGetSecretValuePolicy, supplying SecretArn from a template parameter (SecretArn: !Ref SecretArnParam)
- DUse Globals section to grant all functions SecretsManagerReadWrite permission
Show answer
Correct answer: C
Explanation: The SAM policy template AWSSecretsManagerGetSecretValuePolicy grants only secretsmanager:GetSecretValue on a single secret. Its SecretArn parameter is mapped from a template parameter with !Ref, so the ARN is not hardcoded in the template and access stays scoped to that one secret. Option A uses overly broad SecretsManagerReadWrite. Options B and D grant excessive permissions violating least-privilege.
Topic: Development with AWS Servicesservices: eventbridgeconcepts: event-drivenquestionTypes: architecture-decision
A developer is designing an event-driven architecture. The application needs to process messages from multiple sources and route them to different targets based on message content. Which AWS service is BEST suited for this requirement?
- AAmazon EventBridge
- BAmazon SQS
- CAmazon SNS
- DAWS Step Functions
Show answer
Correct answer: A
Explanation: Amazon EventBridge is a serverless event bus that makes it easy to connect applications using data from various sources. It can filter and route events to different targets based on rules that match event patterns.