AWS Certified Developer Associate DVA-C01 – Question310

A development team wants to run their container workloads on Amazon ECS. Each application container needs to share data with another container to collect logs and metrics.
What should the developer team do to meet these requirements?

A.
Create two pod specifications. Make one to include the application container and the other to include the other container. Link the two pods together.
B. Create two task definitions. Make one to include the application container and the other to include the other container. Mount a shared volume between the two tasks.
C. Create one task definition. Specify both containers in the definition. Mount a shared volume between those two containers.
D. Create a single pod specification. Include both containers in the specification. Mount a persistent volume to both containers.

Correct Answer: A

AWS Certified Developer Associate DVA-C01 – Question309

A development team is working on a mobile app that allows users to upload pictures to Amazon S3. The team expects the app will be used by hundreds of thousands of users during a single event simultaneously. Once the pictures are uploaded, the backend service will scan and parse the pictures for inappropriate content.
Which approach is the MOST resilient way to achieve this goal, which also smooths out temporary volume spikes for the backend service?

A.
Develop an AWS Lambda function to check the upload folder in the S3 bucket. If new uploaded pictures are detected, the Lambda function will scan and parse them.
B. Once a picture is uploaded to Amazon S3, publish the event to an Amazon SQS queue. Use the queue as an event source to trigger an AWS Lambda function. In the Lambda function, scan and parse the picture.
C. When the user uploads a picture, invoke an API hosted in Amazon API Gateway. The API will invoke an AWS Lambda function to scan and parse the picture.
D. Create a state machine in AWS Step Functions to check the upload folder in the S3 bucket. If a new picture is detected, invoke an AWS Lambda function to scan and parse it.

Correct Answer: B

AWS Certified Developer Associate DVA-C01 – Question308

An application needs to encrypt data that is written to Amazon S3 where the keys are managed in an on-premises data center, and the encryption is handled by S3.
Which type of encryption should be used?

A.
Use server-side encryption with Amazon S3-managed keys
B. Use server-side encryption with AWS KMS-managed keys
C. Use client-side encryption with customer master keys
D. Use server-side encryption with customer-provided keys

AWS Certified Developer Associate DVA-C01 – Question307

A global company has an application running on Amazon EC2 instances that serves image files from Amazon S3. User requests from the browser are causing high traffic, which results in degraded performance.
Which optimization solution should a developer implement to increase application performance?

A.
Create multiple prefixes in the S3 bucket to increase the request rate.
B. Create an Amazon ElastiCache cluster to cache and serve frequently accessed items.
C. Use Amazon CloudFront to serve the content of images stored in Amazon S3.
D. Submit a ticket to AWS Support to request a rate limit increase for the S3 bucket.

Correct Answer: C

AWS Certified Developer Associate DVA-C01 – Question306

An application running on Amazon EC2 opens connections to an Amazon RDS SQL Server database. The developer does not want to store the user name and password for the database in the code. The developer would also like to automatically rotate the credentials.
What is the MOST secure way to store and access the database credentials?

A.
Create an IAM role that has permissions to access the database. Attach the role to the EC2 instance.
B. Use AWS Secrets Manager to store the credentials. Retrieve the credentials from Secrets Manager as needed.
C. Store the credentials in an encrypted text file in an Amazon S3 bucket. Configure the EC2 instance’s user data to download the credentials from Amazon S3 as the instance boots.
D. Store the user name and password credentials directly in the source code. No further action is needed because the source code is stored in a private repository.

AWS Certified Developer Associate DVA-C01 – Question305

An ecommerce startup is preparing for an annual sales event. As the traffic to the company’s application increases, the development team wants to be notified when the Amazon EC2 instance’s CPU utilization exceeds 80%.
Which solution will meet this requirement?

A.
Create a custom Amazon CloudWatch alarm that sends a notification to an Amazon SNS topic when the CPU utilization exceeds 80%.
B. Create a custom AWS Cloud Trail alarm that sends a notification to an Amazon SNS topic when the CPU utilization exceeds 80%.
C. Create a cron job on the EC2 instance that executes the –describe-instance-information command on the host instance every 15 minutes and sends the results to an Amazon SNS topic.
D. Create an AWS Lambda function that queries the AWS CloudTrail logs for the CPUUtilization metric every 15 minutes and sends a notification to an Amazon SNS topic when the CPU utilization exceeds 80%.

Correct Answer: A

AWS Certified Developer Associate DVA-C01 – Question304

A developer wants to send multi-value headers to an AWS Lambda function that is registered as a target with an Application Load Balancer (ALB).
What should the developer do to achieve this?

A.
Place the Lambda function and target group in the same account.
B. Send the request body to the Lambda function with a size less than 1 MB.
C. Include the Base64 encoding status, status code, status description, and headers in the Lambda function.
D. Enable the multi-value headers on the ALB.

AWS Certified Developer Associate DVA-C01 – Question303

A developer is writing a web application that must share secure documents with end users. The documents are stored in a private Amazon S3 bucket. The application must allow only authenticated users to download specific documents when requested, and only for a duration of 15 minutes.
How can the developer meet these requirements?

A.
Copy the documents to a separate S3 bucket that has a lifecycle policy for deletion after 15 minutes.
B. Create a presigned S3 URL using the AWS SDK with an expiration time of 15 minutes.
C. Use server-side encryption with AWS KMS managed keys (SSE-KMS) and download the documents using HTTPS.
D. Modify the S3 bucket policy to only allow specific users to download the documents. Revert the change after 15 minutes.

AWS Certified Developer Associate DVA-C01 – Question302

A developer is updating an application deployed on AWS Elastic Beanstalk. The new version is incompatible with the old version. To successfully deploy the update, a full cutover to the new, updated version must be performed on all instances at one time, with the ability to roll back changes in case of a deployment failure in the new version.
How can this be performed with the LEAST amount of downtime?

A.
Use the Elastic Beanstalk All at once deployment policy to update all instances simultaneously.
B. Perform an Elastic Beanstalk Rolling with additional batch deployment.
C. Deploy the new version in a new Elastic Beanstalk environment and swap environment URLs.
D. Perform an Elastic Beanstalk Rolling deployment.

Correct Answer: D

Explanation:

Explanation: Elastic Beanstalk has rolled out a couple of features over the last year that make zero-downtime deployment. Reference: https://rollout.io/blog/batch-deployment-in-aws-elastic-beanstalk/

AWS Certified Developer Associate DVA-C01 – Question301

A developer receives the following error message when trying to launch or terminate an Amazon EC2 instance using a boto3 script.

What should the developer do to correct this error message?

A.
Assign an IAM role to the EC2 instance to allow necessary API calls on behalf of the client.
B. Implement an exponential backoff algorithm for optimizing the number of API requests made to Amazon EC2.
C. Increase the overall network bandwidth to handle higher API request rates.
D. Upgrade to the latest AWS CLI version so that boto3 can handle higher request rates.

Correct Answer: B

Explanation: