Notes from Sam Newman's talk "Confusion In The Land Of The Serverless" at CraftConf

The full recording is here:

A definition of Serverless

Serverless - five things a platform need to have to be serverless (see

  1. Requires no management of Server hosts or Server processes
  2. Self auto-scale and auto-provision, based on load
  3. The costs are based on precise usage
  4. Performance capabilities defined in terms other than host size / count
  5. Implicit High Availability

Be warned on "high-availability" though: high availability of what? You don't have high-availability of all your solution/platform just because you use some components that provide high-availability out-of-the-box.

Serverless is a form of PAAS, a most prescriptive abstraction of a PAAS


When one component is massively scalable and the other is not, you have a potential issue: cascading failures

Typically, you would use protection patterns like connection pools or circuit breakers.

Connection pools: throttles the number of clients going to talk to the db => load shedding

How could I throttle functions? you can't, or better, you've to use api gateway

How would you mix a sql db (e.g. mysql) into a serverless architecture?
If you want all the solution to be highly scalable, you should use a BAAS (e.g. dynamodb, google big data), but mysql and dynamo are not semantic equivalent!

So, what about hybrid apps?

Can I build a highly resilient serverless app with an hybrid approach? probably not.

Circuit breaker

To integrate FAAS components with other non-serverless components you have to provide some sort of middleware to load-shedding the components that cannot transparently scale

lambda => circuit breaker: can I call downstream component?
circuit breaker => lambda: ok, go
lambda => calls the component

Mixing vendors?

Is mixing vendors a good strategy to "spreading your eggs" => not so much => you got latency (es. BAAS google, frontend in lambda)


Serverless definition... Ignore the specific definition: the goal of a platform is making easy for you to focus on the job you're doing

Serverless is a much better developer-friendly abstraction that allow to focus on the problems at hand