Writing Your Own AWS CDK Constructs in Python
Version 1 of the AWS Cloud Development Kit (AWS CDK) is now in maintenance mode.
Refer to the AWS Cloud Development Kit (AWS CDK) v2 Learning Path for updated CDK v2 Labs and Challenges.
Description
The AWS CDK construct library contains classes that shape the AWS resources in your stack and come with proper defaults that allow you to focus on developing your application without worrying too much about resource details. This is useful for developing prototypes or smaller applications quickly and establishing a proof-of-concept, but what happens when the application or your development team grows?
Writing your own custom CDK constructs provides the following benefits:
- Establish organization standards to follow best practices
- Ensure AWS resource conventions continue to be adhered to as your application or team grows
- Reduce the amount of code developers need to write by extracting repetitive sections
In this lab, you will refactor an existing CDK application by creating your own custom S3 construct. The process of writing your own custom constructs outlined in this lab can be applied to your own projects and development teams to fit your specific needs.
Learning Objectives
Upon completion of this intermediate-level lab, you will be able to:
- Write a custom S3 Bucket construct with the AWS CDK
- Refactor a CDK application to implement custom CDK constructs that you create
Intended Audience
- Cloud Architects
- DevOps Engineers
- Software Engineers
Prerequisites
Familiarity with the following will be beneficial:
- AWS Cloud Development Kit
- Python Programming
The following courses and labs can be used to fulfill the prerequisite: