AWS CDK Basics

SaurabhG
2 min readOct 18, 2021

--

AWS Cloud Development Kit (AWS CDK) is an open-source software development framework for defining cloud infrastructure as code. Using AWS CloudFormation, AWS CDK then provisions the cloud infrastructure resources with the help of command line tools.

What does AWS CDK do?

Compiling your source code into an assembly language is a common code-development process. Think of AWS CDK as a compiler that compiles your source code into an AWS CloudFormation template.

Core framework of AWS CDK.

Three basic components make up the core framework of an AWS CDK project.

Constructs : Constructs are the basic building blocks of AWS CDK apps. A construct represents a cloud component and encapsulates everything that AWS CloudFormation needs to create the component. A construct can represent a single cloud resource (such as an AWS Lambda function), or it can represent a higher-level component consisting of multiple AWS CDK resources.

AWS CDK includes the AWS Construct Library, which contains constructs representing Amazon Web Services (AWS) resources. This library includes constructs that represent all the resources available on AWS.

For more information, see “Constructs” in the AWS Cloud Development Kit Developer Guide.

Stacks : Stacks are a unit of deployment in AWS CDK. All AWS resources defined within the scope of a stack, directly or indirectly, are provisioned as a single unit. Because AWS CDK stacks are implemented through AWS CloudFormation stacks, they have the same limitations. You can define any number of stacks in an AWS CDK app.

For more information, see “Stacks” in the AWS Cloud Development Kit Developer Guide.

For more information about AWS CloudFormation limits and restrictions, see limits and restrictions in the AWS CloudFormation FAQs.

Apps : CDK application is an app, and is represented by the AWS CDK App class. To provision infrastructure resources, all constructs that represent AWS resources must be defined, directly or indirectly, within the scope of a stack construct.

For more information, see “Apps” in the AWS Cloud Development Kit Developer Guide.

--

--

SaurabhG
SaurabhG

Written by SaurabhG

I am an enthusiastic learner. Always want to challenge my last learning & keep hunting for new learning. about.me/saurabh.gangrade

No responses yet