πŸ”

DVA-C02 β€” questions

Page 23 of 28 Β· 557 total questions.

Topic 1 Β· Question 441

A developer is working on an ecommerce application that stores data in an Amazon RDS for MySQL cluster. The developer needs to implement a caching layer for the application to retrieve information about the most viewed products. Which solution will meet these requirements?

  • AEdit the RDS for MySQL cluster by adding a cache node. Configure the cache endpoint instead of the cluster endpoint in the application.
  • BCreate an Amazon ElastiCache for Redis cluster. Update the application code to use the ElastiCache for Redis cluster endpoint. (correct answer)
  • CCreate an Amazon DynamoDB Accelerator (DAX) cluster in front of the RDS for MySQL cluster. Configure the application to connect to the DAX endpoint instead of the RDS endpoint.
  • DConfigure the RDS for MySQL cluster to add a standby instance in a different Availability Zone. Configure the application to read the data from the standby instance.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Create an Amazon ElastiCache for Redis cluster. Update the application code to use the ElastiCache for Redis cluster endpoint.

Explanation

Amazon ElastiCache provides in-memory caching (Redis/Memcached) to reduce latency and offload the database.

Topic 1 Β· Question 442

A developer is working on an ecommerce application that stores data in an Amazon RDS for MySQL cluster. The developer needs to implement a caching layer for the application to retrieve information about the most viewed products. Which solution will meet these requirements?

  • AEdit the RDS for MySQL cluster by adding a cache node. Configure the cache endpoint instead of the cluster endpoint in the application.
  • BCreate an Amazon ElastiCache for Redis cluster. Update the application code to use the ElastiCache for Redis cluster endpoint. (correct answer)
  • CCreate an Amazon DynamoDB Accelerator (DAX) cluster in front of the RDS for MySQL cluster. Configure the application to connect to the DAX endpoint instead of the RDS endpoint.
  • DConfigure the RDS for MySQL cluster to add a standby instance in a different Availability Zone. Configure the application to read the data from the standby instance.
Reveal answer & explanation
Correct answer: B

The correct answer is B.

Topic 1 Β· Question 443

A developer is creating a database of products. Queries for frequently accessed products must have retrieval times of microseconds. To ensure data consistency, the application cache must be updated whenever products are added, changed, or deleted. Which solution will meet these requirements?

  • ASet up an Amazon DynamoDB database and a DynamoDB Accelerator (DAX) cluster. (correct answer)
  • BSet up an Amazon RDS database and an Amazon ElastiCache for Redis cluster. Implement a lazy loading caching strategy with ElastiCache.
  • CSetup an Amazon DynamoDB database that has an in-memory cache. Implement a lazy loading caching strategy in the application.
  • DSet up an Amazon RDS database and an Amazon DynamoDB Accelerator (DAX) cluster. Specify a TTL setting for the DAX cluster.
Reveal answer & explanation
Correct answer: A

The correct answer is A. Option A: Set up an Amazon DynamoDB database and a DynamoDB Accelerator (DAX) cluster.

Explanation

Amazon DynamoDB is a fully managed, serverless NoSQL database with single-digit millisecond latency and automatic scaling. DynamoDB Accelerator (DAX) adds an in-memory cache for microsecond DynamoDB reads.

Topic 1 Β· Question 444 Β· Select all that apply

A developer is creating a script to automate the deployment process for a serverless application. The developer wants to use an existing AWS Serverless Application Model (AWS SAM) template for the application. What should the developer use for the project? (Choose two.)

  • ACall aws cloudformation package to create the deployment package. Call aws cloudformation deploy to deploy the package afterward. (correct answer)
  • BCall sam package to create the deployment package. Call sam deploy to deploy the package afterward. (correct answer)
  • CCall aws s3 cp to upload the AWS SAM template to Amazon S3. Call aws lambda update-function-code to create the application.
  • DCreate a ZIP package locally and call aws serverlessrepo create-applicatiion to create the application.
  • ECreate a ZIP package and upload it to Amazon S3. Call aws cloudformation create-stack to create the application.
Reveal answer & explanation
Correct answer: A, B

The correct answer is A, B. Option A: Call aws cloudformation package to create the deployment package. Call aws cloudformation deploy to deploy the package afterward. Option B: Call sam package to create the deployment package. Call sam deploy to deploy the package afterward.

Explanation

AWS CloudFormation provisions infrastructure as code repeatably.

Topic 1 Β· Question 445

A developer is working on a project that requires regular updates to a web application’s backend code. The code is stored in AWS CodeCommit. Company policy states that all code must have complete unit testing and that the test results must be available for access. The developer needs to implement a solution that will take each change to the code repository, build the code, and run unit tests. The solution also must provide a detailed report of the test results. Which solution will meet these requirements?

  • AConfigure AWS CodeDeploy to deploy code from CodeCommit and to run unit tests. Send the test results to Amazon CloudWatch metrics to view reports.
  • BConfigure Amazon CodeWhisperer to create the code and to run unit tests. Save the test results in an Amazon S3 bucket to generate reports.
  • CConfigure AWS CodeBuild to build the code and to run unit tests. Use test reporting in CodeBuild to generate and view reports. (correct answer)
  • DCreate AWS Lambda functions that run when changes are made in CodeCommit. Program the Lambda functions to build the code, run unit tests, and save the test results to a Lambda layer.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Configure AWS CodeBuild to build the code and to run unit tests. Use test reporting in CodeBuild to generate and view reports.

Explanation

AWS Config tracks resource configuration changes and evaluates compliance. AWS CodeBuild compiles, tests and packages code in a managed build service.

Topic 1 Β· Question 446

A developer is building an application on AWS. The application has an Amazon API Gateway API that sends requests to an AWS Lambda function. The API is experiencing increased latency because the Lambda function has limited available CPU to fulfill the requests. Before the developer deploys the API into production, the developer must configure the Lambda function to have more CPU. Which solution will meet this requirement?

  • AIncrease the virtual CPU (vCPU) cores quota of the Lambda function.
  • BIncrease the amount of memory that is allocated to the Lambda function. (correct answer)
  • CIncrease the ephemeral storage size of the Lambda function.
  • DIncrease the timeout value of the Lambda function.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Increase the amount of memory that is allocated to the Lambda function.

Explanation

AWS Lambda runs code without provisioning servers and scales automatically, which minimizes operational overhead.

Topic 1 Β· Question 447

A developer has an application that uses AWS Lambda functions and AWS CloudFormation templates. Usage of the application has increased. As a result, the Lambda functions are encountering rate limit errors when they retrieve data. The Lambda functions retrieve an advanced parameter from AWS Systems Manager Parameter Store on every call. The parameter changes only during new deployments. Because the application’s usage is unpredictable, the developer needs a way to avoid the rate limiting. Which solution will meet these requirements MOST cost-effectively?

  • AConfigure the Lambda functions to use reserved concurrency that is equal to the last month’s average number of concurrent invocations.
  • BAdd a retry mechanism with exponential backoff to the call to Parameter Store.
  • CRequest a service quota increase for Parameter Store GetParameter API operations to match the expected usage of the Lambda functions.
  • DAdd an SSM dynamic reference as an environment variable to the Lambda functions resource in the CloudFormation templates. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Add an SSM dynamic reference as an environment variable to the Lambda functions resource in the CloudFormation templates.

Explanation

AWS Lambda runs code without provisioning servers and scales automatically, which minimizes operational overhead. AWS CloudFormation provisions infrastructure as code repeatably. This option delivers the requirement at the lowest cost.

Topic 1 Β· Question 448

A developer is using an AWS Lambda function to process data. The developer needs to extract custom metrics about processing times from the Lambda logs. The developer needs to analyze the metrics, set alarms, and detect issues in real time. Which solution will meet these requirements?

  • APublish custom metric data to AWS CloudTrail by using the PutMetricData API operation. Classify and collect the metrics. Create graphs and alarms in CloudTrail for the custom metrics.
  • BUse the open source client libraries provided by Amazon to generate the logs in the Amazon CloudWatch embedded metric format. Use CloudWatch to create the required graphs and alarms for the custom metrics. (correct answer)
  • CUse Amazon CloudWatch Logs Insights to create custom metrics by querying the logs that come from the Lambda function. Use CloudWatch to create the required graphs and alarms for the custom metrics.
  • DCreate an Amazon Kinesis data stream to stream log events in real time from Lambda. Specify an Amazon S3 bucket as the destination for the Kinesis data stream. Use Amazon CloudWatch to visualize the log data and to set alarms.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Use the open source client libraries provided by Amazon to generate the logs in the Amazon CloudWatch embedded metric format. Use CloudWatch to create the required graphs and alarms for the custom metrics.

Explanation

Amazon CloudWatch collects metrics, logs and alarms to monitor and react to operational health. This option meets the real-time / low-latency performance requirement.

Topic 1 Β· Question 449 Β· Select all that apply

A developer needs to fix an AWS CodeDeploy deployment that failed. During the failed deployment, the developer received the following error message: β€œThe overall deployment failed because too many individual instances failed deployment, too few healthy instances are available for deployment, or some instances in your deployment group are experiencing problems. (Error code: HEALTH-CONSTRAINTS)” What are the possible causes of the failed deployment? (Choose two.)

  • AThe CodeDeploy agent was not running on the instances that CodeDeploy was trying to deploy to. (correct answer)
  • BThe unified Amazon CloudWatch agent was not running on the instances that CodeDeploy was trying to deploy to.
  • CThe developer’s IAM role did not have the necessary permissions to perform code deployment to the instances.
  • DCodeDeploy was trying to deploy to instances that were attached to an IAM instance profile that did not have the required permissions.
  • ECodeDeploy was trying to deploy to instances that were not set up with correct CodeDeploy health checks. (correct answer)
Reveal answer & explanation
Correct answer: A, E

The correct answer is A, E. Option A: The CodeDeploy agent was not running on the instances that CodeDeploy was trying to deploy to. Option E: CodeDeploy was trying to deploy to instances that were not set up with correct CodeDeploy health checks.

Explanation

AWS CodeDeploy automates application deployments to compute services.

Topic 1 Β· Question 450

A company is developing a serverless application that requires storage of sensitive API keys as environment variables for various services. The application requires the automatic rotation of the encryption keys every year. Which solution will meet these requirements with no development effort?

  • AEncrypt the environment variables by using AWS Secrets Manager. Set up automatic rotation in Secrets Manager.
  • BEncrypt the environment variables by using AWS Key Management Service (AWS KMS) customer managed keys. Enable automatic key rotation. (correct answer)
  • CEncrypt the environment variables by using AWS Key Management Service (AWS KMS) AWS managed keys. Configure a custom AWS Lambda function to automate key rotation.
  • DEncrypt the environment variables by using AWS Systems Manager Parameter Store. Set up automatic rotation in Parameter Store.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Encrypt the environment variables by using AWS Key Management Service (AWS KMS) customer managed keys. Enable automatic key rotation.

Explanation

AWS KMS manages encryption keys and integrates with most AWS services for encryption at rest.

Topic 1 Β· Question 451

A developer is using an AWS Lambda function to process data. The developer needs to extract custom metrics about processing times from the Lambda logs. The developer needs to analyze the metrics, set alarms, and detect issues in real time. Which solution will meet these requirements?

  • APublish custom metric data to AWS CloudTrail by using the PutMetricData API operation. Classify and collect the metrics. Create graphs and alarms in CloudTrail for the custom metrics.
  • BUse the open source client libraries provided by Amazon to generate the logs in the Amazon CloudWatch embedded metric format. Use CloudWatch to create the required graphs and alarms for the custom metrics. (correct answer)
  • CUse Amazon CloudWatch Logs Insights to create custom metrics by querying the logs that come from the Lambda function. Use CloudWatch to create the required graphs and alarms for the custom metrics.
  • DCreate an Amazon Kinesis data stream to stream log events in real time from Lambda. Specify an Amazon S3 bucket as the destination for the Kinesis data stream. Use Amazon CloudWatch to visualize the log data and to set alarms.
Reveal answer & explanation
Correct answer: B

The correct answer is B.

Topic 1 Β· Question 452

An application stores user data in Amazon S3 buckets in multiple AWS Regions. A developer needs to implement a solution that analyzes the user data in the S3 buckets to find sensitive information. The analysis findings from all the S3 buckets must be available in the eu-west-2 Region. Which solution will meet these requirements with the LEAST development effort?

  • ACreate an AWS Lambda function to generate findings. Program the Lambda function to send the findings to another S3 bucket in eu-west-2.
  • BConfigure Amazon Macie to generate findings. Use Amazon EventBridge to create rules that copy the findings to eu-west-2. (correct answer)
  • CConfigure Amazon Inspector to generate findings. Use Amazon EventBridge to create rules that copy the findings to eu-west-2.
  • DConfigure Amazon Macie to generate findings and to publish the findings to AWS CloudTrail. Use a CloudTrail trail to copy the results to eu-west-2.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Configure Amazon Macie to generate findings. Use Amazon EventBridge to create rules that copy the findings to eu-west-2.

Explanation

Amazon EventBridge routes events between services with rules, enabling event-driven, decoupled architectures. Amazon Macie discovers and protects sensitive data such as PII in S3. AWS Config tracks resource configuration changes and evaluates compliance. This option needs the least custom development effort.

Topic 1 Β· Question 453

An application ingests data from an Amazon Kinesis data stream. The shards in the data stream are set for normal traffic. During tests for peak traffic, the application ingests data slowly. A developer needs to adjust the data stream to handle the peak traffic. What should the developer do to meet this requirement MOST cost-effectively?

  • AInstall the Kinesis Producer Library (KPL) to ingest data into the data stream.
  • BSwitch to on-demand capacity mode for the data stream. Specify a partition key when writing data to the data stream.
  • CDecrease the amount of time that data is kept in the data stream by using the DecreaseStreamRetentionPeriod API operation.
  • DIncrease the shard count in the data stream by using the UpdateShardCount API operation. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Increase the shard count in the data stream by using the UpdateShardCount API operation. This option delivers the requirement at the lowest cost.

Topic 1 Β· Question 454

A developer is building an application that uses an AWS Lambda function to process data. The application requires minimum latency. The Lambda function must have predictable function start times. All setup activities for the execution environment must happen before invocation of the Lambda function. Which solution will meet these requirements?

  • AIncrease the memory of the Lambda function to the maximum amount. Configure an Amazon EventBridge rule to schedule invocations of the Lambda function every minute to keep the execution environment active.
  • BOptimize the static initialization code that runs when a new execution environment is prepared for the first time. Decrease and compress the size of the Lambda function package and the imported libraries and dependencies.
  • CIncrease the reserved concurrency of the Lambda function to the maximum value for unreserved account concurrency. Run any setup activities manually before the initial invocation of the Lambda function.
  • DPublish a new version of the Lambda function. Configure provisioned concurrency for the Lambda function with the required minimum number of execution environments. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Publish a new version of the Lambda function. Configure provisioned concurrency for the Lambda function with the required minimum number of execution environments.

Explanation

AWS Lambda runs code without provisioning servers and scales automatically, which minimizes operational overhead. AWS Config tracks resource configuration changes and evaluates compliance.

Topic 1 Β· Question 455

A company has implemented a pipeline in AWS CodePipeline. The company is using a single AWS account and does not use AWS Organizations. The company needs to test its AWS CloudFormation templates in its primary AWS Region and a disaster recovery Region. Which solution will meet these requirements with the MOST operational efficiency?

  • AIn the CodePipeline pipeline, implement an AWS CodeDeploy action for each Region to deploy and test the CloudFormation templates. Update CodePipeline and AWS CodeBuild with appropriate permissions.
  • BConfigure CodePipeline to deploy and test the CloudFormation templates. Use CloudFormation StackSets to start deployment across both Regions. (correct answer)
  • CConfigure CodePipeline to invoke AWS CodeBuild to deploy and test the CloudFormation templates in each Region. Update CodeBuild and CloudFormation with appropriate permissions.
  • DUse the Snyk action in CodePipeline to deploy and test the CloudFormation templates in each Region.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Configure CodePipeline to deploy and test the CloudFormation templates. Use CloudFormation StackSets to start deployment across both Regions.

Explanation

AWS Config tracks resource configuration changes and evaluates compliance. AWS CloudFormation provisions infrastructure as code repeatably. AWS CodePipeline automates continuous delivery pipelines. By spanning multiple Availability Zones / adding redundancy, this option provides the high availability and resilience required.

Topic 1 Β· Question 456

A company has an Amazon API Gateway REST API that integrates with an AWS Lambda function. The API’s development stage references a development alias of the Lambda function named dev. A developer needs make a production alias of the Lambda function named prod available through the API. Which solution meets these requirements?

  • ACreate a new method on the API. Name the method production. Configure the method to include a stage variable that points to the prod Lambda function alias.
  • BCreate a new method on the API. Name the method production. Configure an integration request on the API’s development stage that points to the prod Lambda function alias.
  • CDeploy the API to a new stage named production. Configure the stage to include a stage variable that points to the prod Lambda function alias. (correct answer)
  • DDeploy the API to a new stage named production. Configure an integration request on the API’s production stage that points to the prod Lambda function alias.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Deploy the API to a new stage named production. Configure the stage to include a stage variable that points to the prod Lambda function alias.

Explanation

AWS Lambda runs code without provisioning servers and scales automatically, which minimizes operational overhead. AWS Config tracks resource configuration changes and evaluates compliance.

Topic 1 Β· Question 457

A developer is implementing a serverless application by using AWS CloudFormation to provision Amazon S3 web hosting. Amazon API Gateway, and AWS Lambda functions. The Lambda function source code is zipped and uploaded to an S3 bucket. The S3 object key of the zipped source code is specified in the Lambda resource in the CloudFormation template. The developer notices that there are no changes in the Lambda function every time the CloudFormation stack is updated. How can the developer resolve this issue?

  • ACreate a new Lambda function alias before updating the CloudFormation stack.
  • BChange the S3 object key or the S3 version in the CloudFormation template before updating the CloudFormation stack. (correct answer)
  • CUpload the zipped source code to another S3 bucket before updating the CioudFormation stack.
  • DAssociate a cade signing configuration with the Lambda function before updating the CloudFormation stack.
Reveal answer & explanation
Correct answer: B

The correct answer is B. Option B: Change the S3 object key or the S3 version in the CloudFormation template before updating the CloudFormation stack.

Explanation

Amazon S3 provides durable, scalable object storage that is fully managed. AWS CloudFormation provisions infrastructure as code repeatably.

Topic 1 Β· Question 458

A developer published a change to a new version of an AWS Lambda function. To test the change, the developer must route 50% of the traffic to the new version and 60% of the traffic to the current version. What is the MOST operationally efficient way to meet this requirement?

  • ACreate two Amazon Route 53 records that use a simple routing policy to route traffic to the different versions of the Lambda function. Create another Route 53 record that uses a weighted routing policy to route 50% of the traffic to each simple routing record. Test the Lambda function by using the weighted routing record.
  • BCreate an Amazon API Gateway API with a POST method that is integrated with the Lambda function. Add a stage variable that includes the version of the Lambda function. Add a canary release that will override the version variable 50% of the time. Deploy and test the Lambda function through the API Gateway stage.
  • CCreate a Lambda function alias. Set the weight to 50% for the current version and 50% for the new version. Set the event source mappings for the Lambda function to point to the alias. (correct answer)
  • DUpdate the event source mappings for the Lambda function. In the mappings, set the weight to 50% for the current version and 50% for the new version.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Create a Lambda function alias. Set the weight to 50% for the current version and 50% for the new version. Set the event source mappings for the Lambda function to point to the alias.

Explanation

AWS Lambda runs code without provisioning servers and scales automatically, which minimizes operational overhead.

Topic 1 Β· Question 459

A developer is building an application that processes a stream of user-supplied data. The data stream must be consumed by multiple Amazon EC2 based processing applications in parallel and in real time. Each processor must be able to resume without losing data if there is a service interruption. The application architect plans to add other processors in the near future, and wants to minimize the amount of data duplication involved. Which solution will satisfy these requirements?

  • APublish the data to Amazon Simple Queue Service (Amazon SQS).
  • BPublish the data to Amazon Data Firehose.
  • CPublish the data to Amazon EventBridge.
  • DPublish the data to Amazon Kinesis Data Streams. (correct answer)
Reveal answer & explanation
Correct answer: D

The correct answer is D. Option D: Publish the data to Amazon Kinesis Data Streams.

Explanation

Kinesis Data Streams ingests and processes high-volume real-time streaming data. Amazon Kinesis ingests and processes real-time streaming data at scale. This option meets the real-time / low-latency performance requirement.

Topic 1 Β· Question 460

An application is experiencing performance issues based on increased demand. This increased demand is on read-only historical records pulled from an Amazon RDS-hosted database with custom views and queries. A developer must improve performance without changing the database structure. Which approach will improve performance and MINIMIZE management overhead?

  • ADeploy Amazon DynamoDB, move all the data, and point to DynamoDB.
  • BDeploy Amazon ElastiCache (Redis OSS) and cache the data for the application.
  • CDeploy Memcached on Amazon EC2 and cache the data for the application. (correct answer)
  • DDeploy Amazon DynamoDB Accelerator (DAX) on Amazon RDS to improve cache performance.
Reveal answer & explanation
Correct answer: C

The correct answer is C. Option C: Deploy Memcached on Amazon EC2 and cache the data for the application.

Explanation

Amazon EC2 provides resizable virtual servers when you need full control of the operating system.

Showing questions 441–460 of 557 Β· Page 23 of 28