Serverless computing is a
cloud computing
Cloud computing is the on-demand availability of computer system resources, especially data storage ( cloud storage) and computing power, without direct active management by the user. Large clouds often have functions distributed over m ...
execution model
A programming language consists of a grammar/syntax plus an execution model. The execution model specifies the behavior of elements of the language. By applying the execution model, one can derive the behavior of a program that was written in term ...
in which the cloud provider allocates machine resources on demand, taking care of the
servers on behalf of their customers. "Serverless" is a
misnomer
A misnomer is a name that is incorrectly or unsuitably applied. Misnomers often arise because something was named long before its correct nature was known, or because an earlier form of something has been replaced by a later form to which the name ...
in the sense that servers are still used by cloud service providers to execute code for developers. However, developers of serverless applications are not concerned with
capacity planning
Capacity planning is the process of determining the production capacity needed by an organization to meet changing demands for its products.
In the context of capacity planning, design capacity is the maximum amount of work that an organization ...
, configuration, management, maintenance,
fault tolerance
Fault tolerance is the property that enables a system to continue operating properly in the event of the failure of one or more faults within some of its components. If its operating quality decreases at all, the decrease is proportional to the ...
, or scaling of containers,
VMs, or physical servers. Serverless computing does not hold resources in
volatile memory
Volatile memory, in contrast to non-volatile memory, is computer memory that requires power to maintain the stored information; it retains its contents while powered on but when the power is interrupted, the stored data is quickly lost.
Volatile ...
; computing is rather done in short bursts with the results persisted to storage. When an app is not in use, there are no computing resources allocated to the app. Pricing is based on the actual amount of resources consumed by an application.
It can be a form of
utility computing
Utility computing or The Computer Utility is a service provisioning model in which a service provider makes computing resources and infrastructure management available to the customer as needed, and charges them for specific usage rather than a ...
.
Serverless computing can simplify the process of
deploying code into production. Serverless code can be used in conjunction with code deployed in traditional styles, such as
microservices
A microservice architecture – a variant of the service-oriented architecture structural style – is an architectural pattern that arranges an application as a collection of loosely-coupled, fine-grained services, communicating through ligh ...
or
monoliths
A monolith is a geological feature consisting of a single massive stone or rock, such as some mountains. For instance, Savandurga mountain is a monolith mountain in India. Erosion usually exposes the geological formations, which are often ma ...
. Alternatively, applications can be written to be purely serverless and use no provisioned servers at all.
This should not be confused with computing or networking models that do not require an actual server to function, such as
peer-to-peer
Peer-to-peer (P2P) computing or networking is a distributed application architecture that partitions tasks or workloads between peers. Peers are equally privileged, equipotent participants in the network. They are said to form a peer-to-peer ...
(P2P).
Serverless runtimes
Serverless vendors offer compute runtimes, also known as
Function as a Service Function as a service (FaaS) is a category of cloud computing services that provides a platform allowing customers to develop, run, and manage application functionalities without the complexity of building and maintaining the infrastructure typical ...
(FaaS) platforms, which execute application logic but do not store data. Common languages supported by serverless runtimes are
Java
Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
,
Python and
PHP
PHP is a General-purpose programming language, general-purpose scripting language geared toward web development. It was originally created by Danish-Canadian programmer Rasmus Lerdorf in 1993 and released in 1995. The PHP reference implementati ...
. Generally, the functions run under isolation boundaries, such as,
Linux containers.
Commercial offerings
The first "pay as you go" code execution platform was
Zimki, released in 2006, but it was not commercially successful. In 2008,
Google
Google LLC () is an American Multinational corporation, multinational technology company focusing on Search Engine, search engine technology, online advertising, cloud computing, software, computer software, quantum computing, e-commerce, ar ...
released
Google App Engine
Google App Engine (often referred to as GAE or simply App Engine) is a cloud computing platform as a service for developing and hosting web applications in Google-managed data centers. Applications are sandboxed and run across multiple servers ...
, which featured metered billing for applications that used a custom Python framework, but could not execute arbitrary code. PiCloud, released in 2010, offered FaaS support for Python.
Kubeless and Fission are two
Open Source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
FaaS platforms which run with
Kubernetes
Kubernetes (, commonly stylized as K8s) is an open-source container orchestration system for automating software deployment, scaling, and management. Google originally designed Kubernetes, but the Cloud Native Computing Foundation now maintai ...
.
Google App Engine, introduced in 2008, was the first abstract serverless computing offering. App Engine included HTTP functions with a 60-second timeout, and a blob store and data store with their own timeouts. No in-memory persistence was allowed. All operations had to be executed within these limits, but this allowed apps built in App Engine to scale near-infinitely and was used to support early customers including
Snapchat
Snapchat is an American multimedia instant messaging app and service developed by Snap Inc., originally Snapchat Inc. One of the principal features of Snapchat is that pictures and messages are usually only available for a short time before th ...
, as well as many external and internal Google apps. Language support was limited to Python using native Python modules, as well as a limited selection of Python modules in C that were chosen by Google. Like later serverless platforms, App Engine also used pay-for-what-you-use billing.
AWS Lambda
Amazon Web Services, Inc. (AWS) is a subsidiary of Amazon.com, Amazon that provides Software as a service, on-demand cloud computing computing platform, platforms and Application programming interface, APIs to individuals, companies, and gover ...
, introduced by Amazon in 2014,
popularized the abstract serverless computing model. It is supported by a number of additional AWS serverless tools such as AWS Serverless Application Model (AWS SAM)
Amazon CloudWatch
Amazon Elastic Compute Cloud (EC2) is a part of Amazon.com's cloud-computing platform, Amazon Web Services (AWS), that allows users to rent virtual computers on which to run their own computer applications. EC2 encourages scalable deployment of ...
, and others.
Google Cloud Platform created a second serverless offering,
Google Cloud Functions in 2016.
Oracle Cloud Functions is a serverless platform offered on
Oracle Cloud Infrastructure, and is based on the open source Fn Project so developers can create applications that can be ported to other cloud and on-premise environments. It supports code in
Python,
Go,
Java
Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
,
Ruby
A ruby is a pinkish red to blood-red colored gemstone, a variety of the mineral corundum (aluminium oxide). Ruby is one of the most popular traditional jewelry gems and is very durable. Other varieties of gem-quality corundum are called sapp ...
, and
Node
In general, a node is a localized swelling (a "knot") or a point of intersection (a vertex).
Node may refer to:
In mathematics
* Vertex (graph theory), a vertex in a mathematical graph
* Vertex (geometry), a point where two or more curves, line ...
.
Serverless databases
Several serverless
databases
In computing, a database is an organized collection of data stored and accessed electronically. Small databases can be stored on a file system, while large databases are hosted on computer clusters or cloud storage. The design of databases spa ...
have emerged in the last few years. These systems extend the serverless execution model to the
RDBMS
A relational database is a (most commonly digital) database based on the relational model of data, as proposed by E. F. Codd in 1970. A system used to maintain relational databases is a relational database management system (RDBMS). Many relatio ...
, eliminating the need to provision or scale
virtualized
In computing, virtualization or virtualisation (sometimes abbreviated v12n, a numeronym) is the act of creating a virtual (rather than actual) version of something at the same abstraction level, including virtual computer hardware platforms, sto ...
or physical database hardware.
Nutanix
Nutanix, Inc. is an American cloud computing company that sells software, cloud services (such as desktops as a service, disaster recovery as a service, and cloud monitoring), and software-defined storage.
History
Nutanix was founded on September ...
offers a solution named Era which turns an existing RDBMS such as
Oracle
An oracle is a person or agency considered to provide wise and insightful counsel or prophetic predictions, most notably including precognition of the future, inspired by deities. As such, it is a form of divination.
Description
The wor ...
,
MariaDB
MariaDB is a community-developed, commercially supported fork of the MySQL relational database management system (RDBMS), intended to remain free and open-source software under the GNU General Public License. Development is led by some of the ...
,
PostgreSQL
PostgreSQL (, ), also known as Postgres, is a free and open-source relational database management system (RDBMS) emphasizing extensibility and SQL compliance. It was originally named POSTGRES, referring to its origins as a successor to the In ...
or
Microsoft SQL Server
Microsoft SQL Server is a relational database management system developed by Microsoft. As a database server, it is a software product with the primary function of storing and retrieving data as requested by other software applications—which ...
into a serverless service.
Amazon Aurora
Amazon Aurora is a relational database service developed and offered by Amazon Web Services beginning in October 2014. Aurora is available as part of the Amazon Relational Database Service (RDS).
History
Aurora offered MySQL compatible servic ...
offers a serverless version of its databases, based on MySQL and PostgreSQL, providing on-demand, auto-scaling configurations.
Azure Data Lake
Azure Data Lake is a scalable data storage and analytics service. The service is hosted in Azure, Microsoft's public cloud.
History
Azure Data Lake service was released on November 16, 2016. It is based on COSMOS, which is used to store and pr ...
is a highly scalable data storage and analytics service. The service is hosted in
Azure, Microsoft's public cloud.
Azure Data Lake Analytics provides a distributed infrastructure that can dynamically allocate or de-allocate resources so customers pay for only the services they use.
Oracle Cloud
Oracle Cloud is a cloud computing service offered by Oracle Corporation providing servers, storage, network, applications and services through a global network of Oracle Corporation managed data centers. The company allows t ...
offers a serverless version of its Oracle Autonomous Database, which is the Autonomous Transaction Processing service. The serverless service also includes a JSON edition.
Firebase
Firebase is a set of hosting services for any type of application (Android, iOS, Javascript, Node.js, Java, Unity, PHP, C++ ...). It offers NoSQL and real-time hosting of databases, content, social authentication (Google, Facebook, Twitter an ...
, also owned by Google, includes a
hierarchical database
A hierarchical database model is a data model in which the data are organized into a tree-like structure. The data are stored as records which are connected to one another through links. A record is a collection of fields, with each field containin ...
and is available via fixed and pay-as-you-go plans.
Advantages
Cost
Serverless can be more cost-effective than renting or purchasing a fixed quantity of servers,
which generally involves significant periods of underutilization or idle time.
It can even be more cost-efficient than provisioning an
autoscaling group, due to more efficient
bin-packing of the underlying machine resources.
This can be described as pay-as-you-go computing
or bare-code
as you are charged based solely upon the time and memory allocated to run your code; without associated fees for idle time.
Immediate cost benefits are related to the lack of operating costs, including: licenses, installation, dependencies, and personnel cost for maintenance, support, or patching.
The lack of personnel cost is an advantage that applies broadly to cloud computing.
Elasticity versus scalability
In addition, a serverless architecture means that developers and operators do not need to spend time setting up and tuning autoscaling policies or systems; the cloud provider is responsible for scaling the capacity to the demand.
As Google puts it: "from prototype to production to planet-scale."
As cloud native systems inherently scale down as well as up, these systems are known as elastic rather than scalable.
Small teams of developers are able to run code themselves without the dependence upon teams of infrastructure and support engineers; more developers are becoming
DevOps
DevOps is a set of practices that combines software development (''Dev'') and IT operations (''Ops''). It aims to shorten the systems development life cycle and provide continuous delivery with high software quality. DevOps is complementary t ...
skilled and distinctions between being a software developer or hardware engineer are blurring.
Productivity
With
function as a service Function as a service (FaaS) is a category of cloud computing services that provides a platform allowing customers to develop, run, and manage application functionalities without the complexity of building and maintaining the infrastructure typical ...
, the units of code exposed to the outside world are simple event driven
functions. This means that typically, the programmer does not have to worry about
multithreading or directly handling
HTTP
The Hypertext Transfer Protocol (HTTP) is an application layer protocol in the Internet protocol suite model for distributed, collaborative, hypermedia information systems. HTTP is the foundation of data communication for the World Wide Web, ...
requests in their code, simplifying the task of back-end software development.
Disadvantages
Performance
Infrequently-used serverless code may suffer from greater response
latency than code that is continuously running on a dedicated server, virtual machine, or container. This is because, unlike with autoscaling, the cloud provider typically "spins down" the serverless code completely when not in use. This means that if the runtime (for example, the
Java
Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
runtime) requires a significant amount of time to start up, it will create additional latency.
Resource limits
Serverless computing is not suited to some computing workloads, such as
high-performance computing
High-performance computing (HPC) uses supercomputers and computer clusters to solve advanced computation problems.
Overview
HPC integrates systems administration (including network and security knowledge) and parallel programming into a multi ...
, because of the resource limits imposed by cloud providers, and also because it would likely be cheaper to bulk-provision the number of servers believed to be required at any given point in time.
Monitoring and debugging
Diagnosing performance or excessive resource usage problems with serverless code may be more difficult than with traditional server code, because although entire functions can be timed,
there is typically no ability to dig into more detail by attaching
profilers
Offender profiling, also known as criminal profiling, is an investigative strategy used by law enforcement agencies to identify likely suspects and has been used by Detective, investigators to link cases that may have been committed by the same pe ...
,
debugger
A debugger or debugging tool is a computer program used to test and debug other programs (the "target" program). The main use of a debugger is to run the target program under controlled conditions that permit the programmer to track its execut ...
s or
APM APM, apm, or Apm may refer to:
Technology Computer technology
* Active policy management, a discipline within enterprise software
*Advanced Power Management, a legacy technology in personal computers
* Apple Partition Map, computer disk partit ...
tools.
Furthermore, the environment in which the code runs is typically not
open source
Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use the source code, design documents, or content of the product. The open-source model is a decentralized sof ...
, so its performance characteristics cannot be precisely replicated in a
local environment
Local may refer to:
Geography and transportation
* Local (train), a train serving local traffic demand
* Local, Missouri, a community in the United States
* Local government, a form of public administration, usually the lowest tier of administrat ...
.
Security
Serverless is sometimes mistakenly considered as more secure than traditional architectures. While this is true to some extent because OS vulnerabilities are taken care of by the cloud provider, the total attack surface is significantly larger as there are many more components to the application compared to traditional architectures and each component is an entry point to the serverless application. Moreover, the security solutions customers used to have to protect their cloud workloads become irrelevant as customers cannot control and install anything on the
endpoint and
network
Network, networking and networked may refer to:
Science and technology
* Network theory, the study of graphs as a representation of relations between discrete objects
* Network science, an academic field that studies complex networks
Mathematics ...
level such as an
intrusion detection/prevention system (IDS/IPS).
This is intensified by the mono-culture properties of the entire server network. (A single flaw can be applied globally.) According to Protego, the "solution to secure serverless apps is close partnership between developers, DevOps, and AppSec, also known as DevSecOps. Find the balance where developers don't own security, but they aren't absolved from responsibility either. Take steps to make it everyone's problem. Create cross-functional teams and work towards tight integration between security specialists and development teams. Collaborate so your organization can resolve security risks at the speed of serverless."
Privacy
Many serverless function environments are based on
proprietary public cloud environments. Here, some
privacy
Privacy (, ) is the ability of an individual or group to seclude themselves or information about themselves, and thereby express themselves selectively.
The domain of privacy partially overlaps with security, which can include the concepts of a ...
implications have to be considered, such as
shared resource
In computing, a shared resource, or network share, is a computer resource made available from one host to other hosts on a computer network.
It is a device or piece of information on a computer that can be remotely accessed from another comput ...
s and access by external employees. However, serverless computing can also be done on private cloud environment or even on-premises, using for example the
Kubernetes
Kubernetes (, commonly stylized as K8s) is an open-source container orchestration system for automating software deployment, scaling, and management. Google originally designed Kubernetes, but the Cloud Native Computing Foundation now maintai ...
platform. This gives companies full control over privacy mechanisms, just as with hosting in traditional server setups.
Standards
Serverless computing is covered by International Data Center Authority (IDCA) in their Framework AE360. However, the part related to portability can be an issue when moving business logic from one public cloud to another for which the
Docker solution was created.
Cloud Native Computing Foundation
The Cloud Native Computing Foundation (CNCF) is a Linux Foundation project that was founded in 2015 to help advance container technology and align the tech industry around its evolution.
It was announced alongside Kubernetes 1.0, an open sourc ...
(CNCF) is also working on developing a specification with
Oracle
An oracle is a person or agency considered to provide wise and insightful counsel or prophetic predictions, most notably including precognition of the future, inspired by deities. As such, it is a form of divination.
Description
The wor ...
.
Vendor lock-in
Serverless computing is provided as a third-party service. Applications and software that run in the serverless environment are by default locked to a specific cloud vendor. Therefore, serverless can cause multiple issues during migration.
Uses/functions
Serverless functions can be used for:
* Data analytics
* CI/CD operations
* File conversions
* Log aggregation and restructuring
* Support for dynamic website content
See also
*
Cloud computing
Cloud computing is the on-demand availability of computer system resources, especially data storage ( cloud storage) and computing power, without direct active management by the user. Large clouds often have functions distributed over m ...
*
Function as a service Function as a service (FaaS) is a category of cloud computing services that provides a platform allowing customers to develop, run, and manage application functionalities without the complexity of building and maintaining the infrastructure typical ...
References
Further reading
*
* {{Cite web, url=http://www.bcs.org/content/conWebDoc/58491, title=Losing the server? Everybody is talking about serverless architecture, last=Jamieson, first=Frazer, website=BCS, the Chartered Institute for IT , date=4 September 2017, accessdate=7 November 2017, ref=none
Cloud computing