The author | li gq Ali cloud senior product specialist

This article is adapted from Serverless Technology Open Course. Follow “Serverless” public account, reply “getting started”, you can get Serverless series articles PPT.

Today, in the big field of Serverless, there is not only a product form and application type of function calculation, but also Serverless products suitable for different user groups and usage habits. For example, function-oriented function computing, application-oriented Serverless application engine, and container-oriented Serverless Kubernetes. Users can choose Serverless products based on their usage habits, application scenarios, or application types. The following through this article to introduce to you, Ali Cloud what are available for you to choose Serverless products.

Serverless products and layering

As we all know, Serverless was first proposed by AWS, and its flagship product in the Serverless field is Function Compute. Ali Cloud also has function computing products to help users build Serverless functions. However, Serverless is not just a function. As shown in the figure below, users can expect to enjoy Serverless benefits in applications and containers, including payment by volume and extreme flexibility, which is more in line with users’ original usage habits.

In the figure above, we can see that Ali Cloud has launched Serverless products for functions, applications and containers. Users can choose different products according to their own usage scenarios.

Function to calculate

1. Introduction to function calculation

The figure above shows how function calculations are used. From the user’s point of view, all he needs to do is code and then upload the code to the function calculation. There is no charge at this point, only when it is called. The method of invocation can be the API/SDK provided by the product, or through some event sources, such as the events of OSS of Ali Cloud. For example, a user uploads a file to a bucket in OSS and expects the file to be processed automatically. For example, uploading a ZIP package in the hope that it will automatically unzip to another bucket is a typical functional scenario.

In addition, the function calculation can provide very good flexibility, and the final charge is based on the time and memory amount, if the call usage is small, there will be a small charge. It is also very rich in language, common nodeJS, PHP, Python, Java are directly supported. It also provides a custom runtime environment that can support any executable language.

2. Functions calculate typical scenarios

In terms of usage scenarios, there are three main types:

  • Web applications: Can be written in a variety of languages, such as new programs written using the Serverless framework, or existing applications. Such as applets back end, or API back end applications published to the API market;
  • Applications with strong elastic demands for computing power: AI reasoning, audio and video processing, document conversion, etc.;
  • Event-driven applications: for example, function calculation has been connected with many products, such as object storage, table storage, timer, CDN, log service, cloud monitoring, etc., through other Aliyun product-driven scenarios, Web hooks, scheduled tasks, etc., which can quickly assemble some business logic.

3. Function calculation of core competitiveness

One of the biggest values of functional computing for customers is that users can only focus on their own business logic development, and do not need to manage operation and maintenance, such as computing resources, network Settings, etc. In isolation, vm level isolation is provided to ensure users’ data security and runtime security at runtime. In terms of availability, the high availability architecture of 3AZ is provided by default, ensuring that customers are provided with the high availability best practice architecture by default. In terms of elasticity, it can achieve the elastic efficiency of millisecond level to meet the unexpected flow impact of customers. It’s also very flexible in terms of billing, really charging on a per-request basis, and supporting a more friendly pre-paid model for Long Run apps.

Serverless Application engine

1. Summary of SAE

SAE is the industry’s first application-oriented Serverless Paas platform. The product takes an application-oriented view, helping users put their inventory into the cloud without making any changes. At the resource layer, users no longer need to manage, operate and maintain machines and clusters by themselves, but only need to pay attention to the specifications and number of instances required by their applications, rather than whether the underlying layer is a virtual machine or a container.

SAE provides computing resources, resiliency, and isolation at the resource level, allowing users to focus only on their own applications. At the application level, SAE provides monitoring, logging, and microservice governance capabilities to help users address their application observability and governance needs. At the same time, it provides network configuration and flow control capabilities, and provides good integration with CICD. Users can use existing CICD to deploy to SAE, such as Jenkins and Cloud Effect, etc., which can be said to cover the complete scenario of cloud application.

2. Typical SCENARIO of SAE

SAE has several typical application scenarios. One is the existing business cloud, especially micro-services and Java applications, and also supports individual applications of other languages. SAE platform can be run on Ali Cloud without any code modification. In terms of industry, SAE is particularly suitable for online businesses with relatively large traffic fluctuations, such as e-commerce promotion, online education and other industries. In addition, as an application platform, SAE can also be integrated with the upper industry Saas to help users build industry Saas faster.

3. SAE features

Through introducing the scenario above, we can see that the SAE besides Serverless experience itself brings extreme flexibility, from operational characteristics, focus on the application layer to the user’s ability to provide full stack, including support for micro service enhancement, as well as the integration and application ability, which is closely linked, including configuration, monitoring, logging, flow control, etc. Coupled with the user zero code changes, is the enterprise online business smooth cloud is a very good choice.

Serverless Kubernetes

1. ASK overview

Another Serverless product provided by Aliyun is Serverless K8s. But how can K8s still Serverless? This requires an understanding of the evolution of technology architecture.

In the earliest days, Docker images were deployed in virtual machines. Users needed to purchase ECS, then deploy images, and finally some configurations of the network, such as SLB and EIP. During this process, users need to complete deployment and capacity expansion by themselves, or build a set of automatic scripts, which are relatively low in cost and stability.

Then K8s came along to help solve the problem of container choreography. This standardized approach has really made everyone more productive. Users orchestrate and deploy using standard K8s methods such as Deployment, Service, etc. However, the operation and management of K8s is relatively complex and requires high skills. Users need to operate and maintain ECS and K8s constructed through ECS. Another pain point is that ECS in THE K8s cluster need to be purchased in advance. If the customer’s load fluctuates greatly, more resources will be wasted. Although there are technical solutions, such as the flexibility of Worker Nodes, this is still quite complex for beginner users.

Is there a solution that allows users to enjoy the container choreography capabilities provided by K8s without having to worry about ECS and K8s operations, management, and resiliency? This is the solution for Serverless K8s. The product corresponding to Aliyun is ASK. In ASK’s scenario, users create an ASK cluster without specifying any ECS nodes, and then deploy the image through standard K8s container orchestration, Deployment, and so on. According to users’ load requirements, ASK will automatically build required PODS in the underlying resource pool and perform elastic scaling. Users no longer need to care about LaaS layer issues such as capacity planning, ECS machine operation and maintenance, and resource limitation, which is very convenient.

2. ASK Typical scenario

In what situations is ASK mainly used? First of all, it can be used to run online business. The deployment mode is flexible, including deployment, Helm Chart and other K8s native modes. In particular, it can deal with sudden traffic well and be extremely flexible, which can complete 500 container instances in 30 seconds. Such flexible efficiency can support big data computing tasks, such as Spark and Presto, as well as timely access to resources when needed, supporting more than 10,000 Pod specifications, effectively reducing customer costs.

Another ideal scenario is for building on-demand build tasks, such as running Jenkins, Gitlab-Runner, and so on in ASK. Start as soon as you have a build task. Zero consumption when there is no task, the cost is the lowest. Here are just a few examples of scenarios, but based on this feature of ASK, users can actually run many K8s native workloads that require extreme flexibility.

3. ASK features

ASK is fully container deployed and isolated through containers. In the process of using, users do not need to operate and maintain ECS or K8s clusters, nor do they need to consider cluster upgrade, capacity planning, OS and system software issues, etc., theoretically providing unlimited elastic capacity. Because it’s all about usage, there’s no need to pay for restricted resources.

conclusion

To sum up, it can be seen that Ali Cloud has a variety of products in the Serverless field today, including function-oriented function calculation, users can only focus on the code, rapid development and delivery; There is also an application-oriented Serverless application engine, which allows users to focus more on the application perspective and provides a series of capabilities around the application, including monitoring, logging, traffic and other capabilities integration; For users more accustomed to the K8s ecosystem, ASK allows users to enjoy the benefits of Serverless without changing their current K8s usage habits. A variety of products, while meeting the demands of different users, users also experience the advantages of Serverless free operation and maintenance, extreme flexibility, payment by volume and so on.

Course recommended

In order for more developers to enjoy the dividends brought by Serverless, this time, we gathered 10+ Technical experts in the field of Serverless from Alibaba to create the most suitable Serverless open course for developers to learn and use immediately. Easily embrace the new paradigm of cloud computing – Serverless.

Click to free courses: developer.aliyun.com/learning/ro…

“Alibaba Cloud originator focuses on micro-service, Serverless, container, Service Mesh and other technical fields, focuses on the trend of cloud native popular technology, large-scale implementation of cloud native practice, and becomes the public account that most understands cloud native developers.”