Free AWS Certified Developer - Associate DVA-C02 Exam Braindumps (page: 22)

Page 22 of 116

A company has a web application that is deployed on AWS. The application uses an
Amazon API Gateway API and an AWS Lambda function as its backend.
The application recently demonstrated unexpected behavior. A developer examines the Lambda function code, finds an error, and modifies the code to resolve the problem. Before deploying the change to production, the developer needs to run tests to validate that the application operates properly.
The application has only a production environment available. The developer must create a new development environment to test the code changes. The developer must also prevent other developers from overwriting these changes during the test cycle.
Which combination of steps will meet these requirements with the LEAST development effort? (Choose two.)

  1. Create a new resource in the current stage. Create a new method with Lambda proxy integration. Select the Lambda function. Add the hotfix alias.
    Redeploy the current stage. Test the backend.
  2. Update the Lambda function in the API Gateway API integration request to use the hotfix alias. Deploy the API Gateway API to a new stage named hotfix.
    Test the backend.
  3. Modify the Lambda function by fixing the code. Test the Lambda function.
    Create the alias hotfix. Point the alias to the $LATEST version.
  4. Modify the Lambda function by fixing the code. Test the Lambda function.
    When the Lambda function is working as expected, publish the Lambda function as a new version. Create the alias hotfix. Point the alias to the new version.
  5. Create a new API Gateway API for the development environment. Add a resource and method with Lambda integration. Choose the Lambda function and the hotfix alias. Deploy to a new stage. Test the backend.

Answer(s): B,D



A developer is implementing an AWS Cloud Development Kit (AWS CDK) serverless application. The developer will provision several AWS Lambda functions and Amazon
API Gateway APIs during AWS CloudFormation stack creation. The developer's workstation has the AWS Serverless Application Model (AWS SAM) and the AWS CDK
installed locally.
How can the developer test a specific Lambda function locally?

  1. Run the sam package and sam deploy commands. Create a Lambda test event from the AWS Management Console. Test the Lambda function.
  2. Run the cdk synth and cdk deploy commands. Create a Lambda test event from the AWS Management Console. Test the Lambda function.
  3. Run the cdk synth and sam local invoke commands with the function construct identifier and the path to the synthesized CloudFormation template.
  4. Run the cdk synth and sam local start-lambda commands with the function construct identifier and the path to the synthesized CloudFormation template.

Answer(s): C



A company's new mobile app uses Amazon API Gateway. As the development team completes a new release of its APIs, a developer must safely and transparently roll out the API change.
What is the SIMPLEST solution for the developer to use for rolling out the new API version to a limited number of users through API Gateway?

  1. Create a new API in API Gateway. Direct a portion of the traffic to the new
    API using an Amazon Route 53 weighted routing policy.
  2. Validate the new API version and promote it to production during the window of lowest expected utilization.
  3. Implement an Amazon CloudWatch alarm to trigger a rollback if the observed
    HTTP 500 status code rate exceeds a predetermined threshold.
  4. Use the canary release deployment option in API Gateway. Direct a percentage of the API traffic using the canarySettings setting.

Answer(s): D



A company caches session information for a web application in an Amazon DynamoDB
table. The company wants an automated way to delete old items from the table.
What is the simplest way to do this?

  1. Write a script that deletes old records; schedule the script as a cron job on an Amazon EC2 instance.
  2. Add an attribute with the expiration time; enable the Time To Live feature based on that attribute.
  3. Each day, create a new table to hold session data; delete the previous day's table.
  4. Add an attribute with the expiration time; name the attribute
    ItemExpiration.

Answer(s): B



Page 22 of 116



Post your Comments and Discuss Amazon AWS Certified Developer - Associate DVA-C02 exam with other Community members:

Ernesto commented on August 26, 2024
Prepared and passed this exam. Valid question and very tough exam. So good luck.
Spain
upvote