Amazon

DVA-C02 Free Practice Questions — Page 9

Question 81

A company is hosting an Amazon AP! Gateway REST API that calls a single AWS Lambda function. The function is infrequently invoked by multiple clients at the same time. The code performance is optimal, but the company wants to optimize the startup time of the function What can a developer do to optimize the initialization of the function?

A. Enable API Gateway caching for the REST API.
B. Configure provisioned concurrency for the Lambda function.
C. Use Lambda proxy integration for the REST API.
D. Configure AWS Global Accelerator for the Lambda function.
Show Answer
Correct Answer: B
Explanation:
The problem describes optimizing Lambda startup (cold start) time when the function is infrequently invoked but may receive concurrent requests. Provisioned concurrency keeps a specified number of Lambda execution environments pre-initialized and ready to serve requests, which directly reduces or eliminates cold start latency. The other options do not affect Lambda initialization time: API Gateway caching affects response caching, proxy integration affects request handling, and Global Accelerator optimizes network routing, not function startup.

Question 82

A gaming company has deployed a web portal on AWS Elastic Beanstalk. The company sometimes needs to deploy new versions three or four times in a day. The company needs to deploy new features for all users as quickly as possible. The solution must minimize performance impact and must maximize availability. What solution will meet these requirements?

A. Use a rolling deployment policy to deploy to Amazon EC2 instances.
B. Use an immutable deployment policy to deploy to Amazon EC2 instances.
C. Use an all-at-once deployment policy to deploy to Amazon EC2 instances.
D. Use a-canary deployment strategy to deploy changes to Amazon EC2 instances.
Show Answer
Correct Answer: B
Explanation:
An immutable deployment in Elastic Beanstalk launches a new set of EC2 instances with the new application version while keeping the existing environment fully serving traffic. After the new instances pass health checks, traffic is switched over and the old instances are terminated. This provides maximum availability, minimizes performance impact, allows fast rollback, and supports frequent deployments throughout the day. Rolling and all-at-once deployments can reduce capacity or cause brief outages, and canary deployments intentionally delay full rollout, which conflicts with the requirement to deploy new features to all users as quickly as possible.

Question 83

An Amazon Data Firehose delivery stream is receiving customer data that contains personally identifiable information. A developer needs to remove pattern-based customer identifiers from the data and store the modified data in an Amazon S3 bucket. What should the developer do to meet these requirements?

A. Implement Firehose data transformation as an AWS Lambda function. Configure the function to remove the customer identifiers. Set an Amazon S3 bucket as the destination of the delivery stream.
B. Launch an Amazon EC2 instance. Set the EC2 instance as the destination of the delivery stream. Run an application on the EC2 instance to remove the customer identifiers. Store the transformed data in an Amazon S3 bucket.
C. Create an Amazon OpenSearch Service instance. Set the OpenSearch Service instance as the destination of the delivery stream. Use search and replace to remove the customer identifiers. Export the data to an Amazon S3 bucket.
D. Create an AWS Step Functions workflow to remove the customer identifiers. As the last step in the workflow, store the transformed data in an Amazon S3 bucket. Set the workflow as the destination of the delivery stream.
Show Answer
Correct Answer: A
Explanation:
Amazon Kinesis Data Firehose natively supports data transformation using AWS Lambda. A Lambda function can perform pattern-based removal or masking of PII before delivery. Firehose can then directly deliver the transformed data to Amazon S3. The other options are unsupported or unnecessarily complex: Firehose cannot deliver directly to EC2 or Step Functions, and OpenSearch is not designed for preprocessing and exporting transformed data back to S3.

Question 84

A company hosts applications on premises. The on-premises servers generate audit logs that are available through an HTTP endpoint. The company needs an automated solution to regularly ingest and store large volumes of audit data from the on-premises servers. The company also needs to perform queries on the audit data. Which solution will meet these requirements in the MOST operationally efficient way?

A. Export the audit logs. Upload the logs to Amazon S3. Import the logs to an Amazon RDS DB instance.
B. Create an AWS Lambda function to call the HTTP endpoint to fetch audit logs. Configure an Amazon EventBridge scheduled rule to invoke the Lambda function. Configure the Lambda function to push the logs to AWS CloudTrail Lake.
C. Use AWS DataSync to transfer audit logs to an Amazon S3 bucket. Load the logs into an Amazon S3 bucket. Use Amazon Athena to query the bucket.
D. Install the Amazon CloudWatch agent on the on-premises servers. Give the agent the ability to push audit logs to CloudWatch. Use CloudWatch Insights to query the logs.
Show Answer
Correct Answer: B
Explanation:
The key requirement is that audit logs are exposed through an HTTP endpoint. AWS DataSync and the CloudWatch agent are designed for file or storage-based log collection, not HTTP-based ingestion, which makes options C and D unsuitable. Option A adds unnecessary database management overhead. A scheduled AWS Lambda function invoked by EventBridge can directly fetch data from the HTTP endpoint without installing on-premises software, and CloudTrail Lake provides a managed, scalable service for storing and querying large volumes of audit data. This makes option B the most operationally efficient solution.

Question 85

A company has an ecommerce application. The application's API sends order data to an Amazon Simple Queue Service (Amazon SOS) queue. A developer needs to modify the application to enrich the order data before the application sends the order data to a fulfillment system. Which solution will meet this requirement with the LEAST development effort?

A. Create an AWS Lambda function to poll the SOS queue. enrich the message data, and send the enriched data to the fulfilment system, Create an Amazon Simple Notification Service (Amazon SNS) topic. Subscribe the Lambda function to the SNS topic.
B. Create an AWS Step Functions state machine. Configure an Amazon EventBridge rule to run the state machine when an order is published to the SQS queue. Map the orders to an AWS Lambda function. Program the Lambda function to perform the data enrichment and to invoke the state machine. Configure the last step of the state machine to send the enriched data to the fulfilment system,
C. Create an Amazon EMR cluster to read messages from the SQS queue. Configure an EMR job to enrich the order data. Create and configure an Amazon S3 bucket as the output location. Adjust the order fulfilment system to retrieve the enriched files from the S3 bucket.
D. Create an Amazon EventBridge pipe that uses event enrichment. Configure the SQS queue as a source for the pipe. Set the fulfillment system as the target of the pipe.
Show Answer
Correct Answer: D
Explanation:
The requirement is to enrich messages from an SQS queue before sending them to a fulfillment system with the least development effort. Amazon EventBridge Pipes natively supports SQS as a source and provides built-in event enrichment and transformation with minimal or no custom code, then forwards the enriched events directly to a target. The other options require significantly more development and operational overhead (custom Lambda polling, Step Functions orchestration, or EMR clusters).

Question 86

A developer is creating an application that uses an Amazon DynamoDB table. The developer needs to develop code that reads all records that were added to the table during the previous day, creates HTML reports, and pushes the reports into third-party storage. The item size varies from 1 KB to 4 KB, and the index structure is defined with the date. The developer needs to minimize the read capacity that the application requires from the DynamoDB table. Which DynamoDB API operation should the developer use in the code to meet these requirements?

A. Query
B. Scan
C. BatchGetItem
D. GetItem
Show Answer
Correct Answer: A
Explanation:
The requirement is to read only the items added during the previous day while minimizing DynamoDB read capacity usage. Because the table or a secondary index is defined with the date attribute, the Query operation can efficiently retrieve only the matching partition (or partition + sort key range) for that date. Query reads only the relevant items and avoids scanning the entire table, which significantly reduces consumed read capacity units. Scan would read every item, GetItem retrieves only a single item, and BatchGetItem requires knowing specific primary keys in advance, which is not suitable here.

Question 87

A developer needs to configure an AWS Lambda function to make HTTP POST requests to an internal application. The application is in the same AWS account that hosts the function. The internal application runs on Amazon EC2 instances in a private subnet within a VPC. Which solution will meet these requirements?

A. Configure a VPC endpoint to connect to the private subnet. Attach the endpoint to the Lambda function.
B. Attach the Lambda function to the VPC and to the private subnet.
C. Configure a VPN connection between the Lambda function and the private subnet. Attach the VPN to the Lambda function.
D. Configure the VPC route table to include the Lambda function’s IP address.
Show Answer
Correct Answer: B
Explanation:
To access EC2 instances in a private subnet, a Lambda function must be configured to run inside the same VPC. By attaching the Lambda function to the VPC and selecting the appropriate private subnets and security groups, the function gains network access to the internal application. VPC endpoints, VPNs, or route table entries are not applicable for connecting Lambda directly to private EC2 resources.

Question 88

A company runs a new application on AWS Elastic Beanstalk. The company needs to deploy updates to the application. The updates must not cause any downtime for application users. The deployment must forward a specified percentage of incoming client traffic to a new application version during an evaluation period. Which deployment type will meet these requirements?

A. rolling
B. traffic-splitting
C. in-place
D. immutable
Show Answer
Correct Answer: B
Explanation:
Elastic Beanstalk traffic-splitting deployments (canary) allow forwarding a specified percentage of incoming traffic to a new application version during an evaluation period with no downtime. Rolling and in-place can cause partial unavailability or do not support percentage-based traffic shifting, and immutable launches a parallel environment but does not split traffic by percentage during evaluation.

Question 89

An application interacts with Amazon Aurora to store and track customer information. The primary database is set up with multiple read replicas for improving the performance of the read queries. However, one of the Aurora replicas is receiving most or all of the traffic, while the other Aurora replica remains idle. How can this issue be resolved?

A. Disable application-level DNS caching.
B. Enable application-level DNS caching.
C. Enable application pooling
D. Disable application pooling
Show Answer
Correct Answer: A
Explanation:
Aurora read endpoints distribute traffic across replicas using DNS-based load balancing. If the application caches DNS resolutions, it can continue sending all read traffic to a single replica IP, leaving others idle. Disabling application-level DNS caching forces periodic re-resolution of the endpoint, allowing traffic to be balanced across all Aurora read replicas.

Question 90

A developer manages encryption keys in AWS Key Management Service (AWS KMS). The developer must ensure that all encryption keys can be deleted immediately when the keys are no longer required. The developer wants a solution that is highly available and does not require manual management for compute infrastructure. Which solution will meet these requirements?

A. Use AWS KMS managed keys. When the keys are no longer required, schedule the keys for immediate deletion.
B. Use customer managed keys with imported key material. When the keys are no longer required, delete the imported key material.
C. Use customer managed keys. When the keys are no longer required, delete the key material.
D. Use customer managed keys and an AWS CloudHSM key store. When the keys are no longer required, schedule the keys for immediate deletion.
Show Answer
Correct Answer: B
Explanation:
AWS KMS keys (both AWS-managed and customer managed) cannot be deleted immediately; they require a mandatory waiting period of at least 7 days when scheduled for deletion. However, with customer managed keys that use imported key material, the key material itself can be deleted immediately. Deleting the imported key material renders the key unusable right away, meets the immediate deletion requirement, remains highly available (KMS-managed), and does not require managing compute infrastructure. Therefore, option B best meets all requirements.

$19

Get all 555 questions with detailed answers and explanations

  • Instant download HTML + PDF delivered the moment payment clears.
  • Secure Stripe checkout we never see or store your card details.
  • 7-day refund if files are defective see our refund policy.