AWS Certified Developer Associate DVA-C01 – Question240

A Developer wants to insert a record into an Amazon DynamoDB table as soon as a new file is added to an Amazon S3 bucket.
Which set of steps would be necessary to achieve this?

A.
Create an event with Amazon CloudWatch Events that will monitor the S3 bucket and then insert the records into DynamoDB.
B. Configure an S3 event to invoke a Lambda function that inserts records into DynamoDB.
C. Create a Lambda function that will poll the S3 bucket and then insert the records into DynamoDB.
D. Create a cron job that will run at a scheduled time and insert the records into DynamoDB.

Correct Answer: B

AWS Certified Developer Associate DVA-C01 – Question239

A Developer migrated a web application to AWS. As part of the migration, the Developer implemented an automated continuous integration/continuous improvement (CI/CD) process using a blue/green deployment. The deployment provisions new Amazon EC2 instances in an Auto Scaling group behind a new Application Load Balancer. After the migration was completed, the Developer began receiving complaints from users getting booted out of the system. The system also requires users to log in after every new deployment.
How can these issues be resolved?

A.
Use rolling updates instead of a blue/green deployment
B. Externalize the user sessions to Amazon ElastiCache
C. Turn on sticky sessions in the Application Load Balancer
D. Use multicast to replicate session information

Correct Answer: C

AWS Certified Developer Associate DVA-C01 – Question238

A Developer uses Amazon S3 buckets for static website hosting. The Developer creates one S3 bucket for the code and another S3 bucket for the assets, such as image and video files. Access is denied when a user attempts to access the assets bucket from the code bucket, with the website application showing a 403 error.
How should the Developer solve this issue?

A.
Create an IAM role and apply it to the assets bucket for the code bucket to be granted access.
B. Edit the bucket policy of the assets bucket to open access to all principals.
C. Edit the cross-origin resource sharing (CORS) configuration of the assets bucket to allow any origin to access the assets.
D. Change the code bucket to use AWS Lambda functions instead of static website hosting.

AWS Certified Developer Associate DVA-C01 – Question237

A software company needs to make sure user-uploaded documents are securely stored in Amazon S3. The documents must be encrypted at rest in Amazon S3. The company does not want to manage the security infrastructure in-house, but the company still needs extra protection to ensure it has control over its encryption keys due to industry regulations.
Which encryption strategy should a Developer use to meet these requirements?

A.
Server-side encryption with Amazon S3 managed keys (SSE-S3)
B. Server-side encryption with customer-provided encryption keys (SSE-C)
C. Server-side encryption with AWS KMS managed keys (SSE-KMS)
D. Client-side encryption

AWS Certified Developer Associate DVA-C01 – Question236

A company has implemented AWS CodeDeploy as part of its cloud native CI/CD stack. The company enables automatic rollbacks while deploying a new version of a popular web application from in-place to Amazon EC2.
What occurs if the deployment of the new version fails due to code regression?

A.
The last known good deployment is automatically restored using the snapshot stored in Amazon S3.
B. CodeDeploy switches the Amazon Route 53 alias records back to the known good green deployment and terminates the failed blue deployment.
C. A new deployment of the last known version of the application is deployed with a new deployment ID.
D. AWS CodePipeline promotes the most recent deployment with a SUCCEEDED status to production.

Correct Answer: B

AWS Certified Developer Associate DVA-C01 – Question235

A Development team wants to immediately build and deploy an application whenever there is a change to the source code.
Which approaches could be used to trigger the deployment? (Choose two.)

A.
Store the source code in an Amazon S3 bucket. Configure AWS CodePipeline to start whenever a file in the bucket changes.
B. Store the source code in an encrypted Amazon EBS volume. Configure AWS CodePipeline to start whenever a file in the volume changes.
C. Store the source code in an AWS CodeCommit repository. Configure AWS CodePipeline to start whenever a change is committed to the repository.
D. Store the source code in an Amazon S3 bucket. Configure AWS CodePipeline to start every 15 minutes.
E. Store the source code in an Amazon EC2 instance’s ephemeral storage. Configure the instance to start AWS CodePipeline whenever there are changes to the source code.

AWS Certified Developer Associate DVA-C01 – Question234

A company wants to migrate an imaging service to Amazon EC2 while following security best practices. The images are sourced and read from a non-public Amazon S3 bucket.
What should a Developer do to meet these requirements?

A.
Create an IAM user with read-only permissions for the S3 bucket. Temporarily store the user credentials in the Amazon EBS volume of the EC2 instance.
B. Create an IAM user with read-only permissions for the S3 bucket. Temporarily store the user credentials in the user data of the EC2 instance.
C. Create an EC2 service role with read-only permissions for the S3 bucket. Attach the role to the EC2 instance.
D. Create an S3 service role with read-only permissions for the S3 bucket. Attach the role to the EC2 instance.

AWS Certified Developer Associate DVA-C01 – Question233

A Developer has built an application running on AWS Lambda using AWS Serverless Application Model (AWS SAM).
What is the correct order of execution to successfully deploy the application?

A.

1. Build the SAM template in Amazon EC2.
2. Package the SAM template to Amazon EBS storage.
3. Deploy the SAM template from Amazon EBS.

B.
1. Build the SAM template locally.
2. Package the SAM template onto Amazon S3.
3. Deploy the SAM template from Amazon S3.

C.
1. Build the SAM template locally.
2. Deploy the SAM template from Amazon S3.
3. Package the SAM template for use.

D.
1. Build the SAM template locally.
2. Package the SAM template from AWS CodeCommit.
3. Deploy the SAM template to CodeCommit.

AWS Certified Developer Associate DVA-C01 – Question232

A company has implemented AWS CodePipeline to automate its release pipelines. The Development team is writing an AWS Lambda function what will send notifications for state changes of each of the actions in the stages.
Which steps must be taken to associate the Lambda function with the event source?

A.
Create a trigger that invokes the Lambda function from the Lambda console by selecting CodePipeline as the event source.
B. Create an event trigger and specify the Lambda function from the CodePipeline console.
C. Create an Amazon CloudWatch alarm that monitors status changes in Code Pipeline and triggers the Lambda function.
D. Create an Amazon CloudWatch Events rule that uses CodePipeline as an event source.

AWS Certified Developer Associate DVA-C01 – Question231

A Software Engineer developed an AWS Lambda function in Node.js to do some CPU-intensive data processing. With the default settings, the Lambda function takes about 5 minutes to complete.
Which approach should a Developer take to increase the speed of completion?

A.
Instead of using Node.js, rewrite the Lambda function using Python.
B. Instead of packaging the libraries in the ZIP file with the function, move them to a Lambda layer and use the layer with the function.
C. Allocate the maximum available CPU units to the function.
D. Increase the available memory to the function.