Off-by-none: Issue #77

February 18, 2020

Monoliths versus Microservices…

Welcome to Issue #77 of Off-by-none. Thanks for joining us! 🙌

Last week, we looked at the new Serverless Lens for the Well-Architected Framework Tool. This week, we have a few posts that explore the pros and cons of microservices versus monoliths, plus plenty of excellent content from the community.

Serverless Stories 📖

Modern monitoring for microservice & serverless architectures
Understand Lambda & container-based applications in a truly unified platform. Epsagon’s automated, end-to-end tracing enables full visibility into your production in minutes without needing to install an agent. Try free today. Sponsored

Migrating to a serverless contact management backend
This is a great post from Emily Shea that perfectly captures how serverless can allow you to build something quickly, prove its value, and then enhance it as your feature requirements grow. The first version of her architecture shows a heavy reliance on SendGrid to handle the undifferentiated processes of contact management and email delivery. But as more features are needed, the architecture evolves to support functionality that can provide unique business value to her app. There are a lot of really good lessons to be learned from her overall approach.

Why the ‘WHY’ matters more than the ‘WHAT’ in Serverless!
Sheen Brisals is getting tired of endless serverless definitions, and instead wants to focus more on “why” we should be building applications with it.

Serverless and the RDS Data API: A journey to deployment
Chris Buonocore recounts his team’s all-too-familiar story of spiking database connections with Lambda functions connecting to RDS. They migrated to the RDS Data API and learned some lessons along the way.

Serverless Use Cases 🗺

Building a static serverless website using S3 and CloudFront
Sometimes it’s those little nuances that really get you. Sander Knape points out a very important factor to consider when hosting static sites with S3 and CloudFront.

Using AWS Lambda to Create a MongoDB Connection Proxy
Interesting approach here by the team at Webiny. The DB connection / FaaS concurrency issue is a real problem, but introducing another layer of Lambda functions seems like more overhead than it’s worth. I’d suggest using the same approach as serverless-mysql and managing connections using db.serverStatus().connections to get the current usage.

Saga Patterns inside Step Functions world
The team at Chaos Gears points out some standard practices for implementing Saga patterns with Step Functions. Interesting subtext in here about using Step Functions for communicating across distributed components/microservices, a topic I recently debated with Yan Cui.

Introducing Multi-Region Asynchronous Object Replication Solution
If you need to replicate S3 objects to different regions automatically, this new AWS Solution gives you everything you need to make it happen.

Serverless Concepts 🏗

Serverless Framework: Warming up AWS Lambda to avoid “cold start”
I appreciate the content from Michele Riso, but as someone who has written the Lambda Warmer package, I can tell you that the pitfalls of this approach are grave. AWS now has an official solution to this problem with Provisioned Concurrency (so does Azure). So, if you really need to reduce cold starts (which in many cases you don’t), then take a look at some better, non-blocking solutions.

Tagging Traces in Distributed Applications
Monitoring distributed applications is hard. So any time there are features that give you the ability to both trace transactions, and classify them with tags to make it easier to investigate issues, I’m going to be a fan.

7 ways to do async message processing in AWS
Paul Swail has a great article that shows you seven different ways to send messages asynchronously between Lambda functions when building serverless applications. Lots of these are standard ways, but as he mentions at the end, you should consider using Step Functions if you have complex workflows that require lots of guarantees and rollbacks.

DynamoDB Transactions: Use Cases and Examples
Everything you’ve ever wanted to know about DynamoDB Transactions (and even some things you probably didn’t 😉). Alex DeBrie has another excellent in depth post that will show you how transactions work, when you should use them, and when you should be aware of their performance impact.

Amazon Builders’ Library in focus #7: Going faster with continuous delivery
In the seventh installment of Amazon Builders’ Library in focus series, Mike Roberts of Symphonia picks out the key insights from the article Going faster with Continuous Delivery by Mark Mansour. This is an excellent analysis with lots of lessons for teams looking to build and release quality software faster.

Enhancing Distributed Tracing with Business Context
As with Epsagon’s tagging features, Thundra provides a similar functionality. Great stuff for understanding your distributed workloads.

Building a serverless URL shortener app without AWS Lambda
Brilliant series of posts by Eric Johnson. I can almost guarantee that the built-in features of the cloud are much more secure, resilient, and reliable than any Lambda code you or I could write. This doesn’t mean we never need Lambda, but if you can evolve certain apps to reduce its synchronous usage, there are a lot of performance gains to be had.

Where do you store secrets for AWS Serverless apps?!?
George Mao breaks down the Ease of Use, Level of Security, and Cost associated with the different approaches to secrets storage on AWS.

The Serverless Chats Podcast
Geek out on everything serverless! Each week, Jeremy Daly, serverless advocate, AWS Serverless Hero, and Off-by-none founder, chats with another serverless champion to explore and do a deep-dive into specific topics in the serverless space. Sponsored

Serverless Tutorials 👷‍♀️

Painless AWS Chalice Application Debug
If you’re building your serverless applications with AWS Chalice, this post from Alex Gelman will show you how you can speed up your workflow and debug your applications locally.

Promotion Pipelines
As I’ve said before, I really like what the Serverless Framework Pro is doing with CI/CD. In this post, Gareth McCumskey shows you how to “kind of” build promotion pipelines using a Gitflow strategy. I’m still waiting for actual promotion pipelines that reuse immutable artifacts, but I realize that it’s a more difficult problem to solve.

Ensuring Usernames are Unique in Your AWS Amplify App
This seems like a really roundabout way to do username checks with AWS Amplify, but as of this writing, nobody has challenged it yet.

Building a Serverless JAMstack ECommerce Store with Gatsby & AWS Amplify
Nader Dabit walks you through the building blocks needed to build a completely serverless, JAMstack ecommerce store using a static site generator and AWS Amplify.

Create PDF using PdfKit on Serverless AWS Lambda with Layer
Crespo Wang shows you how to package PdfKit into a Lambda Layer and then use it to manipulate PDFs with your Lambda functions.

Serverless Security 🔒

Keeping your Lambda functions safe with Joi
I really like what Tal Bereznitskey has done here to validate events being passed into Lambda functions. Event injection is a real thing, so having a standard way to sanitize those events can really up your security posture.

Serverless Reads 🤓

What’s next for serverless architecture?
This is an excellent article by Brecht De Rooms that lays out the evolution of cloud computing and how eventually the edge will be the source of both compute and dynamic data. For those of you that are still holding on to the idea of monoliths, this is a good read for you. If edge is in fact the future of distributed applications, then the monolith is not going to hold up.

How Serverless Impacts Design: Gojko Adzic at DDD Europe
It’s always great to hear Gojko Adzic’s perspective on serverless. This article is a nice recap of his talk at DDD Europe and links to his slides as well.

How to avoid turning microservices into distributed spaghetti code
Interesting post by Matt Asay. There has been a lot of talk lately about the value of monoliths versus microservices, particularly around the notion that most “microservices” are ending up as just distributed monoliths. This is likely an education and organization problem, but if you build a tightly coupled network of services, you’re going to feel the pain of that very quickly.

Comparing Serverless and Containers: Which is Best?
“Containers are a more secure technology that can help support long-term cloud infrastructure.” If you feel like reading another Containers vs. Serverless post that’ll make you want to bang your head against a wall, please click here.

Ask the Expert: Serverless: Public cloud’s second wave
Great post by Tim Wagner about the architectural shifts in cloud computing and how serverless is clearly becoming the new norm for developing cloud-based applications. He touches on some of the main pain points that have slowed serverless adoption, but also points out the hybrid approach taken by services like Fargate and Cloud Run that help with the inevitable transition.

The Serverless Supremacy
I’m glad Sven Al Hamad had the time to write this post, because I’m very much so in agreement with him. It wouldn’t be another day on the Internet without DHH defending his approach to application architecture. I’ve been doing this for a very long time, and I’ve never seen anything as promising as serverless and (properly designed) microservice architectures. Nothing is a panacea, and that most definitely includes Ruby on Rails and its monolithic approach.

For the A/V enthusiast… 🍿

Episode #36: The Cloud Database Landscape with Suphatra Rufo
In this episode, I chat with Suphatra Rufo about how enterprises are migrating data to the cloud, why the cloud database market is shifting to NoSQL, and the hybrid database strategy that companies need to adopt.

Choosing the right Infrastructure as Code framework – between CloudFormation, SAM, CDK and Amplify
Marcia Villalba shares a brief description of CloudFormation, AWS SAM, AWS CDK, and AWS Amplify, and then shows you when and where you should use each of them.

New from AWS 🆕

Configure fine-grained data access with Amazon Elasticsearch Service
Until there is a serverless Elasticsearch service, we are still required to provision our own managed ES clusters. Setting up a new cluster for each service is expensive and a major pain, so giving us more control over who can access what in a shared environment is a very cool feature.

Amazon MSK increases the default broker limit per cluster to 30 brokers
If you are using Amazon Managed Streaming for Apache Kafka for your workloads and you need 30 brokers, good for you! That is some serious throughput.

Amazon Cognito User Pools service now supports case insensitivity for user aliases
Hmm, I wonder if this helps solve the Amplify unique username issue from the post we mentioned earlier?

AWS CloudFormation StackSets introduces automatic deployments across accounts and regions through AWS Organizations
I really like what AWS is doing with StackSets, so having additional automation built in is a nice improvement.

Amazon Rekognition now detects text in videos, and lets you filter results by region, bounding box size and confidence score
I remember when I built a service that used an open source OCR tool to attempt text detection in images. It was pretty terrible, and it took me a very long time to do it. If I had a tool like Rekognition back in the day, who knows what the impact would have been if I had all that extra time to work on things that actually mattered to the business.

You can now restore Amazon DynamoDB table backups as new tables in other AWS Regions
I can see this being a handy feature, especially if you are running multi-region rollups through a single region pipeline.

Serverless Tools 🛠

Essential Open Source Serverless Code Libraries
Erez Berkner points you towards several open source libraries to use with your serverless applications. And thanks for the Lambda API mention.

LearnServerless.dev
Jeremy Thomerson is putting together an online training course to teach you how to build a serverless REST API on AWS. I’m not sure if there is a cost associated with this, but you can sign up for the mailing list to get more info.

DynamoDB Pricing Calculator
Simple web-based tool for forecasting DynamoDB costs.

Make a serverless Express API with OpenJS Architect
Another way to migrate an existing Express API to serverless is now available via Architect’s Express migration middleware.

Thoughts from Twitter 🐦

I’ve been in a cave over the past few months working in silence. I’ve become much more aligned with “why” I started @serverlessgurux. One of the biggest reasons, empowering the community and giving back equally. Based on this, you will find 100% free templates, docs, training videos, deep dive articles, podcast episodes, meetups, webinars and so on all free. ~ Ryan Jones
Ryan has done some great work with serverless, so if you’re interested in checking out all the work he’s contributed, give his site a look.

Upcoming Serverless Events 🗓

There are a lot of upcoming serverless events, webinars, livestreams, and more. If you have an event you’d like me to mention, please email me.

February 20, 2020 – The Complete Guide to Observability (webinar)

February 21, 2020 – ServerlessDays Rome

February 27, 2020 – ServerlessDays Nashville 🗣

March 19, 2020 – ServerlessDays Zürich

March 24, 2020 – ServerlessDays Helsinki 🗣

March 27, 2020 – ServerlessDays Hamburg 🗣

April 6, 2020 – ServerlessDays Boston

April 20, 2020 – ServerlessDays Auckland

April 23, 2020 – ServerlessDays Vienna

April 24, 2020 – ServerlessDays Paris

Serverless Star of the Week ⭐️

There is a very long list of people that are doing #ServerlessGood and contributing to the Serverless community. These people deserve recognition for their efforts. So each week, I will mention someone whose recent contribution really stood out to me. I love meeting new people, so if you know someone who deserves recognition, please let me know.

This week’s star is Ajay Nair (@ajaynairthinks). Ajay is the Director of Product for Lambda at Amazon Web Services, which means he’s your guy for all things AWS Lambda. Ajay’s role is instrumental in driving the serverless product strategy at AWS and he leads a team of amazing individuals that keep propelling the product roadmap forward. Thank you Ajay for your work bringing the serverless features we need to life! 🙌

Final Thoughts 🤔

I spent the end of last week in Wales at the ServerlessDays Cardiff event, and it was a really great showing of serverless enthusiasts and newcomers to the community. The overall community is still relatively small, but seeing so many engaged developers, and listening to others talk about how serverless is having a hugely positive effect on their development processes, makes me think all this nonsense of monolith versus microservices is just a bunch of background noise. If you’ve yet to experience the power of serverless, I can understand your skepticism. But a new world order is coming, and spoiler alert, it’s not going to be monolithic Rails apps running on Heroku. 🤷‍♂️

I hope you enjoyed this issue of Off-by-none. Please send me your feedback and suggestions as they help to make this newsletter better each week. You can reach me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or (perhaps) even how you’d like to contribute to Off-by-none.

Until next time,
Jeremy

Previous Issue

Issue #76February 11, 2020

Next Issue

Issue #78February 25, 2020

Sign up for the Newsletter

Stay up to date on using serverless to build modern applications in the cloud. Get insights from experts, product releases, industry happenings, tutorials and much more, every week!

 

This Week's Sponsor

Check out all of our amazing sponsors and find out how you can help spread the #serverless word by sponsoring an issue.

 

About the Author

Jeremy is the CEO and Founder of Ampt and an AWS Serverless Hero that has a soft spot for helping people solve problems using serverless. He frequently consults with companies and developers transitioning away from the traditional “server-full” approach. You can find him ranting about serverless on Twitter, in several forums and Slack groups, hosting the Serverless Chats podcast, and at conferences around the world.

 

Nominate a Serverless Star

Off-by-none is committed to celebrating the diversity of the serverless community and recognizing the people who make it awesome. If you know of someone doing amazing things with serverless, please nominate them to be a Serverless Star ⭐️!