Frequently Asked Questions

Lambda Extensions: Features & Functionality

What are Lambda Extensions and why were they developed?

Lambda Extensions are a feature introduced by AWS to empower customers to integrate their preferred operational tools with Lambda functions without adding extra operational burden or requiring complex configurations. The core motivation was to streamline operational tooling and allow developers to focus on application logic while specialized vendors handle tooling. Lambda Extensions were previewed in October 2020 and became generally available in May 2021. Source

How do Lambda Extensions work within the Lambda execution environment?

Lambda Extensions operate in parallel with your function and runtime code within the Lambda execution environment. They can be initialized before the function code, run throughout the invocation process, and continue after the function completes, enabling tasks like telemetry collection or cleanup. Extensions communicate with the Lambda platform via dedicated APIs, including the Extensions API and Logs API, providing flexibility and control over operational tooling. Source

What APIs are available for Lambda Extensions?

Lambda Extensions utilize the Extensions API and Logs API. The Extensions API allows agents to run independently from function code and communicate with the Lambda platform. The Logs API provides direct access to logs generated by both the function code and Lambda service, enabling extensions to collect and send logs to backends without relying solely on CloudWatch Logs. Source

What operational use cases do Lambda Extensions address?

Lambda Extensions are particularly useful for monitoring, observability, security, and governance. Customers and partners leverage extensions to integrate operational tools for these use cases, simplifying configuration and installation. Source

Can I use third-party or open-source extensions with Lambda?

Yes, you can use extensions provided by AWS, Independent Software Vendors (ISVs), or open-source solutions. AWS offers extensions like CloudWatch Lambda Insights, AppConfig, CodeGuru Profiler, and OpenTelemetry Collector. ISV partners provide certified extensions, and you can also build your own or use open-source extensions. Source

How do Lambda Extensions improve log management?

With the Logs API, Lambda Extensions gain direct access to logs generated by both the function code and Lambda service. This allows extensions to collect and send logs to backends independently, offering more flexibility than relying solely on CloudWatch Logs. Source

What is the lifecycle of a Lambda Extension?

Lambda Extensions are initialized before the function code and runtime. Once initialization is complete, both the function and extension operate in parallel during invocations. Extensions can continue running after the function completes, enabling post-invocation tasks such as telemetry collection or cleanup. Source

How can I get started with Lambda Extensions?

You can start by including extensions as layers within your Lambda function configuration. AWS documentation provides detailed information, lists of available extensions, and examples for building and running your own extension. Documentation

What are some examples of AWS-provided Lambda Extensions?

Examples include CloudWatch Lambda Insights for monitoring, AppConfig for feature flagging, CodeGuru Profiler for profiling function code, and AWS Distro for OpenTelemetry Collector for observability. Source

Can I build my own Lambda Extension?

Yes, you can build your own Lambda Extension if existing solutions do not meet your requirements. AWS documentation provides guidance and examples for custom extension development. Documentation

How do Lambda Extensions support the shared responsibility model?

Lambda Extensions reflect the AWS Lambda shared responsibility model, where the platform manages certain aspects while you maintain control over your code, including any extensions. This allows for flexibility and customization in operational tooling. Source

What are the benefits of using Lambda Extensions for monitoring and observability?

Lambda Extensions simplify the integration of monitoring and observability tools, enabling real-time telemetry collection, enhanced log management, and seamless integration with preferred operational tools. This improves visibility and control over Lambda function performance. Source

How do Lambda Extensions enhance security and governance?

Lambda Extensions enable integration with security and governance tools, allowing organizations to strengthen their serverless architecture by monitoring, auditing, and enforcing policies within the Lambda execution environment. Source

What is the timeline for Lambda Extensions availability?

Lambda Extensions were previewed in October 2020 and became generally available in May 2021. Source

How do I configure Lambda Extensions in my function?

Extensions are typically included as layers within your Lambda function configuration. You can select from AWS-provided, ISV, or open-source extensions, or build your own. Documentation provides step-by-step guidance. Documentation

What flexibility do Lambda Extensions offer for operational tooling?

Lambda Extensions provide flexibility by allowing you to use AWS-provided, ISV, or open-source extensions, or build your own. This enables organizations to tailor operational tooling to their specific needs and integrate seamlessly with their preferred tools. Source

How do Lambda Extensions impact the initialization phase of Lambda functions?

Extension initialization occurs before the runtime or function code is initialized. The initialization phase concludes when both the function code, runtime, and extension initialization are completed, or when a timeout occurs. This ensures extensions are ready to operate in parallel with function invocations. Source

What are the main advantages of using Lambda Extensions?

Lambda Extensions streamline operational processes, enhance monitoring and observability, strengthen security, and enable seamless integration with preferred tools. They simplify configuration, improve log management, and provide flexibility for operational tooling. Source

Where can I find more information and examples about Lambda Extensions?

Detailed information, lists of available extensions, and examples for building and running your own extension are available in the AWS documentation. Documentation

Sedai Autonomous Cloud Optimization: Features & Capabilities

What is Sedai's autonomous cloud management platform?

Sedai offers an autonomous cloud management platform designed to optimize cloud operations for cost, performance, and availability. It uses machine learning to eliminate manual intervention and delivers up to 50% cost savings, 75% latency reduction, and 6X productivity gains. Source

How does Sedai ensure safe, autonomous optimizations in production?

Sedai is patented for safe, autonomous optimizations in production. Unlike risky optimizers that make all-at-once changes, Sedai performs slow, gradual optimizations with continuous validation checks, ensuring no incidents or SLO breaches. Every optimization is constrained, validated, and reversible. Source

What are the key benefits of using Sedai?

Sedai delivers up to 50% cloud cost reduction, 75% latency reduction, 6X productivity gains, and reduces failed customer interactions by up to 50%. It proactively resolves issues, improves release quality, and enhances reliability. Source

What modes of operation does Sedai offer?

Sedai offers Datapilot (observability), Copilot (one-click optimizations), and Autopilot (fully autonomous execution), providing flexibility for different operational needs. Source

How does Sedai optimize cloud resources?

Sedai autonomously optimizes compute, storage, and data across AWS, Azure, GCP, and Kubernetes environments using machine learning. It rightsizes workloads, eliminates waste, and aligns optimizations with application behavior and business outcomes. Source

What is Sedai for S3 and how does it help?

Sedai for S3 optimizes Amazon S3 costs by managing Intelligent-Tiering and Archive Access Tier selection. It achieves up to 30% cost efficiency gain and 3X productivity gain by reducing manual effort in S3 management. Source

What is Sedai's Release Intelligence feature?

Release Intelligence tracks changes in cost, latency, and errors for each deployment, improving release quality and minimizing risks during deployments. Source

How does Sedai proactively resolve issues?

Sedai detects and resolves performance and availability issues before they impact users, reducing failed customer interactions by up to 50% and ensuring seamless operations. Source

What integrations does Sedai support?

Sedai integrates with monitoring and APM tools (Cloudwatch, Prometheus, Datadog, Azure Monitor), Kubernetes autoscalers (HPA/VPA, Karpenter), IaC and CI/CD tools (GitLab, GitHub, Bitbucket, Terraform), ITSM tools (ServiceNow, Jira), notification tools (Slack, Microsoft Teams), and runbook automation platforms. Source

How easy is it to implement Sedai?

Sedai offers plug-and-play implementation, connecting securely to cloud accounts via IAM. Setup takes just 5 minutes for general use cases and up to 15 minutes for AWS Lambda. Personalized onboarding, documentation, and a 30-day free trial are available. Source

What security and compliance certifications does Sedai have?

Sedai is SOC 2 certified, demonstrating adherence to stringent security requirements and industry standards for data protection and compliance. Security page

Who is Sedai's target audience?

Sedai targets platform engineering, IT/cloud ops, technology leadership, site reliability engineering (SRE), and FinOps roles in organizations with significant cloud operations across industries such as cybersecurity, IT, financial services, healthcare, travel, and e-commerce. Source

What pain points does Sedai address?

Sedai addresses fragmentation, operational toil, risk vs. speed, autoscaler limits, visibility-action gaps, ticket volume, change risk, config drift, hybrid complexity, capacity/cost surprises, outcome gaps, cloud spend pressure, tool sprawl, talent bandwidth, release risk, pager fatigue, brittle automation, cross-team trade-offs, visibility without action, multi-cloud complexity, misaligned priorities, resistance to change, manual optimization, and slow anomaly response. Source

What business impact can customers expect from Sedai?

Customers can expect up to 50% cost savings, 75% latency reduction, 6X productivity gains, reduced failed customer interactions by up to 50%, enhanced reliability, and improved release quality. For example, Palo Alto Networks saved $3.5 million and KnowBe4 achieved 50% cost savings. Source

What industries are represented in Sedai's case studies?

Sedai's case studies cover cybersecurity, IT, financial services, security awareness training, travel and hospitality, healthcare, car rental services, retail and e-commerce, SaaS, and digital commerce. Source

Who are some of Sedai's customers?

Notable customers include Palo Alto Networks, HP, Experian, KnowBe4, Expedia, CapitalOne Bank, GSK, and Avis. These companies trust Sedai to optimize their cloud environments and improve operational efficiency. Source

How does Sedai differ from similar products in the market?

Sedai offers 100% autonomous optimization, proactive issue resolution, application-aware intelligence, full-stack cloud coverage, release intelligence, and plug-and-play implementation. Unlike competitors, Sedai is patented for safe, gradual optimizations with continuous validation, ensuring no incidents or SLO breaches. Source

What customer feedback has Sedai received regarding ease of use?

Customers highlight Sedai's quick setup (5–15 minutes), agentless integration, personalized onboarding, extensive documentation, community Slack channel, and risk-free 30-day trial as key factors contributing to its ease of use. Source

Where can I find Sedai's technical documentation?

Sedai provides detailed technical documentation for setup, features, and usage at docs.sedai.io/get-started. Additional resources, case studies, and datasheets are available at sedai.io/resources.

Can you share specific case studies or success stories of Sedai customers?

KnowBe4 achieved up to 50% cost savings and saved $1.2 million on AWS. Palo Alto Networks saved $3.5 million, reduced Kubernetes costs by 46%, and saved 7,500 engineering hours. Belcorp reduced AWS Lambda latency by 77%. KnowBe4 case study, Palo Alto Networks case study

Sedai Logo

Understanding Lambda Extensions

S

Sedai

Content Writer

March 28, 2024

Understanding Lambda Extensions

Featured

This blog is based on a transcript of a talk by Shridhar Pandey of AWS at Sedai's autocon conference.

Introduction

Hello everyone! In this article, we'll be exploring an important topic: Lambda Extensions. These extensions are a powerful feature that was introduced last year. So, let's jump straight into it and understand the details of this valuable addition.

Throughout this blog, I'll make sure to provide you with concise and informative insights. We will uncover the reasons behind the development of Lambda Extensions, understanding what drove its creation. We will then take a closer look at what these extensions actually are, giving you a clear overview of their functionality. Moreover, we will cover the wide range of use cases they can address, showcasing their versatility. Lastly, I'll guide you through the process of getting started with Extensions, ensuring you have the necessary tools to explore this feature on your own. So, let's start discovering more about Lambda Extensions. You can watch the full video here.

Seamless Integration of Operational Tools with Lambda

The motivation behind building Lambda Extensions stemmed from a few different reasons, but the core idea was to empower our customers to use their preferred operational tools on Lambda without adding any extra operational burden or requiring complex configurations. Our philosophy is to allow you to focus on developing your application logic while leaving the heavy lifting of tooling to specialized vendors. This formed the foundation of Lambda Extensions.

We also listened to feedback from customers who expressed the need for simplified operational tooling on Lambda. We embarked on a mission to create an ecosystem of operational tools around Lambda, making it easier for organizations and customers to bring their existing tools to the platform. We wanted to streamline the process, whether customers desired to utilize their own tooling or build their own. With this goal in mind, we launched Lambda Extensions last year. We initially previewed it in October 2020 and made it generally available in May 2021.

In essence, Lambda Extensions offer a straightforward method for integrating various operational tools, whether developed internally or provided by independent software vendors (ISVs), with the Lambda execution environment. This execution environment is where your Lambda function code runs. The purpose is to simplify the configuration and installation of these tools, and that's where Extensions come into play. In terms of use cases, we envisioned Extensions being particularly useful for monitoring, observability, security, and governance. We've witnessed customers leveraging these use cases, and both Lambda partners and ISV tooling partners have built and support Extensions for them.

Under the Hood and API Functionality

So, let's explore what Lambda Extensions are and how they work under the hood. In the image you see here, the box on the left with the Lambda sign represents the Lambda service itself. On the right-hand side, you'll notice several boxes that collectively represent the execution environment. This environment is where your function code, runtime code, and Extension code operate. The platform takes care of initiating and managing the execution environment's life cycle, and communication with the platform occurs through APIs, such as the runtime API.

6477aac6c270c22a08c501cd_a6171945.webp

With the introduction of Extensions, we added additional APIs to the mix. In the pre-Extensions world, the runtime in the function code communicated with the platform using the runtime API. However, with Extensions, you can now run tools or agents in parallel with the runtime and function code. These agents operate independently from the function code and communicate with the Lambda platform through a new API specifically designed for Extensions.

The Extension agent can be initialized even before the function code itself, enabling it to run in parallel throughout the entire function invocation process. It can continue running even after the function code has completed its execution, allowing for tasks like cleanup or collecting telemetry data. For example, an Extension could use the post-invocation period to send the function's response back to a backend or perform other post-execution actions. Many Extension authors utilize this model to integrate their extensions effectively. Additionally, we introduced the Logs API, which offers exciting capabilities. By default, the Lambda service generates logs for your function, which are stored in CloudWatch Logs. However, with the Logs API, Extensions gain direct access to the logs generated by both the function code and the Lambda service. This means that if you're running an Extension within the Lambda execution environment and want to collect and send logs to your backend, you can do so without solely relying on CloudWatch Logs. The Logs API provides more flexibility and control in managing your function's logs.

The Extensions API and Logs API collectively form part of the Extensions offering. Now that we have an understanding of what Lambda Extensions are and how they work, let's delve into their lifecycle and timeline representation.

6477aac5cc40d44e656b2962_08648ed4.webp

As we observe the diagram, let's delve into its details. Firstly, notice the line that distinguishes what is managed by the Lambda service and what falls under the responsibility of your Extensions within your code. This line reflects the shared responsibility model of AWS Lambda, where the platform manages certain aspects while you maintain control over your code, including any extensions.

Now, focusing on the left side of the diagram, you'll notice that extension initialization takes place even before the runtime or function code is initialized. This initialization phase concludes when both the function code, runtime, and extension initialization are completed, or when a timeout occurs, depending on whichever comes first. Once this initialization process is finalized, and an invocation or request is received, indicated by the invocations depicted, assuming the function is properly initialized, both the function and the extension operate in parallel. A series of invocations will occur, facilitating the execution of the function and the extension simultaneously.

AWS Services, ISV Partners, and Open-Source Solutions

There are multiple ways to utilize extensions, providing flexibility based on your specific needs. Firstly, as mentioned earlier, you have the option to build your own extensions or leverage ready-to-use extensions offered by our trusted tooling vendors, who are our partners.

Let's explore some of the available extensions. AWS provides services like CloudWatch, which offers the CloudWatch Lambda Insights extension for enhanced monitoring. AWS AppConfig offers an extension that enables feature flagging and other useful functionalities. The AWS CodeGuru Profiler extension helps with profiling function code, while the AWS Distro for OpenTelemetry provides the OpenTelemetry collector as an extension.

In addition to these AWS extensions, we have partnered with several Independent Software Vendors (ISVs) who offer certified extensions. These extensions have undergone a rigorous evaluation process and can be used directly from the respective vendors. To use them, you typically include the provided extensions as layers within your function code configuration. If you're looking for open-source solutions, there are also various open-source extensions available for download and personal use. And if you can't find an extension that perfectly fits your requirements, you have the option to build your own Lambda extension. Our documentation provides detailed information on extensions, including a list of available extensions and examples to guide you through the process of building and running your own extension.

Summary

Lambda Extensions open up a world of possibilities for streamlining your operational processes, enhancing monitoring and observability, strengthening security, and enabling seamless integration with your preferred tools. Whether you choose to leverage existing extensions, explore partnerships with ISV tooling vendors, or embark on building your own extensions, the power is in your hands to optimize your Lambda functions and focus on what truly matters—building exceptional applications. I encourage you to look into the versatility of Lambda Extensions and unlock the full potential of your serverless architecture today.