AWS Certified Developer – Associate (DVA-C02) — Question 265
A developer is building a serverless application that runs on AWS. The developer wants to create an accelerated development workflow that deploys incremental changes to AWS for testing. The developer wants to deploy the incremental changes but does not want to fully deploy the entire application to AWS for every code commit.
What should the developer do to meet these requirements?
Answer options
- A. Use the AWS Serverless Application Model (AWS SAM) to build the application. Use the sam sync command to deploy the incremental changes.
- B. Use the AWS Serverless Application Model (AWS SAM) to build the application. Use the sam init command to deploy the incremental changes.
- C. Use the AWS Cloud Development Kit (AWS CDK) to build the application. Use the cdk synth command to deploy the incremental changes.
- D. Use the AWS Cloud Development Kit (AWS CDK) to build the application. Use the cdk bootstrap command to deploy the incremental changes.
Correct answer: A
Explanation
The sam sync command in the AWS Serverless Application Model (AWS SAM) CLI is specifically designed to accelerate development workflows by syncing local code changes directly to AWS without performing a full CloudFormation stack redeployment. In contrast, sam init is only used to initialize new projects, while AWS CDK's cdk synth compiles code into CloudFormation templates and cdk bootstrap prepares the AWS environment, neither of which performs incremental sync deployments.