Lambda
Learn how Sedai uniquely optimizes AWS serverless functions to achieve your performance and cost goals.
Last updated
Was this helpful?
Learn how Sedai uniquely optimizes AWS serverless functions to achieve your performance and cost goals.
Last updated
Was this helpful?
Sedai optimizes two key aspects of AWS Lambdas:
Memory Allocation
Autonomous Concurrency
Sedai profiles serverless functions and determines optimal memory configurations based on reinforcement learning. Optimizations typically yield faster and cheaper results.
You can define specific to guide how the system optimizes functions.
This feature helps eliminate cold starts with marginal impact on cloud spend. Using a combination of the following, Sedai informs its central control and learning unit to manage Lambda cold starts:
Sedai AV Lambda Extension (external extension written in Go): Analyzes Lambda behavior such as runtime events, cold start duration, and concurrency patterns (this allows close Lambda monitoring without any overhead)
Traffic Seasonality: Monitors and builds a seasonality model in order to understand local and global trends and anticipate traffic fluctuations
Provisioned Concurrency: Monitors concurrency events as well as concurrency scaling based on seasonality
NodeJS 12 and above on x86_64
Python 3.7 and above on x86_64
Java 8 and above on x86_64
The static and runtime characteristics of the extension are limited to:
Additional 12 MB size in deployed Lambda layer
0.1 ms latency overhead per 1,000 invocations
0.11 ms execution time overhead per 1,000 invocations
The AV Lambda extension acts as Sedai's control center for your Lambdas. It is responsible for collecting metrics from Sedai's autonomous concurrency extensions and communicating with Sedai core components.
Deploy the AV Lambda extension manually or via your preferred IaC tool:
Before you get started, please make sure you install Serverless Framework 3 and as recommended.
Navigate to and select Create Role. Select AWS Service as your trusted entity and choose Lambda as the use case.
Download a from Sedai's repository and update the <AWS-REGION>
and <AWS-ACCOUNT-ID>
placeholders in it, then paste the policy into the JSON editor. Select Next to optionally add tags, then Next to review the policy. Enter a unique name for the policy (such as iam-policy-sedai-avlambda-control-center
) and select Create Policy to complete.
Go to the and select Create function.