Vector data packet processing software integration method and device and electronic equipment

By deploying the VPP interactive component and SAI implementation library in an open-source network operating system, the integration problem of VPP in the open-source network operating system is solved, unified management and configuration of the data plane is achieved, and an efficient, flexible and scalable network processing platform is built.

CN121658094APending Publication Date: 2026-03-13XINGRONG METADATA TECH (SUZHOU) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-31
Publication Date
2026-03-13

AI Technical Summary

Technical Problem

How to deeply integrate high-performance user-space data plane forwarding software VPP into an open-source network operating system, so as to realize unified management, configuration distribution and status monitoring of the data plane by the operating system, and build an efficient, flexible and scalable network processing platform.

Method used

The interactive components of Vector Packet Processing (VPP), including VPP software and SAI implementation library, are deployed in the first adaptation container of the network operating system. The VPP software is adapted through the SAI implementation library to build the SAI adaptation layer. The VPP platform is then configured according to the platform extension mechanism of the network operating system, and the VPP software is started.

Benefits of technology

It enables the integration of VPP onto the network operating system, reducing dependence on specific vendor switching chips and allowing standard hardware network cards, DPDK network cards, virtual machines, and container systems to run standard network operating systems and perform network packet processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121658094A_ABST
    Figure CN121658094A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an integration method and device of vector data packet processing software and electronic equipment, and relates to the technical field of software development, and the integration method of the vector data packet processing software comprises the following steps: deploying an interaction component of a vector data packet processing VPP in a first adaptation container of a network operation system; the interaction component comprises VPP software and an SAI implementation library based on the VPP software; performing adaptation processing on the VPP software based on the SAI implementation library to obtain an SAI adaptation layer of the VPP software, and constructing a running environment of the VPP software; the SAI adaptation layer is used for converting a command from the SAI interface into a configuration operation of the VPP; and configuring a VPP platform according to a platform extension mechanism of the network operating system, and starting the VPP software based on the operating environment and the VPP platform. According to the invention, the effect of integrating the VPP on the network operating system is realized, so that the network operating system can process the network data packet by managing the VPP.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of software development technology, and in particular to an integration method, apparatus and electronic device for vector data packet processing software. Background Technology

[0002] With the rapid development of cloud computing, big data, and high-performance network applications, higher demands are being placed on the flexibility, compatibility, and data processing efficiency of network operating systems. As the core carrier connecting diverse hardware with upper-layer network functions, open-source network operating systems must possess cross-hardware platform adaptability. Simultaneously, high-performance data plane forwarding has become a key requirement for network processing. User-space data plane forwarding technologies, represented by VPP (Vector Packet Processing), demonstrate significant advantages in improving forwarding performance due to their efficient packet processing mechanism, rich basic network functions (such as switching and routing), and flexible plug-in extension capabilities. As an open-source data plane forwarding software running in user space, VPP provides standard switching and routing basic functions, and its plug-in mechanism allows for easy expansion of related functions. Furthermore, its well-adapted DPDK plug-in supports current mainstream network drivers.

[0003] Therefore, how to deeply integrate high-performance user-space data plane forwarding software (such as VPP) with open-source network operating systems to achieve unified management, configuration distribution, and status monitoring of the data plane by the operating system, and thus combine the advantages of both to build an efficient, flexible, and scalable network processing platform, has become one of the urgent problems to be solved in the current network technology field.

[0004] SAI (Switch Abstraction Interface) is a standardized API designed to provide a unified way to control network switching entities (such as ASICs, NPUs, and switching software) in a vendor-independent manner. By using SAI, network operating systems can ensure simple, consistent, and stable control and operation of hardware or switching software, thereby shifting the focus of the network operating system to providing more integrated network services. Summary of the Invention

[0005] This application provides an integrated method, apparatus, and electronic device for vector data packet processing software to alleviate or solve one or more technical problems existing in the prior art.

[0006] In a first aspect, embodiments of this application provide an integration method for vector data packet processing software, comprising: An interactive component for Vector Packet Processing (VPP) is deployed in the first adaptation container of the network operating system; the interactive component includes: VPP software and a SAI implementation library based on the VPP software; The VPP software is adapted based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software, and the runtime environment of the VPP software is constructed; the SAI adaptation layer is used to convert commands from the SAI interface into configuration operations of the VPP. Configure the VPP platform according to the platform extension mechanism of the network operating system, and start the VPP software based on the operating environment and the VPP platform.

[0007] Secondly, embodiments of this application provide an integrated apparatus for vector data packet processing software, comprising: A deployment module is used to deploy the interactive component of Vector Packet Processing (VPP) in a first adaptation container of the network operating system; the interactive component includes: VPP software and a SAI implementation library based on the VPP software; A construction module is used to adapt the VPP software based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software and build the runtime environment of the VPP software; the SAI adaptation layer is used to convert commands from the SAI interface into configuration operations of the VPP. The startup module is used to configure the VPP platform according to the platform extension mechanism of the network operating system, and to start the VPP software based on the operating environment and the VPP platform.

[0008] Thirdly, embodiments of this application provide an electronic device, including a memory, a processor, and a computer program stored in the memory, wherein the processor implements any of the methods of embodiments of this application when executing the computer program.

[0009] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the method of any one of the embodiments of this application.

[0010] Fifthly, embodiments of this application provide a computer program product, including a computer program, which, when executed by a processor, implements any of the methods described in the embodiments of this application.

[0011] According to the technical solution of this application embodiment, an interactive component for Vector Packet Processing (VPP) is deployed in a first adaptation container of the network operating system. This interactive component includes VPP software and a SAI implementation library based on the VPP software. The VPP software is adapted using the SAI implementation library to obtain a SAI adaptation layer for the VPP software, and a runtime environment for the VPP software is constructed. The SAI adaptation layer is used to convert commands from the SAI interface into VPP configuration operations. The VPP platform is configured according to the platform extension mechanism of the network operating system, and the VPP software is started based on the runtime environment and the VPP platform. This achieves the effect of integrating VPP onto the network operating system, thereby freeing the network operating system from dependence on specific vendors' switching chips. Furthermore, due to the characteristics of VPP, servers with standard hardware network cards, DPU network cards that can run DPDK, virtual machines based on virtual network cards, container systems, etc., can all run standard network operating systems, enabling the network operating system to manage network packet processing through VPP.

[0012] The above description is only an overview of the technical solution of this application. In order to better understand the technical means of this application, it can be implemented according to the contents of the specification. In order to make the above and other objects, features and advantages of this application more obvious and understandable, specific embodiments of this application are given below. Attached Figure Description

[0013] In the accompanying drawings, unless otherwise specified, the same reference numerals throughout the various drawings denote the same or similar parts or elements. These drawings are not necessarily drawn to scale. It should be understood that these drawings depict only some embodiments according to this application and should not be construed as limiting the scope of this application.

[0014] Figure 1 A flowchart illustrating the integration method of the vector data packet processing software provided in an embodiment of this application is shown; Figure 2 This application illustrates a standard system architecture diagram of SONiC provided in an embodiment. Figure 3 This paper illustrates a system architecture diagram of SONiC with integrated VPP provided in an embodiment of this application; Figure 4 A system architecture diagram of SONiC with integrated VPP provided in another embodiment of this application is shown; Figure 5 A flowchart of the VPP initialization method provided in an embodiment of this application is shown; Figure 6 A block diagram of an integrated apparatus for vector packet processing software provided in an embodiment of this application is shown; Figure 7A block diagram of an electronic device provided in an embodiment of this application is shown. Detailed Implementation

[0015] In the following description, only certain exemplary embodiments are briefly described. As those skilled in the art will recognize, the described embodiments can be modified in various ways without departing from the concept or scope of this application. Therefore, the drawings and description are considered to be exemplary in nature and not restrictive.

[0016] To facilitate understanding of the technical solutions of the embodiments of this application, the relevant technologies of the embodiments of this application are described below. The following relevant technologies are optional solutions and can be combined with the technical solutions of the embodiments of this application in any way, and all of them fall within the protection scope of the embodiments of this application.

[0017] The technical solution of this application and how it solves the aforementioned technical problems are described in detail below with specific embodiments. The listed specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will be described in detail below with reference to the accompanying drawings.

[0018] In one or more embodiments provided in this application, the network operating system can be SONiC (Software for Open Networking in the Cloud). As an open-source network operating system, SONiC supports various network hardware vendors and devices, providing a hardware abstraction layer that enables it to run on various switches and routers. Users only need to select the hardware best suited to their needs. SONiC uses Docker containers to run its various network function modules. Each network function runs in an independent container, and the containers are isolated from each other, reducing the risk of system conflicts and failures. SONiC provides standard methods to support different types of switching chips. However, since VPP is not an ASIC chip but a software-based user-space data plane, it is necessary to solve how SONiC communicates with the VPP software and manages its configuration. Furthermore, since non-specific hardware products can run on various different hardware, even virtual machines or containers, integrating VPP into SONiC requires compatibility with different port types and numbers. Moreover, SAI provides SONiC with a hardware abstraction layer and a unified programming interface for operating different ASIC chips, so a VPP-based SAI implementation framework is required. To address these issues, embodiments of this application provide an integration method for vector data packet processing software, which will be described in detail below.

[0019] Figure 1A flowchart illustrating the integration method of the vector packet processing software provided in this application embodiment is shown, such as... Figure 1 As shown, the method may include steps S101, S102 and S103.

[0020] Step S101: Deploy the interaction component of Vector Packet Processing (VPP) in the first adaptation container of the network operating system; the interaction component includes: VPP software and SAI implementation library based on VPP software.

[0021] Step S102: Adapt the VPP software based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software, and build the VPP software's runtime environment; the SAI adaptation layer is used to convert commands from the SAI interface into VPP configuration operations.

[0022] Step S103: Configure the VPP platform according to the platform extension mechanism of the network operating system, and start the VPP software based on the operating environment and the VPP platform.

[0023] According to the technical solution of this application embodiment, an interactive component for Vector Packet Processing (VPP) is deployed in a first adaptation container of the network operating system. This interactive component includes VPP software and a SAI implementation library based on the VPP software. The VPP software is adapted using the SAI implementation library to obtain a SAI adaptation layer for the VPP software, and a runtime environment for the VPP software is constructed. The SAI adaptation layer is used to convert commands from the SAI interface into VPP configuration operations. The VPP platform is configured according to the platform extension mechanism of the network operating system, and the VPP software is started based on the runtime environment and the VPP platform. This achieves the effect of integrating VPP onto the network operating system, thereby freeing the network operating system from dependence on specific vendors' switching chips. Furthermore, due to the characteristics of VPP, servers with standard hardware network cards, DPU network cards that can run DPDK, virtual machines based on virtual network cards, container systems, etc., can all run standard network operating systems, enabling the network operating system to manage network packet processing through VPP.

[0024] In some embodiments, the first adapter container in the standard system architecture of SONiC is first modified to enable the first adapter container to manage and run VPP. Figure 2 The standard system architecture of SONiC is shown, in which the first adapter container is a "synced container". It can be seen that the first adapter container is pre-configured with an SDK (Software Development Kit) and a SAI interface for interacting with the SDK. Figure 2Specifically, this manifests as follows: the container "syncd container" is configured with the ASIC SDK and SAI API. Optionally, when deploying the VPP interactive components in the first adaptation container of the network operating system, the following steps A1, A2, and A3 are executed: Step A1: Replace the SAI interface in the first adapter container with the SAI implementation library.

[0025] Step A2: Replace the SDK in the first adapter container with the VPP software.

[0026] Step A2: Connect the physical network interface of the network operating system through the first plugin of VPP, and create a virtual network interface through the second plugin of VPP; the physical network interface and / or the virtual network interface are used to transmit relevant data of VPP.

[0027] For example, Figure 2 Replace the SAI interface "sai api" configured in the "syncd container" shown with an SAI implementation library, such as Libvppsai. Figure 2 The "asic sdk" configured in the "syncd container" shown is replaced with VPP software. Afterwards, VPP takes over the control of physical network interfaces (such as hardware NICs) or virtual network interfaces (such as virtual NICs). Figure 3 The modified SONiC system architecture is shown.

[0028] Because the VPP software needs to run within a "synced container," VPP takes over the relevant NIC devices in the system through plugins (such as DPDK). Simultaneously, VPP uses its built-in linux_cp_plugin to create corresponding Tap / Tun network devices for the NIC devices on the SONiC system kernel side for uploading relevant network control packets, such as... Figure 4 As shown.

[0029] In some embodiments, when adapting VPP software based on the SAI implementation library to obtain the SAI adaptation layer of VPP software and constructing the runtime environment of VPP software, the following steps B1, B2, and B3 are executed: Step B1 involves using a specified programming language and configuring multiple class structures based on the SAI implementation library to implement the SAI adaptation layer. The multiple class structures include: SAI interface base class, SAI interface implementation class, device status management class, and communication base class.

[0030] The specified programming language can be C++.

[0031] Step B1: Compile VPP independently and package the compiled VPP into a VPP installation package; compile the SAI interface independently and package the compiled SAI interface into a SAI installation package.

[0032] Step B1: Add the dependency files for the VPP and SAI installation packages to the network operating system.

[0033] The sonic-sairedis compilation depends on the dynamic link library generated by SAI VPP (i.e., SAI based on VPP), and the SAI VPP compilation depends on VPP. Compile VPP and SAI VPP independently, then package them into a deb installer. Add the dependency files for VPP and SAI VPP to sonic-sairedis.

[0034] In this embodiment, the implementation of the SAI adaptation layer needs to consider two aspects: the implementation framework of the SAI interface itself and how to communicate with VPP. The VPP API defines a set of control plane and RPC interfaces for interaction, supporting both shared memory and Unix domain socket communication methods. The implementation of the SAI adaptation layer can rely on the VPP-based API for configuration changes and maintenance of VPP.

[0035] The SAI adapter layer is implemented in C++. It achieves its external functional interface by inheriting from the classes defined in `meta / SaiInterface.h` of the SONiC sonic-sairedis library and implementing all pure virtual functions within them. The SAI adapter layer implements its own SAI class by inheriting the `meta / SaiInterface.h` interface.

[0036] In some embodiments, the class structure includes a SAI interface base class. When configuring the SAI interface base class based on the SAI implementation library, it can be inherited from the SAI interface base class defined in the network operating system as the external public interface of the VPP. The external public interface is used to perform at least one of the following services: initializing the SAI adapter layer, reading the configuration file of the SAI adapter layer, and initializing the relevant resources of the SAI adapter layer.

[0037] The base class for the SAI interface is represented as `Class Sai: public sairedis::SaiInterface`. The public interface of the VPP can be implemented by inheriting from `Class sairedis::SaiInterface` in `meta / SaiInterface.h`. It is mainly used to initialize the SAI interface, read the SAI configuration file, and initialize related resources based on the configuration file.

[0038] In some embodiments, the class structure includes SAI interface implementation classes. When configuring SAI interface implementation classes based on the SAI implementation library, the external public interface of VPP can be used, and the SAI interface implementation classes can be initialized based on the configuration file of the SAI adapter layer; the configuration file predefines multiple running modes of the SAI interface implementation classes.

[0039] The SAI adaptation layer is based on the VPP interface implementation. The SAI implementation library initializes VppSwitchSaiInterface (i.e., the SAI interface implementation class) based on the configuration file. This method can easily implement different modes of SAI VPP through the configuration file.

[0040] In some embodiments, the class structure includes SAI interface implementation classes. When configuring SAI interface implementation classes based on the SAI implementation library, the SAI interface implementation classes can be initialized in response to a call to a specific instance of the SAI adapter layer, through the initialization executor of that specific instance, or by inheriting a subclass of the SAI interface implementation class.

[0041] The specific instance can be `SAI create_switch` (i.e., the creation switch instance of the SAI adaptation layer). When `SAI create_switch` is called, `VppSwitchStateBase` is initialized through the `init_switch` method, or it can be a subclass of `VppSwitchStateBase`. The `init_switch` method is used to initialize `SAI create_switch`. This approach facilitates rapid development and adaptation for specific hardware or specific VPP extensions.

[0042] In some embodiments, the device state management class is represented as Class VppSwitchState, which provides public methods and properties with concrete implementations for the SAI VPP.

[0043] In some embodiments, a class structure `Class VppSwitchStateBase:VppSwitchState` is constructed. SAIVPP, based on `VppSwitchState`, adds a SAI implementation class adapted to the standard VPP, containing standard L2 / L3 layer implementations based on VPP. If there are devices with specific hardware, features, or different feature sets, adaptation to new devices or specific feature sets can be quickly achieved by inheriting the `VppSwitchStateBase` subclass. During instance initialization, communication with VPP is established via the VPP API.

[0044] In some embodiments, the communication base class is represented as Vppxlate, which is the library in SAI VPP responsible for communicating with VPP. It can be compared to the SDK provided by the chip manufacturer. Vppxlate communicates with VPP through the VPP-based API.

[0045] In some embodiments, when the VPP software is started based on the operating environment and VPP platform, the following steps C1, C2, and C3 are executed: Step C1: Configure the process management tool in the VPP platform to initialize the VPP software.

[0046] Step C2: Configure the startup template file in the VPP platform, and generate the startup configuration file of the VPP software based on the startup template file and the initialization environment variables of the VPP software; the startup template file includes the parameters required to start the VPP software.

[0047] Step C3: Start the first adapter container based on the startup configuration file, and use the first adapter container to start the VPP software.

[0048] In this embodiment, SONiC provides a standard mechanism for adding platforms. For VPP, simply add the VPP platform according to the standard. For different hardware, such as virtual machines, servers, or specific hardware, simply add the corresponding sub-platform to the VPP platform. Common issues that need to be addressed for the VPP platform include: which ports need to be bound to VPP for operation, VPP startup configuration file generation, how netdev binds to DPDK, and how to rebind to the kernel.

[0049] The startup of the container "docker-syncd" in the VPP platform is managed by supervisord, so an additional process management tool (such as the supervisord program) is required to initialize VPP.

[0050] In addition, a template file, VPP_startup.conf.tmpl, is added. This template file will generate the final VPP startup configuration file based on the relevant environment variables through the VPP initialization program.

[0051] Optionally, the environment variables required by VPP_init.sh are generated when the container "syncd container" starts. SONiC starts the syncd container through the syncd.service service. Modifications to syncd.service are needed to ensure the generation of the environment variables required by VPP_init.sh. The template file for syncd.service is located at files / build_templates / per_namespace / syncd.service.j2; add logic for handling sonic-asic-platform as VPP during startup.

[0052] Figure 5 A flowchart of the VPP initialization method provided in an embodiment of this application is shown. Figure 5 As shown, the VPP initialization method includes the following steps S501 to S505: Step S501: Obtain onie_platform from " / etc / machine.conf" in SONiC.

[0053] Step S502: Determine whether the platform is a VM / server or a specific hardware platform.

[0054] Step S503: Perform relevant differential configurations for the VM / server or specific hardware platform.

[0055] The differential configuration may include at least one of the following: network card driver plugin (using DPDK plugin or specific plugin), VPP BUFFER configuration, port packet sending and receiving queue, number of cores used, feature plugins that need to be loaded, etc.

[0056] Step S504: The port that VPP needs to bind to is obtained from the environment variable VPP_PORTS.

[0057] Step S505: Generate the corresponding VPP startup configuration file.

[0058] Step S506: Start VPP using the VPP startup configuration file.

[0059] In this embodiment, VPP_ports_setup.sh reads environment variables from " / etc / sonic / vpp / syncd_vpp_env" to initialize the devices that need to be managed by VPP. " / etc / sonic / vpp / syncd_vpp_env" is a configuration file that shows which ports need to be bound to VPP for operation. For specific hardware platforms, ports can be manually specified in syncd_vpp_env. For KVM, the required ports can be scanned in syncd_vpp_env, and the corresponding driver or PCI information can be used to determine which ports need to be bound.

[0060] The integration method of the vector data packet processing software provided in this application will be described below with specific embodiments.

[0061] Assuming SONiC+VPP is running on specific hardware, the following actions can be performed during the compilation phase: 1. Add the VPP platform (platform / vpp / ); 2. Add the vpp makefile (rule / vpp.mk) to generate the vpp deb file; 3. You can add a SAI VPP makefile independently, or import SAI VPP in rules / sairedis.mk; 4. Add the vpp_init.sh script to docker-syncd in the vpp platform; 5. Add the hardware platform of the specific manufacturer to the vpp platform, and write a Python script for the standard SONiC platform to obtain information such as power supply, fan, and module. 6. Add the corresponding manufacturer's hardware platform device (device / ); 7. Specify platform_asic as vpp, create the corresponding SKU, set default_sku, and import syncd_vpp_env; 8. Include vpp_ports_setup.sh in file / scripts / and add vpp_ports_setup.sh to files / build_templates / sonic_debian_extension.j2 to package it into the rootfs; 9. Modify files / build_templates / per_namespace / syncd.service.j2 to introduce the processing logic of sonic-asic-platform as vpp.

[0062] Runtime phase: Simply install the compiled sonic-vpp.bin onto the corresponding hardware platform device and run it.

[0063] Assuming SONiC+VPP is running on a virtual machine, the following actions can be performed during the compilation phase: 1. Add the VPP platform (platform / vpp / ); 2. Add the vpp makefile (rule / vpp.mk) to generate the vpp deb file; 3. You can add a SAI VPP makefile independently, or import SAI VPP in rules / sairedis.mk; 4. Add the vpp_init.sh script to docker-syncd in the vpp platform; 5. Change . / device / virtual / x86_64-kvm_x86_64-r0 / platform_asic to vpp; 6. Write a custom VPP-based SKU and add syncd_vpp_env; 7. Modify . / device / virtual / x86_64-kvm_x86_64-r0 / default_sku to a custom VPP-based SKU; 8. Include vpp_ports_setup.sh in file / scripts / and add vpp_ports_setup.sh to files / build_templates / sonic_debian_extension.j2 to package it into the rootfs; 9. Modify files / build_templates / per_namespace / syncd.service.j2 to introduce the processing logic of sonic-asic-platform as vpp.

[0064] Runtime phase: Simply install the compiled sonic-vpp.img.gz image via KVM.

[0065] Corresponding to the application scenarios and methods provided in the embodiments of this application, the embodiments of this application also provide an integrated device for vector data packet processing software.

[0066] Figure 6 A block diagram of an integrated apparatus for vector packet processing software provided in an embodiment of this application is shown, such as... Figure 6 As shown, the integrated apparatus for vector packet processing software includes: Deployment module 61 is used to deploy the interaction component of Vector Packet Processing (VPP) in the first adaptation container of the network operating system; the interaction component includes: VPP software and SAI implementation library based on the VPP software; The construction module 62 is used to adapt the VPP software based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software and build the runtime environment of the VPP software; the SAI adaptation layer is used to convert commands from the SAI interface into configuration operations of the VPP. The startup module 63 is used to configure the VPP platform according to the platform extension mechanism of the network operating system, and to start the VPP software based on the operating environment and the VPP platform.

[0067] In some embodiments, the first adapter container is pre-configured with a software development kit (SDK) and a SAI interface for interacting with the SDK; When the deployment module 61 deploys the vector packet processing VPP interaction component in the first adaptation container of the network operating system, it performs the following steps: Replace the SAI interface in the first adaptation container with the SAI implementation library; Replace the SDK in the first adapter container with the VPP software; The physical network interface of the network operating system is connected through the first plugin of the VPP, and a virtual network interface is created through the second plugin of the VPP; the physical network interface and / or the virtual network interface are used to transmit relevant data of the VPP.

[0068] In some embodiments, when the construction module 62 performs adaptation processing on the VPP software based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software and constructs the runtime environment of the VPP software, it performs the following steps: The SAI adaptation layer is implemented by using a specified programming language and configuring multiple class structures based on the SAI implementation library; the multiple class structures include: SAI interface base class, SAI interface implementation class, device status management class, and communication base class; The VPP is compiled independently, and the compiled VPP is packaged into a VPP installation package; the SAI interface is compiled independently, and the compiled SAI interface is packaged into a SAI installation package. Add dependency files for the VPP installation package and the SAI installation package to the network operating system.

[0069] In some embodiments, the class structure includes the SAI interface base class; When configuring multiple class structures based on the SAI implementation library, the construction module 62 performs the following steps: The VPP inherits the SAI interface base class defined in the network operating system as its external public interface. The external public interface is used to perform at least one of the following services: initializing the SAI adaptation layer, reading the configuration file of the SAI adaptation layer, and initializing the relevant resources of the SAI adaptation layer.

[0070] In some embodiments, the class structure includes the SAI interface implementation class; When configuring multiple class structures based on the SAI implementation library, the construction module 62 performs the following steps: The SAI interface implementation class is initialized using the external public interface of the VPP and based on the configuration file of the SAI adaptation layer; the configuration file predefines multiple running modes of the SAI interface implementation class.

[0071] In some embodiments, the class structure includes the SAI interface implementation class; When configuring multiple class structures based on the SAI implementation library, the construction module 62 performs the following steps: In response to calling a specific instance of the SAI adaptation layer, the SAI interface implementation class is initialized through the initialization executor of the specific instance, or a subclass of the SAI interface implementation class is inherited.

[0072] In some embodiments, when the startup module 63 starts the VPP software based on the operating environment and the VPP platform, it performs the following steps: Configure a process management tool in the VPP platform to initialize the VPP software using the process management tool; Configure a startup template file in the VPP platform, and generate a startup configuration file for the VPP software based on the startup template file and the initialization environment variables of the VPP software; the startup template file includes the parameters required to start the VPP software; The first adapter container is started based on the startup configuration file, and the VPP software is started using the first adapter container.

[0073] The apparatus according to embodiments of this application deploys an interactive component for Vector Packet Processing (VPP) in a first adaptation container of a network operating system. This interactive component includes VPP software and a SAI implementation library based on the VPP software. The VPP software is adapted using the SAI implementation library to obtain an SAI adaptation layer for the VPP software, and a runtime environment for the VPP software is constructed. The SAI adaptation layer is used to convert commands from the SAI interface into VPP configuration operations. The VPP platform is configured according to the platform extension mechanism of the network operating system, and the VPP software is started based on the runtime environment and the VPP platform. This achieves the effect of integrating VPP onto the network operating system, thereby freeing the network operating system from dependence on specific vendors' switching chips. Furthermore, due to the characteristics of VPP, servers with standard hardware network cards, DPU network cards capable of running DPDK, virtual machines based on virtual network cards, container systems, etc., can all run standard network operating systems, enabling the network operating system to manage network packet processing through VPP.

[0074] The functions of each module in each device in the embodiments of this application can be found in the corresponding description in the above method, and they have corresponding beneficial effects, which will not be repeated here.

[0075] Figure 7 This is a block diagram for implementing the electronic device provided in the embodiments of this application. Figure 7 As shown, the electronic device includes a memory 701 and a processor 702. The memory 701 stores a computer program that can run on the processor 702. When the processor 702 executes the computer program, it implements the method described in the above embodiments. The number of memories 701 and processors 702 can be one or more. In a specific implementation, the electronic device may also include a communication interface 703 for communicating with external devices and performing data exchange and transmission.

[0076] In practical implementation, if the memory 701, processor 702, and communication interface 703 are implemented independently, they can be interconnected via a bus to communicate with each other. This bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 7The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0077] Optionally, in a specific implementation, if the memory 701, processor 702, and communication interface 703 are integrated on a single chip, the memory 701, processor 702, and communication interface 703 can communicate with each other through an internal interface.

[0078] This application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method provided in this application.

[0079] This application provides a computer program product, including a computer program that, when executed by a processor, implements the method provided in this application.

[0080] This application also provides a chip including a processor for calling and executing instructions stored in a memory, causing a communication device with the chip installed to perform the method provided in this application.

[0081] This application also provides a chip, including: an input interface, an output interface, a processor, and a memory. The input interface, output interface, processor, and memory are connected through an internal connection path. The processor is used to execute code in the memory. When the code is executed, the processor is used to execute the method provided in the application embodiment.

[0082] It should be understood that the aforementioned processor can be a Central Processing Unit (CPU), or other general-purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field-Programmable Gate Arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. General-purpose processors can be microprocessors or any conventional processor. It is worth noting that the processor can be a processor supporting Advanced Reduced Instruction Set Machines (ARM) architecture.

[0083] Further, optionally, the aforementioned memory may include read-only memory and random access memory. The memory may be volatile memory or non-volatile memory, or may include both. Non-volatile memory may include read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory may include random access memory (RAM), which serves as an external cache. By way of example, but not limitation, many forms of RAM are available. Examples include Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDR SDRAM), Enhanced Synchronous DRAM (ESDRAM), Sync Link DRAM (SLDRAM), and Direct Rambus RAM (DR RAM).

[0084] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. A computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions according to this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another.

[0085] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of those different embodiments or examples.

[0086] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "a plurality of" means two or more, unless otherwise explicitly specified.

[0087] Any process or method described in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process. Furthermore, the scope of the preferred embodiments of this application includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functionality involved.

[0088] The logic and / or steps described in the flowchart or otherwise herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus or device (such as a computer-based system, a processor-included system or other system that can fetch and execute instructions from, an instruction execution system, apparatus or device).

[0089] It should be understood that various parts of this application can be implemented using hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented using software or firmware stored in memory and executed by a suitable instruction execution system. All or part of the steps of the methods in the above embodiments can be implemented by a program instructing related hardware, the program being stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiments.

[0090] Furthermore, the functional units in the various embodiments of this application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into a module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. This storage medium can be a read-only memory, a disk, or an optical disk, etc.

[0091] The above description is merely an exemplary embodiment of this application, but the scope of protection of this application is not limited thereto. Any person skilled in the art can easily conceive of various variations or substitutions within the technical scope described in this application, and these should all be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. An integration method for vector data packet processing software, characterized in that, include: Deploy the interactive components of the Vector Packet Processing VPP in the first adaptation container of the network operating system; The interactive components include: VPP software and a SAI implementation library based on the VPP software; The VPP software is adapted based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software, and the runtime environment of the VPP software is constructed; the SAI adaptation layer is used to convert commands from the SAI interface into configuration operations of the VPP. Configure the VPP platform according to the platform extension mechanism of the network operating system, and start the VPP software based on the operating environment and the VPP platform.

2. The method according to claim 1, characterized in that, The first adapter container is pre-configured with a software development kit (SDK) and an SAI interface for interacting with the SDK; The interactive component for deploying the Vector Packet Processing (VPP) in the first adaptation container of the network operating system includes: Replace the SAI interface in the first adaptation container with the SAI implementation library; Replace the SDK in the first adapter container with the VPP software; The physical network interface of the network operating system is connected through the first plugin of the VPP, and a virtual network interface is created through the second plugin of the VPP; the physical network interface and / or the virtual network interface are used to transmit relevant data of the VPP.

3. The method according to claim 1, characterized in that, The process of adapting the VPP software based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software and constructing the runtime environment of the VPP software includes: The SAI adaptation layer is implemented by using a specified programming language and configuring multiple class structures based on the SAI implementation library; the multiple class structures include: SAI interface base class, SAI interface implementation class, device status management class, and communication base class; The VPP is compiled independently, and the compiled VPP is packaged into a VPP installation package; the SAI interface is compiled independently, and the compiled SAI interface is packaged into a SAI installation package. Add dependency files for the VPP installation package and the SAI installation package to the network operating system.

4. The method according to claim 3, characterized in that, The class structure includes the SAI interface base class; The configuration of multiple class structures based on the SAI implementation library includes: The SAI interface base class defined in the network operating system is inherited as the public interface of the VPP. The external public interface is used to perform at least one of the following services: initializing the SAI adaptation layer, reading the configuration file of the SAI adaptation layer, and initializing the relevant resources of the SAI adaptation layer.

5. The method according to claim 4, characterized in that, The class structure includes the SAI interface implementation class; The configuration of multiple class structures based on the SAI implementation library includes: The SAI interface implementation class is initialized using the external public interface of the VPP and based on the configuration file of the SAI adaptation layer; the configuration file predefines multiple running modes of the SAI interface implementation class.

6. The method according to claim 3, characterized in that, The class structure includes the SAI interface implementation class; The configuration of multiple class structures based on the SAI implementation library includes: In response to calling a specific instance of the SAI adaptation layer, the SAI interface implementation class is initialized through the initialization executor of the specific instance, or a subclass of the SAI interface implementation class is inherited.

7. The method according to claim 2, characterized in that, The step of starting the VPP software based on the operating environment and the VPP platform includes: Configure a process management tool in the VPP platform to initialize the VPP software using the process management tool; Configure a startup template file in the VPP platform, and generate a startup configuration file for the VPP software based on the startup template file and the initialization environment variables of the VPP software; the startup template file includes the parameters required to start the VPP software; The first adapter container is started based on the startup configuration file, and the VPP software is started using the first adapter container.

8. An integrated apparatus for vector data packet processing software, characterized in that, include: The deployment module is used to deploy the interactive components of the Vector Packet Processing VPP in the first adaptation container of the network operating system; The interactive components include: VPP software and a SAI implementation library based on the VPP software; A construction module is used to adapt the VPP software based on the SAI implementation library to obtain the SAI adaptation layer of the VPP software and build the runtime environment of the VPP software; the SAI adaptation layer is used to convert commands from the SAI interface into configuration operations of the VPP. The startup module is used to configure the VPP platform according to the platform extension mechanism of the network operating system, and to start the VPP software based on the operating environment and the VPP platform.

9. An electronic device, characterized in that, It includes a memory, a processor, and a computer program stored in the memory, wherein the processor, when executing the computer program, implements the method of any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method of any one of claims 1 to 7.