Amap is a leading provider of digital map content, navigation, and location-based solutions in China. Established in 2002, Amap is now a wholly owned subsidiary of Alibaba Group and is integrated with the e-commerce ecosystem of Alibaba Group. In 2018, Amap became the first Chinese maps service to navigate a path to 100 million daily users.02
The core business of Amap is to provide mapping, navigation, and location-based services that allow users to go anywhere, anytime. Amap, especially its mobile app AMAP, generates large volumes of traffic while providing these services to its customers. To support its core business, Amap has adopted the Node FaaS framework for the scene, route planning, and navigation stop pages in the app.
With an increasing number of new features, Amap has upgraded itself from being just a navigational tool to a complete travel service platform. Amap provides users with information on daily services along travel routes to bring a more comprehensive user experience. This is evident through Amap's Scenario Recommendation Card feature, which provides relevant information based on users' travel requirements.
In order to provide an optimal user experience, this feature must support fast iteration, be lightweight, and be flexible. Therefore, to update its services in a fast and flexible manner, Amap stores card style templates in the cloud and renders styles to clients when a service is introduced to the clients.03
Why Alibaba Cloud
After detailed evaluation and judgment, the team at Amap and Alibaba categorized this scenario as a stateless service. Considering the Alibaba Cloud's mature serverless ecosystem, AMAP finally chose to integrate the Node FaaS service of Alibaba Cloud's Function Compute to build the Scenario Recommendation Card service in the front-end. The card capabilities of UI template acquisition, data request aggregation and logic processing, and Schema generating are all realized in the FaaS layer. The client directly renders and displays data based on the Schema issued by the service so as to achieve the goal of being more lightweight and flexible.
This serverless architecture delivered outstanding performance during the peak hours of the 2020 Chinese National Day (Golden Week). The architecture processed more than 1,000,000 access requests per minute and over 20,000 queries per second. The service success rate exceeded 99.99% and the average response time was less than 60 ms. The service stability provided by this solution was beyond the team's expectations.04
High efficiency: Amap has seamlessly integrated the AMAP mobile app with its R&D system at the FaaS layer by using the serverless architecture. As a result, it is 40% faster to put new features of the app into commercial use, and the employee efficiency and productivity has greatly improved. Amap benefits from the serverless architecture in development, testing, phased release, and publishing of new features. In addition, the architecture helps Amap facilitate the development of standardized capabilities such as flow control, auto scaling, and disaster recovery.
High elasticity and low costs: Based on traffic trends, Amap can analyze the traffic characteristics of the difference between traffic peaks and off-peaks shown on the map. Traditionally, Amap needed to reserve a large number of computing resources to handle traffic surges during peak hours. However, redundant servers incur additional costs during off-peak hours. To solve this problem, Amap used Function Compute to provide auto scaling based on traffic changes. Although it is complex to increase scaling speed and the higher scaling speed feature has always been exclusive to large enterprises only, Function Compute can start within milliseconds and provide fast scaling to more enterprises, helping them use computing resources more flexibly and at lower costs.
High observability: Observability is a prerequisite attribute for an application diagnostic platform. This attribute allows users to observe the changes of response time, usage rate of resources, and full-link invocation of system applications so that the users can quickly diagnose application issues. Function Compute has seamlessly integrated with Log Service, Cloud Monitor, Tracing Analysis, and Serverless Workflow. To use these features, users only need to configure functions once. This reduces learning costs and simplifies the application diagnosis process.05
Serverless architecture is becoming increasingly popular across various industries, and it is beginning to be implemented for large-scale applications, such as Amap. After adapting the serverless architecture, Amap can now update its services more flexibly and at a higher speed, paving the way for service innovation. This serverless architecture allows frontend developers to focus on key issues and drive business growth. From its capability pilot in the beginning of 2020 National Day "Travel Week", the travel service of Amap has been fully integrated with Function Compute, laying a solid foundation for Amap to migrate all of its services to the cloud in the near future.