AWS Builder Center

What I Learned Using AWS CDK with TypeScript

A personal look at how using AWS CDK with TypeScript helped me understand Infrastructure as Code and made cloud development feel more approachable as a software engineer.

I first got hands-on experience with AWS CDK while working as an apprentice software engineer at Tripadvisor. At the time, I was already comfortable with TypeScript, so being able to use it for infrastructure made AWS feel a lot less intimidating.
Before that, I mostly thought of cloud infrastructure as something separate from the code developers worked on every day. Using CDK changed that for me.

Infrastructure as Code Clicked for Me

One of the things I liked most about CDK was that I could work with infrastructure using TypeScript instead of spending all my time inside large YAML or JSON files.
I could use things I was already familiar with, like variables, functions, classes, and type checking. Because of that, the infrastructure code felt much more like normal software development.
That made Infrastructure as Code easier for me to understand.

Small Changes Can Affect a Lot

At Tripadvisor, I worked with CDK stacks related to monitoring, scaffolding, and internal migration tools.
One thing I learned pretty quickly was that even a small infrastructure change can have a much bigger impact than you might expect. Changing a dependency or configuration isn't just changing a few lines of code. It can change what actually gets deployed into an AWS environment.
That made me much more careful about reviewing changes and understanding what CDK was generating before deploying anything.

Reusable Constructs Are Really Useful

Another thing I liked about CDK was the idea of constructs.
Instead of every developer creating the same infrastructure setup from scratch, you can create reusable building blocks and use them across different projects.
I could see why this was especially useful at a larger company. If teams already have tested and approved infrastructure patterns, developers can reuse them instead of reinventing everything every time they start a new service.

It Helped Bridge the Gap Between Development and Cloud

My background is mostly in software engineering, so CDK was a nice introduction to the infrastructure side of things.
Using TypeScript made concepts like provisioning resources, configuring environments, monitoring, and deployments feel more approachable because I could connect them back to skills I already had.
It also made me realize that software engineers can have a lot more ownership over infrastructure than I originally thought.

What I Want to Learn Next

I still have a lot more I want to learn about AWS.
A few areas I'm especially interested in are:
  • VPCs, subnets, and networking
  • IAM and AWS security
  • Designing highly available systems
  • Serverless applications with Lambda
  • CI/CD for CDK projects
  • Monitoring and cost optimization
I'm also continuing to work on my AWS knowledge and learn more about cloud architecture.
Overall, using AWS CDK was probably one of the things that made cloud development finally start to click for me. Being able to use TypeScript made Infrastructure as Code feel much less foreign, and it gave me a better understanding of what actually goes into deploying and running software in the cloud.
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article