Free AWS-Certified-Developer-Associate Exam Braindumps

Pass your Amazon AWS Certified Developer - Associate exam with these free Questions and Answers

Page 5 of 26
QUESTION 16

A developer is building a serverless application by using AWS Serverless Application Model (AWS SAM) on multiple AWS Lambda functions.
When the application is deployed, the developer wants to shift 10% of the traffic to the new deployment of the application for the first 10 minutes after deployment. If there are no issues, all traffic must switch over to the new version.
Which change to the AWS SAM template will meet these requirements?

  1. A. Set the Deployment Preference Type to Canary10Percent10Minute
  2. B. Set theAWS-Certified-Developer-Associate dumps exhibitAutoPublishAlias property to the Lambda alias.
  3. C. Set the Deployment Preference Type to LinearlOPercentEvery10Minute
  4. D. Set AutoPubIishAIias property to the Lambda alias.
  5. E. Set the Deployment Preference Type to CanaryIOPercentIOMinute
  6. F. Set the PreTraffic and PostTraffic properties to the Lambda alias.
  7. G. Set the Deployment Preference Type to LinearlOPercentEveryIOMinute
  8. H. Set PreTraffic and Post Traffic properties to the Lambda alias.

Correct Answer: A
The AWS Serverless Application Model (AWS SAM) comes built-in with CodeDeploy to provide gradual AWS Lambda deployments1.
The DeploymentPreference property in AWS SAM allows you to specify the type of deployment that you want. The Canary10Percent10Minutes option means that 10 percent of your customer traffic is immediately shifted to your new version. After 10 minutes, all traffic is shifted to the new version1. The AutoPublishAlias property in AWS SAM allows AWS SAM to automatically create an alias that points to the updated version of the Lambda function1. Therefore, option A is correct.

QUESTION 17

A developer is troubleshooting an application mat uses Amazon DynamoDB in the uswest- 2 Region. The application is deployed to an Amazon EC2 instance. The application requires read-only permissions to a table that is named Cars The EC2 instance has an attached IAM role that contains the following IAM policy.
AWS-Certified-Developer-Associate dumps exhibit
When the application tries to read from the Cars table, an Access Denied error occurs. How can the developer resolve this error?

  1. A. Modify the IAM policy resource to be "arn aws dynamo* us-west-2 account-id table/*"
  2. B. Modify the IAM policy to include the dynamodb * action
  3. C. Create a trust policy that specifies the EC2 service principa
  4. D. Associate the role with the policy.
  5. E. Create a trust relationship between the role and dynamodb Amazonas com.

Correct Answer: C
https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/access-control- overview.html#access-control-resource-ownership

QUESTION 18

A company is developing an ecommerce application that uses Amazon API Gateway APIs. The application uses AWS Lambda as a backend. The company needs to test the code in a dedicated, monitored test environment before the company releases the code to the production environment.
When solution will meet these requirements?

  1. A. Use a single stage in API Gatewa
  2. B. Create a Lambda function for each environmen
  3. C. Configure API clients to send a query parameter that indicates the endowment and the specific lambda function.
  4. D. Use multiple stages in API Gatewa
  5. E. Create a single Lambda function for all environment
  6. F. Add different code blocks for different environments in the Lambda function based on Lambda environments variables.
  7. G. Use multiple stages in API Gatewa
  8. H. Create a Lambda function for each environmen
  9. I. Configure API Gateway stage variables to route traffic to the Lambda function in different environments.
  10. J. Use a single stage in API Gatewa
  11. K. Configure a API client to send a query parameter that indicated the environmen
  12. L. Add different code blocks tor afferent environments in the Lambda Junction to match the value of the query parameter.

Correct Answer: C
The solution that will meet the requirements is to use multiple stages in API Gateway. Create a Lambda function for each environment. Configure API Gateway stage variables to route traffic to the Lambda function in different environments. This way, the company can test the code in a dedicated, monitored test environment before releasing it to the production environment. The company can also use stage variables to specify the Lambda function version or alias for each stage, and avoid hard-coding the Lambda function name in the API Gateway integration. The other options either involve using a single stage in API Gateway, which does not allow testing in different environments, or adding different code blocks for different environments in the Lambda function, which increases complexity and maintenance.
Reference: Set up stage variables for a REST API in API Gateway

QUESTION 19

AWS-Certified-Developer-Associate dumps exhibitA developer is creating a serverless application that uses an AWS Lambda function The developer will use AWS CloudFormation to deploy the application The application will write logs to Amazon CloudWatch Logs The developer has created a log group in a CloudFormation template for the application to use The developer needs to modify the CloudFormation template to make the name of the log group available to the application at runtime
Which solution will meet this requirement?

  1. A. Use the AWS:lnclude transform in CloudFormation to provide the log group's name to the application
  2. B. Pass the log group's name to the application in the user data section of the CloudFormation template.
  3. C. Use the CloudFormation template's Mappings section to specify the log group's name for the application.
  4. D. Pass the log group's Amazon Resource Name (ARN) as an environment variable to the Lambda function

Correct Answer: D
FunctionName: MyLambdaFunction Code:
S3Bucket: your-lambda-code-bucket S3Key: lambda-code.zip
Runtime: nodejs14.x # Specify the desired runtime for your Lambda function Environment:
Variables:
LOG_GROUP_NAME: !Ref MyLogGroup https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-logs- loggroup.html

QUESTION 20

A company has an analytics application that uses an AWS Lambda function to process transaction data asynchronously A developer notices that asynchronous invocations of the Lambda function sometimes fail When failed Lambda function invocations occur, the developer wants to invoke a second Lambda function to handle errors and log details.
Which solution will meet these requirements?
Solution:
Configuring a Lambda function destination with a failure condition is the best solution for invoking a second Lambda function to handle errors and log details. A Lambda function destination is a resource that Lambda sends events to after a function is invoked. The developer can specify the destination type as Lambda function and the ARN of the error-handling Lambda function as the resource. The developer can also specify the failure condition, which means that the destination is invoked only when the initial Lambda function fails. The destination event will include the response from the initial function, the request ID, and the timestamp. The other solutions are either not feasible or not efficient. Enabling AWS X-Ray active tracing on the initial Lambda function will help to monitor and troubleshoot the function performance, but it will not automatically invoke the error-handling Lambda function. Configuring a Lambda function trigger with a failure condition is not a valid option, as triggers are used to invoke Lambda functions, not to send events from Lambda functions. Creating a status check alarm on the initial Lambda function will incur additional costs and complexity, and it will not capture the details of the failed
invocations. References
✑ Using AWS Lambda destinations
✑ Asynchronous invocation - AWS Lambda
✑ AWS Lambda Destinations: What They Are and Why to Use Them
✑ AWS Lambda Destinations: A Complete Guide | Dashbird

Does this meet the goal?

  1. A. Yes
  2. B. No

Correct Answer: A

Page 5 of 26

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