Data processing method, proxy device and related device
By decoupling data pull, intermediate business logic conversion and data issuance in the proxy device, the problems of poor adaptability and high development costs of SDN proxy devices when adapting to different data sources and network elements are solved, and a higher level of development is achieved adaptability and lower development costs.
Patent Information
- Application Number
- CN202310627636.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-30
- Publication Date
- 2024-12-03
AI Technical Summary
When existing SDN proxy devices adapt to different data sources and network elements, they require a lot of additional development, resulting in poor adaptability and high development costs.
By decoupling the internal data pull, intermediate business logic conversion and data distribution of the proxy device, blocking the differences between different data sources and network elements, you only need to modify the data pull or data distribution part of the code to avoid modifying the entire proxy The device's code.
Improves the adaptability of proxy devices, reduces the additional development of a large amount of code, and reduces development costs.
Smart Images

Figure CN119071356A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer and network communication technology, and in particular to a data processing method, proxy equipment and related devices. Background Art
[0002] In recent years, Software Defined Network (SDN) technology has been widely used in various fields and in various user networks. As the brain of the network, the SDN controller can control a variety of network elements that can complete specific traffic forwarding or services.
[0003] The SDN controller's control over network elements can include the delivery of network configurations to network elements. Currently, the delivery of network configurations can be achieved through the agent device in the SDN controller. Specifically, SDN includes various network elements, each of which implements a specific agent. The agent pulls the original data from the data source through middleware or other means, and then translates the original data into data that can be recognized by the network element to complete the configuration delivery.
[0004] However, the Agent may be connected to multiple data sources or multiple network elements. In order to complete the configuration and delivery to specific network elements in various environments, even if the data source is the same, but the network elements are different, an Agent needs to be rewritten for adaptation. If the data source is different, even if the network elements are the same, a new Agent needs to be re-implemented to adapt the data source. This results in poor adaptability of the Agent when adapting network elements or data sources, requiring a lot of additional development and consuming a lot of additional costs. Summary of the invention
[0005] In order to solve the above technical problems, the present application provides a data processing method, an agent device and related apparatus, which improve the adaptability of the agent device, reduce the additional development of a large amount of code, and reduce the development cost.
[0006] The embodiments of the present application disclose the following technical solutions:
[0007] On the one hand, an embodiment of the present application provides a data processing method, the method comprising:
[0008] When it is detected that the configuration delivery conditions are met, a target proxy device corresponding to the target network element is determined;
[0009] Pulling original data of the target configuration type from the data source through the target proxy device;
[0010] The target proxy device converts the original data into a unified receiving object, wherein the original data from different data sources correspond to the same object interface of the unified receiving object;
[0011] The target proxy device performs service conversion on the unified receiving object to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same;
[0012] The unified return object is converted into target data through the target proxy device, and the target data is sent to the target network element, where the target data is used to configure the target configuration type for the target network element.
[0013] On the one hand, an embodiment of the present application provides a proxy device, the proxy device includes at least one extension component, one extension component corresponds to one configuration type, and one extension component is decoupled into multiple components, the multiple components include a data pulling module, a resource processing module and a data sending module:
[0014] The data pulling module is used to pull the original data of the corresponding configuration type from the data source and convert the original data into a unified receiving object. The object interface of the unified receiving object corresponding to the original data from different data sources is the same;
[0015] The resource processing module is used to receive the unified receiving object sent by the data pulling module, and perform service conversion on the unified receiving object to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same;
[0016] The data sending module is used to receive the unified return object sent by the resource processing module, convert the unified return object to obtain target data, and send the target data to the corresponding network element, and the target data is used to configure the corresponding network element with the corresponding configuration type.
[0017] On the one hand, an embodiment of the present application provides a data processing device, the device comprising a determination unit, a pulling unit, a conversion unit and a sending unit:
[0018] The determining unit is used to determine the target proxy device corresponding to the target network element when it is detected that the configuration delivery condition is met;
[0019] The pulling unit is used to pull original data of a target configuration type from a data source through the target proxy device;
[0020] The conversion unit is used to convert the original data into a unified receiving object through the target proxy device, and the object interface of the unified receiving object corresponding to the original data from different data sources is the same;
[0021] The conversion unit is further used to perform service conversion on the unified receiving object through the target proxy device to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same;
[0022] The conversion unit is further used to convert the unified return object into target data through the target proxy device;
[0023] The sending unit is used to send the target data to the target network element, and the target data is used to configure the target configuration type for the target network element.
[0024] In one aspect, an embodiment of the present application provides a computer device, the computer device comprising a processor and a memory:
[0025] The memory is used to store a computer program and transmit the computer program to the processor;
[0026] The processor is configured to execute the method described in any one of the preceding aspects according to instructions in the computer program.
[0027] On the one hand, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium is used to store a computer program, and when the computer program is executed by a processor, the processor executes the method described in any of the aforementioned aspects.
[0028] In one aspect, an embodiment of the present application provides a computer program product, including a computer program, which implements the method described in any of the aforementioned aspects when executed by a processor.
[0029] It can be seen from the above technical solution that when using a proxy device, the present application decouples the data pulling, intermediate business logic conversion and data delivery performed inside the proxy device. Specifically, when it is detected that the configuration delivery conditions are met, the target proxy device corresponding to the target network element is determined, so that the target proxy device is used to deliver the configuration to the target network element. The target proxy device pulls the original data of the target configuration type from the data source (i.e., data pulling), and then converts the original data into a unified receiving object through the target proxy device. The object interface of the unified receiving object corresponding to the original data from different data sources is the same, and the target proxy device performs business conversion on the unified receiving object to obtain a unified return object. The object interface of the unified return object corresponding to different network elements is the same (i.e., intermediate business logic conversion), thereby shielding the differences between different data sources and different network elements from the intermediate business conversion logic. Finally, the unified return object is converted into target data through the target proxy device, and the target data is delivered to the target network element (i.e., data delivery), so that the target network element is configured with the target data for the target configuration type. Since the input of the intermediate business conversion logic is a unified receiving object and the output is a unified return object, the differences between different data sources and different network elements are shielded. In this way, when the data sources or network elements are different, it is only necessary to adaptively modify the partial code of data pulling or data sending of the target proxy device. There is no need to modify the intermediate business conversion logic, and thus there is no need to modify the code of the entire proxy device, which improves the adaptability of the proxy device, reduces a large amount of additional code development, and reduces development costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technical members in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0031] Figure 1 Architecture diagram of proxy devices provided for related technologies;
[0032] Figure 2 An application scenario architecture diagram of a data processing method provided in an embodiment of the present application;
[0033] Figure 3 A flowchart of a data processing method provided in an embodiment of the present application;
[0034] Figure 4 An example diagram of the internal module interaction of an extension component provided in an embodiment of the present application;
[0035] Figure 5A signaling interaction diagram for data filtering provided in an embodiment of the present application;
[0036] Figure 6 An example diagram of arranging different proxy devices through a device editor provided in an embodiment of the present application;
[0037] Figure 7 An example diagram of arranging different extension components through a component manager provided in an embodiment of the present application;
[0038] Figure 8 An architecture diagram of a proxy device provided in an embodiment of the present application;
[0039] Fig. 9 A structural diagram of a data processing device provided in an embodiment of the present application;
[0040] Fig.10 A structural diagram of a terminal provided in an embodiment of the present application;
[0041] Fig.11 A structural diagram of a server provided in an embodiment of the present application. DETAILED DESCRIPTION
[0042] The embodiments of the present application are described below in conjunction with the accompanying drawings.
[0043] In the related art, the network configuration can be delivered through the agent device in the SDN controller. Figure 1 As shown, SDN includes various network elements, such as Linux Virtual Server (lvs), virtual switching software (Open vSwitch, ovs), HAProxy (a free and open source software written in C language), DNSmasq (a small and convenient tool for configuring DNS and DHCP, suitable for small networks). Each network element will implement a specific Agent, which pulls the original data from the data source through middleware or other means, and then converts it through certain business logic, translating the original data into data that can be recognized by the network element, and completing the configuration delivery (that is, completing the traffic programming of the network element).
[0044] It should be noted that many network architectures are arranged vertically from top to bottom, with data sources placed at the top and network elements at the bottom. According to the principle of north at the top and south at the bottom, the direction of the data source can be called northbound, so the original data obtained from the data source can be called northbound data, that is, the upstream data connected to the data source, and the data source can also be called northbound data source; correspondingly, the direction of the network element can be called southbound, so the data used to identify the network element can be called southbound data, that is, the data connected to the network element, and the network element can also be called a southbound network element.
[0045] Since the Agent may be connected to multiple data sources, for example Figure 1 In the case of databases (DataBase, DB), kafka (a high-throughput distributed publish-subscribe messaging system), rabbitmq (an open source message broker that implements the Advanced Message Queuing Protocol), and distributed application coordination service software (zookeeper), it is also possible that they are connected to multiple network elements. In order to complete the configuration and delivery to specific network elements in each environment, even if the data source is the same, but the network elements are different, an Agent needs to be rewritten for adaptation. If the data source is different, even if the network elements are the same, a new Agent needs to be re-implemented to adapt the data source. For example Figure 1 In the process of developing a new agent, different agents are written, namely l3-Agent, Dynamic Host Configuration Protocol-Agent (dhcp-Agent), lb-Agent, and host-Agent. This results in poor adaptability of the agent when adapting to network elements or data sources, requiring a lot of additional development and consuming a lot of additional costs.
[0046] In order to solve the above technical problems, an embodiment of the present application provides a data processing method, which decouples the data pulling, intermediate business logic conversion and data sending performed within the proxy device, thereby shielding the differences between different data sources and different network elements in the intermediate business conversion logic. In this way, when the data source or network element is different, it is only necessary to adaptively modify part of the data pulling code or part of the data sending code of the target proxy device, and there is no need to modify the intermediate business conversion logic, thereby eliminating the need to modify the code of the entire proxy device, thereby improving the adaptability of the proxy device, reducing a large amount of additional code development, and reducing development costs.
[0047] The method provided in the embodiment of the present application can be applied to scenarios where various proxy devices are used to configure and send network elements, for example, in an SDN network architecture. The data pulling, intermediate business logic conversion, and data sending performed inside the proxy device are decoupled, so that when facing different data sources and network elements, various proxy devices adapted to different data sources and network elements can be developed.
[0048] It should be noted that the configuration and delivery scenarios of network elements are usually used to implement "cloud" network architectures, such as SDN network architectures. Therefore, the methods provided in the embodiments of the present application may involve cloud technology, such as the field of cloud computing. Cloud computing is a computing model that distributes computing tasks across a resource pool consisting of a large number of computers, enabling various application systems to obtain computing power, storage space, and information services as needed. The network that provides resources is called a "cloud". The resources in the "cloud" appear to be infinitely expandable to users, and can be obtained at any time, used on demand, expanded at any time, and paid for on a per-use basis.
[0049] As a provider of basic cloud computing capabilities, a cloud computing resource pool (referred to as a cloud platform, generally referred to as an IaaS (Infrastructure as a Service) platform) will be established, and various types of virtual resources will be deployed in the resource pool for external customers to choose to use. The cloud computing resource pool mainly includes: computing devices (virtualized machines, including operating systems), storage devices, and network devices.
[0050] Types of cloud computing include private cloud, public cloud, and hybrid cloud. Private cloud is a cloud infrastructure and software and hardware resources created within a firewall so that departments within an organization or enterprise can share resources within the data center. In addition to hardware resources, creating a private cloud generally also requires cloud equipment (IaaS, Infrastructure as a Service) software.
[0051] Public Cloud usually refers to a cloud provided by a third-party provider for users to use. Public Cloud is generally available through the Internet and may be free or low-cost. The core attribute of Public Cloud is shared resource services. There are many instances of this cloud, which can provide services throughout the open public network today.
[0052] Hybrid Cloud combines public cloud and private cloud, and is the main model and development direction of cloud computing in recent years. Private cloud is mainly for enterprise users. For security reasons, enterprises are more willing to store data in private cloud, but at the same time hope to obtain computing resources of public cloud. In this case, hybrid cloud is increasingly adopted, which mixes and matches public cloud and private cloud to obtain the best effect. This personalized solution achieves the purpose of saving money and security.
[0053] It should be understood that the method provided in the embodiments of the present application can be executed by a computer device, which may be, for example, a server and / or a terminal. The server may be an independent physical server, or a server cluster or distributed system consisting of multiple physical servers, or a cloud server providing cloud computing services. The terminal may be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, a car terminal, a smart TV, etc., but is not limited thereto. The terminal and the server may be directly or indirectly connected via wired or wireless communication, which is not limited in this application.
[0054] The following uses the computer device being a server as an example to introduce the application scenario architecture of the data processing method provided in the embodiment of the present application. Figure 2 As shown, Figure 2 An application scenario architecture diagram of a data processing method is shown. The application scenario may include a server 100, multiple network elements (e.g., network element 1, network element 2, ...) and multiple proxy devices (e.g., proxy device 1, proxy device 2, ...). In the SDN network architecture, the server 100 can be used as a virtual network controller (SDN controller) in the SDN network architecture to program the network elements, thereby realizing specific traffic service logic.
[0055] When using a proxy device, the present application decouples the data pulling, intermediate business logic conversion, and data delivery performed within the proxy device. Specifically, when the server 100 detects that the configuration delivery conditions are met, that is, configuration delivery is required, the target proxy device (e.g., proxy device 1) corresponding to the target network element (e.g., network element 1) can be determined, so that the target proxy device is used to deliver the configuration to the target network element. Among them, the target network element is the network element that needs to be delivered, and the target proxy device is a proxy device used to deliver the configuration to the target network element.
[0056] The server 100 pulls the original data of the target configuration type from the data source through the target proxy device (i.e., data pulling). The original data can also be called northbound data. Then, the original data is converted into a unified receiving object through the target proxy device. The object interface of the unified receiving object corresponding to the original data from different data sources is the same. The unified receiving object is converted into a unified return object through the target proxy device. The object interface of the unified return object corresponding to different network elements is the same (i.e., intermediate business logic conversion), thereby shielding the differences between different data sources and different network elements from the intermediate business conversion logic. Finally, the unified return object is converted into target data (the target object can also be called southbound data) through the target proxy device, and the target data is sent to the target network element (i.e., data sending), so as to configure the target network element with the target configuration type using the target data.
[0057] Since the input of the intermediate business conversion logic is a unified receiving object and the output is a unified return object, the differences between different data sources and different network elements are shielded. In this way, when the data sources or network elements are different, it is only necessary to adaptively modify the partial code of data pulling or data sending of the target proxy device. There is no need to modify the intermediate business conversion logic, and thus there is no need to modify the code of the entire proxy device, which improves the adaptability of the proxy device, reduces a large amount of additional code development, and reduces development costs.
[0058] Next, the data processing method provided in the embodiment of the present application will be described in detail by taking the server executing the method provided in the embodiment of the present application as an example in conjunction with the accompanying drawings. Figure 3 , Figure 3 A flow chart of a data processing method is shown, the method comprising:
[0059] S301: When it is detected that a configuration delivery condition is met, a target proxy device corresponding to a target network element is determined.
[0060] In the network architecture, there may be various network elements, each of which implements a specific proxy device. When configuration delivery is required, the configuration delivery can be completed through the proxy device. In the embodiment of the present application, it can be detected whether the configuration delivery conditions are met. Usually, the situation where configuration delivery is required may be the restart of the network element, or new data generated during the operation of the network architecture needs to be updated to the network element. Based on this, the configuration delivery condition may be the restart of the network element or the generation of new data that needs to be updated to the network element.
[0061] When different configuration delivery conditions are met, the target network element may be different. If the configuration delivery condition is that the network element is restarted, the target network element may be the restarted network element; if the configuration delivery condition is that new data needs to be updated to the network element, the target network element may be the network element corresponding to the new data.
[0062] Based on this, since each network element has a corresponding proxy device, it is also necessary to determine the proxy device corresponding to the target network element as the target proxy device, so as to implement the configuration delivery of the target network element.
[0063] S302: Pull original data of the target configuration type from a data source through the target proxy device.
[0064] After the target proxy device is determined, the target proxy device can complete the configuration and distribution of the target network element. Specifically, the target proxy device can pull the original data of the target configuration type from the data source. A network element can usually support at least one service. Accordingly, in order to support different services, the network element also needs to complete the configuration of the corresponding configuration type. The configuration type may include, for example, virtual private cloud (VPC), rtable, subnet, route, etc. The target configuration type may be the configuration type that needs to be configured for the target network element.
[0065] It should be noted that the target configuration type may also be different depending on the configuration delivery conditions. For example, if the configuration delivery condition is the restart of the network element, the target configuration type may be all configuration types that the target network element needs to complete to support different services, and the original data may be full data; if the configuration delivery condition is the generation of new data that needs to be updated to the network element, the target configuration type may be the configuration type corresponding to the new data, and the original data may be incremental data.
[0066] It is understandable that the data source usually includes a lot of data, some of which are required to complete the configuration and distribution of the target network element, while some data may not be required by the target network element. In this case, in order to cope with the filtering support of the southbound network element for the northbound data source, the method of pulling the original data of the target configuration type from the data source through the target proxy device can be based on the filtering parameters, and the target proxy device can filter the source data in the data source to obtain the original data that meets the preset conditions, and then pull the original data. Among them, the preset conditions can be conditions that meet the data requirements of the target network element, the filtering parameters can reflect the data requirements of the target network element, and the filter implemented based on the filtering parameters can be used to filter the source data in the data source to obtain the original data that meets the preset conditions.
[0067] S303: Convert the original data into a unified receiving object through the target proxy device, and the object interface of the unified receiving object corresponding to the original data from different data sources is the same.
[0068] S304: Performing service conversion on the unified receiving object through the target proxy device to obtain a unified return object, wherein the object interface of the unified return object corresponding to different network elements is the same.
[0069] In order to simplify the implementation of the proxy device, the embodiment of the present application decouples the data pulling, intermediate business logic conversion and data distribution performed inside the proxy device. When using the proxy device, the intermediate business logic conversion shields the differences between the northbound data (i.e., the original data) and the southbound data (i.e., the target data). In other words, for the intermediate business logic conversion, the data it receives is a unified object, referred to as a unified receiving object, and the data it outputs is also a unified object, referred to as a unified return object. Therefore, after pulling the original data, before performing the intermediate business logic conversion, the original data is first converted to obtain a unified receiving object. The object interface of the unified receiving object corresponding to the original data from different data sources is the same, so that the difference in northbound data is not perceived. Then, the unified receiving object is subjected to business conversion to obtain a unified return object. The object interface of the unified return object corresponding to different network elements is the same, so that the difference in southbound data is shielded.
[0070] S305: Convert the unified return object into target data through the target proxy device, and send the target data to the target network element, where the target data is used to configure the target configuration type for the target network element.
[0071] After obtaining the unified return object, in order to adapt to different network elements, the unified return object can be converted into target data adapted to the target network element through the target proxy device, and the target data can be sent to the target network element so that the target network element can be configured with the target configuration type using the target data.
[0072] It can be seen from the above technical solution that when using a proxy device, the present application decouples the data pulling, intermediate business logic conversion and data delivery performed inside the proxy device. Specifically, when it is detected that the configuration delivery conditions are met, the target proxy device corresponding to the target network element is determined, so that the target proxy device is used to deliver the configuration to the target network element. The target proxy device pulls the original data of the target configuration type from the data source (i.e., data pulling), and then converts the original data into a unified receiving object through the target proxy device. The object interface of the unified receiving object corresponding to the original data from different data sources is the same, and the target proxy device performs business conversion on the unified receiving object to obtain a unified return object. The object interface of the unified return object corresponding to different network elements is the same (i.e., intermediate business logic conversion), thereby shielding the differences between different data sources and different network elements from the intermediate business conversion logic. Finally, the unified return object is converted into target data through the target proxy device, and the target data is delivered to the target network element (i.e., data delivery), so that the target network element is configured with the target data for the target configuration type. Since the input of the intermediate business conversion logic is a unified receiving object and the output is a unified return object, the differences between different data sources and different network elements are shielded. In this way, when the data sources or network elements are different, it is only necessary to adaptively modify the partial code of data pulling or data sending of the target proxy device. There is no need to modify the intermediate business conversion logic, and thus there is no need to modify the code of the entire proxy device, which improves the adaptability of the proxy device, reduces a large amount of additional code development, and reduces development costs.
[0073] It is understandable that the embodiment of the present application mainly uses a proxy device, and the decoupling of data pulling, intermediate business logic conversion and data sending can also be reflected in the composition of the proxy device. Taking the target proxy device as an example, in a possible implementation, the target proxy device can include at least one extension component (which can be called extension), and an extension component is decoupled into multiple components, and the multiple components include a data pulling module (which can be called upstream), a resource processing module (which can be called resource) and a data sending module (which can be called downstream). The target configuration type corresponds to a target extension component in at least one extension component. Based on this, a method for pulling the original data of the target configuration type from the data source through the target proxy device may be to pull the original data from the data source through the data pulling module in the target extension component; a method for converting the original data into a unified receiving object through the target proxy device may be to convert the original data into a unified receiving object through the data pulling module in the target extension component; a method for performing business conversion on the unified receiving object through the target proxy device to obtain a unified return object may be to perform business conversion on the unified receiving object through the resource processing module in the target extension component to obtain a unified return object; a method for converting the unified return object into target data through the target proxy device and sending the target data to the target network element may be to convert the unified return object into target data through the data sending module in the target extension component and send the target data to the target network element.
[0074] In one possible implementation, the data pulling module can be connected to the first driver, and a first driver is connected to a specific data source, so the first driver can be called a northbound driver. The data sending module can be connected to the second driver, and a second driver is connected to a specific network element, so the second driver can be called a southbound driver. Based on this, the method of pulling the original data from the data source through the data pulling module in the target extension component can be to call the first driver through the data pulling module in the target extension component, and pull the original data from the data source through the first driver; the method of sending the target data to the target network element can be to send the target data to the second driver through the data sending module in the target extension component, and send the target data to the target network element through the second driver.
[0075] Specifically, see Figure 4 As shown, Figure 4 An example diagram of the internal module interaction of an extension component is shown. The internal business implementation of the Agent is decomposed into docking with the northbound driver (for example Figure 4 404) of the data pull module (ie, upstream, such as Figure 4 401), connecting to the southbound drive (e.g. Figure 4 405) of the data delivery module (ie, downstream, for example Figure 4 403) and a resource processing module (ie, resource, for example) for central business processing (ie, intermediate business logic conversion) Figure 4 402 in the figure). By assembling upstream, resource and downstream to form an extension, a specific extension can deal with a specific data source and network element. Then different extensions are arranged to form an Agent that can complete a specific business.
[0076] The northbound driver and the southbound driver are general drivers that can be used separately. The northbound driver connects to a specific data source, pulls raw data from the northbound data source, and passes it to the upstream. The upstream converts the raw data into a unified receiving object, sends the unified receiving object to the resource, shields the resource from the differences in northbound data, and allows the resource to adapt to different operating environments by replacing the upstream without re-modification. The resource performs business conversion on the unified receiving object to obtain a unified return object, and passes it to the downstream so that the downstream can convert the unified return object into target data. In addition, the resource can also save the unified receiving object locally. The southbound driver is a driver that connects to the network element, and the caller is the downstream. The southbound driver mainly sends the target data passed by the downstream to the network element (such as the target network element) through the specified protocol and port.
[0077] Among them, upstream can pull raw data through the RemoteGet interface. Correspondingly, resource can also have a RemoteGet interface to call the RemoteGet of upstream to pull raw data. In addition, the RemoteGet interface of upstream and resource can also support registration of whether to monitor incremental data (that is, newly generated data).
[0078] The embodiment of the present application decomposes the internal business implementation of the Agent into an upstream connected to the northbound drive, a downstream connected to the southbound drive, and a resource for central business processing (i.e., intermediate business logic conversion). An extension is formed by assembling upstream, resource, and downstream. A specific extension can handle specific data sources and network elements. Different extensions are then orchestrated to form an Agent that can complete specific services, abstracting the common code logic of the Agent to form a unified Agent framework. Since in each extension, the resource is unaware of the differences between northbound data and southbound data, the resource can adapt to different operating environments by replacing upstream and downstream without re-modification, thereby reducing the duplication of code development and improving code quality due to unified code maintenance.
[0079] In an embodiment of the present application, the data sending module is an abstract layer for connecting to the southbound driver, and the target data sent by the data sending module should be data that conforms to the parameter type supported by the southbound driver. Based on this, in a possible implementation method, the method of converting the unified return object into target data through the data sending module in the target extension component can be to obtain the target parameter type corresponding to the second driver (i.e., the southbound driver), thereby converting the unified return object into target data of the target parameter type. Among them, the target parameter type is the parameter type supported by the second driver.
[0080] Specifically, downstream is an abstract layer for connecting to southbound drivers. Even when connecting to different southbound drivers, the same object interface and parameters are provided for the same resource. For interface features that are not supported by some southbound drivers, downstream will also make corresponding conversions so that the southbound drivers can support them.
[0081] For example, the southbound driver does not support the interface with parameter type "A", and because the conversion of parameter type "A" data has certain business logic, it cannot be directly shielded in the driver layer. Then this type of conversion will be completed by the downstream, which will call the external interface of the resource to convert the same return object into the parameter type supported by the southbound driver, that is, the target parameter type. Here, the target parameter type can be parameter type "A".
[0082] In S302, it is introduced that when pulling the original data, the source data in the data source can be filtered based on the filter parameters. When the target proxy device includes at least one extension component, one extension component is decoupled into multiple components, and the multiple components include a data pulling module, a resource processing module, and a data sending module, and the target configuration type corresponds to the target extension component in at least one extension component, the support of the filter parameters can be allocated to each component. Specifically, in a possible implementation, according to the filter parameters, the source data in the data source is filtered by the target proxy device to obtain the original data that meets the preset conditions. The method can be that the resource processing module of the target extension component obtains the filter parameters from the data sending module of the target extension component, and sends the filter parameters to the data pulling module of the target extension component; according to the filter parameters, the source data in the data source is filtered by the data pulling module to obtain the original data that meets the preset conditions. Among them, the way in which the resource processing module of the target extension component obtains the filtering parameters from the data sending module of the target extension component can be that the resource processing module of the target extension component sends a filtering parameter acquisition request to the data sending module of the target extension component. After receiving the filtering parameter acquisition request, the data sending module of the target extension component obtains the filtering parameters through the device type or other operating environment, and returns the filtering parameters to the resource processing module of the target extension component.
[0083] In the case of filtering, the RemoteGet interface of the data pulling module can also support filtering parameters, so that when pulling raw data, only the raw data that meets the preset conditions can be pulled according to the filtering parameters. Correspondingly, the Get interface of the resource processing module can also support filtering parameters (or filters formed based on filtering parameters), and the Get interface of the data sending module can also support filtering parameters. In addition, since the data sending module is used to connect to the network element, it can be connected to the network element through the second driver (southbound driver) to facilitate the data requirements of the network element. Therefore, the filtering parameters can be obtained from the data sending module. For example, the data sending module can obtain the corresponding filtering parameters supported by the second driver through the GetFilter interface, which is used to filter the pulling of northbound data.
[0084] See also Figure 5 As shown, Figure 5 A signaling interaction diagram of data filtering is shown, where the resource processing module sends a request for obtaining filtering parameters to the data delivery module (see Figure 5 After receiving the request to obtain the filtering parameters, the data delivery module obtains the filtering parameters by device type or other operating environment (see Figure 5 ), and returns the filtering parameters to the resource processing module (see Figure 5 The resource processing module passes the filtering parameters to the data pulling module (see S503). Figure 5 As shown in S504 in the figure, for example, the resource processing module can call the RemoteGet interface of the data pulling module, so that the RemoteGet interface carries the filtering parameters, thereby passing the filtering parameters to the data pulling module. The data pulling module filters the source data in the data source according to the filtering parameters to obtain the original data (see Figure 5 ), and returns the original data to the resource processing module (see Figure 5 (as shown in S506).
[0085] In a possible implementation, in order to realize the orchestration of Agents, so as to obtain Agents adapted to different data sources and network elements, the embodiment of the present application also designs a device editor (composer), in which the extended component set of each Agent can be specified in the composer to obtain device orchestration information, so that according to the device orchestration information, the extended components respectively included in multiple agent devices are loaded through the device editor to obtain agent devices respectively corresponding to multiple network elements, and the device orchestration information is used to indicate the extended component set of different agent devices, the multiple agent devices are agent devices respectively corresponding to multiple network elements, the multiple network elements are network elements included in the target network, and the target network is the network to which the target network element belongs. In this way, the method of determining the target agent device corresponding to the target network element in S301 can be to determine the target agent device from the agent devices respectively corresponding to the multiple network elements.
[0086] For example, if multiple network elements are gateway A and gateway B, and the Agent of gateway A needs two extension components, which are respectively represented by ext_a and ext_b, and the Agent of gateway B needs four extension components, which are respectively represented by ext_a, ext_b, ext_c and ext_d, then the device orchestration information can be obtained by configuring composer, so that the corresponding Agent orchestration can be completed by loading the corresponding extension component on demand through composer, so that complex business logic can be completed through combination while ensuring the closed loop of extension capabilities.
[0087] See also Figure 6As shown, the required extensions are combined through Composer to support gateway agents of different services. For example, the extension component ext_a required by the Agent of gateway A needs to support the configuration type of rtable, then the extension component ext_a includes rtable_upstream (i.e. upstream adapted to the configuration type of rtable), rtable_resource (i.e. resource adapted to the configuration type of rtable), and rtable_downstream (i.e. downstream adapted to the configuration type of rtable), and rtable_upstream has a corresponding northbound driver, and rtable_downstream has a corresponding southbound driver; the extension component ext_b required by gateway A needs to support the configuration type of vpc, then the extension component ext_b includes vpc_upstream (i.e. upstream adapted to the configuration type of vpc), vpc_resource (i.e. resource adapted to the configuration type of vpc), and vpc_downstream (i.e. downstream adapted to the configuration type of vpc), and vpc_upstream has a corresponding northbound driver, and vpc_downstream has a corresponding southbound driver. Then, the device arrangement information of composer should indicate that the corresponding Agent includes the above two extension components. By loading the corresponding extension components, the Agent of gateway A can be obtained (see Figure 6 (as shown in the figure marked with (a)).
[0088] Similarly, in addition to the above-mentioned extended components ext_a and ext_b, the Agent of gateway B also includes ext_c and ext_d. If ext_c needs to support the configuration type of route, then ext_c includes route_upstream (i.e. upstream that is adapted to the configuration type of route), route_resource (i.e. resource that is adapted to the configuration type of route), and route_downstream (i.e. downstream that is adapted to the configuration type of route). Route_upstream has a corresponding northbound driver, and route_downstream has a corresponding southbound driver. If ext_d needs to support the configuration type of subnet, then the extended component ext_d includes subnet_upstream (i.e. upstream that is adapted to the configuration type of subnet), subnet_resource (i.e. resource that is adapted to the configuration type of subnet), and subnet_downstream (i.e. downstream that is adapted to the configuration type of subnet). Subnet_upstream has a corresponding northbound driver, and subnet_downstream has a corresponding southbound driver. Then, the device arrangement information of composer should indicate that the corresponding Agent includes the above four extension components. By loading the corresponding extension components, the Agent of gateway B can be obtained (see Figure 6 (as shown in the figure marked with (b) in the figure).
[0089] In a possible implementation, there may be data interaction between multiple extension components included in an Agent. In this case, the device orchestration information may also include a pipeline and parameters, where the parameters are used to indicate the extension components used as imports and the extension components used as exports.
[0090] The embodiment of the present application facilitates the arrangement of different proxy devices through a device editor, thereby completing complex business logic by combining extension components, avoiding rewriting the code of the entire proxy device, and reducing repeated code development.
[0091] It should be understood that the Agent involved in the embodiment of the present application is composed of an extension component, and the extension component includes multiple components, and the multiple components are decoupled from each other, and each component can be assembled into different extension components by replacement. Therefore, in a possible implementation, the extension component can also be managed. To this end, the embodiment of the present application can also implement a component manager (extension manager) for registering and searching for specified extensions. When a registration operation is received, component arrangement information can be generated by the component manager in response to the registration operation, and the component arrangement information is used to indicate the components included in different extension components. Among them, the registration operation can, for example, be to provide the upstream, downstream and resrouce of the extension to be registered to the interface specified by the extension manager, as well as the name of the extension component (extension name).
[0092] In this case, according to the device orchestration information, the extension components respectively included in the multiple proxy devices are loaded through the device editor to obtain the proxy devices corresponding to the multiple network elements respectively. The method can be that according to the device orchestration information and the component orchestration information, the extension components respectively included in the multiple proxy devices are loaded through the device editor to obtain the proxy devices corresponding to the multiple network elements respectively.
[0093] It is understandable that the component manager records the component arrangement information, so that it can determine which components can form the corresponding extension component according to the component arrangement information. In this way, when the extension component needs to be loaded to implement the corresponding proxy device, the corresponding extension component can be implemented in combination with the component arrangement information. Figure 7 As shown, Figure 7 The figure marked with (a) shows an rtable extension component of an mq mother machine. The data source corresponding to the extension component is the rabbitmq data source. The extension component includes rtable_upstream, rtable_resource and rtable_downstream. The first driver connected to rtable_upstream is the rabbitmq driver, and the second driver connected to rtable_downstream is the mother machine virtual switch driver. When the data source changes, for example, from the rabbitmq data source to the zk data source, in order to adapt to the change of the data source, the first driver in (a) is replaced from the rabbitmq driver to the zk driver, which solves the business scenario with different northbound data sources and the same southbound network elements. For example, private cloud and public cloud have different data sources, but the gateway (ie network element) and business logic to be sent to are the same, for example Figure 7As shown in the figure marked by (b) in the figure. When the network element changes, for example, from a parent machine to an L3 gateway, in order to adapt to the change of the network element, the second driver in (b) is replaced from the parent machine virtual switch driver to the L3 gateway driver, which solves the business scenario where the northbound data source is the same but the southbound network elements are different. For example, the same northbound data needs to be sent to different gateways, Figure 7 As shown in the figure marked with (c).
[0094] The above introduces the data processing method provided in the embodiment of the present application. The key to implementing this data processing method is to decouple the data pulling, intermediate business logic conversion and data delivery performed inside the proxy device. This decoupling method is reflected in both the process of using the proxy device to implement configuration delivery and the design and implementation of the proxy device. The design and implementation of the proxy device is the foundation. The proxy device provided in the embodiment of the present application will be introduced in detail below.
[0095] The proxy device provided in the embodiment of the present application includes at least one extension component, one extension component corresponds to one configuration type, and one extension component is decoupled into multiple components, and the multiple components include a data pulling module, a resource processing module, and a data sending module:
[0096] The data pulling module is used to pull the original data of the corresponding configuration type from the data source and convert the original data into a unified receiving object. The object interface of the unified receiving object corresponding to the original data from different data sources is the same;
[0097] The resource processing module is used to receive the unified receiving object sent by the data pulling module, and perform business conversion on the unified receiving object to obtain a unified return object. The object interface of the unified return object corresponding to different network elements is the same;
[0098] The data sending module is used to receive the unified return object sent by the resource processing module, convert the unified return object to obtain target data, and send the target data to the corresponding network element. The target data is used to configure the corresponding configuration type for the corresponding network element.
[0099] In a possible implementation, the resource processing module is further used to obtain filtering parameters from the data sending module and send the filtering parameters to the data pulling module. Accordingly, the data pulling module is specifically used to pull original data that meets preset conditions from the data source according to the filtering parameters.
[0100] In a possible implementation, the data pulling module has a corresponding first driver, which is a driver for connecting to a data source, and the data sending module has a corresponding second driver, which is a driver for connecting to a network element. Accordingly, the data pulling module is specifically used to call the first driver and pull the original data from the data source through the first driver; the data sending module is specifically used to send the target data to the second driver, and send the target data to the corresponding network element through the second driver.
[0101] It should be noted that the extension component can be represented by extension, which is the smallest unit that Agent can handle a specified business capability. Extension is implemented in layers, each layer is a data pull module (i.e. upstream), a resource processing module (i.e. resource) and a data delivery module (i.e. downstream). The functional implementation of each layer is as follows:
[0102] The upstream pulls the full data or incremental data (i.e., original data) through the northbound driver (i.e., the first driver), then converts the original data into a unified object format (i.e., a unified receiving object) and passes it to the resource. The main function of the upstream is to shield the inconsistency of the northbound data from the resource, so that the resource can adapt to different operating environments by replacing the upstream without re-modification. The main interface capabilities should include:
[0103] RemoteGet: Pull northbound data and support registration of whether to monitor incremental data (watch). It also supports filtering parameters to pull only northbound data that meets the preset conditions;
[0104] UnWatch: Cancel the watch notification of the specified data, that is, you will not receive incremental notifications of the corresponding data in the future.
[0105] Resource is connected to upstream in the north and to downstream in the south. After upstream pulls the raw data from the data source, it converts it into a unified receiving object, performs business conversion on the unified receiving object to obtain a unified return object, and calls the resource interface to complete the change of full data or incremental data. This layer is unaware of the difference between northbound data and southbound data. The data objects of the unified receiving object and the unified return object are both unified object interfaces. Resource is the module for the core business implementation of Agent. Once implemented, it is generally not modified due to changes in upstream and downstream. In order to cope with the filtering support of southbound network elements for northbound data sources, resource can pull the filtering parameters of downstream and pass them to upstream, and then upstream implements data filtering, so that on-demand pulling can be achieved when northbound data is pulled. See. Figure 5 shown.
[0106] In summary, resource is an intermediate layer that is unaware of the difference between southbound data and northbound data, completes data localization and business conversion, and completes configuration delivery by calling the corresponding downstream. The interface capabilities provided by resource mainly include (in order to improve concurrency capabilities, all interfaces support batch):
[0107] FullSync: Called by upstream to synchronize the full amount of data at startup (synchronize northbound data to the local machine and send it to the network element);
[0108] Get: Get locally saved data, support filtering parameters and paging functions;
[0109] Update: Updates local data and calls downstream to update, which is called by upstream to update incremental data;
[0110] Delete: Deletes local data and calls downstream to delete. It is called by upstream for incremental deletion.
[0111] Add: Add local data and call downstream to add, which is called by upstream for incremental addition;
[0112] RemoteGet: Calls the upstream RemoteGet to pull the original data, and supports specifying whether to watch;
[0113] UnWatch: Call the upstream UnWatch interface to UnWatch the specified data.
[0114] Downstream is an abstract layer for connecting to southbound drivers. Even if it connects to different southbound drivers, it provides the same interface and parameters for the same resource. The interfaces provided to the outside world mainly include:
[0115] Get: Get the data of the specified configuration of the southbound network element, supporting filtering parameters and paging functions;
[0116] Update: Update the configuration of the southbound network element;
[0117] Add: Add the configuration of the southbound network element;
[0118] Delete: Delete the configuration of the southbound NE;
[0119] GetAttribute: Gets the attributes supported by the specified configuration of the southbound network element for general processing;
[0120] GetDrivers: Get the driver support of the southbound network element;
[0121] GetFilter: Gets the filter parameters supported by the southbound driver, which is used to filter the northbound data.
[0122] The interface support provided by upstream, downstream, and resource in Extension is just an example. Its ability is mainly that each layer exposes the capabilities of this layer to the next layer through the same interface. And it ensures the unified management of extension. The key to the proxy device provided in the embodiment of the present application is the decoupling of data pulling, intermediate business logic conversion, and data distribution, and supports the orchestration of Agent and extension. The universality of other modules is based on the standardization of extension interfaces and the cohesion of capabilities, which is not limited in the embodiment of the present application.
[0123] Since extensions all have unified interfaces, and unified receiving objects and unified returning objects all implement unified interface capabilities, the embodiments of the present application also support exposing the interface capabilities of extensions indiscriminately to the outside world (providing exposure strategies) through Hyper Text Transfer Protocol (HTTP) or grpc, etc. This facilitates data analysis, problem diagnosis, and data interaction between extension components during the Agent operation process.
[0124] In addition, since the southbound driver, northbound driver, and core business are all integrated into the extension, and the extension provides a unified interface capability to the outside world, the business-related codes of the Agent are highly cohesive. Therefore, many business-independent codes can be programmed into common modules and turned into common capabilities of all Agents, such as monitoring, transaction logs, and operation and maintenance capabilities.
[0125] In a possible implementation, the proxy device has a corresponding device editor (i.e., composer), which is used to record device orchestration information, and the device orchestration information is used to indicate the set of extension components included in different proxy devices. In this way, when it is necessary to implement a proxy device for a network element, the composer can be configured to load the corresponding extension on demand to complete the orchestration of the corresponding Agent. In this way, complex business logic can be completed through combination while ensuring the closed loop of extension capabilities.
[0126] In a possible implementation, the proxy device has a corresponding component manager (i.e., extension manager), which is used to record component arrangement information, and the component arrangement information is used to indicate the components included in different extension components. In this way, the arrangement of extensions can be completed to obtain different proxy devices.
[0127] The specific application of the above-mentioned device editor and component manager can be found in the above introduction, and the embodiments of the present application will not be elaborated on this.
[0128] Based on the above introduction to the proxy device, the architecture of the proxy device provided in the embodiment of the present application can be referred to. Figure 8 As shown, Figure 8The data sources include zookeeper, CRS (cloud redis store, a cloud storage device), TRPC, and the network elements can include ovs, lvs, iptables, haproxy, and nginx. Different data sources are connected to the corresponding northbound drivers, and different network elements are connected to the corresponding southbound drivers. The extension includes the extension composed of table_upstream, rtable_resource, and rtable_downstream, the extension composed of subnet_upstream, subnet_resource, and subnet_downstream, and the extension composed of gateway_upstream, gateway_resource, and gateway_downstream. In addition, the device editor (composer) can be used to orchestrate l3gw-Agent, host-Agent, and natgw-Agent. In addition to the above components, the Agent architecture also includes core modules, which can realize major functions such as reconciliation, process daemon, component management, indicator collection, transaction log, http interface, and other functions.
[0129] The Agent provided in the embodiment of the present application has clear layers and decouples the upstream, resource, and downstream used to implement the service, thereby reducing a large amount of duplicate code development. When there are enough north-south drivers and resources, the code development required to adapt to new network elements or data sources will be greatly reduced.
[0130] For example, when a new network element needs to be adapted, the northbound data does not need to be changed. Only part of the configuration of the existing Agent needs to be sent, but the southbound driver is brand new. Specifically, the southbound driver of the southbound network element and the corresponding downstream can be rewritten, and then orchestrated based on the northbound driver, upstream, and resource included in the existing extension. There is no need to consider operation and maintenance, operation, and monitoring. Because these general capabilities are already included in the basic code of the Agent, and there is no business logic.
[0131] It should be noted that, based on the implementation methods provided in the above aspects, this application can also be further combined to provide more implementation methods.
[0132] based on Figure 3 Corresponding to the data processing method provided in the embodiment, the embodiment of the present application also provides a data processing device 900. Fig. 9The data processing device 900 includes a determining unit 901, a pulling unit 902, a converting unit 903 and a sending unit 904:
[0133] The determining unit 901 is used to determine the target proxy device corresponding to the target network element when it is detected that the configuration delivery condition is met;
[0134] The pulling unit 902 is used to pull the original data of the target configuration type from the data source through the target proxy device;
[0135] The conversion unit 903 is used to convert the original data into a unified receiving object through the target proxy device, and the object interface of the unified receiving object corresponding to the original data from different data sources is the same;
[0136] The conversion unit 903 is further configured to perform service conversion on the unified receiving object through the target proxy device to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same;
[0137] The conversion unit 903 is further configured to convert the unified return object into target data through the target proxy device;
[0138] The sending unit 904 is used to send the target data to the target network element, where the target data is used to configure the target configuration type for the target network element.
[0139] In a possible implementation, the target proxy device includes at least one extension component, one extension component is decoupled into multiple components, the multiple components include a data pulling module, a resource processing module and a data sending module, the target configuration type corresponds to the target extension component in the at least one extension component, and the pulling unit 902 is used to:
[0140] Pull the original data from the data source through the data pulling module in the target extension component;
[0141] The conversion unit 903 is used to:
[0142] Converting the original data into the unified receiving object through the data pulling module in the target extension component;
[0143] The conversion unit 903 is used to:
[0144] Performing business conversion on the unified receiving object by the resource processing module in the target extension component to obtain a unified return object;
[0145] The conversion unit 903 is used to:
[0146] Converting the unified return object into target data through a data delivery module in the target extension component;
[0147] The sending unit 904 is used to:
[0148] The target data is sent to the target network element.
[0149] In a possible implementation, the pulling unit 902 is used to:
[0150] Calling a first driver through a data pulling module in the target extension component, and pulling the original data from the data source through the first driver;
[0151] The sending unit 904 is used to:
[0152] The target data is sent to the second driver through the data sending module in the target extension component, and the target data is sent to the target network element through the second driver.
[0153] In a possible implementation, the conversion unit 903 is configured to:
[0154] Obtaining a target parameter type corresponding to the second driver;
[0155] Convert the unified return object into target data of the target parameter type.
[0156] In a possible implementation, the device further includes a loading unit:
[0157] The loading unit is used to load the extension components respectively included in the plurality of proxy devices through the device editor according to the device arrangement information, so as to obtain the proxy devices respectively corresponding to the plurality of network elements, wherein the device arrangement information is used to indicate the extension component sets of different proxy devices, the plurality of proxy devices are the proxy devices respectively corresponding to the plurality of network elements, the plurality of network elements are the network elements included in the target network, and the target network is the network to which the target network elements belong;
[0158] The determining unit 901 is used to:
[0159] The target proxy device is determined from the proxy devices respectively corresponding to the multiple network elements.
[0160] In a possible implementation manner, the device further includes a generating unit:
[0161] The generating unit is used to generate component arrangement information through the component manager in response to the registration operation, wherein the component arrangement information is used to indicate components included in different extension components;
[0162] The loading unit is used for:
[0163] According to the device arrangement information and the component arrangement information, the extended components respectively included in the plurality of proxy devices are loaded through the device editor to obtain the proxy devices respectively corresponding to the plurality of network elements.
[0164] In a possible implementation, the pulling unit 902 is used to:
[0165] According to the filtering parameters, the source data in the data source is filtered by the target proxy device to obtain the original data that meets the preset conditions, and the original data is pulled.
[0166] In a possible implementation, the target proxy device includes at least one extension component, one extension component is decoupled into multiple components, the multiple components include a data pulling module, a resource processing module and a data sending module, the target configuration type corresponds to the target extension component in the at least one extension component, and the pulling unit 902 is used to:
[0167] Acquire the filtering parameters from the data sending module of the target extension component through the resource processing module of the target extension component, and send the filtering parameters to the data pulling module of the target extension component;
[0168] According to the filtering parameters, the source data in the data source is filtered by the data pulling module to obtain the original data that meets the preset conditions.
[0169] It can be seen from the above technical solution that when using a proxy device, the present application decouples the data pulling, intermediate business logic conversion and data delivery performed inside the proxy device. Specifically, when it is detected that the configuration delivery conditions are met, the target proxy device corresponding to the target network element is determined, so that the target proxy device is used to deliver the configuration to the target network element. The target proxy device pulls the original data of the target configuration type from the data source (i.e., data pulling), and then converts the original data into a unified receiving object through the target proxy device. The object interface of the unified receiving object corresponding to the original data from different data sources is the same, and the target proxy device performs business conversion on the unified receiving object to obtain a unified return object. The object interface of the unified return object corresponding to different network elements is the same (i.e., intermediate business logic conversion), thereby shielding the differences between different data sources and different network elements from the intermediate business conversion logic. Finally, the unified return object is converted into target data through the target proxy device, and the target data is delivered to the target network element (i.e., data delivery), so that the target network element is configured with the target data for the target configuration type. Since the input of the intermediate business conversion logic is a unified receiving object and the output is a unified return object, the differences between different data sources and different network elements are shielded. In this way, when the data sources or network elements are different, it is only necessary to adaptively modify the partial code of data pulling or data sending of the target proxy device. There is no need to modify the intermediate business conversion logic, and thus there is no need to modify the code of the entire proxy device, which improves the adaptability of the proxy device, reduces a large amount of additional code development, and reduces development costs.
[0170] The embodiment of the present application further provides a computer device, which can execute the aforementioned data processing method. The computer device can be, for example, a terminal, taking a smart phone as an example:
[0171] Fig.10 The block diagram shows a partial structure of a smart phone provided in an embodiment of the present application. Fig.10 , the smartphone includes: a radio frequency (full name: Radio Frequency, English abbreviation: RF) circuit 1010, a memory 1020, an input unit 1030, a display unit 1040, a sensor 1050, an audio circuit 1060, a wireless fidelity (English abbreviation: WiFi) module 1070, a processor 1080, and a power supply 1090. The input unit 1030 may include a touch panel 1031 and other input devices 1032, the display unit 1040 may include a display panel 1041, and the audio circuit 1060 may include a speaker 1061 and a microphone 1062. It can be understood that, Fig.10 The structure of the smartphone shown in the figure does not constitute a limitation of the smartphone, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0172] The memory 1020 can be used to store software programs and modules. The processor 1080 executes various functional applications and data processing of the smartphone by running the software programs and modules stored in the memory 1020. The memory 1020 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the smartphone (such as audio data, a phone book, etc.), etc. In addition, the memory 1020 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0173] The processor 1080 is the control center of the smartphone, which uses various interfaces and lines to connect various parts of the entire smartphone, and executes various functions of the smartphone and processes data by running or executing software programs and / or modules stored in the memory 1020, and calling data stored in the memory 1020. Optionally, the processor 1080 may include one or more processing units; preferably, the processor 1080 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 1080.
[0174] In this embodiment, the steps performed by the processor 1080 in the smartphone may be based on Fig.10 The structure shown is implemented.
[0175] The computer device provided in the embodiment of the present application may also be a server. Fig.11 As shown, Fig.11 The structural diagram of the server 1100 provided in the embodiment of the present application, the server 1100 may have relatively large differences due to different configurations or performances, and may include one or more processors, such as a central processing unit (CPU) 1122, and a memory 1132, one or more storage media 1130 (such as one or more mass storage devices) storing application programs 1142 or data 1144. Among them, the memory 1132 and the storage medium 1130 can be short-term storage or permanent storage. The program stored in the storage medium 1130 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations on the server. Furthermore, the central processing unit 1122 can be configured to communicate with the storage medium 1130 and execute a series of instruction operations in the storage medium 1130 on the server 1100.
[0176] The server 1100 may also include one or more power supplies 1126, one or more wired or wireless network interfaces 1150, one or more input and output interfaces 1158, and / or one or more operating systems 1141, such as Windows Server 2003. TM , Mac OS X TM , Unix TM ,Linux TM , FreeBSD TM etc.
[0177] In this embodiment, the CPU 1122 in the server 1100 may perform the following steps:
[0178] When it is detected that the configuration delivery conditions are met, a target proxy device corresponding to the target network element is determined;
[0179] Pulling original data of the target configuration type from the data source through the target proxy device;
[0180] The target proxy device converts the original data into a unified receiving object, wherein the original data from different data sources correspond to the same object interface of the unified receiving object;
[0181] The target proxy device performs service conversion on the unified receiving object to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same;
[0182] The unified return object is converted into target data through the target proxy device, and the target data is sent to the target network element, where the target data is used to configure the target configuration type for the target network element.
[0183] According to one aspect of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium is used to store a computer program, and the computer program is used to execute the data processing method described in the above-mentioned embodiments.
[0184] According to one aspect of the present application, a computer program product is provided, the computer program product comprising a computer program, the computer program being stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device executes the method provided in various optional implementations of the above-mentioned embodiments.
[0185] The descriptions of the processes or structures corresponding to the above-mentioned figures have different emphases. For parts that are not described in detail in a certain process or structure, please refer to the relevant descriptions of other processes or structures.
[0186] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein, for example. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0187] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0188] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0189] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0190] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store computer programs.
[0191] As described above, the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, ordinary technical members in the art should understand that they can still modify the technical solutions recorded in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A data processing method, characterized in that: The method comprises: When it is detected that the configuration delivery conditions are met, a target proxy device corresponding to the target network element is determined; Pulling original data of the target configuration type from the data source through the target proxy device; The target proxy device converts the original data into a unified receiving object, wherein the original data from different data sources correspond to the same object interface of the unified receiving object; The target proxy device performs service conversion on the unified receiving object to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same; The unified return object is converted into target data through the target proxy device, and the target data is sent to the target network element, where the target data is used to configure the target configuration type for the target network element.
2. The method according to claim 1, characterized in that The target proxy device includes at least one extension component, one extension component is decoupled into multiple components, the multiple components include a data pulling module, a resource processing module and a data sending module, the target configuration type corresponds to the target extension component in the at least one extension component, and the original data of the target configuration type is pulled from the data source by the target proxy device, including: Pull the original data from the data source through the data pulling module in the target extension component; The converting the original data into a unified receiving object by the target proxy device includes: Converting the original data into the unified receiving object through the data pulling module in the target extension component; The performing business conversion on the unified receiving object by the target proxy device to obtain a unified return object includes: Performing business conversion on the unified receiving object by the resource processing module in the target extension component to obtain a unified return object; The converting the unified return object into target data by the target proxy device and sending the target data to the target network element includes: The unified return object is converted into target data through the data sending module in the target extension component, and the target data is sent to the target network element.
3. The method according to claim 2, characterized in that The step of pulling the original data from the data source through the data pulling module in the target extension component includes: Calling a first driver through a data pulling module in the target extension component, and pulling the original data from the data source through the first driver; The sending the target data to the target network element includes: The target data is sent to the second driver through the data sending module in the target extension component, and the target data is sent to the target network element through the second driver.
4. The method according to claim 3, characterized in that The converting the unified return object into target data through the data sending module in the target extension component includes: Obtaining a target parameter type corresponding to the second driver; Convert the unified return object into target data of the target parameter type.
5. The method according to claim 2, characterized in that: The method further comprises: According to the device arrangement information, the extension components respectively included in the plurality of proxy devices are loaded through the device editor to obtain the proxy devices respectively corresponding to the plurality of network elements, wherein the device arrangement information is used to indicate a set of extension components of different proxy devices, the plurality of proxy devices are proxy devices respectively corresponding to the plurality of network elements, the plurality of network elements are network elements included in the target network, and the target network is a network to which the target network elements belong; The step of determining a target proxy device corresponding to a target network element includes: The target proxy device is determined from the proxy devices respectively corresponding to the multiple network elements.
6. The method according to claim 5, characterized in that The method further comprises: In response to the registration operation, generating component arrangement information through the component manager, wherein the component arrangement information is used to indicate components included in different extension components; The method of loading the extension components respectively included in the plurality of proxy devices through the device editor according to the device arrangement information to obtain the proxy devices respectively corresponding to the plurality of network elements includes: According to the device arrangement information and the component arrangement information, the extended components respectively included in the plurality of proxy devices are loaded through the device editor to obtain the proxy devices respectively corresponding to the plurality of network elements.
7. The method according to claim 1, characterized in that The step of pulling original data of the target configuration type from the data source through the target proxy device includes: According to the filtering parameters, the source data in the data source is filtered by the target proxy device to obtain the original data that meets the preset conditions, and the original data is pulled.
8. The method according to claim 7, characterized in that The target proxy device includes at least one extension component, one extension component is decoupled into multiple components, the multiple components include a data pulling module, a resource processing module and a data sending module, the target configuration type corresponds to the target extension component in the at least one extension component, and according to the filtering parameter, filtering the source data in the data source through the target proxy device to obtain the original data that meets the preset conditions includes: Acquire the filtering parameters from the data sending module of the target extension component through the resource processing module of the target extension component, and send the filtering parameters to the data pulling module of the target extension component; According to the filtering parameters, the source data in the data source is filtered by the data pulling module to obtain the original data that meets the preset conditions.
9. A proxy device, characterized in that: The proxy device includes at least one extension component, one extension component corresponds to one configuration type, and one extension component is decoupled into multiple components, and the multiple components include a data pulling module, a resource processing module and a data sending module: The data pulling module is used to pull the original data of the corresponding configuration type from the data source and convert the original data into a unified receiving object. The object interface of the unified receiving object corresponding to the original data from different data sources is the same; The resource processing module is used to receive the unified receiving object sent by the data pulling module, and perform service conversion on the unified receiving object to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same; The data sending module is used to receive the unified return object sent by the resource processing module, convert the unified return object to obtain target data, and send the target data to the corresponding network element, and the target data is used to configure the corresponding network element with the corresponding configuration type.
10. The proxy device according to claim 9, characterized in that: The resource processing module is further used to obtain filtering parameters from the data sending module and send the filtering parameters to the data pulling module; The data pulling module is specifically used to pull the original data that meets the preset conditions from the data source according to the filtering parameters.
11. The proxy device according to claim 9, characterized in that: The data pulling module has a corresponding first driver, which is a driver for connecting to a data source, and the data sending module has a corresponding second driver, which is a driver for connecting to a network element: The data pulling module is specifically used to call the first driver and pull the original data from the data source through the first driver; The data sending module is specifically used to send the target data to the second driver, and send the target data to the corresponding network element through the second driver.
12. The proxy device according to claim 9, characterized in that: The proxy device has a corresponding device editor: The device editor is used to record device arrangement information, where the device arrangement information is used to indicate a set of extension components included in different proxy devices.
13. The proxy device according to claim 9, characterized in that: The proxy device has a corresponding component manager: The component manager is used to record component arrangement information, and the component arrangement information is used to indicate the components included in different extension components.
14. A data processing device, characterized in that: The device includes a determination unit, a pulling unit, a conversion unit and a sending unit: The determining unit is used to determine the target proxy device corresponding to the target network element when it is detected that the configuration delivery condition is met; The pulling unit is used to pull original data of a target configuration type from a data source through the target proxy device; The conversion unit is used to convert the original data into a unified receiving object through the target proxy device, and the object interface of the unified receiving object corresponding to the original data from different data sources is the same; The conversion unit is further used to perform service conversion on the unified receiving object through the target proxy device to obtain a unified return object, and the object interface of the unified return object corresponding to different network elements is the same; The conversion unit is further used to convert the unified return object into target data through the target proxy device; The sending unit is used to send the target data to the target network element, and the target data is used to configure the target configuration type for the target network element.
15. A computer device, characterized in that: The computer device comprises a processor and a memory: The memory is used to store a computer program and transmit the computer program to the processor; The processor is configured to execute the method according to any one of claims 1 to 8 according to the instructions in the computer program.
16. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store a computer program, which, when executed by a processor, causes the processor to perform the method according to any one of claims 1 to 8.
17. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.
