Off-by-none: Issue #28

Live from ServerlessDays Boston…

Welcome to Issue #28 of Off-by-none. Thank you so much for being a part of the community! 🙌

Last week we looked at Lyft’s AWS bill and what it means for multi-cloud. This week we’re live at ServerlessDays Boston, plus we’ve got plenty of great stories and content from the community.

Lots of serverless stuff to get to, so here we go! 🚀

Charity Majors giving the opening keynote at ServerlessDays Boston

Serverless Product Announcements 📢

Meet the Adobe I/O Team: Mihai Corlan on Building Adobe’s Serverless Platform
Adobe’s developer tools is introducing Adobe I/O Runtime, a serverless platform built on top of OpenWhisk. You likely won’t build all your apps there, but this is an interesting way to interact with your Adobe data from collocated execution environments. Props for not naming them “functions.” 👍

Easy Observability and Monitoring with Lambda Layers
The team over at IOpipe put together a handy guide that shows you three ways to add their service using Lambda Layers. While the guide is about their service, you can apply these to any Layer.

Manage table resources in serverless
Chris Feist created a new plugin for the Serverless Framework that reduces the amount of boilerplate needed to create DynamoDB tables.

SQL order from API chaos
A new “API composition platform” called Transposit just recently appeared. “Transposit is a zero-ops platform that brings the power of a relational database to the API ecosystem. Our relational engine provides the ability to write SQL and JavaScript to query and transform your data as though each data connection were a virtual table in a single relational database.” Hmm. 🤔

Serverless Use Cases 🗺

Dyson Fan Control over MQTT via Serverless
Here’s an interesting use case. Nathan Glover set up a couple of Lambda functions to control a Dyson Fan by using the public MQTT endpoint.

Build a serverless data pipeline with AWS S3 Lamba and DynamoDB
More of a how-to, but goes to show an interesting use case for putting dependencies into a separate layer.

Async APIs
Richard Boyd’s post addresses a common use case for long-running or throttled asynchronous events.

If you’re new to Serverless… 🐣

What can serverless do for Node.js developers?
If you’re a Node.js developer and want to know how you can up your game with serverless, this short article will give you a good primer.

Best Practices for Serverless Development
Here’s another best practices post that will give you some good ideas whether you’re new to serverless or a hardened veteran.

How to Get Started With Serverless, Express and AWS Lambda
If you are thinking about migrating your Express app to a monolithic Lambda function, this post’s for you. While not a best practice, this is a common use case for those just getting started. I’ll allow it (for now). 😉

Serverless FAQ
Have questions about serverless? Know someone that does? This short post by the Serverless Gurus answers some of the common questions that our newbie friends might have.

Deploy your existing Nodejs APIs in serverless 
Another post about using the Serverless Framework to migrate your Node.js workload to Lambda. Some helpful setup tips in here as well.

Create a Highly Scalable Image Processing Service on AWS Lambda and API Gateway in 10 Minutes
This is a detailed walkthrough of how to use the AWS console to setup an image processing service with Python. This is a good post for the beginner because it walks you through all the configurations by hand. But please, learn how to write this as IaC before you go into production.

Serverless Tutorials 👷‍♂️

Everything you ever wanted to know about the Amazon DynamoDB console but were afraid to ask: A detailed walkthrough
If you’ve been using DynamoDB for awhile, you’ve likely been using CloudFormation to build your tables. This is a good post to show us how powerful the console is when you want to explore your data and configurations.

How to Configure and Connect to Serverless MySQL Database
For many a developer, you will need to pry RDBMS from their cold dead hands. That’s okay. I still use MySQL with some of my serverless applications (yes, it is possible). This is a good tutorial to show you how to get a cluster configured and connect from an execution environment.

Dynamize your resources’ parameters with the Serverless Framework!
This is a helpful post that shows you how to inject parameters into your serverless application configurations. This is extremely useful for managing variables between stages.

How to set up AWS accounts for multiple product environments
This is an extremely common use case, and if you’re not in the business of setting up nested AWS accounts all the time, it’s easy to get confused. Paul Swail has this nice write up that should save you some time.

Creating an AWS DocumentDB Cluster
The Serverless Gurus have been busy this past week. Here is another great post that will walk you through setting up a new AWS DocumentDB Cluster. Whether you should or not is another question.

Sharing Lambda Layers and Restricting Your Own Usage
Zac Charles has a great post that gives you some of the ins-and-outs of sharing Lambda Layers. If you’re planning on publishing your own, this is a useful guide to make sure you get the permissions right.

Securing APIs in Serverless (AWS Lambda)
A detailed post that shows you how to secure your API Gateways using Amazon Cognito. Not always as straightforward as you might think.

Tutorial: Setting up a private subnet on AWS
If you need to use VPCs with your serverless components, use this guide to configure your environments correctly.

Serverless Stories 📖

How Shamrock transacts billions of dollars with Serverless Framework Enterprise
Great story about Shamrock moving from containers to Lambda using the Serverless Framework. They are apparently using a “multi-cloud” strategy, so let’s see how that plays out.

ETL (Extract, Transform, Load) in Insights
Shiyang Fei discusses the decision making process that Compass used to choose between Apache AirFlow and AWS Step Functions. Lots of pros and cons outlined in here, and spoiler alert: they chose Step Functions.

Reflections on Serverless:From SOA to Serverless part 2
An interesting discussion from Diego Pacheco describing the architecture evolution from SOA to Serverless. Part 2 focuses on strategy evolution and architecture strategy.

Serverless Reads 👓

What AWS Lambda Users Should Know About Azure Functions, and Vice Versa
I’m a huge AWS fan, but it’s good for us serverless developers to see what other cloud providers are offering. Mahdi Azarboon gives us a breakdown of the differences between Azure Functions and Lambda.

Understanding the scaling behaviour of DynamoDB OnDemand tables
Yan Cui gives us another excellent post that takes a deep dive into DynamoDB on-demand tables. He’s got everything you need to know about costs, auto-scaling, and pre-warming to handle massive throughput.

Lambda Concurrency Limits and SQS Triggers Don’t Mix Well (Sometimes)
Another great post by Zac Charles that highlights some of the issues around SQS Triggers with Lambda functions. The ability to consume SQS with Lambda was a welcome addition, but you need to be a bit prescriptive when configuring your concurrency and redrive policy settings.

A Serverless 2.0 point of view
Alain Rouen says the evolution in the serverless movement is arriving and explains why it is important to understand it and how it will change the way we build apps.

3 Tips to Control the Cost of AWS Lambda
Emrah Samdan from Thundra gives us three excellent tips to help you reduce your Lambda costs.

Can you use database pooling with serverless?
Alastair Taft asks this question and gives us five possible solutions for using database pooling with Postgres and AWS Lambda. Luckily for us, AWS is working on better solutions for this problem.

The main stories from QCon London ’19
QCon London was last week, and Alex Wauters gives us a good roundup of the event. There is an interesting discussion about serverless in here.

Introduction to Monitoring Serverless Applications
A good read that will give you the basics.

When you’re wondering what AWS has been up to… 🛠

AWS Amplify Console supports instant cache invalidation and delta deployments on every code commit
Great new feature that will automatically invalidate CloudFront caches when you publish new code. If you’ve ever needed to do a manual cache invalidation, you’ll appreciate this.

Automate Releases to the AWS Serverless Application Repository using AWS CodePipeline
Eliminate the need to use the SDK or console to publish changes to your SAR apps. No more extra code needed. 👍

AWS Step Functions Adds Tag-Based Permissions
Control access based on tags using AWS Identity and Access Management. Very cool.

New Amazon SNS Console Now Available
Updated user interface in the new Amazon SNS Console is optimized for screens of all sizes, making configuration, management, and monitoring more accessible on a variety of devices.

Upcoming Serverless Events 🗓

Serverless Application Troubleshooting
This webinar, tomorrow (March 13th), features Erez Berkner talking about gathering the right data and improving your team’s velocity with distributed serverless visibility and monitoring.

AWS Lambda Security: Inside & Out
Mike Deck, Principal Solutions Architect at AWS, and Ory Segal, CTO & co-founder at PureSec, are running a webinar covering deep topics in serverless and AWS Lambda security. Happening on April 3, 2019.

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 Zac Charles (@zaccharles). Zac is Lead Engineer at JUST EAT and has been quite prolific lately with his serverless blog posts. He shares a lot of his work with C# and .NET on AWS Lambda and has a number of open source projects including LambdaNative and LambdaRemoteDebug. He’s also an active voice on Twitter. Keep the great content coming, Zac. The community appreciates it! 🙌

Final Thoughts 🤔

ServerlessDays Boston is in full swing and there have already been several amazing talks, with many more to go. If you’re here, come say “HI!” and make sure you grab some “Off-by-none” stickers. Looking forward to writing a few follow up posts on what we learned today. Just need to decompress first.

I hope you enjoyed this issue of Off-by-none. Please feel free to send feedback and suggestions so I can keep making this newsletter better each week. You can reach me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or how you’d like to contribute to Off-by-none.

And please do me the honor of sharing this newsletter with your friends and coworkers who might be interested in serverless. It would be greatly appreciated. 👍

Take care,
Jeremy

Off-by-none: Issue #27

Let’s focus on business value…

Welcome to Issue #27 of Off-by-none. Thanks for being here! 🙌

Last week we discussed whether or not serverless is really dead and met some new serverless heroes. This week we look at Lyft’s AWS bill, share lots of serverless tutorials, use cases, and stories from the community… and shamelessly plug ServerlessDays Boston!

So much happening with serverless, so let’s jump right on in. 🏊‍♂️

When you find out that Lyft is spending $8 million per month on AWS… 💰

The other day, as part of Lyft’s IPO filings, it came out that they are obligated to spend $300 million on Amazon Web Services by 2022. It seems like a big number (~$8M per month), but according to Corey Quinn on Twitter, it works out to something like $0.14 per ride. Whether that is considered a lot or a little is up to the number crunchers, but it seems to me that the cost (and headaches) of owning your own global network of data-centers would cost a heck of a lot more than that.

We know that Lyft is using a wide variety of AWS services (including Lambda, DynamoDB and other serverless offerings), but another interesting part of this story has to do with what “all-in” with AWS really means for some of its other vendors. After this news came out, MongoDB shares plummeted due to speculation that this might mean that Lyft would be moving from MongoDB to AWS’ new DocumentDB. There has been no confirmation from either side, but according to that article, Lyft “is quite dissatisfied with Mongo’s performance and is in the process of a massive database migration.”

This may be bad news for MongoDB, but I think it goes a bit deeper than that. To me, this seems like more confirmation of the “Multi-Cloud Fallacy.” I’m a huge supporter of open-source, but the business model is going to need to find a way to adapt to the changing cloud economy. At scale, multi-cloud strategies continue to breakdown, and consolidating and collocating your applications and data in hyperconnected data-centers, IMO, will be the preferred approach. Something to think about when choosing your vendors.

Serverless Use Cases 🗺

Sending funny dog GIFs using AWS IoT Button and Lambda
This is clearly the best use case for serverless that I’ve ever seen. 😂 But seriously, IoT is a great serverless use case, and I’m thinking about ordering one of those buttons just to do something fun like this.

Serverless collaboration
A quite fascinating look at how you can use WebRTC to create “serverless” communication between browsers. There are some limitations, but this is pretty cool.

How a Monolith Architecture Can Be Transformed into Serverless
Kyle Galbraith has a great piece that outlines a number of use cases for “movable” parts of your monolithic architecture and how they can be adapted to serverless. He also points out some limitations that make certain components “unmovable” due to things like high memory requirements or low latency. He concludes that serverless is not the future because of the need for other types of workloads. Agree to disagree. 😉

A Typescript Runtime for Lambda and Why You May Not Want To Use It
Matthew Bonig wrote a custom TypeScript runtime for Lambda, and then wasn’t happy with the performance. From my experience, performance with custom runtimes has been quite good, but something to consider if you’re thinking about building your own.

ArcGIS in Lambda
Interesting use case that ties ArcGIS management into Lambda functions. I’m sure there is much more you could do with this API that could allow for additional mapping capabilities.

Serverless Computing with Drupal
It’s only a matter of time before WordPress ends up in a Lambda function. Luckily, the team at Opensense Labs took a slightly different approach with Drupal. The article spends quite a bit of time justifying serverless, but key take away is the use of CloudFront as a caching layer to globally distribute your CMS.

If you’re interested in some serverless product announcements… 📢

Announcing OpenTracing Compatibility for Go Agent
Golang continues to gain popularity on AWS Lambda, and now Thundra has extended their Go Agent to allow you to manually instrument your functions with the OpenTracing interface.

Aqua Security Introduces Industry’s First Serverless Function Assurance for Securing Serverless Environments
I’m not sure it’s actually the first, but this shows continued investments into the severless security space. Detecting vulnerabilities and over-provisioned roles is a good first step, but restricting execution based on defined policies is pretty cool.

If you’re new to Serverless… 🐣

Serverless computing 101 for developers
Rodric Rabbah (one of the original creators of Apache OpenWhisk), gave a great interview with App Developer Magazine about serverless. It is a good introduction to the overall landscape (a bit skewed to open source, of course), but does a great job explaining some of the key concepts. Most important takeaway: “What developers are showing us is that serverless will become the way you develop all applications in the future.”

Five Frequently Asked Questions about Serverless
Micah Adams answers five questions that I’m sure most teams new to serverless will be asking. While I don’t agree completely with all his answers, it is good to see these types of questions being raised.

Serverless Architecture using Serverless Framework and AWS Lambda
This quick tutorial from Atin Kapoor gives newbies a step-by-step guide that should get them up and running fast.

How to explain serverless in plain English
I keep trying to refine my own pitch for the uninformed, but this post gives a nice roundup of definitions by some industry experts. Might help you better explain what you do to your significant other.

Three Projects to Get You Started with Serverless in 2019
Alex DeBrie has another great post that outlines starter projects for Ops engineers, web developers, and “anyone that wants to be a hero,” so they can jumpstart their serverless journey.

Cutting Through the Layers: AWS Lamba Layers Explained
Michael Lavers from IOpipe gives a great overview of Lambda Layers and what they’re good for. There is a mention of using layers as composition, but I still think there is a bigger opportunity here beyond just importing prebuilt packages. I have to work on that.

Serverless Tutorials 👷‍♂️

DynamoDB TTL as an ad-hoc scheduling mechanism
Yan Cui runs a series of experiments to see if you can use DynamoDB TTLs as a way to build a massively scalable scheduler system. Unfortunately, there just isn’t enough precision for certain tasks, but could certainly be useful in a number of circumstances.

There Is More than One Way to Schedule a Task
Zac Charles followed up on Yan’s post and offered some alternative approaches to scheduling a task, including SQS Delay Queues, SQS Message Timers, SQS Visibility Timeout, and my favorite, Step Functions.

OpenWhisk Web Action Errors With Sequences
James Thomas has a great post that explains the power of Action Sequences with OpenWhisk Functions and how you can tie those to synchronous web actions. Function composition is still one of the most confusing aspects of serverless, but Action Sequences are an interesting approach.

Setup CI/CD pipeline with AWS Lambda and the Serverless Framework
Lorenzo Micheli walks you through setting up a CI/CD pipeline for your serverless projects, complete with approval steps.

AWS Infrastructure as Code with CDK
If you’re not a fan of CloudFormation and you’d like to use a more familiar programming language to manage your infrastructure, Ross Rhodes’ post will teach you how to use the AWS Cloud Development Kit to configure a simple serverless application.

Using Little’s Law to estimate IP capacity in VPC for AWS Lambda
If you still need to use VPCs with your Lambda functions, you need to make sure you have enough IPs available for your ENIs. Vladyslav Usenko shows you some quick calculations to make sure your CIDR blocks aren’t too small.

Building serverless apps with components from the AWS Serverless Application Repository
Aleksandar Simovic reminds us that we should not be reinventing the wheel if someone has already created a good solution. The AWS SAR is loaded with really great apps to jumpstart your serverless projects.

AWS Lambda for .NET Developers
If you love .NET core, this great post by Marc Roussy will give you some good insight and all the details you need to run .NET on AWS Lambda.

Serverless Stories 📖

Paul Swail has an excellent series of posts documenting the decisions he needs to make in order to Migrate a Monolithic SaaS App to Serverless. In part two, he tackles Routing requests away from a legacy API. This should be an interesting set of posts to keep up with.

Painless Serverless: Destructuring services into functions automatically
Not sure how effective this would actually be (nor is the author) but the basic idea is to take a monolithic service and automatically break it down into discrete serverless functions. Interesting idea.

Going serverless: How we migrated our customer websites to AWS Lambda
Andy Buckingham and his team over at Aiir built a custom PHP Lambda Layer to replace nginx based web servers. I’m assuming they are using Lambda like mini servers (so maybe not the best use case), but they are taking advantage of ALBs instead of API Gateways, so that’s interesting.

How we migrated from monolithic to serverless mentality
This is just a short write-up by Darlei Soares that shows how quickly small teams (with the right mindset) can start to implement serverless architectures.

Serverless For Devops Teams
A list of “weird and wonderful use cases that the DevOps team” at Space Ape has found for Lambda functions.

SEEKing Serverless with DevopsGirls
Just a nice story about people coming together and volunteering their time to spread the idea of serverless, one small bootcamp at a time.

Serverless Computing: The Story of Success
The story of how the JetRuby Agency built a serverless application for a client, what technologies they used, how many people it required, and how long it took. Interesting read.

Serverless Reads 👓

Macroservices vs. Microservices vs. Serverless: the story of a modern solution architect
Mick Roper takes us through his decision making process when choosing a particular design pattern.

Why I, A Serverless Developer, Don’t Care About Your Containers
An important point in here while we continue to argue about what makes something “serverless.” Developers won’t really care about any of it as long as the providers are managing the services for them.

Serverless Architectural Patterns
Eduardo Romero outlines several useful patterns that you can use with your serverless applications. Lots of excellent links at the end as well.

Industry predictions for 2019
A good overview of how companies think about moving to the cloud and why leapfrogging containers might be the better approach.

Project Management In The Age Of Serverless
Robert Ayres argues that project managers need to know more about the technology as their teams adopt serverless. This posts lays out a number of factors to consider when defining your project management methodology as well as outlining the impact of emerging technologies on your projects.

Amazon DynamoDB auto scaling: Performance and cost optimization at any scale
Helpful post that gives an overview of how auto scaling works and how to use it to reduce your overall costs.

How Might Serverless Impact Node.js Ecosystem?
Aditya Modi asks an important question, especially when it comes to the size of third-party Node.js libraries. As he says, it takes time to load dependencies into memory, which can affect cold start times. Doesn’t mean we avoid libraries, it just means we need to be smarter about how we optimize them.

When you’re wondering what AWS has been up to… 🛠

Amazon Aurora Serverless Publishes Logs to Amazon CloudWatch
Don’t know how I missed this last week, but this is big. A major deficiency with Aurora Serverless was the inability to see your log files. You can now publish general logs, slow query logs, audit logs, and error logs directly to CloudWatch.

Resource Groups Tagging API Supports Additional AWS Services
Step Functions was added to the list, so more useful ways to organize and track your serverless application components.

Amazon Athena Now Supports Resource Tagging
The Athena Workgroup resource lets you separate query execution and query history between Users, Teams, or Applications running under the same AWS account, and now you can tag them for better insight for billing.

Amazon DynamoDB adds support for switching encryption keys to encrypt your data at rest
Probably not a common need, but it’s good to know that you can do this.

Introducing AWS X-Ray support for Python web frameworks used in Serverless
If you use Flask or Django with your serverless Python apps, you can now auto instrument them with X-Ray, which is pretty cool.

Upcoming Serverless Events 🗓

ServerlessDays Boston is next week Tuesday, March 12th! If you haven’t bought your ticket yet, you still have time. They are only $49 and include breakfast, lunch, happy hour drinks, and an amazing lineup of speakers. If that’s not enough, Christina Wong and I will be emceeing the event, so you don’t want to miss our comedy stylings. 😉

ServerlessDays Helsinki is on April 25th. Tickets are on sale now and the CFP is still open. ServerlessDays Tel Aviv is on June 4th (CFP is open).  And the Call for Papers for Serverless Computing London is also open.

If you don’t feel like traveling, Yan Cui is teaching an online training course for Designing Serverless Architecture with AWS Lambda on April 15th and 16th.

When you prefer multimedia… 📽

And speaking of ServerlessDays, all the ServerlessDays Cardiff 2019 videos are now available for your viewing pleasure. Lots of great stuff in there.

I also came across this video to help you Understand Serverless Kubernetes and Serverless on Kubernetes. It’s short, and actually worth watching if you are curious as to what Azure actually means by these terms. The idea of “nodeless” Kubernetes is particularly interesting.

The lasted episode of the Think FaaS Podcast finishes up a three part interview with Yan Cui. From DevOps to FinDev gives you a good overview of what FinDev is and why serverless plays an important role. However, we have to deduct 1 point because it went over the 15 minute timeout. 😬

Serverless Security 🔒

AWS Security Best Practices for API Gateway
Ory Segal from PureSec lays out the different ways that you can control access to your AWS API Gateways and gives you some best practices to make sure you keep your serverless functions secure.

The 12 Most Critical Risks for Serverless Applications 2019 Guide
PureSec also published a new guide that outlines the 12 Most Critical Risks for Serverless Apps. While serverless apps are more secure just given the fact that the provider is managing the infrastructure, it’s important to remember that the application code is still our responsibility.

5 Best Serverless Security Platform for Your Applications
A quick list and overview of five of the main serverless security platforms that are available to you.

Injection Attacks: Protecting Your Serverless Functions
Another reminder that event injection is a little different with serverless applications. Good overview of the issue, plus some mitigation strategies using Stackery and Twistlock.

When you’re looking for some serverless insights on Twitter… 🐦

A clever post by @mykola that does a great job explaining Eventual Consistency.

A valuable insight from Dwayne Monroe‏  that  “the age of bespoke IT needs to end, serverless is the method.”

Joe Emison also made a good point about people who see serverless as just as FaaS.

And Forrest Brazeal asked what is the most underrated AWS service? He got some pretty good answers.

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 Matt Weagle (@mweagle). Matt is another recently named AWS Serverless Hero and a valuable member of the serverless community. He organizes the Seattle Serverless Meetup and is a co-organizer of Seattle Serverless Days. You can find his serverless musings on Medium as well as his Twitter feed. Matt’s GitHub is loaded with sample serverless applications as well as his Sparta project, a Go framework for building serverless microservices with AWS Lambda. 👍

Final Thoughts 🤔

I’m curious what your thoughts are about the new format of the newsletter. I’ll be experimenting a bit more in future, so please let me know what you like (or don’t like) about it.

I hope you enjoyed this issue of Off-by-none. Please feel free to send feedback and suggestions so I can keep making this newsletter better each week. You can reach me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or how you’d like to contribute to Off-by-none.

And please do me the honor of sharing this newsletter with your friends and coworkers who might be interested in serverless. It would be greatly appreciated. 👍

See you next week (hopefully at ServerlessDays Boston),
Jeremy

Off-by-none: Issue #25

Serverless architectures for the rest of us…

Welcome to Issue #25 of Off-by-none. Thanks for joining us! 👍

Last week we discussed the UC Berkeley paper about serverless and pondered how SaaS providers should be thinking about serverless integrations. This week we thank IOpipe for supporting open source, explore some helpful serverless architectural patterns, and share plenty of great content and stories from the community.

A lot happening with serverless this week, so let’s get to the good stuff. 🍰

When you care about supporting the open source community… 🎗️

I am super excited to announce that IOpipe is now sponsoring two of my serverless open source projects! Lambda API and Lambda Warmer are projects that aim to make building serverless applications easier, and now with the generous financial support from IOpipe, I can make them even better. First item on the agenda: push Lambda API to a stable v1 release so that organizations can more easily build and test serverless applications before shifting their workloads with the strangler pattern.

When you’re not sure how to design your serverless architecture… 🤷‍♂️

When I first stared working with serverless applications, my biggest challenge was wrapping my head around event-driven architectures and function composition. Building small, single-purpose functions makes sense, but as soon as you start trying to figure out how they all efficiently communicate with one another (and with other services), the options can become overwhelming.

So which “pattern” do we use? The default answer always seems to be “it depends,” which, is usually not that helpful. Luckily for us, the good folks over at AWS have put together a new resources called AWS Solutions. This is a collection of vetted, technical reference implementations designed to help you solve common problems and build applications faster. These solutions cover a number of categories, but there’s a great section on serverless.

Everything from building an Ops automation tool, to centralized logging, to predictive analytics using SageMaker is covered. They even have a solution for our favorite serverless use case: image processing 😉. But seriously, these solutions include deep technical references, source code, architectural drawings, and the ability to launch the solution directly. If you are thinking about building anything on AWS, this is an amazing reference to inspire you and help you work through your own solution.

And speaking of amazing references, Rob Gruhl from Nordstrom has published the first article in a series entitled Adventures in event-sourced architecture. Event-sourcing is another pattern for distributed systems that is very effective for building large-scale, loosely coupled microservices. By using a distributed ledger to capture event stream data, you provide a tremendous amount of flexibility while increasing data quality and system reliability. I highly suggest reading this piece, even if it’s just to get the old gears turning. ⚙️

What to do if you prefer a serverless multimedia experience… 🍿

Forrest Brazeal is back with his Think FaaS Podcast. This week he discussed “Serverless In Production” with Yan Cui, another AWS Serverless Hero and serverless wizard. 🧙‍♂️

Marcia Villalba spends some more time sitting on the terrace at the Venetian talking about Serverless with Nitzan Shapira. Nitzan’s the CEO and co-founder of Epsagon, and knows his stuff when it comes to serverless observability.

And on the topic of people who know their stuff, Jeff Hollan talks about Azure Functions and the future of Serverless in the Enterprise in this talk for SSW TV.

When you want the latest serverless announcements… 📢

Nubewa has come out of stealth mode with a hefty $4.8M seed round. How Nuweba Brings Serverless Computing into the Mainstream explains a little more about what the company does and their plans for the future. More financial investments into the serverless ecosystem is always good news. 💰

Thundra released a new User Interface which helps you Identify “Jobs To Be Done.” This makes taking the right actions more intuitive when new events happen. I like this approach as it goes beyond just traditional alerts.

When people can’t stop talking about serverless security… 🔑

If you’re using Amazon GuardDuty and you want a better way to analyze the results, this post will teach you How to visualize Amazon GuardDuty findings using a completely serverless backend.

Insufficient logging in any system can lead to security issues simply because you don’t have enough data to see what’s happening within your application. Serverless implementations mostly require us to handle logging ourselves. In Securing Serverless Applications with Critical Logging, Renato from Dashbird points out some of the most important things that should (and shouldn’t) be logged from our serverless functions.

And Baffle released it First Data Protection Solution for AWS Lambda Serverless Compute, which essentially provides a data management layer that automatically encrypts and decrypts data as it is passed back and forth to Lambda functions.

When you don’t have enough frequent flyer miles… ✈️

If you weren’t able to attend ServerlessDays Cardiff, there’s a nice write up here. And ServerlessDays Hamburg was also a great success. Here’s a breakdown of Day 1 and Day 2 so you can see what you missed 😉. And there are plenty more ServerlessDays events coming up, including Boston and the recently announced ServerlessDays Helsinki.

If you don’t feel like traveling, Lumigo is hosting a webinar on the 7 things you need to know before going serverless.

Ory Segal from PureSec and Dan Cornell from Denim Group are hosting An OWASP SAMM Perspective on Serverless Computing webinar this Thursday.

And finally, Ran Ribenzaft from Epsagon and Heitor Lessa from AWS, are hosting a Serverless Observability Webinar that’s sure to provide some excellent insights.

When you’re interested in some real-world Serverless Stories… 🔦

In My Experience With Serverless GraphQL, Amo Moloko walks through some of the major gotchas he experienced and shows you how to get around them.

Intercom shows us How they used DynamoDB Streams to visualize changes in frequently updated objects. Sort of a twist on the event-sourcing model we discussed earlier, but using data changes as events. It’s an interesting way to capture history without completely redesigning the data flow.

Chris Oh spend weeks trying to figure out the best way to deploy a Scala serverless Lambda function using Travis CI. Luckily for us, he documented what he went through here and provided all the code.

Reusing Connections Lambda Functions (POC) is an interesting read that shows what happens when you start to bump up against “non-serverless” components in your serverless applications. Nice shoutout to Serverless MySQL in there as well. 😀

Manav Kohli from Thanx wrote an in-depth piece that tells us How to Process Data with Terraform and Lambda. There are still some great serverless use cases for Terraform, though I’d rather control my serverless applications using SAM or the Serverless Framework.

Where to look for some thought-provoking serverless use cases… 👀

Alex DeBrie teaches us how to Connect AWS API Gateway directly to SNS using a service integration. There are plenty of use cases for bypassing Lambda, and Alex walks us through a very popular one.

Jason Mihalopoulos show us an example of Serverless Data Processing with AWS Step Functions that uses sentiment analysis to flag negative reviews.

CouchDB Filters with OpenWhisk Triggers is another great use case by James Thomas that shows you how to restrict document changes to only the events you care about.

And how about a use case that provides a serverless, single page web application and set of supporting API Gateway end points and backing Lambda functions, which allow users to upload videos into S3 and compute and edit closed captions? Good news, AWS Labs already took care of it for you.

When your brain needs some good serverless reads… 🔖

FinDev and Serverless Microeconomics: Part 1 is a great piece by Aleksandar Simovic that discusses the new economic paradigm that serverless brings to software and how understanding the business value, revenue, cost, and the relationships among them, touches nearly every aspect of your business.

Forrest Brazeal published a new issue of Cloud Irregular that discusses how IAM Is The Real Cloud Lock-In. For those of you that are chained to your Active Directory cluster, you’ll understand this all too well. And Forrest’s FaaS and Furious cartoon got its own site, so be sure to go and check the archives.

SignalFX published The Definitive Guide to Serverless Monitoring and Observability that points out the challenges associated with monitoring serverless applications. It’s a good read that will get you thinking about what additional tools need to be put in place.

Better local development for Serverless Functions by Shane Dowling takes you through the trials and tribulations of attempting to emulate cloud services locally.

A new blog called Serverless Life has just recently popped up. There are some interesting articles on there that can keep you busy reading for awhile.

The Developer’s New Role in 300 Serverless Environments is a great piece by Toby Fee of Stackery that talks about the pains and benefits of managing multiple cloud environments for your serverless projects. Separating resources using stages, accounts and versions can get a bit difficult to manage, but Toby argues the tradeoffs are worth it.

If you’re interested in how Fission (sort of like Knative) works, Four Techniques Serverless Platforms Use to Balance Performance and Cost is a really in-depth piece that looks at it from a number of angles.

When people are (maybe) trying to make serverless easier… 💁‍♀️

λ# (pronounced “Lambda Sharp”) is a Compiler for CloudFormation that  compiles all associated code, uploads all generated assets, and deploys a CloudFormation stack in a single command. Hmm.

Maxim Zaks is working on LIDL , an  Interface Definition Language for AWS Lambda. I haven’t formed any opinions around this yet, but I’d be interested to hear your feedback.

What to do if you’re new to serverless, and really like listicles…

John Demian from Dashbird gives you Ten Amazing Benefits of Serverless Technology, which you may want to compare and contrast with the Ten Attributes of Serverless.

If you are a Google fan, you can learn Everything You Need to Know About Google Cloud Functions in this post on the New Stack.

And finally, if you are overwhelmed by all the new serverless lingo, Paul Swail put together a Serverless Glossary for you.

When you want to fire up your IDE and get hands-on with serverless… 👩‍💻

Here’s a quick and easy guide to Using Cognito for users management in your Serverless application. Everything you need to get up and running.

This is another short post that teaches you how to Use Git with AWS CodeCommit Across Multiple AWS Accounts. Very handy feature if you are using different profiles for different repositories.

If you’re using OpenFaaS, How to build a Serverless Single Page App gives you a very detailed walkthrough of the code and infrastructure needed.

Zac Charles is back teaching you how to Remotely debug .NET in AWS Lambda (with Breakpoints). And Gavin Lewis shows you How to Debug .NET Core Lambda Functions Locally with the Serverless Framework.

When you’re glad AWS is keeping everything up-to-date… 🛡️

AWS jumped right on the Container Security Issue (CVE-2019-5736) and updated all of their affected services. Check the list to see if you need to take any action on your side.

For you IoT fans, AWS announced IoT Atlas, a collection of IoT designs available in an easy-to-use, searchable website. The designs are cloud-service agnostic, allowing you to use them under the Creative Commons license where ever you want.

Amazon Kinesis Data Firehose Announced Support for Custom Amazon S3 Prefixes. Great way to partition your data for faster querying with something like Athena.

And finally, Jerry Hargrove updated his Periodic Table of Amazon Web Services, just in case you weren’t confused enough by their seemingly endless set of cloud offerings. 😁

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 Rob Gruhl (@RobGruhl). Rob is a senior engineering manager at Nordstrom and an AWS Serverless Hero. His team has been using serverless architectures to build scalable solutions since the advent of the serverless era. Rob and his team have also created and released two major open source projects: Serverless Artillary and the amazing, Hello Retail. He has been discussing event-sourcing architecture in distributed serverless systems for quite some time, and his new series of posts we discussed earlier is sure to make this excellent pattern easier to grok. Thanks for your continued contributions, Rob! 🙌

Final Thoughts 🤔

Lots of good news for the serverless ecosystem this week! I really like the new AWS Solutions compendium that was released. I think it will help a lot of people struggling with these new design patterns. And, of course, investments in companies like Nuweba are positive indicators that the space is continuing to grow and mature. Always more work to do, but it is great to see the pace of serverless adoption speeding up.

I hope you enjoyed this issue of Off-by-none. Please send feedback and suggestions so I can keep making this newsletter better each week. Feel free to contact me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or how you’d like to contribute to Off-by-none.

And please share this newsletter with your friends and coworkers who are interested in serverless. I shall be eternally grateful. 🙇‍♂️

See you next week,
Jeremy

Off-by-none: Issue #23

The State of Serverless…

Welcome to Issue #23 of Off-by-none. It’s so great to have you all here! 🤗

Last week we looked at recent investments into the serverless ecosystem, highlighted some serverless events, and offered some thoughts for picking a database for your next project. This week we’re going to look at how we can use serverless to deal with third-party API quotas, watch some helpful videos, introduce “Serverless Stories”, and so much more.

It’s been another really busy week for serverless, so let’s get right to the good stuff. 🚀

When your third-party API imposes quota limits… 🙅‍♂️

In the serverless world, we often get the impression that our applications can scale without limits. With the right design (and enough money), this is theoretically possible. But in reality, many components of our serverless applications DO have limits. Whether these are physical limits, like network throughput or CPU capacity, or soft limits, like AWS Account Limits or third-party API quotas, our serverless applications still need to be able to handle periods of high load. And more importantly, our end users should experience minimal, if any, negative effects when we reach these thresholds.

One way in which our serverless applications can be limited, is when using third-party APIs that enforce quotas. In my new post, Throttling Third-Party API calls with AWS Lambda, we look at how we can use a combination of SQS, CloudWatch Events, and Lambda functions to implement a precisely controlled throttling system. We also discuss how you can implement (almost) guaranteed ordering, state management (for multi-tiered quotas), and how to plan for failure. Not only is this solution extremely robust and flexible, it’s also very cost effective (like < $2/mth).

When AWS has a slow week… 🐌

I’m sure the AWS teams are all working hard on their next big releases, but in the meantime, they managed to release a few interesting serverless-related updates.

Speaking of state management, AWS Step Functions are an excellent way to add orchestration to your serverless workflows. Now you can Develop and Test AWS Step Functions Workflows Locally, which is a pretty cool feature. Integration testing in the cloud is still necessary, but the more we can do locally, the better.

And for more local testing goodness, Amazon DynamoDB Local Added Support for Transactional APIs, On-Demand Capacity Mode, and 20 GSIs. For many of us that use DynamoDB, these features for the local version are a welcome addition. Uber cool feature: track and return the capacity units consumed by your queries. 👍

Not so serverless, but perhaps “server-less”, is the announcement that AWS Ops Automator v2 now features vertical scaling. Unfortunately, most of us still have to use servers for some of our workloads. But this new vertical scaling feature lets you increase instance sizes instead of simply adding more instances. Scaling up instead of scaling out can be much more cost effective (plus it uses Lambda to do the work 😉).

When you’re looking for innovations in serverless… 👩‍🔬

Epsagon introduced their new Issues Manager that allows you to easily track issues in your serverless applications, identify trends, and quickly jump to Trace Search to troubleshoot them.

IOPipe now enables auto-tracing of HTTP/S calls by default, giving you insight into what external (and internal) API calls are being made and how long they take. You can read all about this new feature at The Secret Life of HTTP(S) Calls in a Serverless World.

Braintree, the payments service, is Introducing Serverless Payment Functions. According to this, “developers will be able to use Braintree to write and deploy serverless functions to instrument their transaction lifecycles, enable 3rd party connections, hook into existing business processes, streamline data exports, and more, all via Braintree tooling.” Not quite sure how this will all work yet, but could be an interesting approach for other SaaS companies to allow for more seamless serverless integrations.

CloudFlare introduced the Workers Cache API, which now lets you modify the REQUEST and RESPONSE objects from within your workers. This is similar to the functionality that Lambda@Edge provides, which is very cool functionality for many use cases.

And Google announced that Cloud Firestore has gone GA. Cloud Firestore is Google’s answer to DynamoDB, but they’ve sprinkled in a handy little feature that lets you export data directly to BigQuery to do additional analysis. Nice way to reduce a data replication step.

What to do if you prefer Prime Video over the Kindle store… 🍿

Good news, the serverless community has been busy producing some really helpful and interesting video content.

Chris Munns and AWS take you on a Deep Dive into AWS SAM and the SAM CLI, plus another Deep Dive Into Lambda Layers and the Lambda Runtime API. Lots of great information packed into these sessions.

James Hood from AWS also shows us how to Accelerate Serverless Development Using AWS SAM & the AWS Serverless Application Repository. This is an excellent intro to Nested Applications, which can be a very handy feature.

Alex Ellis’ talk from GOTO 2018 is now available. Serverless Beyond the Hype is a great talk that starts by giving you an overview of the serverless landscape, and then gets into the nuts and bolts of what makes OpenFaaS different from alternatives such as Knative. If you’re a member of the “serverless on top of containers” crowd, you’ll enjoy this.

The team at Epsagon held a webinar with plenty of insights into Serverless Monitoring in Practice. Interesting look at how complex tracing can be, and what companies like theirs are doing to make it easier.

Our friend Marcia Villabla released two more re:Invent interviews. In the first interview she is Talking about Serverless with Forrest Brazeal, another AWS Serverless Hero and all around serverless expert. She then talks about building AWS communities with Martin Buberl.

I also discovered this site (thanks to Corey Quinn) that organizes a collection of AWS re:Invent videos and podcasts of past and current breakout sessions. Plus they’re searchable, which is really helpful. And if you missed re:Invent last year, you can sign up for the on-demand version of AWS Innovate re:Invent Recap 2018.

Where to look for some interesting serverless use cases… 🕵️‍♀️

I love seeing people apply serverless in new and interesting ways. Below is a handful of nifty little use cases that will hopefully inspire you to do something amazing. 😉

In Lord of the Patch — Story of the PatchBot, Vladyslav Cherednychenko from About You, explains how his team used AWS Lambda to automate vulnerability scans on their EC2 cluster.

Maxime Preaux built a simple Serverless Mailchimp Subscription service using Webtask.io, but you could easily apply this to other providers.

If you’d prefer that your applications do more listening, Apoorva Dave walks us through Building your own Alexa Skill from scratch. I think voice control is only going to become more prevalent, so my advice: start thinking about how your apps can leverage it to create better user experiences.

How to build a Serverless Twitter bot demonstrates another great serverless use case. Lorenzo Tenti builds one using the Serverless Framework, Python and Lambda. Bots are another useful tool when done correctly, and running them on serverless makes a whole ton of sense.

Maybe more of a tool rather than a use case, but Running Jenkins Pipelines in AWS Lambda is possible with a tool called Jenkinsfile-Runner-Lambda. This might be one of those square peg, round hole situations, but Carlos Sanchez points out that “it could make sense to run Jenkinsfiles in Lambda when you are building AWS related stuff.” Maybe, but I think the point is that Lambda is a potential fit for any type of automation.

Finally, Sam Breed (aka Baby Wolfman) created a Lambda WebSocket chess ♟ demo. Could your next MMO be 100% serverless? Might be worth thinking about.

When you’re looking for some encouraging Serverless Stories… 🏆

I’ve been speaking with several people lately about new voices in the serverless community. While I try to recognize people that create helpful content and companies that are innovating in the space, we tend to get stuck in our own echo chamber. This week I’m introducing “Serverless Stories” (or maybe Serverless Voices 🤔), that shares posts from people who are just starting out with serverless or have been adopting serverless in their organizations. I think there is a lot to learn from these folks, especially for those of us trying to foster and build the community. I’d love to know your thoughts on this.

My Serverless Story is a short read that outlines a developer’s foray into the serverless world. It’s interesting to hear their thoughts on the cost of API Gateway, the limited interfaces into managed services (as opposed to traditional methods), and how they believe that it’s not ready for latency-sensitive workloads.

Jordan Finneran wrote a post about Going Serverless where he discusses the migration of an Express.js app. Lack of tooling, reliance on a single provider, cold starts, and of course, event-driven architecture, are his top concerns.

In Lessons learned from launching TubeStats: a completely serverless service, Joshua Khan talks about the execution timeout limits of AWS Lambda functions and how they built their own state management component to overcome it. Interesting takeaway here: he didn’t use Step Functions for orchestration because of “unfamiliarity” and wanting to get “something launched” as soon as possible.

In part 2 of Dirty Old Code, Pierre Bails discusses the process his company used to move their monolithic Ruby on Rails application to a serverless infrastructure. Interesting step-by-step approach which could be a useful template for other companies looking to make the switch.

When you’re looking for some insights into the state of the serverless ecosystem… 📈

John Demian says that Businesses are overcoming challenges with serverless and that “2019 will be the year of serverless.” He points out that cost and speed of development continue to be the motivating factors for companies to push for adoption.

Likewise, TechRadar points out that 2019 will be A year of reckoning for digital transformation. Key takeaway here is the prediction that serverless will be central to a company’s success.

Then there are stories like this: Developers find cautious optimism for serverless platforms. There is a lot of FUD here that purports that tools don’t work as expected and that the developer learning curve is causing problems. 🤦🏻‍♂️

This doesn’t seem to be stopping investment into the space, however, especially since a new report says that Global Serverless Architecture Market Share will Hit USD 18.04 billion by 2024. Serverless is still new, and it has its share of challenges, but the market is growing, and every day implementation gets easier.

The 2019 Microservices Ecosystem by Tobias Kunze is a great read that outlines all the major players and gives some insights into how they all fit in to the larger ecosystem. Serverless is mentioned, of course, but the vast majority are supporting containers and other types of “server-full” approaches.

Why Amazon’s AWS Cloud Business Will Continue to Grow is another interesting piece that gives a bit of insight into AWS’s growth strategy. While they continue to grow their virtual machine business with EC2, they are also supporting container management, and obviously, serverless. More interestingly (which we saw at re:Invent), AWS is saying, “if you don’t want to come to the cloud, we’ll bring the cloud to you.” Support for On-prem, along with the multitude of other offerings, is helping to build up the cloud computing market for all providers.

And speaking of growing the cloud market, a recent piece titled Capital One’s public cloud strategy at odds with industry, points out the benefits of using a public cloud versus a private one. Perhaps most importantly for a bank, the combined security expertise of public cloud providers supplies the trust needed to let Capital One focus on other parts of their stack.

When you’re finally ready to abandon WordPress… 🤬

In case you missed it, generating static sites is all the rage nowadays, and for good reason. I’d venture a guess that 99.9999% of all website traffic are simple GET requests to essentially static pages. Serving those pages up from an edge location cache makes a whole bunch of sense. But whether you’re looking to go fully-static, or leverage new features to reduce your dependencies on servers, there are plenty of options available.

A Greater Gatsby: Modern, Static-Site Generation by Toby Fee answers all your Gatsby-related questions.

If you’re not ready to go fully static, try Going serverless with React and AWS Amplify. Peter Mbanugo walks you through creating a single page app that uses GraphQL to power your dynamic features.

Adam Henson points out that You Might Not Need Server Side Rendering. But what about SEO? Adam does a pretty good job answering why not.

On the other hand, Dan Quackenbush would probably disagree. He talks about how Caching SPAs for SEO with Lamdba@Edge actually increased their crawl rate by 900%.

And let’s not forget that AWS can help you move ALL THE WAY up the stack in some cases. So What AWS service should you use to publish a web site?  Adrian Hall might have the answer for you.

When serverless security shows up on your cloud audit questionnaire… 🔐

Chris Tozzi outlines some Serverless security best practices for cloud dev and ops teams. Pretty standard stuff, but it seems that best practices need to be repeated over and over again.

If you want a really in-depth look at serverless security, you can now watch the Foundations of AWS Lambda Security webinar that Ory Segal and I did, on-demand. Lots of really good stuff in there.

We talked about adding voice control to ours apps a bit earlier, but how do we secure those, especially if they control sensitive internal components?  Aravind Kodandaramaiah from AWS shows us how to Secure and distribute Alexa skills with Alexa for Business. Which, besides the security aspect, could also make for some great internal tooling for your business.

While this story isn’t about serverless, it is a cautionary tale about being a little too paranoid when it comes to security. Digital exchange loses $137 million as founder takes passwords to the grave is an example of failed redundancy. Be smart about your secrets management, even if you think you’re invincible.

When you need the right tool for your serverless job… 🔨

Remember that time you were asking for more serverless frameworks? Well, here you go. Meet TyX, a TypeScript-based serverless backend framework designed for deployment into AWS Lambda.

If you want some more TypeScript, try IFTO: A simple debugging module for AWS Lambda (λ) timeouts.

OPTASY points out the 6 Best Serverless Plugins to tailor the Serverless Framework to your project-specific needs.

If you’re using Lambda@Edge to do redirects, middy-reroute can make your life a lot simpler.

And if you need to debug your serverless applications, Yan Cui shows us how to do it with Dashbird.

StackShare announce their Top 50 Developer Tools of 2018. There were some nice serverless mentions in there including Architect, OpenWhisk, CloudFlare Workers and AWS CloudFront.

What to do if you’re an audiophile, but also love serverless… 🔊

A recent episode of the ThoughtWorks Podcast does some Diving into serverless architecture.  Mike Roberts offers some of his insights.

The Cloudcast: A Serverless Look Ahead for 2019 features special guest, Paul D. Johnston, chatting about the current state of serverless, how to economically think about functions, and areas where serverless needs to improve.

In Diving into Data with Amazon Athena, Simon Elisha shares how Amazon Athena can give you powerful SQL querying capabilities over text files in your S3 buckets. If you’re not familiar with Amazon Athena, you seriously need to check it out.

When you want to get hands-on with serverless tutorials… 👨🏻‍💻

Here is an insanely complete, and step-by-step guide to building a full-stack application using AWS Lambda and React-native.

Binaris also has a Full Stack Tutorial with Serverless & React that includes all the code you need to get up and running in no time.

Yan Cui offers a quick Lambda optimization tip that can speed up HTTP API calls from your serverless applications. TLDR; enable HTTP keep-alive.

For those of you that might be interested in Connecting to AWS DocumentDB from a Lambda function, this post will walk you through it in painstaking detail.

Step Functions can be a bit confusing, but in AWS Step Functions – Doing Serverless is Easier Than You Think, the team at Thundra gives you the all basics.

James Beswick teaches us How to add file upload features to your website with AWS Lambda and S3.

Richard Freeman, PhD, has a great tutorial for Building a Serverless Microservice CRUD RESTful API with MongoDB.

Another thing that can trip you up is Configuration management for serverless AWS applications. Marcin Z-Pa has some thoughts on how to make it easier for you.

If you’re a GitLab CI user, Forrest Brazeal will show you How to set up multi-account AWS SAM deployments.

And finally, if you’re interested in Migrating an Express App into AWS Lambda the Easy Way, this post will give you some practical tips.

Where to go for some interesting serverless reads… 📚

Finding Serverless’ Hidden Costs is an important reminder that pay-per-use can lead to costly mistakes if you aren’t properly monitoring your serverless functions.

In AWS SLA: Are you able to keep your availability promise?, Andreas Wittig show us how to use the new AWS SLAs to calculate our own SLAs. Key point is to make sure you account for other variables besides just AWS’s promises.

Debunking Serverless Tropes by Ryan Marsh has a bit of fun at serverless naysayers’ expense. It made me laugh. 😀

🔥 Multi-region serverless backend — reloaded by Adrian Hornsby is an updated version of his old post on the topic. This time he discusses how the new Global Accelerator service works to eliminate DNS caching for better DR. Highly recommended read for anyone building out a serious, highly-available serverless application.

Raoul Meyer’s AppSync: Basically GraphQL as a service, is a good overview of what AppSync is and provides a few examples to help you get your head around it.

The Top 7 Takeaways from our 2018 Serverless Shows is a look back at Protego’s podcast episodes from last year. They had some great guests with some very good insights.

Nuweba published their Top Serverless Resources You Should Know About. A good list for those interested in staying current with what’s happening in the serverless world.

In Why DevOps Engineers Love AWS Lambda, Ran Ribenzaft from Epsagon gives us a number of great Lambda use cases for automating DevOps processes. These types of practical use cases are a great way for companies to get started with serverless.

Think you can run Kubernetes better than a cloud provider? Think again. Matt Asay argues that building your own Kubernetes cluster is a waste of valuable time. This is based off of a great Twitter thread from Ben Kehoe.

On Infrastructure at Scale: A Cascading Failure of Distributed System by Dan Woods, isn’t really about serverless, but I thought it highlighted some interesting challenges that arise from running distributed systems.

When you want to try something other than AWS… 🤷‍♂️

Ride the Serverless Wave with DigitalOcean’s One-click Droplet shows you how to get OpenFaaS up and running in DigitalOcean with just one click (sort of).

Azure Functions now has moves like Swagger (sorry, bad joke). Introducing Swagger UI on Azure Functions show you how to use a few services to generate your own API docs.

The Mixology Playbook: Kubernetes and Serverless is a well-written piece that talks about the values of a hybrid approach. While I believe there is room for a lot of players at this point, I think serverless (in whatever form it ends up taking) will ultimately win the war.

Hey Google, help me use Cloud Functions is another piece that points out how voice automation could be used to enhance a user experience. Susie Coleman works for the Guardian’s Voice Lab, which is trying to bring the “Guardian’s voice” to Google Assistant. If you’re not thinking about voice automation for your app, you might miss out on a huge opportunity.

Anchal Bhalla teaches you how to Build a Serverless App with Facial Recognition using IBM Cloud Functions. Simple tutorial, but it shows you how powerful some of this stuff is.

And last but not least, Simona Cotin shows us how to use the Azure Resource Manager to write Infrastructure as code for Serverless APIs using just a bit of JSON.

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 James Beswick (@jbesw). James is a developer, author, AWS-Certified builder, and cofounder of Indevelo, a consulting firm that builds products on AWS. He’s also a speaker, a blogger, and an active member of the serverless community. He recently launched Ask James About AWS, a video series that walks you through a number of common AWS tasks. Through his writings, videos, and talks, James is helping to spread the benefits of serverless, as well as providing useful insights and education to those looking to adopt the cloud. Thanks for what you do, James!

Final Thoughts 🤔

I’ve had a number of really interesting talks with people over the last few weeks about the overall state of serverless. There is a tremendous amount of innovation, lots of great use cases emerging, and new people joining the community every day. However, we have a long way to go before serverless becomes top of mind. We need to continue to encourage collaboration between everyone in this space so that we can educate and spread the word.

Speaking of spreading the word, there are a number of ServerlessDays events coming up that are a great way to support and expand the community. ServerlessDays Boston just announced an amazing speaker lineup, and Hamburg and Austin are right around the corner. I hope you all get a chance to attend one of these events.

I hope you enjoyed this issue of Off-by-none. I love hearing your feedback and suggestions, it helps me make this newsletter better each week. Feel free to contact me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or how you’d like to contribute to Off-by-none.

Take care,
Jeremy

Throttling Third-Party API calls with AWS Lambda

In the serverless world, we often get the impression that our applications can scale without limits. With the right design (and enough money), this is theoretically possible. But in reality, many components of our serverless applications DO have limits. Whether these are physical limits, like network throughput or CPU capacity, or soft limits, like AWS Account Limits or third-party API quotas, our serverless applications still need to be able to handle periods of high load. And more importantly, our end users should experience minimal, if any, negative effects when we reach these thresholds.

There are many ways to add resiliency to our serverless applications, but this post is going to focus on dealing specifically with quotas in third-party APIs. We’ll look at how we can use a combination of SQS, CloudWatch Events, and Lambda functions to implement a precisely controlled throttling system. We’ll also discuss how you can implement (almost) guaranteed ordering, state management (for multi-tiered quotas), and how to plan for failure. Let’s get started!

Continue Reading…

Off-by-none: Issue #22

Investing in the future of serverless…

Welcome to Issue #22 of Off-by-none. I’m so happy you’ve joined us this week! 😁

Last week we looked at ways to scale your serverless apps, highlighted some recent innovations, and examined how serverless and the cloud is affecting the IT landscape. This week, we look at some recent investments into the serverless ecosystem, highlight some upcoming events, help you pick the right database for your next project, and share plenty of great serverless resources and reads.

There is so much happening in serverless right now! Let’s get to it. 💥

When you see people jumping on the serverless investment train… 🚂

This past week, Lumigo raised an $8M seed round to help manage serverless operations. I love seeing companies that are focusing on serverless raising money. It means that investors are seeing the value, which means they can see a market for it, which means that more companies will begin to invest in serverless technology, which means more options, which means great adoption, and ultimately, world domination… Okay, maybe I pushed that a bit too far.

Torsten Volk recently posted the Top 10 VC investments in serverless startups in 2018: $33M for Twistlock, $15M for Pulumi, $11M for Solo.io, $7M for Puresec, $10M for Serverless Inc., $5.5M for Stackery, $5M for CloudZero, $4.1M for Epsagon, $2M for IOpipe, and $2M for Protego Labs.

I really hope to see companies like this succeed and continue to push the limits of serverless!

When you’re trying to think of some useful serverless use cases… 🤔

Authentication at Edge with StackPath by Jason Byrne is an interesting look at how his company is attempting to eliminate an extra round trip to authenticate requests.

Centralized Logging System for Lambda Functions walks you through the process Mohamed Labouardy and the team over at Foxintelligence followed to deliver near real-time feed of logs from CloudWatch to ELK.

CloudFetch released an open source project called cloudquery that lets you turn any website to serverless API, including support for single-page applications.

Ricardo Trindade shows us a super simple way to create Slack Notifications via AWS Lambda and SQS. Great example of how you can add serverless to your existing workflows to reduce the complexity of your “serverfull” systems.

Our data lake story: How Woot.com built a serverless data lake on AWS is a great article that shows how Woot.com was able to reduce their operational costs by 90%. Plus, it’s a great use case that you can apply to your business straight away.

When your database selection process is down to eeny meeny Dyna-mo… 🤷‍♂️

You’re not alone. Choosing the right database for your application isn’t always easy. AWS has a great post that shows you How to determine if Amazon DynamoDB is appropriate for your needs, and then plan your migration. DynamoDB is an excellent choice for many different types of workloads, but it’s not right for everything.

If you do choose DynamoDb, getting started with writing interactions can be a bit overwhelming. You might want to check out Begin Data: DynamoDB made ridiculously easy!

Another often confusing concept is figuring out How to calculate a DynamoDB item’s size and consumed capacity. Zac Charles has got you covered in his recent piece.

Sasidhar Sekar from Hotels.com has a great piece about creating Efficient Indexes in DynamoDB. It’s the fifth post their DynamoDB series and definitely worth checking out.

Of course, if you want to push serverless data to the extreme, you can always Analyze and visualize nested JSON data with Amazon Athena and Amazon QuickSight. Mariano Kamp’s piece is incredibly useful.

When serverless observability just keeps getting better… 🕵️‍♀️

Thundra now supports observability for .NET functions. For those of you that thought (or were hoping) that C# was dead, Microsoft has news for you. Azure Functions is gaining a tremendous amount of popularity, and where there’s Microsoft, there’s .NET. Learn more by ready Sarjeel Yusuf’s post about Monitoring .NET Lambda Functions with Thundra.

If you want to learn a bit more about Serverless Observability Fundamentals, check out Christina Wong’s post about Breaking down your options when collecting data from AWS Lambda.

And Epsagon, another amazing observability platform, just released their public changelog. I really like this type of radical transparency, especially when you’re trusting companies like this to support your applications. They also initiated a fun Twitter contest. Export a picture of your architecture from Epsagon and tweet #ThisIsMyEpsagon to win a prize.

When you’re looking for deep thoughts on serverless… 🤓

Julian Friedman has a really interesting post titled What comes after Serverless? In it he argues that there is a “Deployless” future, where we’ll skip passed code repos and staging environments, and essentially just edit code. It might seemed a bit far-fetched, but it is worth a read.

From Servers to Serverless recounts Avner Braverman’s journey through infrastructure and cloud innovation. Interesting read with some good history and insights into why serverless is so powerful.

NoOps in a serverless world is an interesting piece that talks about shifting IT’s focus from operations to outcomes. The authors point out that in a 2018 Deloitte global CIO survey, 69% of respondents identified “process automation and transformation” as the primary focus of their digital agendas. NoOps is still a ways off, but as the authors argue, serverless is a powerful tool for companies to reduce their operational overhead.

Sujith Reddy Komma argues the PRO’s & CON’s of Serverless Architectures. It’s a fairly simple list, but I’ve included it because his “cons” are quickly being solved thanks to observability startups, multi-region deployments and SLAs. And the cost argument is starting to get a bit old (at least to me). Need to figure TCO, not just your services bill.

And speaking of costs, The Great Serverless Cost Debate: Serverless ≠ Costless is a great piece by John Demian that explains the cost benefits of going serverless. He makes the extremely salient point that “Running back-end operations is a business in itself.” For larger companies, this may be fine, but for smaller ones looking for a competitive advantage, it’s probably not a business you want to be in.

If you’re looking for more reasons to go serverless, Ryan Jones from Serverless Guru’s piece, Serverless Impact — Developer Velocity explains how serverless speeds up developers and lets them accelerate the delivery features faster.

Greg Simons also wrote about the added benefits of serverless. In Serverless; it’s more than a FaaS, he outlines a number of reasons why serverless is much more than just hype. Plus, there was a nice mention in there. 👍

9 trends to watch in systems engineering and operations from O’Reilly Media touches on a few interesting topics. They waver on whether Knative will become the standard (I don’t think so), the importance that cloud security will play in both automation and DevOps culture, and, of course, AIOPs, because we don’t have enough buzzwords right now.

They also noted that the “serverless craze is in full swing,” with a growth of over 17% from 2017. Erez Berkner, CEO & co-founder of Lumigo says, “2019 could be serverless’ breakthrough year.”

Of course, security should always be top of mind when deploying services to the public cloud. Serverless And The Evolution In Cloud Security, How FaaS Differs From IaaS is a great piece by Ory Segal from Puresec that will give you a side-by-side look so you know what you’re responsible for.

If you’re looking for some visuals, check out How to Fold a Fitted Sheet by Joe Emison from Monktoberfest 2018. If you don’t take away a higher meaning from it, at least you’ll know how to fold a fitted sheet.

Also, Slobodan Stojanovic was interviewed on the The Serverless Show talking about The Importance of Open Source & Community Involvement. Always love listening to Slobodan.

Finally, The Rise of “No Code” by Ryan Hoover isn’t about serverless, but it makes some interesting points about the people who are becoming makers. Thanks to products that allow “non-developers” to build MVPs (or even full-scale working applications), everyone is becoming a maker. What does this mean and how does it affect an IT world that is already being eaten up by automation? Something to think about.

When you’re looking to up your Lambda Layers game… 🚀

Ever wanted to publish your Docker containers as Lambda Layers? Well, now you can with aws-lambda-container-image-converter. This should open up some people’s imaginations.

Serverless Anything: Using AWS Lambda Layers to build custom runtimes by Ben Ellerby shows you how to use layers to build a custom PHP runtime. Sure, we’ve seen this before, but this piece provides an important reminder: “Don’t forget to terminate your large EC2 instance.” 😉

AWS already created a custom Rust runtime for us, but Doug Tangren took it a step further and built the serverless-rust plugin for the Serverless Framework. Love this type of community support!

Just recently, Gojko Adzic gave us some utility Lambda Layers for FFmpeg, SOX, Pandoc and RSVG. Nathan Glover used them to create Serverless Watermarks. Very cool.

When you’re trying to simplify your serverless development… 👩‍💻

Serverless, Inc. announced the release of Serverless Framework v1.36.3. Lots of enhancements and bug fixes in this one.

Brian Leroux published Introducing Architect 5.0: fully serverless WebSockets. More great updates and, of course, support for WebSockets.

And it seems that more frameworks are emerging everyday. Osiris is a new library for building and deploying serverless web apps on AWS. Haven’t spent much time with it, but give it a look.

I also came across the functional-typescript project, a TypeScript standard for rock-solid serverless functions. Looks pretty interesting.

And Eslam Hefnawy created a project called backend.js. It’s a super light module that lets you import your Lambda functions into the browser as a backend library. Not sure what I’d do with this, but kind of a cool concept.

Where to go to find some great serverless events… ✈️

If you’d like to go sans travel, there are a number of webinars scheduled to up your serverless game.

Nested Applications: Accelerate Serverless Development Using AWS SAM and the AWS Serverless Application Repository is on January 31. This is a good opportunity to learn more about SAM and how to reuse your serverless components.

Trend Micro also has a webinar on the 31st to help you Make Sense of the Cloud, Containers, and Serverless. There are some promises of security principles in there, a topic I’m always interested in.

If you’re in the area, or just feel like taking a trip, Serverless, Inc. is running a Serverless workshop on March 1 in San Francisco. Lots of topics covered in here for the serious serverless professional.

AWS is running a Serverless Solution Provider Day in London on February 12th. There will be three great talks by three great companies: Epsagon, Stackery and Puresec. Definitely worth the visit.

Serverlessconf announced that it is coming to the east coast this fall. Exact location and date to drop in February. 🤞 for Boston. 😉

Serverless Computing London 2019 announced that their call for papers is now open. This was a great conference last year, so no doubt it will be amazing again.

The Serverless Architecture Conference in The Hague, Netherlands is running from April 8th through the 10th. Lots of great speakers, plus yours truly will be giving a talk about Serverless Microservice Patterns for AWS. Definitely looking forward to this one.

And don’t forget ServerlessDays Cardiff, Hamburg, and Austin are all coming up. Plus ServerlessDays Boston will be announcing speakers later today!

When you’re looking for some good serverless tips and tricks… 💡

Tom McLaughlin wrote a post titled, AWS Lambda And Python Boto3: To Bundle Or Not Bundle With Your Function. Quite a bit of research went into finding out that “you should not be using the AWS Lambda runtime’s boto3 and botocore module.” If you’re developing serverless apps with Python, take a few minutes to review this post.

Subscribe SQS to a SNS topic in another AWS account with CloudFormation, and gotchas! is another time-saver provide by Yan Cui. It’s a common pattern to connect to services from other accounts, and configuring it correctly with CloudFormation is with Yan’s help.

Danielle Heberling from Stackery gives us some Chaos Engineering Ideas for Serverless. Unit tests and integration tests are a necessity for serverless applications, but testing failures in distributed systems is a surefire way to make sure your systems are resilient and can handle different types of failures.

When you realize that serverless is much bigger than just AWS… 🤯

The Serverless360 team put together the Top 15 Azure Serverless Blogs of 2018. Lots of interesting posts here.

Doug Stevenson from Google answers Firebase & Google Cloud: What’s different with Cloud Functions?

An introduction to Azure Durable Functions: patterns and best practices is a great introduction to some common patterns that you can use in Azure. Only caveat, the examples are in Java. 😬

Serverless on Google Cloud Platform: an Introduction with Serverless Store gives a bit of background on serverless, event-driven computing and how it all fits together with Google Cloud Platform. There is also a link to download the Serverless Store demo app.

IBM Cloud Functions is raising the memory execution level to 2Gb to better handle Monte Carlo methods, genetic algorithms, map-reduce, and a host of other combinatorial optimization and operations research algorithms that lend themselves to running in a serverless environment.

Getting started with Custom Dockerfiles for Node.js for Serverless Functions will show you how to us the Fn project to build functions that you can run on Kubernetes.

And if you’re looking for better secrets managment, Unifying Secrets for OpenFaaS will point you in the right direction. Hint: don’t check them into source control.

Finally, if you’re interested in doing more serverless computing at the edge, Taking a look at Cloudflare Workers might be worth your time.

When the teams at AWS are forced to listen to “We can’t stop, we won’t stop” by Miley Cyrus on constant repeat… 👩‍🎤

AWS Introduced Python Shell Jobs in AWS Glue. Now you can leverage your Python skills to build things like serverless ETL tasks without learning Apache Spark.

TLS Termination for Network Load Balancers has also been added. Not applicable for serverless yet, but it could just be a matter of time.

The AWS CloudFormation UpdateReplacePolicy Attribute allows you to specify an update policy to delete, retain, or create a snapshot of old resources once the new ones have been created. Handy feature for automated serverless deployments.

The AWS Amplify CLI now supports IAM roles including MFA flows, which is a nice way of adding some extra security to the set up process.

AWS Cloud9 Supports AWS CloudTrail Logging now. So if you’re using that as your IDE, CloudTrail can track configuration changes to your environment.

Amazon Cognito Announces 99.9% Service Level Agreement, which is nice. Serverless authentication out of the box, now with guaranteed uptime.

And if you’re using Elasticsearch to handle analytics or full-text searches, you’ll be happy to hear that Amazon Elasticsearch Service doubles maximum cluster capacity with 200 node cluster support. And they announced support for Elasticsearch 6.4.

Also, be sure to check out Jerry Hargrove’s visual notes for AWS AppSync.

When you’re looking for spirited serverless discussions on Twitter… 🍿

@rakyll had some thoughts on Kubernetes being about “never having to wait for your cloud provider for a feature because you can build it yourself.” Ben Kehoe and some others whole-heartedly disagreed.

Paul Johnston posted that “Relational databases are the swiss army knife of databases”, meaning that there are likely better choices, especially for your serverless projects. The Internet did what the Internet does best and generated a lot of opinions. Very interesting thread.

Not to be outdone by others, I too sparked a heated discussion around Event Injection in your serverless apps. There was some candid feedback, and perhaps my point of “developer responsibility” was lost a bit in my wording. However, even though event injection existed before Lambda wasn’t the point, it’s still something to be aware of, especially those that are new to event-driven architectures.

The good news about the above discussion is that it actually highlighted some confusion around the “47” service integrations that Lambda has. Ajay Nair thought this was “good feedback”, so hopefully we’ll get some better documentation out of it. Silver linings. ☁️

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 Brian Leroux (@brianleroux). Brian is the co-founder of @begin, a serverless application platform that promises “Serverless in seconds.” He’s also working on the open-source Architect project, another powerful framework for building and deploying serverless applications. Brian is a regular speaker, blogger, and always welcome voice in the serverless community.

Final Thoughts 🤔

When I first started this newsletter almost six months ago, I was scouring the web each week trying to find interesting and relevant serverless content. Now every week I have to narrow down the list, and there are still over 75 links in this week’s issue alone!

I love serverless, and I love how more and more people are embracing it, experimenting with it, and seeing how it can transform the way they are building applications and their businesses. Erez from Lumingo said 2019 could be the breakout year for serverless. With all this momentum, I think he could be right.

I hope you enjoyed this issue of Off-by-none. I love hearing your feedback and suggestions, it helps me make this newsletter better each week. Feel free to contact me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or how you’d like to contribute to Off-by-none.

See you next week,
Jeremy

Off-by-none: Issue #21

The serverless takeover…

Welcome to Issue #21 of Off-by-none. I hope you’re ready to talk serverless! 😃

Last week we got hands-on and learned how to handle “not-so-scalable” systems in our serverless applications. This week we look at some more ways to scale your serverless apps, highlight some recent innovations, examine how serverless and the cloud is affecting the IT landscape, and so much more.

Lots to get to, so let’s jump right in! 🏊‍♂️

When you’re trying to get your serverless application to scale… 📈

Mikhail Shilkov has a brilliant post titled: Serverless at Scale: Serving StackOverflow-like Traffic. In this post he runs experiments across AWS, GCP, and Azure, to test how serverless functions and blob-storage scales to 1,000 requests per second. The results are quite fascinating.

We often talk about scaling “non-serverless” downstream systems in this newsletter, and Tirumarai Selvan has presented us with another option for Scaling RDBMS for GraphQL backends on serverless. Connection management is an ongoing problem with serverless functions. AWS is working to fix this with their Data API for Aurora Serverless (and of course there’s my serverless-mysql package), but overall, not a bad (albeit, non-serverless) approach.

Paul Johnston has some thoughts on Serverless Compute and Serverless Data. It is an interesting way to compartmentalize serverless applications. Without the proper design, ephemeral compute is certainly limited by the underlying datastore. Designing for scale is the new default, and this is a skill that many developers have never really needed to worry about.

Tim Bray started this thread on Twitter that goes deep into microservices and temporal coupling through synchronous communication. 🤓 I love these types of discussions, especially when Marc Brooker and Sam Newman jump in.

And James Thomas tells us about loosely-coupled serverless functions with Apache Openwhisk. Good read that looks at the difference between triggers and queues and how they can affect the scalability of your severless application. A bit specific to Openwhisk, but I think the general concepts are quite universal.

When people are having way too much fun with custom runtimes… 👩‍💻

Danil Smirnov shows you how to access the latest JavaScript SDK from Lambda functions using Layers. You might think that AWS would keep this updated, but you’d be wrong. I ran into this problem a few times, which means you must package the aws-sdk with your Lambda functions. This way is much better. 👍

The team over at Thundra developed their own Node.js Custom Runtime to let you monitor your Lambda functions without making any changes to your code. We’ve seen this type of use case before, but Thundra went the extra step to show us how they actually built it.

Have you ever wondered how to run Elixir on Lambda? Me neither, but Arjan Molenaar has figured it out for us just in case. Building an Elixir runtime for AWS Lambda gives you a brief overview of his motivations, and ultimately leads you to the GitHub repository if you’d like to try it yourself.

And PHP fans can also rejoice! Bref, a serverless framework for PHP, is incorporating a custom PHP runtime into v0.3. Look forward to better performance, PHP-FPM support, and local development with Docker and AWS SAM.

Where to look for serverless events… 🗓

ServerlessDays Cardiff is coming up on January 30th. Tickets are still available, so if you’re going to be in the area, I’d highly suggest you attend. Can’t go wrong with talks from the likes of Yan Cui, Simona Cotin, the Ian MassinghamSlobodan Stojanović and so many more.

And if you’re state-side, ServerlessDays Boston is coming up on March 12th. We just announced the one and only Charity Majors as our opening keynote speaker. And I’m happy to announce that the, wait for it… legendary Chris Munns from AWS will be giving the closing keynote. The remaining speakers will be announced early next week. This is going to be good. 🙌

If you’re looking for something a bit more remote-friendly, Stackery has some upcoming serverless webinars that you can join. They’ll walk you through how to build your serverless applications without needing to write a bunch of YAML.

Feel like doing some traveling? Thundra put together a great list of Serverless Events You Should Be Aware Of in 2019. I’m going to try and get to a few of these myself.

For those of you that are visual learners… 👀

I stumbled across some videos that Cloud Path had created, and I was impressed with how well-produced they were. In AWS S3 & AWS Lambda Integration, they walk you through setting up an S3 trigger and the code required to process the event. Beginner level stuff, but I’m going to keep my eye on this channel.

Marcia Villalba dropped another re:Invent interview where she’s Talking about testing Serverless applications with Slobodan Stojonovic. Slobodan was our very first Serverless Star at Off-by-none and is an awesome serverless resource.

If you can’t get enough of Marcia, check out her Getting ready for AWS reInvent 2018 vlog series. If you’re thinking about going to re:Invent this year, these videos provide a first hand look at this amazing experience.

CloudFlare workers are a relatively new addition to the serverless ecosystem, and they’re quite passionate about how this type of edge computing could change how applications run. How Serverless Platforms are Changing to Enable New Applications is a talk by Zack Bloom that digs deep into this concept.

What to do if you’ve been ignoring serverless security and user privacy… 🔒

If you thought that you didn’t need to worry about GDPR, think again. It was just reported that France fined Google nearly $57 million for an alleged violation. Now this might just be France being France, or it’s a sign of things to come. If you’re not familiar with GDPR, or you’ve already forgot the requirements, Stripe has a great guide to help you out. C’est la vie. 🇫🇷

Last time I’ll mention this (promise). Ory Segal and I are hosting a Foundations of Lambda Security webinar on January 24, 2019 at 11am ET. It will be packed full of practical serverless security advice including risks associate with AWS Lambda, IAM permissions, governance and regulatory compliance, and scalability.

When you’re looking for innovation in the serverless ecosystem… 🔍

Epsagon continues to make serverless observability easier with the introduction of Trace Search. This is a very cool feature that lets you find and drill down into traces using a bunch of different filters. Plus they have created plug-in packages to make integrating tracing and cleaning up your old Lambda versions much easier.

But serverless observability and tracing is a hot space to be in, and Adam Johnson and the team over at IOpipe has their own long list of accomplishments and future plans. In Auld Lang Servers, Adam outlines IOpipe’s milestones and innovations over the last year. Their product continues to get better and better, giving serverless practitioners plenty of options when choosing an observability tool.

And don’t count out OpenWhisk. Release 0.17.0 (18.01.2019) of the Serverless Framework OpenWhisk plugin was recently released, with added support for concurrent actions, which should speed up your deployments.

When you find out that Google Cloud Functions finally supports Go… 🤷‍♂️

Google announced that Go 1.11 is now a supported language for Google Cloud Functions. You’d think that since they invented it, they might have beat Amazon to the punch. Oh well, at least GCP is still innovating its serverless offerings.

Not to be outdone by AWS’s classic serverless example, Adil H has put together a post showing us how to do Image Resizing with Go and Cloud Functions. Code included.

If you’re looking to push the envelope a bit more, Saurabh Deoras has a great article on combining TensorFlow, Go and Cloud Functions. I like when people experiment with stuff like this, and even though his final solution isn’t ideal, it still works. He even waxes-poetic at the end. #deep

When the zombie apocalypse might not be the apocalypse you need to worry about… 🧟‍♂️

Forrest Brazeal wrote a rather depressing (but necessary) piece about the The Creeping IT Apocalypse. With AWS reportedly working on a secretive low-code/no-code project, there is an entire class of engineers that could get automated out of existence. TLDR; learn to code and keep your skills current.

Along the same lines, James Beswick’s latest post, The cloud skills shortage and the unemployed army of the certified, comes at it from a slightly different angle. Of course IT head counts are dropping because of automation, but James argues it isn’t just about keeping your skills current. It’s about the unreasonable expectation that a single developer must now do the jobs of what used to require several highly-specialized people to do. TLDR; become a coding superstar.

Other people are writing about this trend, perhaps without even realizing it. Nader Dabit gives his take on what it means to do Full-Stack Development in the Era of Serverless Computing“This means you basically have a team of specialized engineers that have built out and iterated on something that you or your team simply could not do alone without investing an impractical number of hours.” I think this type of innovation is great, but don’t get caught watching shadows on the wall, this type of undifferentiated development work is going away. Now look who’s being poetic. 😉

When you really like seeing serverless use cases… 🤗

I think we are all in agreement that CloudWatch is not the best place to be digging into our application logs. There are plenty of options out there, but the team at BBC iPlayer shows us how they put Lambda Logs in ELK. It’s a DIY option, but highly effective for their needs.

This is a bit of an old post, but in How I export, analyze, and resurface my Kindle highlights, Sawyer Hollenshead show us how he created a serverless pipeline that extracted his highlights, analyzed them with NLP, and published them to his site to reflect on what he read. Pretty interesting use case, IMO.

Gavin Lewis shows us How To Build a Serverless CI/CD Pipeline On AWS. There is quite a bit of complexity to his approach, but he has it all laid out for you.

When you’re a big fan of the horror genre… 👹

Henning Jacobs has compiled a list of wonderful Kubernetes Failure Stories for us. He claims that these stories “should make it easier for people dealing with Kubernetes operations… to learn from others and reduce the unknown unknowns of running Kubernetes in production.” I say it’s just another opportunity for serverless fans to say I told you so 😂. But seriously, if you want to take a stab at Kubernetes, this is a good list to get you started (or maybe scare you away).

Corey Quinn recounts a horror story of his own in this Twitter thread. The story of an ambitious young man trying to set up his own infrastructure in a shared datacenter goes horribly awry, hilarity ensues. I remember these days myself, but now that the cloud is here, this type of tragedy can easily be avoided.

Where to go for some more serverless reading… 📚

Chris Feist wrote a post called Making serverless variables work for you to accompany his new serverless-plugin-composed-vars plugin for the Serverless framework. I do this a bit differently, but this looks like a handy plugin.

Migrating a Serverless application backend to the Serverless Framework highlights Tai Nguyen Bui’s journey moving away from the console and into the world of serverless deployment automation.

Speaking of serverless journeys, How I Got Comfortable Building with Serverless highlights how Jun Fritz went from code bootcamp graduate, to Stackery employee, to confident serverless builder in just a few months. There is still much to learn, but it is fascinating how quickly people can get things up and running.

The state of serverless: 6 trends to watch highlights a fairly obvious (IMO) evolution of any new technology. However, I think that betting Knative will drive standardization is a bit off. We can argue about what serverless means all day long, but with CloudFlare workers moving compute to the edge, and AWS loading VMs closer to the metal with Firecracker, I personally see anything that adds more layers of abstraction to ephemeral functions being a step in the wrong direction. Maybe it’s just me.

In Dear Go — Thank You For Teaching Me PHP Was A Waste of My Time, Vern Keenan is pretty harsh about the future prospects of PHP. Not sure I agree with him on that, but he does make some good points about Go potentially becoming the dominant serverless runtime.

And finally, Zac Charles asks, What happens to running threads when a Lambda finishes executing? If you’re interested in the inner workings of Lambda functions and container reuse, give this short article a read.

When you’re curious what AWS has been working on… ☁️

There were a lot of serverless announcements and innovations at AWS over the last few months. If you’re having a hard time keeping up, take a look at Eric Johnson’s full recap: ICYMI: Serverless Q4 2018

The new AWS Backup lets you automate and centrally manage your backups across AWS services. Jerry Hargrove (aka @awsgeek) wasted no time putting together a cloud diagram for you. He’s also got a great one for the new Amazon DocumentDB service as well.

AWS also added S3 as a deployment action provider in CodePipeline. Check out this tutorial to learn how to Create a Pipeline That Uses Amazon S3 as a Deployment Provider. Plenty of cool use cases with this.

Two weeks ago AWS announced that AWS Step Functions would support resource tagging. Now they’re getting their very own Service Level Agreement with three 9s.

And Step Functions isn’t the only one getting SLAs. Amazon announced 99.9% Service Level Agreements for Amazon Kinesis Data Streams and Amazon Kinesis Data Firehose.

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 Mikhail Shilkov (@MikhailShilkov). Mikhail is a Microsoft Azure MVP, a frequent conference speaker, and an advocate for all things serverless. His blog is loaded with insanely thorough articles about serverless (and functional programming) that are sure to help you level up your own skills. He mostly focuses on Microsoft, but has articles like this and this that can give you some much needed perspective in the overall serverless ecosystem. And today is his birthday, so Happy Birthday, Mikhail, and thanks for what you do! 🎂🎉🎈

Final Thoughts 🤔

Thank you for all the responses from last week. Everyone that sent me a message said they like the length and that they found it easy to skim and pick out the articles they were interested in. I’m glad you all like it. If you have any other thoughts, I’d be happy to hear them.

I hope you enjoyed this issue of Off-by-none. I love hearing your feedback and suggestions, it helps me make this newsletter better. Feel free to contact me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, or how you’d like to contribute to Off-by-none.

Take care,
Jeremy

How To: Use SNS and SQS to Distribute and Throttle Events

An extremely useful AWS serverless microservice pattern is to distribute an event to one or more SQS queues using SNS. This gives us the ability to use multiple SQS queues to “buffer” events so that we can throttle queue processing to alleviate pressure on downstream resources. For example, if we have an event that needs to write information to a relational database AND trigger another process that needs to call a third-party API, this pattern would be a great fit.

This is a variation of the Distributed Trigger Pattern, but in this example, the SNS topic AND the SQS queues are contained within a single microservice. It is certainly possible to subscribe other microservices to this SNS topic as well, but we’ll stick with intra-service subscriptions for now. The diagram below represents a high-level view of how we might trigger an SNS topic (API Gateway → Lambda → SNS), with SNS then distributing the message to the SQS queues. Let’s call it the Distributed Queue Pattern.

Distributed Queue Pattern

This post assumes you know the basics of setting up a serverless application, and will focus on just the SNS topic subscriptions, permissions, and implementation best practices. Let’s get started!

Continue Reading…

Off-by-none: Issue #17

WebSockets are so hot right now…

Welcome to Issue #17 of Off-by-none. Thanks for being here! 👋

Last week we talked about when to optimize our apps and discussed what the term “serverless” actually means. This week I’ll share some more thoughts on that, plus we’ll explore the new API Gateway WebSocket support, share some great serverless articles, and look at a few more announcements from the world of serverless.

Let’s get to it. 😀

What to do when you want to call every managed service and SaaS app “serverless”… 😳

Maybe let’s not. Last week there was a bit of Twitter chatter about what “serverless” actually meant. Is it a technology, a compute model, an architectural pattern, a spectrum, an operational construct? I contend that it can’t be all of these things. I went into rant mode and wrote a post called Stop Calling Everything Serverless! It’s quite a long post, but I think it’s important that we don’t overload the term to the point that it no longer has any meaning.

In my opinion, serverless is a methodology for planning, building, and deploying software in a way that maximizes value by minimizing undifferentiated heavy lifting. It touches everything up and down the value chain, not only affecting how engineers approach development, but also influencing product strategy, design, budgeting, resource planning and much more.

I got a lot of feedback on this post. Several people disagreed with me, but I think it is a healthy debate. I’d love to hear your feedback as well.

When you’re looking for a reason to use serverless WebSockets just because you can…

AWS finally released support for WebSocket APIs in Amazon API Gateway. Which is very cool. I spent some time playing around with them and the implementation is really good. I can see lots of great use cases for this.

If you want to get a thorough walk-through of how they work, George Mao from AWS has a webinar that covers Building Real Time Applications using WebSocket APIs Supported by Amazon API Gateway.

There is also a simple-websockets-chat-app available on GitHub that you can launch using SAM. Or if you prefer, you can start Using API Gateway WebSockets with the Serverless Framework. Jared Short shows you how to use the new serverless-websockets-plugin, plus gives us a really cool DynamoDB streams pattern that we can use in all sorts of scenarios. 🤘🏻

When you realize that serverless and startups are a perfect match… 💖

Serverless and startups, the beginning of a beautiful friendship by Slobodan Stojanović, takes us through how he and his team built Vacation Tracker using serverless and a hexagonal architecture. He’s not the first to say it, but it’s certainly worth repeating: serverless give startups a huge advantage.

Speaking of Slobodan, he and Aleksandar Simović have finished their book: Serverless Applications with Node.js. Definitely worth taking a look if you’re building your serverless apps with Node.js.

If you’re looking for other startups that bet big on serverless, check out SQQUID: a 100% serverless startup. It seems like there are more and more stories like this every day.

When you can’t get enough serverless input… 🤖

Michael Vargas wrote a great piece about Using Design Patterns with AWS Lambda. Some good lessons in there about separating our business logic from the cloud provider’s interface.

Yan Cui shares his Thoughts on the Serverless Announcements at re:Invent 2018. He also lays out some Considerations for the Beginner Serverless Developer. Good place to start for those of you just getting into serverless.

I’ve spent some time working with the new Lambda support for Application Load Balancers, and there are plenty of pitfalls in there. If you’re interested in finding out more, Jeremy Thomerson has got you covered with his post API Gateway vs Application Load Balancer—Technical Details.

Serverless & SaaS — Part 1: The New Build Versus Buy by Tom McLaughlin is an interesting piece that advocates the use of SaaS products over AWS building blocks whenever possible. It might be easy to glue services together, but that doesn’t mean that your team has the right domain expertise.

Building sandcastles and securing WordPress by James Beswick is a great piece that talks about the state of content management and how it is starting to evolve to serverless backends. WordPress may be the 800 pound guerrilla, but James contends that its days may be numbered.

When you’re looking beyond relational database patterns… 🤓

How to use Amazon DynamoDB global tables to power multi-region architectures by Adrian Hornsby is a pretty cool look at how to geographically disperse your applications for lower latency and disaster recovery.

And if you’re looking for more DynamoDB goodies, Faux-SQL or NoSQL? Examining four DynamoDB Patterns in Serverless Applications by Alex DeBrie is great way to expand your mind and start drinking the NoSQL Kool-Aid.

“Serverless” CQRS using Azure Event Grid and Durable Functions by Duncan Edwards Jones, is great primer on the CQRS pattern and how you could apply that to your serverless applications. Decoupling commands and queries makes for a tremendously scalable approach.

When you’re looking for some more hands-on serverless tutorials…

Angela Wang put together A curated collection of hands-on workshops for learning AWS. There’s a few great serverless ones in there, but plenty of other AWS services are covered too.

Authentication & Authorization in GraphQL with AWS AppSync (MOB402) with Karthik Saligrama is another awesome re:Invent talk. If you’re using AppSync, I really hope you’ve got your authentication locked down. You might want to double check after you watch this video.

Eric Hammond has some ideas on Using AWS SSM Parameter Store With Git SSH Keys. Interesting approach that you might find useful.

And Marcia Villalba released a new video: Lambda layers with Serverless Framework and good practices.

When AWS keeps pumping out new features… 🏭

I was all excited when they introduced AWS Client VPN to Securely Access AWS and On-Premises Resources. Too bad the pricing is quite ridiculous.

Amazon Route 53 Adds Alias Record Support For API Gateway and VPC Endpoints, so no more additional Route 53 charges when mapping your domains to your regional or edge-optimized endpoints.

Amazon DynamoDB Accelerator (DAX) Adds Support for DynamoDB Transactions, which closes the open loop with the new DynamoDB transactions.

Amazon DynamoDB Increases the Number of Global Secondary Indexes and Projected Index Attributes You Can Create Per Table. For those of you that found five global secondary indexes to be too few, now you automatically get 20. Plus you can always ask for more if you need them.

Plus, a New SAM PUBLISH Command Simplifies Publishing Applications to the AWS Serverless Application Repository. This is a nice little addition. Hopefully we’ll see more apps in the repository soon.

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 Alex DeBrie (@alexbdebrie). Alex is a big part of the team over at Serverless, Inc., you know, the ones that brought us the amazing Serverless Framework ⚡️. Alex is constantly working to bring us new features to make our lives easier as serverless developers. He is a regular contributor to the Serverless blog, but has also started posting some great stuff to his personal blog as well. I’m looking forward to keeping up with his content and his continued work on the Serverless Framework.

Final Thoughts 🤔

WebSockets are awesome, I just need to find a reason to use them with some of my apps 😂. But seriously, there are a few use cases that are still beyond the scope of serverless. All the recent additions to DynamoDB, plus now with WebSockets, that list is getting smaller every single day. I’m really excited about what the future of serverless holds, just so long as we don’t keep misappropriating the term. 😉

🎄 Merry Christmas and Happy Holidays to all of you! I wish you all a happy, healthy and prosperous new year!

I hope you’ve enjoyed this issue of Off-by-none. Your feedback and suggestions are always incredibly helpful, so please feel free to reach out to me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, and ideas for making Off-by-none better.

See you next year,
Jeremy

Off-by-none: Issue #15

It’s all about Layers…

Welcome to Issue #15 of Off-by-none. I’m glad that you could join us. 😀

Last week we recapped re:Invent and took a look at some of the excellent talks and AWS product releases. This week we’ll dig deeper into Lambda Layers and see how people are having a bit of fun with custom runtimes. Plus we’ve got more talks from re:Invent and plenty of other serverless tidbits for your mental ingestion.

Lots to get to, so let’s get started! 🚄

What to do when AWS gives people access to Custom Lambda Runtimes… ⚙️

AWS already took care of C++ and Rust for us, plus some launch partners have already added PHP and Cobol support as well. But it seems that the community is taking advantage of this new feature in a big way.

The team over at The Agile Monkeys added a Haskell runtime. Think about it, a purely functional programming language running pure functions on stateless serverless functions! Okay, maybe that’s a bit much, but if you’re a hardcore functional programmer, you may want to give this a look. 😎

Graham Krizek added Bash support, which is pretty darn cool. He even included executables like aws, scp, git, wget and a whole lot more. Think about all the interesting and powerful use cases this opens up. Just this git support alone adds a number of possibilities. 🤓

Data scientists rejoice! You can now run R on Lambda thanks to this tutorial by Philipp Schirmer. There might be some memory limitations, but overall this looks like a workable solution for all you number crunchers. 📊

There’s also this proof of concept for a Serverless Open Runtime for AWS Lambda. Definitely an interesting concept, especially the language agnostic middlewares piece. Could turn out to be a terrible idea, but definitely something to keep your eye on. 🤷‍♂️

When you want to know how to use AWS Lambda Layers… 🥞

You can certainly build Lambda Layers on your own, but several companies are now providing them as a way for you to easily instrument your code. Epsagon, PureSec, Thundra, DataDog, IOpipe, and more, have all built Layers that you can simply plug in to your existing Lambda functions without modifying your code. That’s pretty easy.

Of course, our friend Paul Johnston has some thoughts on Lambda Layers and Custom Runtimes, including initial thoughts on best practices.

If you’re looking to help influence the future of Lambda Layers, take a look at this RFC on how to handle permissions with LayerVersions in SAM. AWS always appreciates feedback from the community, so feel free to throw your hat in the ring and add your comments. 🎩

When you refuse to believe you’ve watched all the good re:Invent talks… 📺

Not all of these are available to watch, but there is still a ton of amazing re:Invent content out there that you probably missed, even if you were at re:Invent! Here are three more talks that I found to be super interesting.

Inside AWS: Technology Choices for Modern Applications (SRV305)
Tim Bray, a Senior Principal Engineer from AWS, talks us through how AWS dogfoods serverless to power many of their own services. Even API Gateway runs on Lambda. He notes that “capacity planning sucks” and that you should “use serverless whenever possible.” This talk is full of great advice, including ways to “minimize state hydration”, plus some helpful notes on the three integration patterns. Watch the talk

Reddit’s Serverless & Compute Infrastructure at Scale (STP18)
Anand Mariappan & Jesjit Birak from Reddit take us through their latest redesign process and the steps they took to avoid another incident like “the Digg Mass Exodus of 2010.” The overall process was helpful to understand, but their method for scaling their video ingestion system using serverless tech is really interesting. A great lesson for enterprises here, as they built this to run along side their existing monolith. Watch the talk

Close Loops & Opening Minds: How to Take Control of Systems, Big & Small (ARC337)
Colm MacCárthaigh, another Senior Principal Engineer from AWS, lays out ten patterns to use while building control planes for distributed systems. Since all of our serverless applications are distributed, this makes for a really useful guide when building our own applications. Colm dives a bit into control theory, but keeps the advice practical so that you can apply these techniques immediately. Watch the talk

When you’re still debating what database to use with your serverless app… ⚖️

If you plan on using DynamoDB, you may want to look at Alex DeBrie’s DynamoDB On-Demand: When, why and how to use it in your serverless applications. Plus, lots of your burning DynamoDB questions are answered in here.

If you still want to go the relational database route, check out A crash course on Serverless with AWS — Building APIs with Lambda and Aurora Serverless by Adnan Rahić. This is a great post to get you started, I just wish he didn’t use an MySQL ORM. 🤦🏻‍♂️

And speaking of MySQL, I released a new version of serverless-mysql that fixes an ENQUEUE issue. If you’re not familiar with it, this module helps you with Managing MySQL at Serverless Scale.

What to do when you need more serverless content… 🙏

Jon Vines gives us some ideas about Breaking Down the Serverless Monolith. It’s tempting to load up functions with a lot of capabilities as it keeps things “simple” and is familiar to most developers. Some good lessons learned are outlined in this post.

If you’re interested in learning some more best practices, take a look at Five Essential Principles for Developing Lambdas. I think most of these are pretty solid (especially single-purpose lambdas), plus there are some examples, which is quite helpful.

Another great thing about single-purpose functions is that they can be optimized for their specific job. Case in point, don’t overpay when waiting on remote API calls by using the appropriate memory configurations.

For you serverless security buffs, take a look at Ory Segal’s 6 Cloud Security Predictions for 2019. And if you want some hands-on experience, try going through this Serverless Security Workshop. 🔒

When you remember that Microsoft Azure has serverless functions too… ⚡️

Mikhail Shilkov is Making Sense of Azure Durable Functions for you with his new (very detailed) post. Though the title suggests this is all about Microsoft’s solution, there is quite a bit of background on microservices, event-driven applications, serverless function composition and more. Definitely worth the read if you’ve got 20 minutes or so to spare. 📖

Kate Baroni, a Software Architect at Microsoft Azure, shows us how an Azure Function can orchestrate a real-time, serverless, big data pipeline.  Plus, if you’re interested, there are some links to related posts that go into more detail. I love finding interesting use cases like this, but it’s curious to me that Azure is doing complex orchestrations within a single function (with no mention of Durable Functions). This has always been a big anti-pattern with AWS Lambda, but maybe not with Microsoft? 😕

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 Simon Wardley (@swardley). Simon invented Wardley Maps, which changes the way we look at strategic planning. You can read all about how it works here (and I suggest you do). Beyond that, Simon is a huge proponent of serverless and has been predicting for quite some time that it is the future of computing. He has a number of brilliant talks about serverless (including ServerlessDays Hamburg and Serverlessconf San Francisco 2018), plus his Twitter feed often contains entertaining back-and-forth arguments as to why serverless adoption is inevitable (see this recent Twitter thread). I’m a big fan of Simon and appreciate the work he is doing to make the case for serverless.

Final Thoughts 🤔

Lambda Layers is exposing serverless computing to a number of new communities, and people have been rushing to add support for all kinds of runtimes and service integrations. A recent report by Gartner identified “serverless computing” as the number one key trend for 2019 and noted that “more than 20 percent of global enterprises will have deployed serverless computing technologies by 2020.”

We are still early in this journey, but as Simon Wardley says, “No more questions on serverless. It’s not an ‘if’ but ‘when’. Get on with learning.” This is sage advice, and what we’re encouraging with this newsletter.

I hope you’ve enjoyed this issue of Off-by-none. I love getting your feedback. It is always most welcome and much appreciated. Your suggestions help me make this newsletter better each week. Please feel free to contact me via Twitter, LinkedIn, Facebook, or email and let me know your thoughts, criticisms, and if you’d like to contribute to Off-by-none.

Go build some amazing serverless apps!

Take care,
Jeremy