Our serverless superhero this week is JR Beaudoin, CTO of Theodo and AWS Community Builder. JR pushes the boundaries of what you can do in Lambda. He’s figured out ways to run Blender in a function to render 3D scenes fast, at scale, and in a cost-effective way. JR also regularly gives talks all around the world, spreading serverless knowledge wherever he goes. Thank you, JR, for everything you bring to the community!
I’m always a fan of posts that explain the logical layers of enterprise-grade Lambda functions. Ran Isenberg takes us through his approach to separation of concerns in his learn how to write AWS Lambda functions with architecture layers post. He explains three layers: handler, logic, and data access. In the post he covers the responsibilities of each and how they relate to each other. It’s akin to what Lee Gilmore writes about and has a lot of parallels (which is a good thing).
Speaking of Lee Gilmore, he’s back with part 4 of his series on CDK best practices and patterns. In this article, he describes the different levels of CDK constructs and why you would use one over the other. He also demonstrates how to use Middy to elevate your logs automatically to structured logs (thank goodness!). The article also covers canary deployments and feature flags with App Config. There’s so much in this article, be sure to set aside some time to let it all soak in!
Automations save us time, money, and heartache. Last week, Neetu Mallan wrote about one that she wrote that will save her hours of time every week. She built a Step Function workflow to reset RDS retention periods automatically. She explains each component step by step with a short video and covers all the logical data branches. It’s a great example of the power of Step Functions to perform asynchronous tasks.
The internet has been buzzing about the talk Luc van Donkersgoed gave at AWS Community Day Nordics. He calls it the tao of event-driven architectures. It’s a summary of what PostNL has done to be successful with EDA boiled down into 10 points. These are great points individually but when put together, really summarize the best practices of event-driven applications. Whether you’re considering getting into events for the first time or have been practicing for years - this is a must watch.
We can’t go a week without seeing something new and cool around ChatGPT. Gabriel Koo shared with us how to train ChatGPT with user-generated content and hook it up to a slack bot. The solution uses a Lambda function and S3 to communicate and train with OpenAI. This is a low-lift, easy way to get started with customizing the AI that took the world by storm.
Last week I was thinking about how we see serverless content from two ends of the spectrum: beginner and advanced level. There’s not much in that “intermediate” area. I began to wonder why that was. So I wrote a post with my thoughts on the matter and offer guidance on how to proceed when you’re past beginner stage and not quite an advanced user. Long story short - build what matters.
You can now use Java 17 as a supported runtime in Lambda. This runtime includes a slew of performance improvements and support for Snap Start - making this the fastest runtime yet for Java.
Right along with the Java 17 release, Momento just released v1 of their Java SDK. Now you can have integrated caching built right into your Lambda functions with simple API calls instead of nasty VPC and cluster size configurations.
JavaScript resolvers were added to AppSync a while ago. But as of last week, you can now build them in TypeScript. They’ve also snuck in integrated support for source maps along with this release.
When implementing a serverless service into your architecture, an interesting consideration to make is flow control. This means you must make sure downstream services can handle the throughput of the serverless service. But what if you don’t? Michael Walmsley wrote a fascinating article on what it looks like when you don’t implement flow control in your app. He builds a great story around letting your service get carried away and shows us what observability tools look like when that happens. Knowing how to identify and fix issues like this is crucial before making your way to production.
If you haven’t seen it already, the lambda-perf GitHub page by Maxime David is a work of art. It executes a Lambda function in all available runtimes every day and monitors the cold start times. It then displays them in order of speed on the page. As of last week, it’s even better. Maxime added 3 new memory configurations and arm64 filters to show how configurations affect your cold start times. This is quickly becoming the de facto cold start benchmark page.
Hey serverless friends! I've updated the lambda-perf tool to add the arm64 support as well as 4 different memory size options! You can play with the filters and see how it's impacting cold start! https://t.co/CBUxDWoxw8 #serverless #AWSCommunityBuilder #lambda #performance
— Maxime David (@_maxday) April 25, 2023
I’m back from London! It was a fantastic trip, and I got to meet tons of super smart people. I presented on three different topics while I was there, so stay tuned as the recordings come online.
If you’d like to make a recommendation for the serverless superhero or for an article you found especially useful, send me a message on Twitter, LinkedIn, or email.
Happy Coding!
Allen
Thank you for subscribing!
View past issues.