Traffic control method and device based on application node grouping, equipment and medium

By identifying and parsing application nodes in the financial back-end service system, and combining load balancing strategies for grouping and condition judgment, the system overload and resource waste caused by application node call frequency are solved, achieving traffic control and balanced request distribution, and improving server performance and reliability.

CN117294768BActive Publication Date: 2026-11-24CHINA PING AN PROPERTY INSURANCE CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202311391893.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-25
Publication Date
2026-11-24
Estimated Expiration
2043-10-25

AI Technical Summary

Technical Problem

Increased call frequency of application nodes in financial back-end service systems leads to increased traffic, causing system overload and resource waste. Existing technologies struggle to effectively control traffic and balance load.

Method used

By using the registration center software toolkit to identify and parse rules for application nodes, and combining it with pre-built load balancing strategies, application nodes are grouped and conditions are judged to ensure that requests are forwarded to the appropriate target application nodes.

Benefits of technology

This achieves a balanced distribution of application node call requests, improves the performance and reliability of the backend application server, avoids excessive load on a single node, and reduces resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117294768B_ABST
    Figure CN117294768B_ABST
Patent Text Reader

Abstract

This invention relates to the field of artificial intelligence, disclosing a traffic control method, apparatus, electronic device, and storage medium based on application node grouping. It can be used to reduce traffic during high concurrency. The method includes: identifying application nodes using a registry center software toolkit to obtain application node identifiers; parsing the calling rules of application nodes using a rule parsing software toolkit to obtain rule parsing results; upon receiving an application node calling request from a client, performing application node condition judgments based on the application node identifiers and rule parsing results using a pre-built load balancing strategy to obtain a judgment result for each application node; forwarding the application node calling request to the target application node based on the judgment results; receiving the application node calling response from the target application node and returning the application node calling response to the client. This invention can improve the performance and reliability of backend application servers.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence, and in particular to a flow control method, apparatus, electronic device, and readable storage medium based on application node grouping. Background Technology

[0002] With the rapid development and expansion of financial business and financial application services, the number of application deployment nodes in the financial back-end service cluster has increased significantly, resulting in entropy increase when applications call each other. In addition, as the frequency of calls between applications increases, the traffic of the financial back-end service system will also increase, which can easily lead to overload and waste of resources in the financial back-end service system. Summary of the Invention

[0003] This invention provides a flow control method, apparatus, electronic device, and readable storage medium based on application node grouping, with the aim of improving the performance and reliability of backend application servers.

[0004] To achieve the above objectives, the present invention provides a flow control method based on application node grouping, the method comprising: The newly registered application nodes in the background application cluster are identified using the registration center software toolkit to obtain the application node identifier; The call rules of the application nodes are parsed using a rule parsing software toolkit to obtain the rule parsing results; When an application node call request is received from a client, the application node condition is judged based on the application node identifier and the rule parsing result, and the judgment result of each application node is obtained by using a pre-built load balancing strategy. Based on the judgment result, the application node call request is forwarded to the target application node in the background application cluster; Receive the application node call response sent by the target application node, and return the application node call response to the client.

[0005] Optionally, the step of using the registration center software toolkit to identify newly registered application nodes in the background application cluster to obtain application node identifiers includes: Obtain application node identification information and write the application node identification information into the registration center software toolkit; The registration center software toolkit is used to monitor the registration of application nodes in the background application cluster and obtain newly added application nodes. Connect the newly added application node to the interface of the registration center software toolkit to build an identifier transmission channel; Based on the application information of the newly added application node, the application node identification information is written into the newly added application node using the identification transmission channel to obtain the application node identification.

[0006] Optionally, the step of determining the application node conditions based on the application node identifier and the rule parsing result, using a pre-built load balancing strategy, to obtain the determination result for each application node, includes: Extract the request information and application node invocation method from the application node invocation request; The request information and the application node invocation method are matched with the application node identifier and the rule parsing result, respectively, to obtain the matching result; Determine whether the matching result satisfies the pre-built load balancing strategy; When the matching result satisfies the load balancing strategy, the application node call request is sent to the application node corresponding to the matching result for processing; If the matching result does not meet the load balancing strategy, then the application node is reselected according to the load balancing strategy.

[0007] Optionally, forwarding the application node call request to the target application node in the background application cluster based on the determination result includes: Extract the application node from the judgment result and use the application node as the target application node; Obtain the target URL and target request method of the target application node; Parse the application node call request to obtain the request header, request parameters, and request body; The request header, the request parameters, and the request body are authenticated to obtain the authentication result. Based on the verification result, the target URL, and the target request method, a forwarding request is constructed and sent to the target application node.

[0008] Optionally, before determining the application node conditions based on the application node identifier and the rule parsing result, and obtaining the determination result for each application node using a pre-built load balancing strategy, the method further includes: The application nodes are initially grouped according to the application node identifier to obtain preliminary application node groups; Based on the results of the rule parsing, the application nodes in the initial application node group are regrouped to obtain the target application node group.

[0009] Optionally, after parsing the calling rules of the application node using a rule parsing software toolkit to obtain the rule parsing result, the method further includes: The application node's calling rules are monitored in real time, and when the calling rules change, the rule parsing software toolkit is used to parse the changed calling rules to obtain the latest rule parsing results.

[0010] Optionally, after receiving the application node invocation response sent by the target application node and returning the application node invocation response to the client, the process includes: Record the client's access process and access results; The access process and the access result are asynchronously reported to the pre-built access storage database.

[0011] To address the above problems, the present invention also provides a flow control device based on application node grouping, the device comprising: The application node preprocessing module is used to identify newly registered application nodes in the background application cluster using the registration center software toolkit to obtain application node identifiers, and to parse the calling rules of the application nodes using the rule parsing software toolkit to obtain rule parsing results. The client request receiving module is used to, when receiving an application node call request sent by a client, perform application node condition judgment based on the application node identifier and the rule parsing result, use a pre-built load balancing strategy to obtain the judgment result for each application node, and forward the application node call request to the target application node in the background application cluster according to the judgment result. The client request and response module is used to receive the application node call response sent by the target application node and return the application node call response to the client.

[0012] To address the above problems, the present invention also provides an electronic device, the electronic device comprising: Memory, storing at least one computer program; and The processor executes the computer program stored in the memory to implement the application node grouping-based flow control method described above.

[0013] To address the aforementioned problems, the present invention also provides a computer-readable storage medium storing at least one computer program, which is executed by a processor in an electronic device to implement the above-described application node grouping-based flow control method.

[0014] This invention, by incorporating the registration center software toolkit, the rule parsing software toolkit, and the load balancing strategy into the backend application cluster, enables traffic control and request forwarding based on conditions and application node grouping. This achieves traffic control based on calling rules. Furthermore, when an application node call request is received from a client, the load balancing strategy ensures that the request is forwarded to a suitable application node, improving the performance and reliability of the backend application server. This achieves a balanced distribution of application node call requests, preventing excessive load on any single application node. Therefore, this invention provides a traffic control method, apparatus, device, and storage medium based on application node grouping, which can improve the performance and reliability of the backend application server. Attached Figure Description

[0015] Figure 1 This is a flowchart illustrating a flow control method based on application node grouping provided in an embodiment of the present invention. Figure 2 and Figure 3 This is a detailed implementation flowchart of one step in a traffic control method based on application node grouping provided in an embodiment of the present invention; Figure 4 A schematic diagram of a flow control device based on application node grouping provided in an embodiment of the present invention; Figure 5 This is a schematic diagram of the internal structure of an electronic device that implements a flow control method based on application node grouping, according to an embodiment of the present invention. The realization of the objective, functional features and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0016] It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

[0017] This invention provides a traffic control method based on application node grouping. The executing entity of the traffic control method based on application node grouping includes, but is not limited to, at least one of electronic devices such as servers and terminals that can be configured to execute the method provided in this application embodiment. In other words, the traffic control method based on application node grouping can be executed by software or hardware installed on terminal devices or server devices, and the software can be a blockchain platform. The server can include independent servers or cloud servers that provide basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms.

[0018] Reference Figure 1 The flowchart shown is a flow chart of a traffic control method based on application node grouping provided in an embodiment of the present invention. In this embodiment, the traffic control method based on application node grouping includes: S1. Use the registration center software toolkit to identify newly registered application nodes in the background application cluster to obtain application node identifiers.

[0019] In this embodiment of the invention, the registration center software toolkit is a customized software toolkit based on the application nodes in the background application cluster. The background application cluster can be a background application server. The application node can be a computer or server used to perform a specific task.

[0020] In an optional embodiment of the present invention, the function of the registration center software toolkit is to identify newly registered application nodes in the background application cluster. Therefore, before using the registration center software toolkit to identify newly registered application nodes in the background application cluster and obtaining application node identifiers, a customized version of the registration center software toolkit can be downloaded from the official website of the registration center provider or other reliable sources, and the registration center software toolkit can be written into the background application cluster.

[0021] Furthermore, in this embodiment of the invention, a registration center software toolkit is used to identify newly registered application nodes in the background application cluster to obtain application node identifiers, thereby classifying the application nodes. This ensures that the background application server can select the appropriate application node to respond to the application node call request sent by the client based on the application node identifier, avoiding the cumbersome response required by all application nodes to the application node call request sent by the client every time, and reducing the traffic of the background application server.

[0022] In detail, as an optional embodiment of the present invention, refer to Figure 2As shown, the step of using the registration center software toolkit to identify newly registered application nodes in the background application cluster to obtain application node identifiers includes: S11. Obtain application node identification information and write the application node identification information into the registration center software toolkit; S12. Use the registration center software toolkit to monitor the registration of application nodes in the background application cluster and obtain newly added application nodes. S13. Connect the newly added application node to the interface of the registration center software toolkit to build an identifier transmission channel; S14. Based on the application information of the newly added application node, the application node identification information is written into the newly added application node using the identification transmission channel to obtain the application node identification.

[0023] In this embodiment of the invention, the application node identification information can be the identification information set by relevant business personnel according to the application nodes they need. For example, in a financial system, application nodes often include insurance sales nodes, insurance recommendation nodes, and bank card processing nodes. Therefore, financial personnel can set identification information such as "insurance sales", "insurance recommendation", and "bank card processing" according to the application node information they have conceived in advance.

[0024] In an optional embodiment of the present invention, the method provided by the registration center software toolkit is used to discover new application nodes, and the new application nodes are connected to the interface of the registration center software toolkit. Further, application identification information is written into the new application nodes through the interface to obtain the application node identifier.

[0025] S2. Use a rule parsing software toolkit to parse the calling rules of the application node to obtain the rule parsing results.

[0026] In this embodiment of the invention, the function of the rule parsing software toolkit is to enable real-time monitoring of changes in application node call rule policies and rule parsing.

[0027] To ensure the smooth and efficient operation of the distributed system, in this embodiment of the invention, before using the rule parsing software toolkit to parse the call rules of the application nodes and obtain the rule parsing results, a customized version of the rule parsing software toolkit can be downloaded from the official website of the parsing engine provider or other reliable sources, and the rule parsing software toolkit can be written into the background application cluster.

[0028] Furthermore, as an optional embodiment of the present invention, after parsing the calling rules of the application node using a rule parsing software toolkit to obtain the rule parsing result, the method further includes: The application node's calling rules are monitored in real time, and when the calling rules change, the rule parsing software toolkit is used to parse the changed calling rules to obtain the latest rule parsing results.

[0029] This invention utilizes a rule parsing software toolkit to parse the calling rules of the application nodes, obtaining the rule parsing results, thereby enabling real-time monitoring and parsing of changes in the application node's calling rule strategy. This allows for timely response to rule changes, ensuring that the application node's calling strategy is always up-to-date.

[0030] S3. When an application node call request is received from the client, the application node condition is judged using the pre-built load balancing strategy based on the application node identifier and the rule parsing result, and the judgment result of each application node is obtained.

[0031] In this embodiment of the invention, the client can be a computer or mobile phone used by the client. The application node invocation request can be a client request instruction sent by the client user when using a certain application node. For example, when a client user needs to purchase insurance, it will send an insurance sales node invocation request to the backend service cluster to help the client user complete the insurance purchase. The constructed load balancing strategy refers to the strategy used to determine how to distribute requests to different servers to achieve load balancing.

[0032] To reduce the time required to respond to application node call requests sent by the client and improve the time to find the target application node, in an optional embodiment of the present invention, before performing application node condition judgment based on the application node identifier and the rule parsing result and using a pre-built load balancing strategy to obtain the judgment result for each application node, it is also necessary to group the application nodes.

[0033] In detail, as an optional embodiment of the present invention, before determining the application node conditions using a pre-built load balancing strategy based on the application node identifier and the rule parsing result to obtain the determination result for each application node, the method further includes: The application nodes are initially grouped according to the application node identifier to obtain preliminary application node groups; Based on the results of the rule parsing, the application nodes in the initial application node group are regrouped to obtain the target application node group.

[0034] In this embodiment of the invention, the application nodes are grouped according to two different methods, so that the application nodes in the same group have the same calling rules and application node identifiers, thereby improving the response efficiency and traffic balance of the application nodes.

[0035] Furthermore, in this embodiment of the invention, based on the application node identifier and the rule parsing result, a pre-built load balancing strategy is used to determine the application node conditions, and the determination result of each application node is obtained. In this way, a suitable application node is selected to respond to the application node call request, reducing the frequency of application node usage, thereby reducing the traffic when receiving application node call requests sent by the client and improving the stability of the background application server.

[0036] In detail, as an optional embodiment of the present invention, the step of using a pre-built load balancing strategy to determine the application node conditions based on the application node identifier and the rule parsing result, and obtaining the determination result for each application node, includes: Extract the request information and application node invocation method from the application node invocation request; The request information and the application node invocation method are matched with the application node identifier and the rule parsing result, respectively, to obtain the matching result; Determine whether the matching result satisfies the pre-built load balancing strategy; When the matching result satisfies the load balancing strategy, the application node call request is sent to the application node corresponding to the matching result for processing; If the matching result does not meet the load balancing strategy, then the application node is reselected according to the load balancing strategy.

[0037] In an optional embodiment of the present invention, a pre-built load balancing strategy is used to perform application node condition judgment on the selected application nodes, thereby determining the application nodes that need to be called, reducing the traffic when receiving application node call requests from clients, and improving the stability of the backend application server.

[0038] S4. Based on the judgment result, forward the application node call request to the target application node in the background application cluster.

[0039] In an optional embodiment of the present invention, when the judgment result is obtained, the corresponding application node in the background application cluster can be found according to the judgment result, and the application node can be used as the target application node to respond to the application node call request, thereby reducing the waste of resources on the background application server and avoiding multiple invalid application nodes from responding invalidly to the application node call request.

[0040] In detail, as an optional embodiment of the present invention, refer to Figure 3 As shown, forwarding the application node call request to the target application node in the background application cluster based on the judgment result includes: S41. Extract the application node from the judgment result and use the application node as the target application node; S42. Obtain the target URL and target request method of the target application node; S43. Parse the application node call request to obtain the request header, request parameters and request body; S44. Verify the request header, the request parameters, and the request body to obtain the verification result; S45. Based on the verification result, the target URL, and the target request method, construct a forwarding request and send the forwarding request to the target application node.

[0041] To ensure the legitimacy of the application node call request and the security of the data, this embodiment of the invention requires verification of the application node call request's identity and permissions before forwarding the request.

[0042] S5. Receive the application node call response sent by the target application node, and return the application node call response to the client.

[0043] In an optional embodiment of the present invention, when the target application node receives a forwarding request, it generates an application node call response based on the forwarding request and sends the application node call response to the forwarding request. Further, after the forwarding request application node receives the application node call response sent by the target application node, it returns the application node call response to the client, thereby ensuring that the client can accurately and timely receive the application node call response sent by the target application node.

[0044] Furthermore, to facilitate system administrators in managing the application nodes and promptly identifying problems in them, after receiving the application node call response sent by the target application node and returning the application node call response to the client, the optional embodiment of the present invention also needs to store the request-response process for each request.

[0045] In detail, as an optional embodiment of the present invention, after receiving the application node invocation response sent by the target application node and returning the application node invocation response to the client, the process includes: Record the client's access process and access results; The access process and the access result are asynchronously reported to the pre-built access storage database.

[0046] In this embodiment of the invention, by asynchronously reporting the client's access process and access results to a pre-built access storage database, it provides convenience for distributed system administrators to query and monitor the backend application cluster.

[0047] This invention, by incorporating the registration center software toolkit, the rule parsing software toolkit, and the load balancing strategy into the backend application cluster, enables traffic control and request forwarding based on conditions and application node grouping. This achieves traffic control based on calling rules. Furthermore, when an application node call request is received from a client, the load balancing strategy ensures that the request is forwarded to a suitable application node, improving the performance and reliability of the backend application server. This achieves a balanced distribution of application node call requests, preventing excessive load on any single application node. Therefore, this invention provides a traffic control method based on application node grouping, which can improve the performance and reliability of the backend application server.

[0048] like Figure 4 The diagram shown is a functional block diagram of the flow control device based on application node grouping of the present invention.

[0049] The application node grouping-based flow control device 100 of the present invention can be installed in an electronic device. Depending on the functions implemented, the flow control device 100 may include an application node preprocessing module 101, a client request receiving module 102, and a client request response module 103. The module mentioned in the present invention may also be referred to as a unit, which refers to a series of computer program segments that can be executed by the processor of an electronic device and can perform a fixed function, and are stored in the memory of the electronic device.

[0050] In this embodiment, the functions of each module / unit are as follows: The application node preprocessing module 101 is used to identify newly registered application nodes in the background application cluster using the registration center software toolkit to obtain application node identifiers, and to parse the calling rules of the application nodes using the rule parsing software toolkit to obtain rule parsing results.

[0051] In this embodiment of the invention, the registration center software toolkit is a customized software toolkit based on the application nodes in the background application cluster. The background application cluster can be a background application server. The application node can be a computer or server used to perform a specific task.

[0052] In an optional embodiment of the present invention, the function of the registration center software toolkit is to identify newly registered application nodes in the background application cluster. Therefore, before using the registration center software toolkit to identify newly registered application nodes in the background application cluster and obtaining application node identifiers, a customized version of the registration center software toolkit can be downloaded from the official website of the registration center provider or other reliable sources, and the registration center software toolkit can be written into the background application cluster.

[0053] Furthermore, in this embodiment of the invention, a registration center software toolkit is used to identify newly registered application nodes in the background application cluster to obtain application node identifiers, thereby classifying the application nodes. This ensures that the background application server can select the appropriate application node to respond to the application node call request sent by the client based on the application node identifier, avoiding the cumbersome response required by all application nodes to the application node call request sent by the client every time, and reducing the traffic of the background application server.

[0054] In detail, as an optional embodiment of the present invention, the step of using the registration center software toolkit to identify newly registered application nodes in the background application cluster to obtain application node identifiers includes: Obtain application node identification information and write the application node identification information into the registration center software toolkit; The registration center software toolkit is used to monitor the registration of application nodes in the background application cluster and obtain newly added application nodes. Connect the newly added application node to the interface of the registration center software toolkit to build an identifier transmission channel; Based on the application information of the newly added application node, the application node identification information is written into the newly added application node using the identification transmission channel to obtain the application node identification.

[0055] In this embodiment of the invention, the application node identification information can be the identification information set by relevant business personnel according to the application nodes they need. For example, in a financial system, application nodes often include insurance sales nodes, insurance recommendation nodes, and bank card processing nodes. Therefore, financial personnel can set identification information such as "insurance sales", "insurance recommendation", and "bank card processing" according to the application node information they have conceived in advance.

[0056] In an optional embodiment of the present invention, the method provided by the registration center software toolkit is used to discover new application nodes, and the new application nodes are connected to the interface of the registration center software toolkit. Further, application identification information is written into the new application nodes through the interface to obtain the application node identifier.

[0057] In this embodiment of the invention, the function of the rule parsing software toolkit is to enable real-time monitoring of changes in application node call rule policies and rule parsing.

[0058] To ensure the smooth and efficient operation of the distributed system, in this embodiment of the invention, before using the rule parsing software toolkit to parse the call rules of the application nodes and obtain the rule parsing results, a customized version of the rule parsing software toolkit can be downloaded from the official website of the parsing engine provider or other reliable sources, and the rule parsing software toolkit can be written into the background application cluster.

[0059] Furthermore, as an optional embodiment of the present invention, after parsing the calling rules of the application node using a rule parsing software toolkit to obtain the rule parsing result, the method further includes: The application node's calling rules are monitored in real time, and when the calling rules change, the rule parsing software toolkit is used to parse the changed calling rules to obtain the latest rule parsing results.

[0060] This invention utilizes a rule parsing software toolkit to parse the calling rules of the application nodes, obtaining the rule parsing results, thereby enabling real-time monitoring and parsing of changes in the application node's calling rule strategy. This allows for timely response to rule changes, ensuring that the application node's calling strategy is always up-to-date.

[0061] The client request receiving module 102 is used to, when receiving an application node call request sent by a client, perform application node condition judgment based on the application node identifier and the rule parsing result, use a pre-built load balancing strategy to obtain the judgment result for each application node, and forward the application node call request to the target application node in the background application cluster according to the judgment result.

[0062] In this embodiment of the invention, the client can be a computer or mobile phone used by the client. The application node invocation request can be a client request instruction sent by the client user when using a certain application node. For example, when a client user needs to purchase insurance, it will send an insurance sales node invocation request to the backend service cluster to help the client user complete the insurance purchase. The constructed load balancing strategy refers to the strategy used to determine how to distribute requests to different servers to achieve load balancing.

[0063] To reduce the time required to respond to application node call requests sent by the client and improve the time to find the target application node, in an optional embodiment of the present invention, before performing application node condition judgment based on the application node identifier and the rule parsing result and using a pre-built load balancing strategy to obtain the judgment result for each application node, it is also necessary to group the application nodes.

[0064] In detail, as an optional embodiment of the present invention, before determining the application node conditions using a pre-built load balancing strategy based on the application node identifier and the rule parsing result to obtain the determination result for each application node, the method further includes: The application nodes are initially grouped according to the application node identifier to obtain preliminary application node groups; Based on the results of the rule parsing, the application nodes in the initial application node group are regrouped to obtain the target application node group.

[0065] In this embodiment of the invention, the application nodes are grouped according to two different methods, so that the application nodes in the same group have the same calling rules and application node identifiers, thereby improving the response efficiency and traffic balance of the application nodes.

[0066] Furthermore, in this embodiment of the invention, based on the application node identifier and the rule parsing result, a pre-built load balancing strategy is used to determine the application node conditions, and the determination result of each application node is obtained. In this way, a suitable application node is selected to respond to the application node call request, reducing the frequency of application node usage, thereby reducing the traffic when receiving application node call requests sent by the client and improving the stability of the background application server.

[0067] In detail, as an optional embodiment of the present invention, the step of using a pre-built load balancing strategy to determine the application node conditions based on the application node identifier and the rule parsing result, and obtaining the determination result for each application node, includes: Extract the request information and application node invocation method from the application node invocation request; The request information and the application node invocation method are matched with the application node identifier and the rule parsing result, respectively, to obtain the matching result; Determine whether the matching result satisfies the pre-built load balancing strategy; When the matching result satisfies the load balancing strategy, the application node call request is sent to the application node corresponding to the matching result for processing; If the matching result does not meet the load balancing strategy, then the application node is reselected according to the load balancing strategy.

[0068] In an optional embodiment of the present invention, a pre-built load balancing strategy is used to perform application node condition judgment on the selected application nodes, thereby determining the application nodes that need to be called, reducing the traffic when receiving application node call requests from clients, and improving the stability of the backend application server.

[0069] In an optional embodiment of the present invention, when the judgment result is obtained, the corresponding application node in the background application cluster can be found according to the judgment result, and the application node can be used as the target application node to respond to the application node call request, thereby reducing the waste of resources on the background application server and avoiding multiple invalid application nodes from responding invalidly to the application node call request.

[0070] In detail, as an optional embodiment of the present invention, forwarding the application node call request to the target application node in the background application cluster according to the determination result includes: Extract the application node from the judgment result and use the application node as the target application node; Obtain the target URL and target request method of the target application node; Parse the application node call request to obtain the request header, request parameters, and request body; The request header, the request parameters, and the request body are authenticated to obtain the authentication result. Based on the verification result, the target URL, and the target request method, a forwarding request is constructed and sent to the target application node.

[0071] To ensure the legitimacy of the application node call request and the security of the data, this embodiment of the invention requires verification of the application node call request's identity and permissions before forwarding the request.

[0072] The client request-response module 103 is used to receive the application node call response sent by the target application node and return the application node call response to the client.

[0073] In an optional embodiment of the present invention, when the target application node receives a forwarding request, it generates an application node call response based on the forwarding request and sends the application node call response to the forwarding request. Further, after the forwarding request application node receives the application node call response sent by the target application node, it returns the application node call response to the client, thereby ensuring that the client can accurately and timely receive the application node call response sent by the target application node.

[0074] Furthermore, to facilitate system administrators in managing the application nodes and promptly identifying problems in them, after receiving the application node call response sent by the target application node and returning the application node call response to the client, the optional embodiment of the present invention also needs to store the request-response process for each request.

[0075] In detail, as an optional embodiment of the present invention, after receiving the application node invocation response sent by the target application node and returning the application node invocation response to the client, the process includes: Record the client's access process and access results; The access process and the access result are asynchronously reported to the pre-built access storage database.

[0076] In this embodiment of the invention, by asynchronously reporting the client's access process and access results to a pre-built access storage database, it provides convenience for distributed system administrators to query and monitor the backend application cluster.

[0077] This invention, by incorporating the registration center software toolkit, the rule parsing software toolkit, and the load balancing strategy into the backend application cluster, enables traffic control and request forwarding based on conditions and application node grouping. This achieves traffic control based on calling rules. Furthermore, when an application node call request is received from a client, the load balancing strategy ensures that the request is forwarded to a suitable application node, improving the performance and reliability of the backend application server. This achieves a balanced distribution of application node call requests, preventing excessive load on any single application node. Therefore, this invention provides a traffic control device based on application node grouping, which can improve the performance and reliability of the backend application server.

[0078] like Figure 5 The diagram shown is a structural schematic of an electronic device that implements the application node grouping-based flow control method of the present invention.

[0079] The electronic device may include a processor 10, a memory 11, a communication bus 12 and a communication interface 13, and may also include a computer program stored in the memory 11 and executable on the processor 10, such as a flow control program based on application node groups.

[0080] The memory 11 includes at least one type of readable storage medium, such as flash memory, portable hard drive, multimedia card, card-type memory (e.g., SD or DX memory), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 11 can be an internal storage unit of an electronic device, such as a portable hard drive. In other embodiments, the memory 11 can be an external storage device of the electronic device, such as a plug-in portable hard drive, Smart Media Card (SMC), Secure Digital (SD) card, Flash Card, etc. Furthermore, the memory 11 can include both internal and external storage units of the electronic device. The memory 11 can be used not only to store application software and various types of data installed on the electronic device, such as the code of a flow control program based on application node groups, but also to temporarily store data that has been output or will be output.

[0081] In some embodiments, the processor 10 may be composed of integrated circuits, such as a single packaged integrated circuit or multiple integrated circuits with the same or different functions, including combinations of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips. The processor 10 is the control unit of the electronic device, connecting various components of the entire electronic device through various interfaces and lines. It executes programs or modules stored in the memory 11 (e.g., flow control programs based on application node groups) and calls data stored in the memory 11 to perform various functions of the electronic device and process data.

[0082] The communication bus 12 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This bus can be divided into an address bus, a data bus, a control bus, etc. The communication bus 12 is configured to enable communication between the memory 11 and at least one processor 10, etc. For ease of illustration, only one thick line is used in the figure, but this does not indicate that there is only one bus or one type of bus.

[0083] Figure 5 Only electronic devices with components are shown; those skilled in the art will understand that... Figure 5The structure shown does not constitute a limitation on the electronic device and may include fewer or more components than shown, or combine certain components, or have different component arrangements.

[0084] For example, although not shown, the electronic device may also include a power supply (such as a battery) to power the various components. Preferably, the power supply can be logically connected to the at least one processor 10 through a power management device, thereby enabling functions such as charging management, discharging management, and power consumption management. The power supply may also include one or more DC or AC power supplies, recharging devices, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components. The electronic device may also include various sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be described in detail here.

[0085] Optionally, the communication interface 13 may include a wired interface and / or a wireless interface (such as a Wi-Fi interface, a Bluetooth interface, etc.), which is typically used to establish communication connections between the electronic device and other electronic devices.

[0086] Optionally, the communication interface 13 may further include a user interface, which may be a display, an input unit (such as a keyboard), or a standard wired or wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, or an OLED (Organic Light-Emitting Diode) touchscreen, etc. The display may also be appropriately referred to as a screen or display unit, used to display information processed in the electronic device and to display a visual user interface.

[0087] It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.

[0088] The application node grouping-based flow control program stored in the memory 11 of the electronic device is a combination of multiple computer programs that, when run in the processor 10, can achieve the following: The newly registered application nodes in the background application cluster are identified using the registration center software toolkit to obtain the application node identifier; The call rules of the application nodes are parsed using a rule parsing software toolkit to obtain the rule parsing results; When an application node call request is received from a client, the application node condition is judged based on the application node identifier and the rule parsing result, and the judgment result of each application node is obtained by using a pre-built load balancing strategy. Based on the judgment result, the application node call request is forwarded to the target application node in the background application cluster; Receive the application node call response sent by the target application node, and return the application node call response to the client.

[0089] Specifically, the processor 10's implementation method of the above-mentioned computer program can be found in [reference needed]. Figure 1 The descriptions of the relevant steps in the corresponding embodiments are not repeated here.

[0090] Furthermore, if the modules / units integrated into the electronic device are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. The computer-readable medium can be non-volatile or volatile. The computer-readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, or a read-only memory (ROM).

[0091] Embodiments of the present invention may also provide a computer-readable storage medium storing a computer program, which, when executed by a processor of an electronic device, can perform the following: The newly registered application nodes in the background application cluster are identified using the registration center software toolkit to obtain the application node identifier; The call rules of the application nodes are parsed using a rule parsing software toolkit to obtain the rule parsing results; When an application node call request is received from a client, the application node condition is judged based on the application node identifier and the rule parsing result, and the judgment result of each application node is obtained by using a pre-built load balancing strategy. Based on the judgment result, the application node call request is forwarded to the target application node in the background application cluster; Receive the application node call response sent by the target application node, and return the application node call response to the client.

[0092] Furthermore, the computer's usable storage medium may mainly include a program storage area and a data storage area, wherein the program storage area may store the operating system, applications required for at least one function, etc.; and the data storage area may store data created based on the use of blockchain nodes, etc.

[0093] In the several embodiments provided by this invention, it should be understood that the disclosed electronic devices, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and other division methods may be used in actual implementation.

[0094] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0095] Furthermore, the functional modules in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in the form of hardware plus software functional modules.

[0096] It will be apparent to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.

[0097] Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of the invention is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be embraced within the invention. No appended diagram markings in the claims should be construed as limiting the scope of the claims.

[0098] The blockchain referred to in this invention is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Essentially, a blockchain is a decentralized database, a chain of data blocks linked together using cryptographic methods. Each data block contains information about a batch of network transactions, used to verify the validity of the information (anti-counterfeiting) and generate the next block. A blockchain can include an underlying blockchain platform, a platform product service layer, and an application service layer.

[0099] Furthermore, it is clear that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. Multiple units or devices recited in a system claim may also be implemented by a single unit or device through software or hardware. The term "second class" is used to indicate names and does not indicate any specific order.

[0100] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.

Claims

1. A flow control method based on application node grouping, characterized in that, The method includes: The newly registered application nodes in the background application cluster are identified using the registration center software toolkit to obtain the application node identifier; The call rules of the application nodes are parsed using a rule parsing software toolkit to obtain the rule parsing results; The application nodes are initially grouped according to the application node identifier to obtain preliminary application node groups; Based on the rule parsing results, the application nodes in the initial application node group are regrouped to obtain the target application node group; When an application node call request is received from a client, the application node condition is judged based on the application node identifier and the rule parsing result, and the judgment result of each application node is obtained by using a pre-built load balancing strategy. Based on the judgment result, the application node call request is forwarded to the target application node in the background application cluster; Receive the application node call response sent by the target application node, and return the application node call response to the client; The step of determining the application node conditions based on the application node identifier and the rule parsing result, using a pre-built load balancing strategy, to obtain the determination result for each application node includes: Extract the request information and application node invocation method from the application node invocation request; The request information and the application node invocation method are matched with the application node identifier and the rule parsing result, respectively, to obtain the matching result; Determine whether the matching result satisfies the pre-built load balancing strategy; When the matching result satisfies the load balancing strategy, the application node call request is sent to the application node corresponding to the matching result for processing; If the matching result does not meet the load balancing strategy, then the application node is reselected according to the load balancing strategy.

2. The flow control method based on application node grouping as described in claim 1, characterized in that, The process of using the registration center software toolkit to identify newly registered application nodes in the background application cluster to obtain application node identifiers includes: Obtain application node identification information and write the application node identification information into the registration center software toolkit; The registration center software toolkit is used to monitor the registration of application nodes in the background application cluster and obtain newly added application nodes. Connect the newly added application node to the interface of the registration center software toolkit to build an identifier transmission channel; Based on the application information of the newly added application node, the application node identification information is written into the newly added application node using the identification transmission channel to obtain the application node identification.

3. The flow control method based on application node grouping as described in claim 1, characterized in that, The step of forwarding the application node call request to the target application node in the background application cluster based on the judgment result includes: Extract the application node from the judgment result and use the application node as the target application node; Obtain the target URL and target request method of the target application node; Parse the application node call request to obtain the request header, request parameters, and request body; The request header, the request parameters, and the request body are authenticated to obtain the authentication result. Based on the verification result, the target URL, and the target request method, a forwarding request is constructed and sent to the target application node.

4. The flow control method based on application node grouping as described in claim 1, characterized in that, After parsing the application node's calling rules using a rule parsing software toolkit to obtain the rule parsing results, the process further includes: The application node's calling rules are monitored in real time, and when the calling rules change, the rule parsing software toolkit is used to parse the changed calling rules to obtain the latest rule parsing results.

5. The flow control method based on application node grouping as described in claim 1, characterized in that, After receiving the application node call response sent by the target application node and returning the application node call response to the client, the process includes: Record the client's access process and access results; The access process and the access result are asynchronously reported to the pre-built access storage database.

6. A flow control device based on application node grouping, characterized in that, The device includes: The application node preprocessing module is used to identify newly registered application nodes in the background application cluster using the registration center software toolkit to obtain application node identifiers, and to parse the calling rules of the application nodes using the rule parsing software toolkit to obtain rule parsing results. The application node preprocessing module is further configured to perform preliminary grouping of the application nodes according to the application node identifier to obtain a preliminary application node group, and to further group the application nodes in the preliminary application node group according to the rule parsing result to obtain a target application node group. The client request receiving module is used to, when receiving an application node call request sent by a client, perform application node condition judgment based on the application node identifier and the rule parsing result, use a pre-built load balancing strategy to obtain the judgment result for each application node, and forward the application node call request to the target application node in the background application cluster according to the judgment result. The client request and response module is used to receive the application node call response sent by the target application node and return the application node call response to the client. The step of determining the application node conditions based on the application node identifier and the rule parsing result, using a pre-built load balancing strategy, to obtain the determination result for each application node includes: Extract the request information and application node invocation method from the application node invocation request; The request information and the application node invocation method are matched with the application node identifier and the rule parsing result, respectively, to obtain the matching result; Determine whether the matching result satisfies the pre-built load balancing strategy; When the matching result satisfies the load balancing strategy, the application node call request is sent to the application node corresponding to the matching result for processing; If the matching result does not meet the load balancing strategy, then the application node is reselected according to the load balancing strategy.

7. An electronic device, characterized in that, The electronic device includes: At least one processor; and, A memory communicatively connected to the at least one processor; wherein, The memory stores computer program instructions that can be executed by the at least one processor to enable the at least one processor to perform the application node grouping-based flow control method as described in any one of claims 1 to 6.

8. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the flow control method based on application node groups as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Microservice load balancing method based on SDN

    CN109587071A