Amazon AWS Certified Developer - Associate DVA-C02 Practice Test 42
Question 410
A staging deployment should use a different feature flag than production without changing code. Suppose the team omits the intended environment-specific AppConfig safeguard. Which failure mode is the MOST direct risk of that omission?
- Missing or wrongly packaged dependencies cause runtime import failures before handler logic runs.
- Copying production flags into staging accidentally enables functionality in the wrong environment.
- A pipeline that rebuilds a different artifact after approval breaks artifact provenance.
- Updating the production stage for every test exposes incomplete behavior to consumers.
Explanation
Correct Answer
B:Copying production flags into staging accidentally enables functionality in the wrong environment. The planned prevention is to store environment-specific configuration in AWS AppConfig and deploy validated configuration versions; the most direct verification is that the correct environment retrieves its scoped configuration and a failed rollout can be rolled back.
Incorrect Answers
A:That failure mechanism is associated with Lambda deployment package dependencies. The omitted environment-specific AppConfig protection instead causes this problem: copying production flags into staging accidentally enables functionality in the wrong environment.
C:That failure mechanism is associated with CodePipeline gated promotion. The omitted environment-specific AppConfig protection instead causes this problem: copying production flags into staging accidentally enables functionality in the wrong environment.
D:That failure mechanism is associated with API Gateway staging endpoints. The omitted environment-specific AppConfig protection instead causes this problem: copying production flags into staging accidentally enables functionality in the wrong environment.
Question 411
A custom API domain has an expiring public TLS certificate and its clients must keep authenticating endpoints. Suppose the team omits the intended TLS certificate rotation ACM safeguard. Which failure mode is the MOST direct risk of that omission?
- An S3 object permission alone does not give decrypt access to its KMS key.
- Adding another Allow statement does not override an explicit Deny.
- Merely checking that Authorization is nonempty accepts fabricated or expired tokens.
- An expired or mismatched certificate causes client TLS verification failures.
Explanation
Correct Answer
D:An expired or mismatched certificate causes client TLS verification failures. The planned prevention is to provision and validate the certificate using AWS Certificate Manager and associate the renewed certificate with the endpoint; the most direct verification is that tLS handshakes present a valid chain and expected hostname before and after rotation.
Incorrect Answers
A:That failure mechanism is associated with KMS key-policy cross-account. The omitted TLS certificate rotation ACM protection instead causes this problem: an expired or mismatched certificate causes client TLS verification failures.
B:That failure mechanism is associated with IAM policy explicit deny. The omitted TLS certificate rotation ACM protection instead causes this problem: an expired or mismatched certificate causes client TLS verification failures.
C:That failure mechanism is associated with API Gateway JWT authorizer. The omitted TLS certificate rotation ACM protection instead causes this problem: an expired or mismatched certificate causes client TLS verification failures.
Question 412
Multiple Python Lambda functions must share a versioned dependency without copying vendor packages into each source tree. Suppose the team omits the intended Lambda layer dependency management safeguard. Which failure mode is the MOST direct risk of that omission?
- A layer built for a different runtime or architecture can cause module import failures.
- Missing or incomplete request models let invalid payloads reach Lambda and trigger runtime exceptions.
- Treating an async DLQ as a complete execution trace omits response context.
- Using Scan for a predictable partition lookup wastes read capacity and creates latency.
Explanation
Correct Answer
A:A layer built for a different runtime or architecture can cause module import failures. The planned prevention is to publish compatible dependencies as a versioned Lambda layer and attach the required layer version to functions; the most direct verification is that each function loads the expected dependency version under the declared runtime and architecture.
Incorrect Answers
B:That failure mechanism is associated with API Gateway request validation. The omitted Lambda layer dependency management protection instead causes this problem: a layer built for a different runtime or architecture can cause module import failures.
C:That failure mechanism is associated with Lambda destinations versus DLQ. The omitted Lambda layer dependency management protection instead causes this problem: a layer built for a different runtime or architecture can cause module import failures.
D:That failure mechanism is associated with DynamoDB Query versus Scan. The omitted Lambda layer dependency management protection instead causes this problem: a layer built for a different runtime or architecture can cause module import failures.
Question 413
A serverless deployment changes Lambda resource properties and needs predeploy checks. Suppose the team omits the intended SAM template validation safeguard. Which failure mode is the MOST direct risk of that omission?
- A hardcoded backend alias in a shared integration can route test traffic into production.
- A malformed template can fail deployment even if application unit tests pass.
- Manual configuration changes may be overwritten or missed by the next IaC deployment.
- Hardcoding production resource names in a shared template can cause cross-environment collisions.
Explanation
Correct Answer
B:A malformed template can fail deployment even if application unit tests pass. The planned prevention is to run sam validate and template linting before packaging and deploying the application; the most direct verification is that invalid resource declarations fail the validation stage before stack mutation.
Incorrect Answers
A:That failure mechanism is associated with API Gateway stage variables. The omitted SAM template validation protection instead causes this problem: a malformed template can fail deployment even if application unit tests pass.
C:That failure mechanism is associated with infrastructure drift detection. The omitted SAM template validation protection instead causes this problem: a malformed template can fail deployment even if application unit tests pass.
D:That failure mechanism is associated with CloudFormation resource parameters. The omitted SAM template validation protection instead causes this problem: a malformed template can fail deployment even if application unit tests pass.
Question 414
An asynchronous Lambda must preserve request and response context when a job ultimately fails. Suppose the team omits the intended Lambda destinations versus DLQ safeguard. Which failure mode is the MOST direct risk of that omission?
- Treating an async DLQ as a complete execution trace omits response context.
- Missing or incorrect event filter patterns cause unwanted work or dropped eligible records.
- An unconditional PutItem can overwrite valid concurrent state without a conflict signal.
- A too-short visibility timeout lets another consumer receive unfinished work.
Explanation
Correct Answer
A:Treating an async DLQ as a complete execution trace omits response context. The planned prevention is to use a Lambda asynchronous failure destination for an invocation record instead of relying solely on a DLQ; the most direct verification is that the target receives a record including request details and failure response context.
Incorrect Answers
B:That failure mechanism is associated with Lambda event filtering. The omitted Lambda destinations versus DLQ protection instead causes this problem: treating an async DLQ as a complete execution trace omits response context.
C:That failure mechanism is associated with DynamoDB conditional update. The omitted Lambda destinations versus DLQ protection instead causes this problem: treating an async DLQ as a complete execution trace omits response context.
D:That failure mechanism is associated with SQS visibility timeout. The omitted Lambda destinations versus DLQ protection instead causes this problem: treating an async DLQ as a complete execution trace omits response context.
Question 415
A CPU-heavy Lambda builds thumbnails and consistently uses its full timeout despite low memory consumption. Suppose the team omits the intended Lambda memory CPU tuning safeguard. Which failure mode is the MOST direct risk of that omission?
- A missing destination silently loses terminal failure context beyond default handling.
- Treating TTL cleanup as synchronous can keep expired data valid until deletion occurs.
- A one-shot Lambda chain obscures per-step recovery and can exceed execution constraints.
- Holding memory at the minimum can constrain compute even when the function has spare heap.
Explanation
Correct Answer
D:Holding memory at the minimum can constrain compute even when the function has spare heap. The planned prevention is to increase the Lambda memory setting experimentally and benchmark latency and cost at several settings; the most direct verification is that duration and billed-duration measurements improve at a tested memory setting without breaching budget.
Incorrect Answers
A:That failure mechanism is associated with Lambda asynchronous failure destination. The omitted Lambda memory CPU tuning protection instead causes this problem: holding memory at the minimum can constrain compute even when the function has spare heap.
B:That failure mechanism is associated with DynamoDB TTL expiry semantics. The omitted Lambda memory CPU tuning protection instead causes this problem: holding memory at the minimum can constrain compute even when the function has spare heap.
C:That failure mechanism is associated with Step Functions orchestration. The omitted Lambda memory CPU tuning protection instead causes this problem: holding memory at the minimum can constrain compute even when the function has spare heap.
Question 416
A support representative can view order state but must not see full customer identity numbers. Suppose the team omits the intended PII response field masking safeguard. Which failure mode is the MOST direct risk of that omission?
- Logging or returning raw records before masking exposes PII despite correct database encryption.
- Shipping permanent IAM access keys in a client creates unrestricted reusable credentials.
- Removing a secret from the latest file does not erase its exposure in repository history.
- Merely checking that Authorization is nonempty accepts fabricated or expired tokens.
Explanation
Correct Answer
A:Logging or returning raw records before masking exposes PII despite correct database encryption. The planned prevention is to apply field-level authorization and mask sensitive attributes before serializing responses; the most direct verification is that requests from nonprivileged roles contain masked fields while approved roles get only permitted detail.
Incorrect Answers
B:That failure mechanism is associated with Cognito identity pool AWS access. The omitted PII response field masking protection instead causes this problem: logging or returning raw records before masking exposes PII despite correct database encryption.
C:That failure mechanism is associated with secret scanning in CI. The omitted PII response field masking protection instead causes this problem: logging or returning raw records before masking exposes PII despite correct database encryption.
D:That failure mechanism is associated with API Gateway JWT authorizer. The omitted PII response field masking protection instead causes this problem: logging or returning raw records before masking exposes PII despite correct database encryption.
Question 417
A team needs to test v2 of an API while consumers still use the production stage. Suppose the team omits the intended API Gateway staging endpoints safeguard. Which failure mode is the MOST direct risk of that omission?
- Testing a bare JSON object instead of an SQS event misses envelope parsing defects.
- A malformed template can fail deployment even if application unit tests pass.
- Updating the production stage for every test exposes incomplete behavior to consumers.
- Insufficient /tmp space causes disk write failures regardless of the function's available heap.
Explanation
Correct Answer
C:Updating the production stage for every test exposes incomplete behavior to consumers. The planned prevention is to deploy API changes to an isolated API Gateway stage with stage-specific configuration; the most direct verification is that test requests route to the test deployment while production routes keep serving the previous version.
Incorrect Answers
A:That failure mechanism is associated with SQS handler contract tests. The omitted API Gateway staging endpoints protection instead causes this problem: updating the production stage for every test exposes incomplete behavior to consumers.
B:That failure mechanism is associated with SAM template validation. The omitted API Gateway staging endpoints protection instead causes this problem: updating the production stage for every test exposes incomplete behavior to consumers.
D:That failure mechanism is associated with Lambda ephemeral disk sizing. The omitted API Gateway staging endpoints protection instead causes this problem: updating the production stage for every test exposes incomplete behavior to consumers.
Question 418
Two Lambda functions need different access to the same customer dataset and billing reports. Suppose the team omits the intended Lambda execution-role separation safeguard. Which failure mode is the MOST direct risk of that omission?
- Reusing an administrator role for every function violates workload-level least privilege.
- Confusing a user pool with an identity pool leaves the app without the expected login and user-directory flow.
- Logging or returning raw records before masking exposes PII despite correct database encryption.
- A correct IAM token without database user setup or TLS configuration can still fail to connect.
Explanation
Correct Answer
A:Reusing an administrator role for every function violates workload-level least privilege. The planned prevention is to assign distinct least-privilege execution roles to functions according to their required service calls; the most direct verification is that iAM policy simulation or live tests show each function cannot use the other's unrelated resources.
Incorrect Answers
B:That failure mechanism is associated with Cognito user pool authentication. The omitted Lambda execution-role separation protection instead causes this problem: reusing an administrator role for every function violates workload-level least privilege.
C:That failure mechanism is associated with PII response field masking. The omitted Lambda execution-role separation protection instead causes this problem: reusing an administrator role for every function violates workload-level least privilege.
D:That failure mechanism is associated with IAM authentication and TLS for RDS. The omitted Lambda execution-role separation protection instead causes this problem: reusing an administrator role for every function violates workload-level least privilege.
Question 419
A Kinesis-connected Lambda should process only IoT records with an alarm category to reduce unnecessary invocations. Suppose the team omits the intended Lambda event filtering safeguard. Which failure mode is the MOST direct risk of that omission?
- An eventually consistent read may briefly return a stale value after a successful write.
- Hardcoded stage URLs in application source can send production traffic to the wrong backend.
- Duplicate deliveries bypass a stable deduplication check and cause the same side effect twice.
- Missing or incorrect event filter patterns cause unwanted work or dropped eligible records.
Explanation
Correct Answer
D:Missing or incorrect event filter patterns cause unwanted work or dropped eligible records. The planned prevention is to configure a supported Lambda event source filtering pattern matching the required record fields; the most direct verification is that matching records reach the handler and unrelated records do not produce application processing.
Incorrect Answers
A:That failure mechanism is associated with DynamoDB strong read consistency. The omitted Lambda event filtering protection instead causes this problem: missing or incorrect event filter patterns cause unwanted work or dropped eligible records.
B:That failure mechanism is associated with Lambda environment configuration. The omitted Lambda event filtering protection instead causes this problem: missing or incorrect event filter patterns cause unwanted work or dropped eligible records.
C:That failure mechanism is associated with idempotent event handling. The omitted Lambda event filtering protection instead causes this problem: missing or incorrect event filter patterns cause unwanted work or dropped eligible records.
Question 420
A web service downloads private S3 objects that are encrypted using an AWS KMS key. Suppose the team omits the intended S3 SSE-KMS access safeguard. Which failure mode is the MOST direct risk of that omission?
- Ignoring exp claims leaves a path for stale tokens to be reused as authorization.
- A role allowed to GetObject but denied KMS Decrypt cannot read the plaintext.
- Deleting the KMS key during rotation makes ciphertext inaccessible after deletion.
- Confusing a user pool with an identity pool leaves the app without the expected login and user-directory flow.
Explanation
Correct Answer
B:A role allowed to GetObject but denied KMS Decrypt cannot read the plaintext. The planned prevention is to ensure the principal has S3 object permission and the required KMS decrypt permission on the encryption key; the most direct verification is that the object can be retrieved and decrypted by the approved principal without broad KMS rights.
Incorrect Answers
A:That failure mechanism is associated with bearer token refresh and expiry. The omitted S3 SSE-KMS access protection instead causes this problem: a role allowed to GetObject but denied KMS Decrypt cannot read the plaintext.
C:That failure mechanism is associated with KMS rotation scope. The omitted S3 SSE-KMS access protection instead causes this problem: a role allowed to GetObject but denied KMS Decrypt cannot read the plaintext.
D:That failure mechanism is associated with Cognito user pool authentication. The omitted S3 SSE-KMS access protection instead causes this problem: a role allowed to GetObject but denied KMS Decrypt cannot read the plaintext.