AWS Certified Developer - Associate DVA-C02 Practice Test 32
Question 310
An independent QA lead must observe a reproducible before-and-after result with controlled test inputs prior to signing the release. A chat app uses one global room key for all messages and scales table throughput without fixing hot writes. What test most directly confirms the intended behavior?
- Compare collected resource IDs against a fixture spanning several result pages including an empty final page.
- Trigger duplicate object notifications and verify exactly one logical downstream ingest result is committed.
- Load test a representative key distribution and inspect throttling by partition-key pattern.
- Publish ordered updates for two account IDs and verify each account's local sequence is processed consistently.
Explanation
Correct Answer
C:The decisive acceptance evidence is: Load test a representative key distribution and inspect throttling by partition-key pattern. It demonstrates: A narrow or concentrated partition key can create hot partitions and throttling even when table capacity is sufficient. Scenario: A chat app uses one global room key for all messages and scales table throughput without fixing hot writes.
Incorrect Answers
A:Option A is an acceptance test for AWS SDK paginator use: Compare collected resource IDs against a fixture spanning several result pages including an empty final page. It is not direct evidence for: A chat app uses one global room key for all messages and scales table throughput without fixing hot writes.
B:Option B is an acceptance test for S3 object events and duplicate handling: Trigger duplicate object notifications and verify exactly one logical downstream ingest result is committed. It is not direct evidence for: A chat app uses one global room key for all messages and scales table throughput without fixing hot writes.
D:Option D is an acceptance test for Kinesis per-shard ordering: Publish ordered updates for two account IDs and verify each account's local sequence is processed consistently. It is not direct evidence for: A chat app uses one global room key for all messages and scales table throughput without fixing hot writes.
Question 311
An independent QA lead must observe a reproducible before-and-after result with controlled test inputs prior to signing the release. A release script deploys whatever is on a developer laptop rather than the reviewed repository branch. What test most directly confirms the intended behavior?
- Replay known API and SQS test events and compare structured outputs and failure handling to expected values.
- Run a fixture representing missing and valid fields and assert deterministic output and error handling.
- Return simulated 200, 429, and timeout responses from a test service and verify the application's resulting state.
- Deploy a tagged test commit and compare runtime version metadata with the repository commit identifier.
Explanation
Correct Answer
D:The decisive acceptance evidence is: Deploy a tagged test commit and compare runtime version metadata with the repository commit identifier. It demonstrates: Traceable source revisions allow a pipeline to rebuild, review, and roll back specific application releases. Scenario: A release script deploys whatever is on a developer laptop rather than the reviewed repository branch.
Incorrect Answers
A:Option A is an acceptance test for Test Lambda JSON event fixture: Replay known API and SQS test events and compare structured outputs and failure handling to expected values. It is not direct evidence for: A release script deploys whatever is on a developer laptop rather than the reviewed repository branch.
B:Option B is an acceptance test for SAM local unit tests and mocks: Run a fixture representing missing and valid fields and assert deterministic output and error handling. It is not direct evidence for: A release script deploys whatever is on a developer laptop rather than the reviewed repository branch.
C:Option C is an acceptance test for Integration test API dependency contract: Return simulated 200, 429, and timeout responses from a test service and verify the application's resulting state. It is not direct evidence for: A release script deploys whatever is on a developer laptop rather than the reviewed repository branch.
Question 312
An independent QA lead must observe a reproducible before-and-after result with controlled test inputs prior to signing the release. A patched image was tested but its release manifest points to an earlier digest with vulnerable dependencies. What test most directly confirms the intended behavior?
- Promote a known digest from test to production and compare ECS task image digests after rollout.
- Commit a safe test change to the selected branch and verify one pipeline execution records the corresponding revision.
- Invoke staging and production URLs and confirm each reaches the configured function version or alias.
- Induce a failing readiness test in the new environment and verify routing returns to the previous one.
Explanation
Correct Answer
A:The decisive acceptance evidence is: Promote a known digest from test to production and compare ECS task image digests after rollout. It demonstrates: Tags can move, whereas a digest identifies specific image content that can be validated across environments. Scenario: A patched image was tested but its release manifest points to an earlier digest with vulnerable dependencies.
Incorrect Answers
B:Option B is an acceptance test for CodePipeline source change trigger: Commit a safe test change to the selected branch and verify one pipeline execution records the corresponding revision. It is not direct evidence for: A patched image was tested but its release manifest points to an earlier digest with vulnerable dependencies.
C:Option C is an acceptance test for API Gateway stage variables and versions: Invoke staging and production URLs and confirm each reaches the configured function version or alias. It is not direct evidence for: A patched image was tested but its release manifest points to an earlier digest with vulnerable dependencies.
D:Option D is an acceptance test for CodeDeploy blue-green rollback: Induce a failing readiness test in the new environment and verify routing returns to the previous one. It is not direct evidence for: A patched image was tested but its release manifest points to an earlier digest with vulnerable dependencies.
Question 313
A staging acceptance reviewer must demonstrate working end-to-end behavior rather than cite a configuration screenshot, using a controlled test before deployment. A media app wants to encrypt gigabyte-sized archives with KMS but exceeds the service's single-request plaintext limit. Which observation is the strongest acceptance evidence?
- Rotate a safe test key using supported policy and decrypt ciphertext written with prior key material.
- Submit valid, expired, and wrong-client tokens and verify only the intended token is accepted by the backend.
- Invoke a safe state machine with and without required task permission and confirm the specific service action fails narrowly.
- Encrypt and decrypt a synthetic large payload while verifying encrypted data keys, authorization, and key handling.
Explanation
Correct Answer
D:The decisive acceptance evidence is: Encrypt and decrypt a synthetic large payload while verifying encrypted data keys, authorization, and key handling. It demonstrates: KMS GenerateDataKey returns key material and an encrypted key blob; the client uses the plaintext key only transiently for data encryption. Scenario: A media app wants to encrypt gigabyte-sized archives with KMS but exceeds the service's single-request plaintext limit.
Incorrect Answers
A:Option A is an acceptance test for KMS rotation and encrypted data continuity: Rotate a safe test key using supported policy and decrypt ciphertext written with prior key material. It is not direct evidence for: A media app wants to encrypt gigabyte-sized archives with KMS but exceeds the service's single-request plaintext limit.
B:Option B is an acceptance test for Cognito user-pool login tokens: Submit valid, expired, and wrong-client tokens and verify only the intended token is accepted by the backend. It is not direct evidence for: A media app wants to encrypt gigabyte-sized archives with KMS but exceeds the service's single-request plaintext limit.
C:Option C is an acceptance test for Cross-service execution role in Step Functions: Invoke a safe state machine with and without required task permission and confirm the specific service action fails narrowly. It is not direct evidence for: A media app wants to encrypt gigabyte-sized archives with KMS but exceeds the service's single-request plaintext limit.
Question 314
An AWS developer is reviewing the next application release. Two services serialize timestamps in different time zones and order events incorrectly after reading them. Which technical change most directly meets the requirement?
- Configure Lambda reserved concurrency to bound function scale when a downstream dependency has a limited connection budget.
- Use DynamoDB TransactWriteItems to apply a small set of related item changes atomically when the transaction limits permit.
- Serialize application objects with explicit schema, numeric types, and timestamp handling before writing to a data store.
- Benchmark Lambda memory settings with representative inputs to improve CPU-bound runtime and total cost.
Explanation
Correct Answer
C:Uncontrolled serialization can change timestamp formats and numeric precision, breaking later readers. Apply: Serialize application objects with explicit schema, numeric types, and timestamp handling before writing to a data store. Acceptance check: Round-trip a fixture with decimals and UTC timestamps and compare exact domain values after deserialization. Scenario: Two services serialize timestamps in different time zones and order events incorrectly after reading them.
Incorrect Answers
A:Option A implements a different developer control (Lambda reserved concurrency): Configure Lambda reserved concurrency to bound function scale when a downstream dependency has a limited connection budget. That does not resolve the specific situation: Two services serialize timestamps in different time zones and order events incorrectly after reading them.
B:Option B implements a different developer control (DynamoDB transaction writes): Use DynamoDB TransactWriteItems to apply a small set of related item changes atomically when the transaction limits permit. That does not resolve the specific situation: Two services serialize timestamps in different time zones and order events incorrectly after reading them.
D:Option D implements a different developer control (Lambda power tuning): Benchmark Lambda memory settings with representative inputs to improve CPU-bound runtime and total cost. That does not resolve the specific situation: Two services serialize timestamps in different time zones and order events incorrectly after reading them.
Question 315
An AWS developer is reviewing the next application release. An event handler bills for messages carrying a status field that should never trigger an action. Which technical change most directly meets the requirement?
- Return the required statusCode and correctly encoded body fields from a Lambda proxy integration.
- Return failed SQS message identifiers through the supported partial batch response format when processing a Lambda batch.
- Use the service SDK paginator or continuation token until all result pages have been retrieved.
- Use supported Lambda event-source mapping filters to discard irrelevant records before function invocation.
Explanation
Correct Answer
D:Event filtering avoids running function code for records that cannot satisfy the configured content condition. Apply: Use supported Lambda event-source mapping filters to discard irrelevant records before function invocation. Acceptance check: Publish matching and nonmatching synthetic queue events and confirm only matching records invoke the function. Scenario: An event handler bills for messages carrying a status field that should never trigger an action.
Incorrect Answers
A:Option A implements a different developer control (API Gateway Lambda proxy response format): Return the required statusCode and correctly encoded body fields from a Lambda proxy integration. That does not resolve the specific situation: An event handler bills for messages carrying a status field that should never trigger an action.
B:Option B implements a different developer control (Lambda partial batch failures for SQS): Return failed SQS message identifiers through the supported partial batch response format when processing a Lambda batch. That does not resolve the specific situation: An event handler bills for messages carrying a status field that should never trigger an action.
C:Option C implements a different developer control (AWS SDK paginator use): Use the service SDK paginator or continuation token until all result pages have been retrieved. That does not resolve the specific situation: An event handler bills for messages carrying a status field that should never trigger an action.
Question 316
An engineering reviewer is evaluating service behavior and authorization boundaries. A worker catches a single invalid SQS record and returns success, causing the bad record to disappear. Which mechanism explains the appropriate design decision?
- Lambda memory allocation also changes available CPU resources, so larger memory may lower duration at acceptable cost.
- Eventually consistent reads can temporarily return stale data, while supported strong reads trade capacity for freshness.
- Partial batch failure reporting limits retries to failed records if the event-source mapping is configured for that feature.
- Caching reduces repeated backend reads but creates a freshness boundary determined by expiration and explicit invalidation.
Explanation
Correct Answer
C:Partial batch failure reporting limits retries to failed records if the event-source mapping is configured for that feature. This is the operating principle for Lambda partial batch failures for SQS. Validation: Inject one poison message in a five-item batch and verify only failed IDs are retried after successful messages commit. Scenario: A worker catches a single invalid SQS record and returns success, causing the bad record to disappear.
Incorrect Answers
A:Option A explains Lambda power tuning rather than this issue: Lambda memory allocation also changes available CPU resources, so larger memory may lower duration at acceptable cost. It does not explain: A worker catches a single invalid SQS record and returns success, causing the bad record to disappear.
B:Option B explains DynamoDB strong read consistency rather than this issue: Eventually consistent reads can temporarily return stale data, while supported strong reads trade capacity for freshness. It does not explain: A worker catches a single invalid SQS record and returns success, causing the bad record to disappear.
D:Option D explains ElastiCache read-through cache rather than this issue: Caching reduces repeated backend reads but creates a freshness boundary determined by expiration and explicit invalidation. It does not explain: A worker catches a single invalid SQS record and returns success, causing the bad record to disappear.
Question 317
A cloud developer must explain the mechanism behind a proposed solution. An API custom domain returns certificate-name errors after deploying a wildcard for the wrong parent domain. Which technical explanation correctly accounts for the solution?
- TLS protects data in transit and server-authentication checks prevent connecting to an impostor endpoint.
- Identity claims determine tenant authorization independently of which resource key a user guesses or sends in a URL.
- A TLS certificate's domain names and issuance or region constraints must match the client-visible service endpoint.
- JWT authorizers check token metadata and claims before invoking protected API routes.
Explanation
Correct Answer
C:A TLS certificate's domain names and issuance or region constraints must match the client-visible service endpoint. This is the operating principle for AWS Certificate Manager HTTPS certificate binding. Validation: Connect to the configured custom domain and inspect hostname matching, chain trust, and expected renewal state. Scenario: An API custom domain returns certificate-name errors after deploying a wildcard for the wrong parent domain.
Incorrect Answers
A:Option A explains TLS server identity validation rather than this issue: TLS protects data in transit and server-authentication checks prevent connecting to an impostor endpoint. It does not explain: An API custom domain returns certificate-name errors after deploying a wildcard for the wrong parent domain.
B:Option B explains Multi-tenant partitioning guard rather than this issue: Identity claims determine tenant authorization independently of which resource key a user guesses or sends in a URL. It does not explain: An API custom domain returns certificate-name errors after deploying a wildcard for the wrong parent domain.
D:Option D explains API Gateway JWT authorizer scope rather than this issue: JWT authorizers check token metadata and claims before invoking protected API routes. It does not explain: An API custom domain returns certificate-name errors after deploying a wildcard for the wrong parent domain.
Question 318
A development team must select an AWS application change. A Lambda swallows DynamoDB conditional-write errors then falsely reports a payment was accepted. Which implementation best addresses this situation?
- Attach Lambda to appropriate VPC subnets and security groups with verified routes to its private database.
- Package shared supported libraries in versioned Lambda layers compatible with the function runtime and architecture.
- Catch typed retryable AWS SDK service errors and handle terminal authorization or input failures separately.
- Use a strongly consistent read on a supported DynamoDB table or local secondary index when immediate read-after-write is required.
Explanation
Correct Answer
C:The SDK can report throttling, transient failures, and permanent access denials that require different client behavior. Apply: Catch typed retryable AWS SDK service errors and handle terminal authorization or input failures separately. Acceptance check: Simulate throttling, invalid input, and access-denied responses and verify only transient cases enter controlled retry logic. Scenario: A Lambda swallows DynamoDB conditional-write errors then falsely reports a payment was accepted.
Incorrect Answers
A:Option A implements a different developer control (Lambda VPC connectivity to private data): Attach Lambda to appropriate VPC subnets and security groups with verified routes to its private database. That does not resolve the specific situation: A Lambda swallows DynamoDB conditional-write errors then falsely reports a payment was accepted.
B:Option B implements a different developer control (Lambda layers and runtime dependency packaging): Package shared supported libraries in versioned Lambda layers compatible with the function runtime and architecture. That does not resolve the specific situation: A Lambda swallows DynamoDB conditional-write errors then falsely reports a payment was accepted.
D:Option D implements a different developer control (DynamoDB strong read consistency): Use a strongly consistent read on a supported DynamoDB table or local secondary index when immediate read-after-write is required. That does not resolve the specific situation: A Lambda swallows DynamoDB conditional-write errors then falsely reports a payment was accepted.
Question 319
An AWS developer is reviewing the next application release. A help-desk API returns complete personal identifiers to any authenticated agent though only partial IDs are necessary. Which technical change most directly meets the requirement?
- Reference Secrets Manager or Parameter Store for secret values and restrict environment access and log exposure.
- Use a supported KMS data key and encrypt large application payloads locally with a data encryption algorithm.
- Classify response fields and return only authorized customer attributes, masking or excluding sensitive columns by role.
- Handle short-lived application access tokens and controlled refresh without reusing an expired bearer token indefinitely.
Explanation
Correct Answer
C:The response serializer can enforce an allowlist for sensitive fields after identity and authorization checks. Apply: Classify response fields and return only authorized customer attributes, masking or excluding sensitive columns by role. Acceptance check: Call the same endpoint with a support role and customer role and assert restricted fields are absent from the lesser role's payload. Scenario: A help-desk API returns complete personal identifiers to any authenticated agent though only partial IDs are necessary.
Incorrect Answers
A:Option A implements a different developer control (Secrets in Lambda environment variables): Reference Secrets Manager or Parameter Store for secret values and restrict environment access and log exposure. That does not resolve the specific situation: A help-desk API returns complete personal identifiers to any authenticated agent though only partial IDs are necessary.
B:Option B implements a different developer control (KMS envelope encryption pattern): Use a supported KMS data key and encrypt large application payloads locally with a data encryption algorithm. That does not resolve the specific situation: A help-desk API returns complete personal identifiers to any authenticated agent though only partial IDs are necessary.
D:Option D implements a different developer control (Cognito bearer-token expiry and refresh): Handle short-lived application access tokens and controlled refresh without reusing an expired bearer token indefinitely. That does not resolve the specific situation: A help-desk API returns complete personal identifiers to any authenticated agent though only partial IDs are necessary.
Question 320
An independent QA lead must observe a reproducible before-and-after result with controlled test inputs prior to signing the release. A release declares success despite a failing 10-percent canary because no CloudWatch alarm is attached. What test most directly confirms the intended behavior?
- Build a test image, inspect its digest, and deploy that exact digest to staging before production promotion.
- Run a safe integration build and confirm production deployment waits for the explicit approval decision.
- Deploy a deliberately failing canary and verify the alarm stops traffic shifting and restores the stable version.
- Deploy a minimal test package and invoke the configured handler while checking import resolution.
Explanation
Correct Answer
C:The decisive acceptance evidence is: Deploy a deliberately failing canary and verify the alarm stops traffic shifting and restores the stable version. It demonstrates: CodeDeploy can send a limited share of traffic to a new version and shift more only after healthy checks. Scenario: A release declares success despite a failing 10-percent canary because no CloudWatch alarm is attached.
Incorrect Answers
A:Option A is an acceptance test for Container image dependency pinning: Build a test image, inspect its digest, and deploy that exact digest to staging before production promotion. It is not direct evidence for: A release declares success despite a failing 10-percent canary because no CloudWatch alarm is attached.
B:Option B is an acceptance test for CodePipeline cross-stage approval: Run a safe integration build and confirm production deployment waits for the explicit approval decision. It is not direct evidence for: A release declares success despite a failing 10-percent canary because no CloudWatch alarm is attached.
D:Option D is an acceptance test for Lambda dependency archive packaging: Deploy a minimal test package and invoke the configured handler while checking import resolution. It is not direct evidence for: A release declares success despite a failing 10-percent canary because no CloudWatch alarm is attached.