Other meanings of Function as a service
Cloud Computing
Function as a service (FaaS) is a cloud computing model that runs event-triggered functions without managing servers, enabling developers to deploy code that executes in response to events and scales automatically. It is a key component of serverless computing, abstracting infrastructure management and billing only for execution time.
FaaS platforms execute application logic as individual functions, each triggered by events such as HTTP requests, database changes, or message queue messages. Developers upload code packages, and the platform handles provisioning, scaling, and fault tolerance, automatically spinning up instances as needed and scaling to zero when idle.1 This event-driven paradigm contrasts with traditional server-based models where resources are continuously allocated. Billing is based on execution duration and memory usage, often at millisecond granularity, which can reduce costs for intermittent workloads but may be unpredictable for sustained high traffic.2 FaaS functions are stateless by design, with state typically stored in external services like databases or object storage, enabling horizontal scaling and resilience.
The concept gained prominence with AWS Lambda's launch in 2014, which popularized the term and established the pattern of event-driven, serverless functions. Since then, major cloud providers have introduced their own offerings: Google Cloud Functions, Microsoft Azure Functions, and IBM Cloud Functions, among others. Open-source frameworks like OpenFaaS and Knative provide portable FaaS layers on Kubernetes, allowing on-premises or multi-cloud deployments.3 These platforms vary in language support, execution time limits, and integration with ecosystem services, but share the core abstraction of functions as the unit of deployment and scaling.
FaaS is well-suited for event-driven workloads such as webhooks, real-time file processing, IoT data ingestion, and API backends with variable traffic. It excels at tasks that are short-lived and can be parallelized, like image resizing or log analysis.4 However, limitations include cold start latency, execution time caps (often minutes), and difficulty in debugging distributed executions. Stateful applications or long-running processes are poor fits, and vendor lock-in can be a concern, though open-source options mitigate this.5 Cost efficiency diminishes for always-on workloads, where traditional servers may be cheaper.
Beyond mainstream use, FaaS has niche applications in scientific computing, such as processing astronomy data or running Monte Carlo simulations, where burst parallelism is valuable. Early academic work on functions-as-a-service predates AWS Lambda, with research projects like JVM-based systems exploring fine-grained deployment. Cold start optimization remains an active research area, with techniques like snapshotting and pre-warming. Additionally, FaaS is used in edge computing, running functions on devices close to users, and in serverless machine learning inference, though GPU support is limited. The term 'serverless' is often used interchangeably, but FaaS specifically refers to the function-level execution model.
FaaS is a subset of serverless computing, focusing on function-level execution.
Help improve the encyclopedia. Reports go straight to the site manager.