A company is deploying a distributed in-memory database on a fleet of Amazon EC2
instances. The fleet consists of a primary node and eight worker nodes. The primary node
is responsible for monitoring cluster health, accepting user requests, distributing user
requests to worker nodes, and sending an aggregate response back to a client. Worker
nodes communicate with each other to replicate data partitions.
The company requires the lowest possible networking latency to achieve maximum
performance.
Which solution will meet these requirements?
Show answerHide answer
Correct answer: CLaunch memory optimized EC2 instances in a cluster placement group
Question 102Choose 3
A company needs to aggregate Amazon CloudWatch logs from its AWS accounts into one
central logging account. The collected logs must remain in the AWS Region of
creation. The central logging account will then process the logs, normalize the logs into
standard output format, and stream the output logs to a security tool for more processing.
A solutions architect must design a solution that can handle a large volume of logging data
that needs to be ingested. Less logging will occur outside normal business hours than
during normal business hours. The logging solution must scale with the anticipated load.
The solutions architect has decided to use an AWS Control Tower design to handle the
multi-account logging process.
Which combination of steps should the solutions architect take to meet the requirements?
(Select THREE.)
Show answerHide answer
Correct answer: A, C, ECreate a destination Amazon Kinesis data stream in the central logging account.Create an IAM role that grants Amazon CloudWatch Logs the permission to add data to
the Amazon Kinesis data stream. Create a trust policy. Specify the trust policy in the IAM
role. In each member account, create a subscription filter for each log group to send data to
the Kinesis data stream.Create an AWS Lambda function. Program the Lambda function to normalize the logs in
the central logging account and to write the logs to the security tool.
Question 103Choose 1
A financial services company has an asset management product that thousands of
customers use around the world. The customers provide feedback about the product
through surveys. The company is building a new analytical solution that runs on Amazon
EMR to analyze the data from these surveys. The following user personas need to access
the analytical solution to perform different actions:
• Administrator: Provisions the EMR cluster for the analytics team based on the team's
requirements
• Data engineer: Runs E TL scripts to process, transform, and enrich the datasets
• Data analyst: Runs SQL and Hive queries on the data
A solutions architect must ensure that all the user personas have least privilege access to
only the resources that they need. The user personas must be able to launch only
applications that are approved and authorized. The solution also must ensure tagging for
all resources that the user personas create.
Which solution will meet these requirements?
Show answerHide answer
Correct answer: CUse AWS Service Catalog to control the Amazon EMR versions available for
deployment, the cluster configuration, and the permissions for each user persona.
Question 104Choose 1
A company is running a serverless ecommerce application on AWS. The application uses
Amazon API Gateway to invoke AWS Lambda Java functions. The Lambda functions
connect to an Amazon RDS for MySQL database to store data.
During a recent sale event, a sudden increase in web traffic resulted in poor API
performance and database connection failures. The company needs to implement a
solution to minimize the latency for the Lambda functions and to support bursts in traffic.
Which solution will meet these requirements with the LEAST amount of change to the
application?
Show answerHide answer
Correct answer: BCreate an RDS Proxy endpoint for the database. Store database secrets in AWS
Secrets Manager. Set up the required 1AM permissions. Update the Lambda functions to
connect to the RDS Proxy endpoint. Increase the provisioned concurrency for the Lambda
functions.
Question 105Choose 1
A company runs an unauthenticated static website (www.example.com) that includes a
registration form for users. The website uses Amazon S3 for hosting and uses Amazon
CloudFront as the content delivery network with AWS WAF configured. When the
registration form is submitted, the website calls an Amazon API Gateway API endpoint that
invokes an AWS Lambda function to process the payload and forward the payload to an
external API call.
During testing, a solutions architect encounters a cross-origin resource sharing (CORS)
error. The solutions architect confirms that the CloudFront distribution origin has the
Access-Control-Allow-Origin header set to www.example.com.
What should the solutions architect do to resolve the error?
Show answerHide answer
Correct answer: CEnable the CORS setting on the API Gateway API endpoint. Ensure that the API
endpoint is configured to return all responses that have the Access-Control -Allow-Origin
header set to www.example.com.
Explanation
Explanation:
CORS errors occur when a web page hosted on one domain tries to make a request to a
server hosted on another domain. In this scenario, the registration form hosted on the static website is trying to make a request to the API Gateway API endpoint hosted on a different
domain, which is causing the error. To resolve this error, the Access-Control-Allow-Origin
header needs to be set to the domain from which the request is being made. In this case,
the header is already set to www.example.com on the CloudFront distribution origin.
Therefore, the solutions architect should enable the CORS setting on the API Gateway API
endpoint and ensure that the API endpoint is configured to return all responses that have
the Access-Control-Allow-Origin header set to www.example.com. This will allow the API
endpoint to respond to requests from the static website without a CORS error.
Question 106Choose 1
A company uses an organization in AWS Organizations to manage the company's AWS
accounts. The company uses AWS CloudFormation to deploy all infrastructure. A finance
team wants to buikJ a chargeback model The finance team asked each business unit to tag
resources by using a predefined list of project values.
When the finance team used the AWS Cost and Usage Report in AWS Cost Explorer and
filtered based on project, the team noticed noncompliant project values. The company
wants to enforce the use of project tags for new resources.
Which solution will meet these requirements with the LEAST effort?
Show answerHide answer
Correct answer: ACreate a tag policy that contains the allowed project tag values in the organization's
management account. Create an SCP that denies the cloudformation:CreateStack API
operation unless a project tag is added. Attach the SCP to each OU.
Explanation
Explanation:
The best solution is to create a tag policy that contains the allowed project tag values in the
organization’s management account and create an SCP that denies the
cloudformation:CreateStack API operation unless a project tag is added. A tag policy is a type of policy that can help standardize tags across resources in the organization’s
accounts. A tag policy can specify the allowed tag keys, values, and case treatment for
compliance. A service control policy (SCP) is a type of policy that can restrict the actions
that users and roles can perform in the organization’s accounts. An SCP can deny access
to specific API operations unless certain conditions are met, such as having a specific tag.
By creating a tag policy in the management account and attaching it to each OU, the
organization can enforce consistent tagging across all accounts. By creating an SCP that
denies the cloudformation:CreateStack API operation unless a project tag is added, the
organization can prevent users from creating new resources without proper tagging. This
solution will meet the requirements with the least effort, as it does not involve creating
additional resources or modifying existing ones. References: Tag policies - AWS
Organizations, Service control policies - AWS Organizations, AWS CloudFormation User
Guide
Question 107Choose 1
A company is rearchitecting its applications to run on AWS. The company's infrastructure
includes multiple Amazon EC2 instances. The company's development team needs
different levels of access. The company wants to implement a policy that requires all
Windows EC2 instances to be joined to an Active Directory domain on AWS. The company
also wants to Implement enhanced security processes such as multi-factor authentication
(MFA). The company wants to use managed AWS services wherever possible.
Which solution will meet these requirements?
Show answerHide answer
Correct answer: ACreate an AWS Directory Service for Microsoft Active Directory implementation. Launch
an Amazon Workspace. Connect to and use the Workspace for domain security
configuration tasks.
Explanation
Explanation:
A is the correct answer because it uses AWS Directory Service for Microsoft Active
Directory to join the Windows EC2 instances to an Active Directory domain on AWS and enable MFA. AWS Directory Service for Microsoft Active Directory, also known as AWS
Managed Microsoft AD, is a fully managed service that is powered by Windows Server
2019. It allows you to run directory-aware workloads in the AWS Cloud, including Microsoft
SharePoint and custom .NET and SQL Server-based applications. You can also configure
a trust relationship between AWS Managed Microsoft AD in the AWS Cloud and your
existing on-premises Microsoft Active Directory. AWS Managed Microsoft AD supports
MFA by integrating with your existing RADIUS-based MFA infrastructure. To join the
Windows EC2 instances to an Active Directory domain on AWS, you can use an Amazon
Workspace, which is a fully managed, secure desktop computing service that runs on
AWS. You can connect to and use the Workspace for domain security configuration tasks.
Question 108Choose 1
A company runs many workloads on AWS and uses AWS Organizations to manage its
accounts. The workloads are hosted on Amazon EC2. AWS Fargate. and AWS Lambda.
Some of the workloads have unpredictable demand. Accounts record high usage in some
months and low usage in other months.
The company wants to optimize its compute costs over the next 3 years A solutions
architect obtains a 6-month average for each of the accounts across the organization to
calculate usage.
Which solution will provide the MOST cost savings for all the organization's compute
usage?
Show answerHide answer
Correct answer: BPurchase a Compute Savings Plan for the organization from the management account
by using the recommendation at the management account level
Question 109Choose 1
A company is using Amazon API Gateway to deploy a private REST API that will provide
access to sensitive data. The API must be accessible only from an application that is
deployed in a VPC. The company deploys the API successfully. However, the API is not
accessible from an Amazon EC2 instance that is deployed in the VPC.
Which solution will provide connectivity between the EC2 instance and the API?
Show answerHide answer
Correct answer: BCreate an interface VPC endpoint for API Gateway. Attach an endpoint policy that
allows the execute-api:lnvoke action. Enable private DNS naming for the VPC endpoint.
Configure an API resource policy that allows access from the VPC endpoint. Use the API
endpoint's DNS names to access the API. Most Voted
Question 110Choose 1
A company needs to improve the reliability ticketing application. The application runs on an
Amazon Elastic Container Service (Amazon ECS) cluster. The company uses Amazon
CloudFront to servo the application. A single ECS service of the ECS cluster is the
CloudFront distribution's origin.
The application allows only a specific number of active users to enter a ticket purchasing
flow. These users are identified by an encrypted attribute in their JSON Web Token (JWT).
All other users are redirected to a waiting room module until there is available capacity for
purchasing.
The application is experiencing high loads. The waiting room modulo is working as
designed, but load on the waiting room is disrupting the application's availability. This
disruption is negatively affecting the application's ticket sale Transactions.
Which solution will provide the MOST reliability for ticket sale transactions during periods of
high load? '
Show answerHide answer
Correct answer: CCreate a separate service in the ECS cluster for the waiting room. Use a separate
scaling configuration. Create a CloudFront function That inspects the JWT information and
appropriately forwards requests to the ticketing service or the waiting room service
Explanation
Explanation:
Implementing a CloudFront function that inspects the JWT information and appropriately
forwards requests either to the ticketing service or the waiting room service within the
Amazon ECS cluster enhances reliability during high load periods. This solution segregates
the load between the main application and the waiting room, ensuring that the ticketing service remains unaffected by the high load on the waiting room. Using CloudFront
functions for request routing based on JWT attributes allows for efficient distribution of user
traffic, thereby maintaining the application's availability and performance during peak times.
Full mock exam
Sit the SAP-C02 exam before exam day
Full-length mocks with the same number of questions and the same time limit as the real SAP-C02 exam. Every attempt draws a new set of questions from the full bank, so you can keep going until you pass comfortably.