A management method, device, equipment, and storage medium for network services
By obtaining network service requests in the SDN controller and analyzing the target service type and configuration information, and dynamically selecting the target configuration nodes, the problem of excessive responsibility chain and complexity is solved, and efficient automatic analysis and execution of network services is achieved.
Patent Information
- Application Number
- CN202211658193.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-22
- Publication Date
- 2025-07-25
- Estimated Expiration
- 2042-12-22
AI Technical Summary
The existing SDN controller has too long responsibility chain in complex business scenarios, resulting in duplication and missing problems, high cost of positioning, and complex design of static responsibility chains, affecting the efficiency of network services.
By obtaining network service requests and storing them into the context, using the data analysis nodes in the responsibility chain to analyze the target service type and configuration information, dynamically selecting the target configuration node to join the responsibility chain, realizing automatic analysis and execution of network services.
It improves the operation flexibility of the responsibility chain, reduces the operation cost and complexity of the responsibility chain, and improves the speed and accuracy of network business creation.
Smart Images

Figure CN116016211B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of software-defined networks, and in particular, to a method, device, equipment, and storage medium for managing network services. Background Art
[0002] An SDN (Software Defined Network) controller is a bridge connecting the underlying switching devices and upper-layer application programs. The SDN controller realizes behaviors such as link discovery, topology management, and flow table distribution in the south direction, and realizes resource scheduling and configuration of the underlying network in the north direction. The SDN controller simplifies the opening of network services and undertakes functions such as resource allocation, conversion of services into configurations, and distribution of configurations to network elements.
[0003] As more and more services are supported by the SDN controller and the application scenarios are wider and wider, there are more and more choices for access methods, control-plane technologies, and forwarding-plane technologies involved in the opening of network services. Different choices will cause changes in the network service process. The existing northward workflow design pattern for network service configuration parsing and configuration distribution in the SDN controller usually connects multiple modules from top to bottom to form a static responsibility chain, and network service requests are transmitted on the responsibility chain. However, this method will cause the responsibility chain to be too long in complex service scenarios, and there may be problems of repetition and omission. At the same time, when an exception occurs, it is necessary to check the responsibility chain level by level, and the cost of locating problems is relatively high. Summary of the Invention
[0004] The present invention provides a method, device, electronic equipment, and storage medium for managing network services to achieve automatic parsing of network services, improve the flexibility of the operation of the responsibility chain, and reduce the operation cost of the responsibility chain.
[0005] In a first aspect, an embodiment of the present invention provides a method for managing network services, the method including:
[0006] Obtain a network service request, and store data matching the network service request into the context;
[0007] Parse the data matching the network service request in the context through a data analysis node in the responsibility chain to obtain a target service type and target configuration information, and store them into the context;
[0008] Determine a target configuration node matching the target service type through a process selection node in the responsibility chain, and add the target configuration node to the responsibility chain;
[0009] Obtain the target configuration information and target service type in the context through the target configuration node, and execute a network service matching the target service type on the target configuration information.
[0010] In a second aspect, an embodiment of the present invention further provides a management device for network services, the device comprising:
[0011] A network service request acquisition module, configured to acquire a network service request and store data matching the network service request into a context;
[0012] A network service request parsing module, configured to parse the data matching the network service request in the context through a data analysis node in a responsibility chain to obtain a target service type and target configuration information, and store them into the context;
[0013] A target configuration node determination module, configured to determine a target configuration node matching the target service type through a process selection node in the responsibility chain, and add the target configuration node to the responsibility chain;
[0014] A network service execution module, configured to obtain the target configuration information and target service type in the context through the target configuration node, and execute a network service matching the target service type on the target configuration information.
[0015] In a third aspect, an embodiment of the present invention further provides a management device for network services, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, where when the processor executes the program, it implements the management method for network services as described in any one of the embodiments of the present invention.
[0016] In a fourth aspect, an embodiment of the present invention further provides a storage medium storing computer-executable instructions, where the computer-executable instructions are used to execute the management method for network services as described in any one of the embodiments of the present invention when executed by a computer processor.
[0017] The technical solution of the embodiment of the present invention is as follows: by acquiring a network service request and storing data matching the network service request into a context; by parsing the data matching the network service request in the context through a data analysis node in a responsibility chain to obtain a target service type and target configuration information, and storing them into the context; by determining a target configuration node matching the target service type through a process selection node in the responsibility chain, and adding the target configuration node to the responsibility chain; by obtaining the target configuration information and target service type in the context through the target configuration node, and executing a network service matching the target service type on the target configuration information. This technical solution can achieve automatic parsing of network services, improve the flexibility of the operation of the responsibility chain, and reduce the operation cost of the responsibility chain.
[0018] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present invention, nor is it used to limit the scope of the present invention. Other features of the present invention will become readily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0020] Figure 1 Flowchart of a method for managing network services provided in Embodiment 1 of the present invention;
[0021] Figure 2 Schematic diagram of a process for joining a target configuration node provided in Embodiment 1 of the present invention
[0022] Figure 3 Flowchart of a method for managing network services provided in Embodiment 2 of the present invention;
[0023] Figure 4 Schematic diagram of a process for configuring a node provided in Embodiment 2 of the present invention;
[0024] Figure 5 Schematic diagram of a process for a target configuration node to work provided in Embodiment 2 of the present invention;
[0025] Figure 6 Flowchart of a method for managing network services provided in Embodiment 3 of the present invention;
[0026] Figure 7 Schematic diagram of the structure of a device for managing network services provided in Embodiment 4 of the present invention;
[0027] Figure 8 Schematic diagram of the structure of a device for managing network services provided in Embodiment 5 of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0028] In order to enable those skilled in the art to better understand the solution of the present invention, the following clearly and completely describes the technical solutions in the embodiments of the present invention in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only some of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0029] It should be noted that the terms "first", "second", etc. in the description, claims and the above-mentioned drawings of the present invention are used to distinguish similar objects, and do not necessarily have to be used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0030] Embodiment 1
[0031] Figure 1 The figure is a flowchart of a method for managing network services provided in Embodiment 1 of the present invention. This embodiment is applicable to the situation of managing network services. This method can be executed by a management device for network services. The management device for network services can be implemented in the form of hardware and / or software, and the management device for network services can be configured in an electronic device with data processing capabilities.
[0032] As Figure 1 shown, the method includes:
[0033] S110. Obtain a network service request and store the data matching the network service request in the context.
[0034] Among them, the network service can send the network configuration to the corresponding network node through the process nodes in the responsibility chain to achieve the purpose of controlling traffic forwarding. Among them, the process node is a specific execution step in the responsibility chain, which is used to process the received request to determine the subsequent direction of the responsibility chain. The network service is to send the configurations required for traffic engineering to switch and router devices, such as layer 2 and layer 3 VPN services based on forwarding methods such as SR tunnels, SR-Policies, and SRv6-Policies. Among them, the network service data can be, for example, virtual routing forwarding tables, device information, etc., which are transmitted throughout the service through the context and released along with the context after the service ends.
[0035] When executing network services, generally, all process nodes are traversed through a static responsibility chain to determine whether to execute a certain function module, or required function modules are added before executing network services. The former makes the static responsibility chain structure too long and affects network transmission performance, and the latter makes the process of the static responsibility chain complex and is only applicable to the scenario of manually dragging tasks on the page to create a responsibility chain.
[0036] In view of the above problems, in the embodiments of the present invention, each process node is connected through a dynamic responsibility chain, so that network services can be quickly executed by accessing the dynamic responsibility chain, the data analysis and processing ability for executing complex network services is improved, the amount of manual operations is reduced, and the network service creation speed is increased.
[0037] Among them, the dynamic responsibility chain is created in the form of a doubly linked list. Each process node in the doubly linked list may include a process node number, an execution service function, a rollback service function, and two pointers. The two pointers respectively point to the successor process node and the predecessor process node. The rollback service rolls back the memory information, hard disk storage, network element configuration, etc. modified during the execution of the service by the process node until it is restored to the state before the execution of the service. It should be noted that the rollback service is only triggered when an exception occurs in the process.
[0038] In the embodiments of the present invention, the data matching the network service request is stored in the context to achieve data transfer. Among them, the context can be used as a temporary data storage medium. Each process node performs data transfer through the context. The data is stored in the context in the form of key-value pairs, that is, one keyword corresponds to a type of data, and all process nodes write and read the data in the context in the same data format. The context is destroyed when the network service execution is completed.
[0039] S120. Through the data analysis node in the responsibility chain, the data in the context that matches the network service request is parsed to obtain the target service type and the target configuration information, and they are stored in the context.
[0040] Among them, the process nodes in the responsibility chain can be divided according to the functions of the included services, such as data analysis nodes, process selection nodes, network element configuration nodes, data storage nodes, etc.
[0041] Among them, the data analysis node can be a node for processing the data of the network service request. The target service type can be determined according to the function of the target service. For example, it can be an add function, a delete function, a modify function, etc. The target configuration information can be the information for implementing the target service function.
[0042] It should be noted that if the target configuration information includes a certain network element resource while the network service request does not include this network element resource, the data analysis node can allocate network element resources for the target service through the resource pool. After the allocation of network element resources is completed, if the data analysis node triggers the rollback service, the network element resources need to be released.
[0043] S130. Through the process selection node in the responsibility chain, the target configuration node matching the target service type is determined, and the target configuration node is added to the responsibility chain.
[0044] Among them, the process selection node can be a node for controlling the responsibility chain, and the direction of the process nodes in the responsibility chain can be determined according to the target service type and the target configuration information. The target configuration node can be a node for implementing the target service function.
[0045] Optionally, adding the target configuration node to the responsibility chain includes: determining the insertion position of the target configuration node in the responsibility chain according to the execution order of the target service type in the network service.
[0046] Among them, the target configuration node can be represented by a node number, and its node number can represent the execution order of the target service type in the network service. Determine the insertion position of the target configuration node in the responsibility chain according to the node number. Through such a setting, the flexibility of the responsibility chain operation can be improved.
[0047] Exemplarily, Figure 2 is a schematic diagram of a process for adding a target configuration node provided in the first embodiment of the present invention. As Figure 2 shown, if the node number of the added target configuration node is 2, before the target configuration node is added to the responsibility chain, the successor node of node 1 points to node 3, and the predecessor node of node 3 points to node 1; after the target configuration node is added to the responsibility chain, the successor node of node 1 points to the target configuration node, the successor node of the target configuration node points to node 3, the predecessor node of node 3 points to the target configuration node, and the predecessor node of the target configuration node points to node 1.
[0048] Before the target configuration node is added to the responsibility chain, the network service is executed in the order of node 1 -> node 3 and rolled back in the order of node 3 -> node 1. After the target configuration node is added to the responsibility chain, the network service is executed in the order of node 1 -> target configuration node -> node 3 and rolled back in the order of node 3 -> target configuration node -> node 1. If an exception occurs at the target configuration node, it is rolled back in the order of target configuration node -> node 1.
[0049] S140. Through the target configuration node, obtain the target configuration information and the target service type in the context, and execute the network service that matches the target service type for the target configuration information.
[0050] Among them, through the target configuration node added to the responsibility chain, obtain the target configuration information and the target service type in the context, and execute the network service that matches the target service type according to the obtained target configuration information.
[0051] An embodiment of the present invention provides a method for managing network services. By obtaining a network service request and storing the data matching the network service request in the context; through a data analysis node in the responsibility chain, parsing the data matching the network service request in the context to obtain the target service type and the target configuration information, and storing them in the context; through a process selection node in the responsibility chain, determining the target configuration node matching the target service type and adding the target configuration node to the responsibility chain; through the target configuration node, obtaining the target configuration information and the target service type in the context and executing the network service matching the target service type on the target configuration information. This technical solution can achieve automatic parsing of network services, improve the flexibility of the operation of the responsibility chain, and reduce the operation cost of the responsibility chain.
[0052] Embodiment 2
[0053] Figure 3 FIG. is a flowchart of a method for managing network services provided in Embodiment 2 of the present invention. Based on the above embodiment, the present invention embodiment further specifies the above embodiment.
[0054] As Figure 3 shown, the method includes:
[0055] S310. Obtain a network service request and store the data matching the network service request in the context.
[0056] S320. Through a data analysis node in the responsibility chain, obtain the data matching the network service request in the context.
[0057] Among them, the data analysis node can read the network service request through the context, analyze the network service request to determine the data matching the network service request. Among them, the data matching the network service request can be newly added network element configuration information, deleted network element configuration information, modified network element configuration information, modified network element configuration information, flag service type, etc.
[0058] S330. Compare the data matching the network service request with the original configuration information in the database to determine the target service type and the target configuration information.
[0059] Among them, the original configuration information in the database can be the configuration information uploaded before the execution of the target service. By comparing the data matching the network service request with the original configuration information in the database, it is determined whether there is a change in the data matching the network service request based on the original configuration information and the type of change, such as modifying some configuration information, adding new configuration information, deleting the original configuration information, etc. Furthermore, the target service type and the target configuration information can be determined according to the comparison result.
[0060] Optionally, through the data analysis nodes in the chain of responsibility, the data in the context that matches the network service request is parsed to obtain the target service type, including steps A1 - A2:
[0061] Step A1: Through the data analysis nodes in the chain of responsibility, the data in the context that matches the network service request is parsed to obtain the forwarding policy and access route.
[0062] Among them, the forwarding policy can be the forwarding rules and forwarding action types of the configuration information. The forwarding rules can include a series of configurations that affect the forwarding path of data packets between network devices through attributes such as the source / destination IP, source / destination port, protocol number, and service level of the data packet, such as filtering, rate limiting, and re - marking. The access route is used to establish the route between the CE (Customer Edge, customer - side device) and the PE (Provider Edge, network - edge - side device), so that customer traffic can be accessed to the virtual private network (VPN) for forwarding. The access route can select one or a combination of BGP access, static route access, and OSPF access.
[0063] It should be noted that multiple types of forwarding policies and access routes can be determined according to the data that matches the network service request.
[0064] Step A2: Determine the target service type according to the forwarding policy and access route.
[0065] Since there are multiple types of forwarding policies and access routes, in the embodiments of the present invention, the corresponding target service type can be determined by judging whether there is a certain type of access route.
[0066] Taking the example of adding the configuration nodes related to the VRF (Virtual Routing and Rorwarding) technology to the chain of responsibility for explanation. Figure 4 This is a schematic flow diagram of a configuration node provided in the second embodiment of the present invention. As Figure 4 shown,
[0067] The first step: Through the data analysis nodes in the chain of responsibility, the data in the context that matches the network service request is parsed to judge whether the target service is an SR - TE service, an SRv6 - Policy service, or an SR - Policy service.
[0068] The second step: Determine the traffic policy according to the target service type; if the target service is an SR - TE service, then adopt the tunnel policy of the SR - TE tunnel; if the target service is an SRv6 - Policy service, then adopt the routing policy of the SRv6 policy; if the target service is an SR - Policy service, then adopt the routing policy of the SR policy.
[0069] Step 3: Determine the traffic policy, access route, and access point; where the access route may include a static route and an OSPF route.
[0070] Step 4: Determine the target service type based on the traffic policy, access route, and access point, and add the target configuration node matching the target service type to the responsibility chain.
[0071] S340: Determine the target configuration node matching the target service type through the process selection node in the responsibility chain, and add the target configuration node to the responsibility chain.
[0072] S350: Obtain the target configuration information and target service type in the context through the target configuration node, and perform network services matching the target service type on the target configuration information.
[0073] An embodiment of the present invention provides a method for managing network services. By obtaining a network service request and storing the data matching the network service request in the context; through the data analysis node in the responsibility chain, obtaining the data matching the network service request in the context; comparing the data matching the network service request with the original configuration information in the database to determine the target service type and target configuration information; through the process selection node in the responsibility chain, determining the target configuration node matching the target service type, and adding the target configuration node to the responsibility chain; through the target configuration node, obtaining the target configuration information and target service type in the context, and performing network services matching the target service type on the target configuration information. This technical solution can compare the data matching the network service request with the original configuration information in the database, quickly and accurately determine the target service type and target configuration information, and further improve the flexibility of the operation of the responsibility chain.
[0074] Based on the above embodiments, optionally, the target configuration node includes at least one of the following: a new configuration node, a delete configuration node, and an update configuration node; where the new configuration node is used to obtain the new configuration information in the context and send the new configuration information and new instructions to the network element matching the network service request; the delete configuration node is used to obtain the delete configuration information in the context and send the delete configuration information and delete instructions to the network element matching the network service request; the update configuration node is used to obtain the original configuration information and the modified configuration information in the context, and send the original configuration information, the modified configuration information, and update instructions to the network element matching the network service request.
[0075] Among them, the newly added configuration node belongs to the network element configuration node, and the newly added network element configuration information can be obtained from the context. The new instruction is sent to the network element through the configuration channel. When an exception occurs, the newly added configuration node performs a rollback and deletes the newly added network element configuration information in the newly added configuration node.
[0076] Among them, the deletion configuration node belongs to the network element configuration node, and the deleted network element configuration information can be obtained from the context. The deletion instruction is sent to the network element that matches the network service request through the configuration channel. When an exception occurs in the deletion configuration node, a rollback is performed to restore the deleted network element configuration information.
[0077] Among them, the update configuration node belongs to the network element configuration node, and the original network element configuration information to be modified and the modified configuration information can be obtained from the context. The modified configuration information is used to replace the original network element configuration information to be modified through the configuration channel. When an exception occurs in the update configuration node, a rollback is performed, and the network element configuration is restored to the state before the update using the original network element configuration information to be modified.
[0078] The formats of context input and output for different types of target configuration nodes are fixed. As long as the formats of context input and output are ensured, determining the corresponding target configuration node through the process selection node can ensure the correctness of network service execution. Figure 5 It is a schematic flowchart of the working process of a target configuration node provided in the second embodiment of the present invention. As Figure 5 shown,
[0079] First step, obtain the network service request, and store the newly added configuration information, updated configuration information, updated configuration information to be updated, and deletion configuration information into the context.
[0080] Second step, obtain the configuration information from the context in the order of configuration addition, configuration update, and configuration deletion; among them, if there is configuration addition, obtain the newly added configuration information from the context; if there is configuration update, obtain the updated configuration information and the updated configuration information to be updated from the context; if there is configuration deletion, obtain the deletion configuration information from the context.
[0081] Third step, obtain the service information in the context, execute the network service corresponding to the service information, and store the service information into the database.
[0082] Embodiment Three
[0083] Figure 6 It is a flowchart of a network service management method provided in the third embodiment of the present invention. On the basis of the above embodiment, the present embodiment further concretizes the above embodiment.
[0084] As Figure 6 shown, the method includes:
[0085] S610. Obtain a network service request, and store the data matching the network service request into the context.
[0086] S620. Parse the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the target service type and the target configuration information, and store them into the context.
[0087] S630. Determine the target configuration node matching the target service type through the process selection nodes in the responsibility chain, and add the target configuration node to the responsibility chain.
[0088] S640. Obtain the target configuration information and the target service type in the context through the target configuration node, and execute the network service matching the target service type on the target configuration information.
[0089] S660. Send the data acquisition request to the network element matching the network service request through the upload configuration node in the responsibility chain.
[0090] Among them, the upload configuration node can be a network element configuration node, which is used when synchronizing the SDN controller and the network element configuration. In the embodiments of the present invention, to send the data acquisition request to the network element matching the network service request, a get command can be sent to the network element matching the network service request through the configuration channel to obtain the configuration information of each network element.
[0091] S660. Receive the configuration information fed back by each network element, and store the configuration information into the context.
[0092] In the embodiments of the present invention, the configuration information fed back by each network element can be received through the data storage nodes in the responsibility chain and stored into the context, so that when subsequent network services are executed, the subsequent network service type and the configuration information can be determined by comparing the data matching the subsequent network service request and the stored configuration information.
[0093] An embodiment of the present invention provides a method for managing network services. The method includes obtaining a network service request and storing the data matching the network service request into the context; parsing, by a data analysis node in the responsibility chain, the data in the context that matches the network service request to obtain a target service type and target configuration information, and storing them into the context; determining, by a process selection node in the responsibility chain, a target configuration node that matches the target service type, and adding the target configuration node to the responsibility chain; obtaining, by the target configuration node, the target configuration information and the target service type in the context, and performing a network service that matches the target service type on the target configuration information; issuing, by an upload configuration node in the responsibility chain, a data acquisition request to a network element that matches the network service request; receiving the configuration information fed back by each network element, and storing the configuration information into the context. This technical solution can achieve real-time update of the network element configuration information and further improve the flexibility of the operation of the responsibility chain.
[0094] Based on the above embodiments, optionally, after storing the configuration information into the context, the method further includes steps B1 - B2:
[0095] Step B1: Obtain, by a data integration node in the responsibility chain, the configuration information fed back by each network element from the context.
[0096] Among them, the data integration node can be a data processing node that sorts and combines the configuration information stored in the context, and can be used when synchronizing the SDN controller and the network element configuration to achieve the synchronization of the configuration information in the database and the device database.
[0097] In an embodiment of the present invention, the configuration information fed back by each network element stored in the context can be read by the data integration node.
[0098] Step B2: Integrate each piece of configuration information to obtain network service information.
[0099] It can be understood that each piece of configuration information comes from different network elements, and there may be situations where their data structures, attribute names, or attribute values are inconsistent. In an embodiment of the present invention, each piece of configuration information can be transmitted to a specified location; processed according to cleaning rules in terms of data format, data encoding, data consistency, etc. to ensure the standardization of the configuration information in the database; and the cleaned configuration information is associated and processed according to a new data organization logic to obtain network service information.
[0100] It should be noted that if there is abnormal information when obtaining the configuration information fed back by each network element from the context through the data integration node in the responsibility chain, the part of the configuration information affected by the abnormality is indeed processed.
[0101] Further, the network service information can also be stored in a database through the data storage node in the responsibility chain to achieve persistent storage of data information. It should be noted that the data storage node is usually located at the end of the responsibility chain and does not need to implement rollback.
[0102] Further, through the concurrency control node in the responsibility chain, the read-write lock mechanism can be used to enable the data acquisition request issuing services to proceed simultaneously, preventing the data acquisition request issuing service and the synchronization network element configuration service from proceeding simultaneously. It should be noted that after locking a certain node, unlocking is required after rollback or normal service issuance is completed.
[0103] Embodiment 4
[0104] Figure 7 FIG. is a schematic structural diagram of a network service management device provided in Embodiment 4 of the present invention. As Figure 7 shown, the device includes:
[0105] A network service request acquisition module 710, configured to acquire a network service request and store data matching the network service request in a context;
[0106] A network service request parsing module 720, configured to parse the data matching the network service request in the context through a data analysis node in the responsibility chain to obtain a target service type and target configuration information, and store them in the context;
[0107] A target configuration node determination module 730, configured to determine a target configuration node matching the target service type through a process selection node in the responsibility chain, and add the target configuration node to the responsibility chain;
[0108] A network service execution module 740, configured to acquire the target configuration information and target service type in the context through the target configuration node, and execute a network service matching the target service type on the target configuration information.
[0109] An embodiment of the present invention provides a management device for network services. The device obtains a network service request and stores the data matching the network service request in the context. Through the data analysis node in the responsibility chain, the data in the context matching the network service request is parsed to obtain the target service type and the target configuration information, and then stored in the context. Through the process selection node in the responsibility chain, the target configuration node matching the target service type is determined and added to the responsibility chain. Through the target configuration node, the target configuration information and the target service type in the context are obtained, and the network service matching the target service type is executed on the target configuration information. This technical solution realizes the automatic parsing of network services, improves the flexibility of the operation of the responsibility chain, and reduces the operation cost of the responsibility chain.
[0110] Further, the network service request parsing module 720 includes:
[0111] A data acquisition unit, configured to obtain, through the data analysis node in the responsibility chain, the data in the context that matches the network service request;
[0112] A target service determination unit, configured to compare the data matching the network service request with the original configuration information in the database to determine the target service type and the target configuration information.
[0113] Further, the network service request parsing module 720 includes:
[0114] A forwarding information determination unit, configured to parse, through the data analysis node in the responsibility chain, the data in the context that matches the network service request to obtain a forwarding policy and an access route;
[0115] A target service type determination unit, configured to determine the target service type according to the forwarding policy and the access route.
[0116] Further, the target configuration node includes at least one of the following: a new configuration node, a delete configuration node, and an update configuration node;
[0117] Among them, the new configuration node is configured to obtain the new configuration information in the context and send the new configuration information and a new instruction to the network element that matches the network service request;
[0118] The delete configuration node is configured to obtain the delete configuration information in the context and send the delete configuration information and a delete instruction to the network element that matches the network service request;
[0119] The update configuration node is configured to obtain the original configuration information and the modified configuration information in the context and send the original configuration information, the modified configuration information, and an update instruction to the network element that matches the network service request.
[0120] Further, the target configuration node determination module 730 includes:
[0121] A node insertion position determination unit, configured to determine the insertion position of the target configuration node in the responsibility chain according to the execution order of the target service type in the network service.
[0122] Further, the apparatus further includes:
[0123] A data acquisition request sending module, configured to, after performing a network service matching the target service type on the target configuration information, send a data acquisition request to a network element matching the network service request through an upload configuration node in the responsibility chain;
[0124] A configuration information storage module, configured to receive configuration information fed back by each network element and store the configuration information in the context.
[0125] Further, the apparatus further includes:
[0126] A configuration information feedback module, configured to, after storing the configuration information in the context, obtain the configuration information fed back by each network element in the context through a data integration node in the responsibility chain;
[0127] A network service information determination module, configured to integrate each piece of configuration information to obtain network service information.
[0128] The network service management apparatus provided by the embodiments of the present invention can execute the network service management method provided by any embodiment of the present invention, and has corresponding functional modules and beneficial effects for executing the method.
[0129] Embodiment 5
[0130] Figure 8 FIG. is a schematic structural diagram of a network service management device provided by Embodiment 5 of the present invention. As Figure 8 shown, the electronic device includes a processor 70, a memory 71, an input device 72, and an output device 73; the number of processors 70 in the electronic device can be one or more, Figure 8 taking one processor 70 as an example; the processor 70, the memory 71, the input device 72, and the output device 73 in the electronic device can be connected through a bus or other means, Figure 8 taking connection through a bus as an example.
[0131] The memory 71, being a computer-readable storage medium, can be used to store software programs, computer-executable programs, and modules, such as the modules corresponding to the network service management method in the embodiments of the present invention (for example, the network service request acquisition module, network service request parsing module, target configuration node determination module, and network service execution module in the network service management device). The processor 70 executes various functional applications and data processing of the electronic device by running the software programs, instructions, and modules stored in the memory 71, that is, implements the above-mentioned network service management method. The method includes:
[0132] Obtain a network service request and store the data matching the network service request into the context;
[0133] Parse the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the target service type and target configuration information, and store them into the context;
[0134] Determine a target configuration node matching the target service type through the process selection nodes in the responsibility chain, and add the target configuration node to the responsibility chain;
[0135] Through the target configuration node, obtain the target configuration information and target service type in the context, and execute the network service matching the target service type on the target configuration information.
[0136] The memory 71 may mainly include a program storage area and a data storage area. Among them, the program storage area can store an operating system and application programs required for at least one function; the data storage area can store data created according to the use of the terminal, etc. In addition, the memory 71 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid-state storage devices. In some instances, the memory 71 may further include a memory remotely set relative to the processor 70, and these remote memories can be connected to the electronic device through a network. Examples of the above network include but are not limited to the Internet, enterprise intranet, local area network, mobile communication network, and their combinations.
[0137] The input device 72 can be used to receive input digital or character information, and generate key signal inputs related to the user settings and function control of the electronic device. The output device 73 may include display devices such as a display screen.
[0138] Embodiment Six
[0139] Embodiment Six of the present invention further provides a storage medium containing computer-executable instructions, and the computer-executable instructions are used to execute a network service management method when executed by a computer processor. The method includes:
[0140] Obtain a network service request and store the data matching the network service request in the context;
[0141] Parse the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the target service type and the target configuration information, and store them in the context;
[0142] Determine the target configuration node matching the target service type through the process selection node in the responsibility chain, and add the target configuration node to the responsibility chain;
[0143] Obtain the target configuration information and the target service type in the context through the target configuration node, and perform the network service matching the target service type on the target configuration information.
[0144] Certainly, for a storage medium containing computer-executable instructions provided by an embodiment of the present invention, the computer-executable instructions are not limited to the method operations described above, and can also execute related operations in the network service management method provided by any embodiment of the present invention.
[0145] From the above description of the embodiments, those skilled in the art can clearly understand that the present invention can be implemented by means of software and necessary general hardware. Of course, it can also be implemented by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present invention, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as a floppy disk, read-only memory (ROM), random access memory (RAM), flash memory (FLASH), hard disk or optical disc of a computer, etc., including several instructions to enable an electronic device (which can be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments of the present invention.
[0146] It should be noted that in the embodiments of the above network service management device, the included units and modules are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of mutual distinction and do not limit the protection scope of the present invention.
[0147] Note that the above is only a preferred embodiment of the present invention and the technical principles applied. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, re-adjustments and substitutions can be made by those skilled in the art without departing from the protection scope of the present invention. Therefore, although the present invention has been described in more detail through the above embodiments, the present invention is not limited to the above embodiments only. Without departing from the concept of the present invention, more other equivalent embodiments can be included, and the scope of the present invention is determined by the scope of the appended claims.
Claims
1. A management method for network services, characterized in that, Including: Obtain a network service request and store the data matching the network service request in the context; Parse the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the target service type and the target configuration information, and store them in the context; Determine the target configuration node matching the target service type through the process selection nodes in the responsibility chain, and add the target configuration node to the responsibility chain; Through the target configuration node, obtain the target configuration information and the target service type in the context, and execute the network service matching the target service type on the target configuration information; Among them, parsing the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the target service type and the target configuration information includes: Obtain the data matching the network service request in the context through the data analysis nodes in the responsibility chain; Compare the data matching the network service request with the original configuration information in the database to determine the target service type and the target configuration information.
2. The method according to claim 1, characterized in that, Parsing the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the target service type includes: Parse the data matching the network service request in the context through the data analysis nodes in the responsibility chain to obtain the forwarding policy and the access route; Determine the target service type according to the forwarding policy and the access route.
3. The method according to claim 1, wherein The target configuration node includes at least one of the following: a new configuration node, a delete configuration node, and an update configuration node; Among them, the new configuration node is used to obtain the new configuration information in the context, and send the new configuration information and the new instruction to the network element matching the network service request; The delete configuration node is used to obtain the delete configuration information in the context, and send the delete configuration information and the delete instruction to the network element matching the network service request; The update configuration node is used to obtain the original configuration information and the modified configuration information in the context, and send the original configuration information, the modified configuration information, and the update instruction to the network element matching the network service request.
4. The method according to claim 1, characterized in that, Adding the target configuration node to the responsibility chain includes: Determine the insertion position of the target configuration node in the responsibility chain according to the execution order of the target service type in the network service.
5. The method according to claim 1, characterized in that After executing the network service matching the target service type on the target configuration information, it further includes: Send a data acquisition request to the network element matching the network service request through the upload configuration node in the responsibility chain; Receive the configuration information fed back by each network element and store the configuration information in the context.
6. The method according to claim 5, characterized in that After storing the configuration information in the context, it further includes: Obtain the configuration information fed back by each network element in the context through the data integration node in the responsibility chain; Integrate each configuration information to obtain network service information.
7. An apparatus for managing network services, characterized in that, The device includes: A network service request acquisition module, configured to obtain a network service request and store the data matching the network service request in the context; A network service request parsing module, which is used to parse the data matching the network service request in the context through the data analysis nodes in the responsibility chain, obtain the target service type and target configuration information, and store them in the context; A target configuration node determination module, which is used to determine the target configuration node matching the target service type through the process selection nodes in the responsibility chain, and add the target configuration node to the responsibility chain; A network service execution module, which is used to obtain the target configuration information and target service type in the context through the target configuration node, and execute the network service matching the target service type on the target configuration information; Among them, the network service request parsing module includes: A data acquisition unit, which is used to acquire the data matching the network service request in the context through the data analysis nodes in the responsibility chain; A target service determination unit, which is used to compare the data matching the network service request with the original configuration information in the database to determine the target service type and target configuration information.
8. A management device for network services, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the management method of the network service according to any one of claims 1-6.
9. A storage medium storing computer-executable instructions, characterized in that, The computer-executable instructions are used to execute the management method of the network service according to any one of claims 1-6 when executed by a computer processor.
Citation Information
Patent Citations
Group insurance service processing method and system based on component responsibility chain
CN113706123A
Modeling method and device based on BPMN, equipment and storage medium
CN114791799A