Sharing| An example of the technical architecture of an open platform for small programs

In recent years, super APPs have gradually risen, and major Internet giants have launched small program open platforms one after another. Under this background, do you need to implement your own open platform for small programs? And how to achieve it? These questions plague many companies. As the most commercialized small program container technology on the market, FinClip has helped many large enterprises successfully build an open platform for small programs. The following uses a certain cloud disk APP as an example to briefly talk about the technical architecture of the applet open platform.


Industry background: User volume of a cloud disk app : Tens of millions of users
Requirement realization: Safely introduce third-party services by building an open platform for small programs

The technical architecture required for an open platform for small programs will vary according to specific business needs and scale. The basic technical architecture includes: front-end framework, back-end service, database, cache, container and orchestration, monitoring and logging, security, etc. The small program open platform created by FinClip with the help of this cloud disk has some experience worth sharing in the following aspects.

From the perspective of the front-end framework , the front-end framework of the mini-program platform draws on the design ideas of the mainstream front-end framework Vue, provides a concise programming model from the application form of the mini-program, defines a set of specifications for components and API interfaces, and reduces the The learning threshold is convenient for developers to quickly develop small programs.

The life cycle management of applets is provided within the applet framework, and each stage of the applet is injected into the applet through events. Developers can use these events to handle the completion of each stage of the applet. business logic. At the same time, the virtual DOM is used inside the framework to process each update of the page, which improves the rendering performance of the page.

Below the front-end framework is the applet Native engine, including the applet container, rendering engine, and JavaScript engine. This part mainly combines the client-side Native capabilities with the front-end framework to provide developers with an interface for the underlying capabilities of the system. .

On the rendering engine , the FinClip  applet not only provides JavaScript + WebView, but also JavaScript + Native. In scenarios with high performance requirements, you can choose the Native rendering mode. The applet open platform provides developers with More R&D support and operation and maintenance support services can help developers develop small programs more efficiently. It also provides IDE, packaging tools, data statistics, performance analysis and many other tools to help developers manage and operate online applet.

In terms of security , the key advantage of the Mini Program platform is that it provides a safe and controllable environment, so that it can safely expose a large number of original capabilities that cannot be exposed to external developers.

The SDK provides a closed security sandbox for business codes, which can effectively prevent the interference of external codes and the risk of data leakage; third-party apps can only start the SDK through the interfaces exposed by the SDK, and the SDK completely controls the data required by the business codes. All external communication of the operating environment and business code can ensure that network communication will not be intercepted and interfered through various mechanisms; the SDK uses an independent browser kernel internally, and the operating environment is completely isolated from the system browser.

In terms of monitoring and logs, the small program open platform system has a complete monitoring system, including log monitoring and system monitoring. The three master and slave computer rooms will be deployed in the same way, which can effectively detect the health status of the service and be used for monitoring and monitoring. The log server will be added to the k8s cluster with corresponding tags to run the monitoring system and log system. 

Generally speaking, the creation process of the open platform for small programs draws lessons from the current mainstream WeChat small programs, Alipay small programs and other mature small program technology solutions on the Internet. The entire platform is mainly composed of iOS/Android SDK, basic library & components, The applet management background, enterprise functions, and monitoring and security tools are composed together.

By deploying a whole set of small program technology, the APP realizes the creation of its own light application distribution center (app store). After the ecological structure is built, the introduction of high-quality third-party cooperation faces two problems: 1. How to lower the threshold for third-party cooperation? 2. How to effectively integrate multilateral partners?

Establishing technical standards and unified platform specifications has become an inevitable choice. FinClip helps the platform to establish standards and norms, and integrates multilateral participants to jointly build an open, compliant and controllable mini program ecosystem.

  1. Internal R&D: The open platform provides standard interface specifications and access procedures, etc.
  2. Internal operations: FinClip provides a complete background management system, through which platform operators can be responsible for the operation and management of small programs, such as review, release, and data statistical analysis.
  3. Small program developers: third-party developers can complete small program development, compilation, listing, publishing, and data viewing in the small program management center.

In addition, FinClip supports the grammatical features of mainstream applets. It not only highly supports the operation of wxml WeChat applets, but also supports applets integrated with third-party frameworks such as uniapp, Taro, and kbone. This makes the entry threshold for third parties extremely low, and the existing WeChat mini-program business functions can be directly entered and run without much code modification.

Through the construction of the platform's ecological structure, combined with the needs of the platform's ecological operation, the platform can integrate high-quality third-party small programs, realize the platform construction, cooperative access, hosting distribution, traffic mutual introduction of small program applications, and explore the small program platform with partners The business model further solves the difficulties of user volume and income.

Guess you like

Origin blog.csdn.net/Lydiasq/article/details/129997256