Blazing fast serverless with Rust

Photo
Daniele Frasca

ProSiebenSat.1

16 December, 11:10, «02 Hall. Ararat»

Abstracts

Even if you can use almost any language to build your serverless app, some choices provide significant advantages in terms of speed, which translates into more cost-effective functions. In this talk, we explore how to match Rust programming language and AWS Lambda millisecond billing.

As a developer, I am requested to optimize the following:
- Bootstrap of the runtime
- Code run
- Use better processor architecture

Being a Serverless engineer means I need to take care of many moving parts, software, architectures, security and so on.

The best practices developing with AWS Lambda functions are:
- The Lambda package should be as small as possible;
- Initialize my classes, SDK clients and database connections outside of the function handler;
- Cache static assets locally in the /tmp directory.

Doing all this and many others will save execution time and cost for subsequent invocations (Warm start).

When we are talking about serverless, speed is essential. I am not talking about spending hours of development time saving a few ms, but I am talking about the relationship between speed and cost.

Speed in a hyperconnected world where everything must be available in real-time is essential, and for few that use this concept at scale, it will result in a cheaper cloud cost.

Rust is the key to unlocking the performance of the next generation of serverless applications. Thanks to the Single Responsibility Function that reduces the code complexity, Rust has become just a tool, another language syntax that allows me to increase the throughput while reducing cost.

The talk was accepted to the conference program