AWS Certified Developer Associate DVA-C01 – Question366

A development team set up a pipeline to launch a test environment. The developers want to automate tests for their application. The team created an AWS CodePipeline stage to deploy the application to a test environment in batches using AWS Elastic Beanstalk. A later CodePipeline stage contains a single action that uses AWS CodeBuild to run numerous automated Selenium-based tests on the deployed application. The team must speed up the pipeline without removing any of the individual tests.
Which set of actions will MOST effectively speed up application deployment and testing?

A.
Set up an all-at-once deployment in Elastic Beanstalk. Run tests in parallel with multiple CodeBuild actions.
B. Set up a rolling update in Elastic Beanstalk. Run tests in serial with a single CodeBuild action.
C. Set up an immutable update in Elastic Beanstalk. Run tests in serial with a single CodeBuild action.
D. Set up a traffic-splitting deployment in Elastic Beanstalk. Run tests in parallel with multiple CodeBuild actions.

Correct Answer: A

AWS Certified Developer Associate DVA-C01 – Question365

A developer is using Amazon CodeGuru Profiler. The developer has configured the application with the CodeGuru Profiler agent. However, when the application runs, the developer notices that a significant number of events are missing from the generated profile.
How can the developer reduce the number of missed events in the profile?

A.
Set a lower value for the SamplingIntervalInMilliseconds property.
B. Set a lower value for the ReportingIntervalInMilliseconds property.
C. Set a higher value for the SamplingIntervalInMilliseconds property.
D. Set a higher value for the ReportingIntervalInMilliseconds property.

Correct Answer: A

AWS Certified Developer Associate DVA-C01 – Question364

A developer is preparing a containerized application for deployment to AWS Lambda. The developer wants to build and optimize the container images to reduce duplicate work and improve build, deploy, and update times.
Which combination of steps should the developer take to meet these requirements? (Choose two.)

A.
Use an AWS provided base image.
B. Use the smallest compatible third-party base image.
C. Build frequently changing layers in the imago first, followed by stable layers.
D. Store images for functions with large layers in the same Amazon Elastic Container Registry (Amazon ECR) repository.
E. Maximize the number of layers in the built image.

Correct Answer: AD

AWS Certified Developer Associate DVA-C01 – Question363

A media company wants to test its web application more frequently. The company deploys the application by using a separate AWS CloudFormation stack for each environment. The same CloudFormation template is deployed to each stack as the application progresses through the development lifecycle.
A developer needs to build an automated alert for the quality assurance (QA) team. The developer wants the alert to occur for new deployments in the final pre-production environment.
Which solution will moot these requirements?

A.
Create an Amazon Simple Notification Service (Amazon SNS) topic. Add a subscription to notify the QA team. Update the CloudFormation stack options to point to the SNS topic in the pro-production environment.
B. Create an AWS Lambda function that notifies the QA team. Create an Amazon EventBridge rule to invoke the Lambda function on the default event bus. Filter the events on the CloudFormation service and the CloudFormation stack Amazon Resource Name (ARM).
C. Create an Amazon CloudWatch alarm that monitors the metrics from CloudFormation. Filter the metrics on the stack name and the stack status. Configure the alarm to notify the QA team.
D. Create an AWS Lambda function that notifies the QA team. Configure the event source mapping to receive events from CloudFormation. Specify the filtering values to limit invocations to the desired CloudFormation stack.

Correct Answer: B

AWS Certified Developer Associate DVA-C01 – Question362

A company has an ecommerce application. To track product reviews, the company's development team uses an Amazon DynamoDB table.
Every record includes the following:
* A Review ID, a 16-digit universally unique identifier (UUID)
* A Product ID and User ID, 16-digit UUIDs that reference other tables
* A Product Rating on a scale of 1-5
* An optional comment from the user
The table partition key is the Review ID. The most performed query against the table is to find the 10 reviews with the highest rating for a given product.
Which index will provide the FASTEST response for this query?

A.
A global secondary index (GSI) with Product ID as the partition key and Product Rating as the sort key
B. A global secondary index (GSI) with Product ID as the partition key and Review ID as the sort key
C. A local secondary index (LSI) with Product ID as the partition key and Product Rating as the sort key
D. A local secondary index (LSI) with Review ID as the partition key and Product ID as the sort key

Correct Answer: B

AWS Certified Developer Associate DVA-C01 – Question361

A social media application uses the AWS SDK for JavaScript on the frontend to get user credentials from AWS Security Token Service (AWS STS). The application stores its assets in an Amazon S3 bucket. The application serves its content by using an Amazon CloudFront distribution with the origin sot to the S3 bucket.
The credentials for the role that the application assumes to make the SDK calls are stored in plaintext in a JSON file within the application code. The developer needs to implement a solution that will allow the application to get user credentials without having any credentials hardcoded in the application code.
Which solution will meet these requirements?

A.
Add a Lambda@Edge function to the distribution. Invoke the function on viewer request. Add permissions to the function's execution role to allow the function to access AWS STS. Move all SDK calls from the frontend into the function.
B. Add a CloudFront function to the distribution. Invoke the function on viewer request. Add permissions to the function's execution role to allow the function to access AWS STS. Move all SDK calls from the frontend into the function.
C. Add a Lambda@Edge function to the distribution. Invoke the function on viewer request. Move the credentials from the JSON file into the function. Move all SDK calls from the frontend into the function.
D. Add a CloudFront function to the distribution. Invoke the function on viewer request. Move the credentials from the JSON file into the function. Move all SDK calls from the frontend into the function.

Correct Answer: B

AWS Certified Developer Associate DVA-C01 – Question359

A calendar application gives users the ability to schedule and share events. The application stores its data in several Amazon DynamoDB tables. The Events table stores all events for the application. The Events table has a primary key in which the partition key is the date of the event and the sort key is the user's unique ID number.
A developer is working on a dashboard that will show each user all the details for all their events scheduled on a single day. The developer needs to get the data from the Events table.
What should the developer do to get the relevant data MOST efficiently?

A.
Perform a scan on the Events table by using the partition key and the sort key as filter expressions.
B. Perform a query on the Events table by using the partition key and the sort key as filter expressions.
C. Perform a scan on the Events table by using the partition key and the sort key in a key condition expression.
D. Perform a query on the Events table by using the partition key and the sort key in a key condition expression.

Correct Answer: D

AWS Certified Developer Associate DVA-C01 – Question358

A developer has created an AWS Lambda function that interacts with an Amazon Aurora MySQL database.
The Lambda function makes queries to the database. After a performance test for the Lambda function, the database starts to show an error for too many connections.
Which solution will solve this problem with the LEAST operational effort?

A.
Create a road replica for the database. Query the replica database instead of the primary database.
B. Migrate the data to an Amazon DynamoDB database.
C. Sot a limit to the Lambda function's concurrency.
D. Create a proxy in Amazon RDS Proxy. Query the proxy instead of the database.

Correct Answer: C

AWS Certified Developer Associate DVA-C01 – Question357

A company is running its application on the most recent generation of hare metal Amazon EC2 instances. A developer is adding a low-latency computation feature to the application. The feature depends on highly sensitive personally identifiable information (PII). When computation occurs on unencrypted data, the feature needs to run in an isolated environment that provides CPU and memory isolation.
Which solution will meet these requirements?

A.
Build and deploy the feature on the original EC2 instance store.
B. Add the now feature in the original application. Deploy the application on a Dedicated Host.
C. Package the now feature and deploy the now feature on AWS Lambda. Use AWS Key Management Service (AWS KMS) to encrypt and decrypt the PII.
D. Build and deploy the now feature as part of the original application. Run the feature on AWS Nitro Enclaves.

Correct Answer: D