Distributed computing power request scheduling method and system
Through the distributed computing power request scheduling method, search and match according to node priority and resource sorting, the mapping relationship between the requesting node and the server node is established, and the problems of local computing power shortage and high development costs in the existing technology are solved, achieving high efficiency The allocation of computing resources reduces service delay.
Patent Information
- Application Number
- CN202410923810.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-10
- Publication Date
- 2024-11-26
AI Technical Summary
The prior art can easily lead to local computing power shortage, high development costs, and large delays in server computing power scheduling.
Using the distributed computing power request scheduling method, the server can be assigned computing power set by receiving node priority and required computing resources, search and match according to node priority and resource sorting, and establish a mapping relationship between the requesting node and the server node, based on the minimum The computing power is allocated during service delay, and the distribution computing power set is updated to optimize resource allocation.
The server computing power scheduling process is simplified, the difficulty and cost of algorithm development is reduced, local computing power is avoided, and service delay is reduced.
Smart Images

Figure CN119025233A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of computer networks, and in particular, relates to a distributed computing power request scheduling method and system. Background Art
[0002] In the data service center, a large number of user requests are received every second, and these requests are generally processed by distributed servers. In response to these user requests, it is necessary to allocate server computing resources to each user node to process user requests. However, due to the large number of access devices and the distribution of servers at various nodes, it is necessary to reasonably schedule the computing power of the servers at each node to avoid network congestion.
[0003] At present, the scheduling of server computing power usually adopts the principle of proximity or centralized computing power scheduling. The principle of proximity means allocating service requests closest to user requests to nearby servers, while centralized computing power scheduling is to conduct comprehensive scheduling based on user requests and server resources. The former method is prone to local computing power shortages, while the latter method requires the design of a large and complex scheduling algorithm, which has high development costs, and the algorithm itself will also cause higher latency. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a distributed computing power request scheduling method and system for solving the problems that the existing computing power scheduling easily leads to local computing power shortage and high development costs.
[0005] In a first aspect of an embodiment of the present invention, a distributed computing power request scheduling method is provided, including:
[0006] Receive a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources;
[0007] Construct a set of allocatable computing power for server nodes and sort the allocatable computing power for each server node in the set;
[0008] In the same scheduling cycle, after sorting by node priority and required computing resources, each requesting node searches and matches in the allocatable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay;
[0009] Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated;
[0010] Based on the mapping relationship, computing resources are allocated to each requesting node.
[0011] In a second aspect of an embodiment of the present invention, a distributed computing power request scheduling system is provided, including:
[0012] A request receiving module, configured to receive a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources;
[0013] A collection construction module is used to construct a collection of allocatable computing power of server nodes and sort the allocatable computing power of each server node in the collection;
[0014] The search and matching module is used to search and match each requesting node in the allocatable computing power set after sorting them by node priority and required computing resources in the same scheduling cycle, and establish a mapping relationship between the requesting node and the server node under the constraint of minimum service delay;
[0015] Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated;
[0016] The computing power allocation module is used to allocate computing power resources to each requesting node based on the mapping relationship.
[0017] In a third aspect of an embodiment of the present invention, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method described in the first aspect of the embodiment of the present invention when executing the computer program.
[0018] In a fourth aspect of an embodiment of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method provided in the first aspect of the embodiment of the present invention are implemented.
[0019] In an embodiment of the present invention, by sorting the requesting nodes and node services, the requesting nodes search and match the node servers in order under the minimum delay constraint, and establish a mapping between the requesting nodes and the node servers to facilitate computing power scheduling and allocation. This not only simplifies the server computing power scheduling and allocation process and reduces the difficulty and cost of algorithm development, but also avoids local computing power shortages and reduces service delays. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0021] Figure 1 A schematic diagram of a flow chart of a distributed computing power request scheduling method provided by an embodiment of the present invention;
[0022] Figure 2 A schematic diagram of the structure of a distributed computing power request scheduling system provided by an embodiment of the present invention;
[0023] Figure 3 A schematic structural diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0024] In order to make the purpose, features and advantages of the present invention more obvious and easy to understand, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the embodiments described below are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0025] It should be understood that the term "including" and other similar expressions in the specification or claims of the present invention and the above-mentioned drawings are intended to cover non-exclusive inclusions, such as a process, method, system, or device including a series of steps or units is not limited to the listed steps or units. In addition, "first" and "second" are used to distinguish different objects, not to describe a specific order.
[0026] See also Figure 1 , a flow chart of a distributed computing power request scheduling method provided by an embodiment of the present invention includes:
[0027] S101, receiving a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources;
[0028] After receiving the node request, the requests with the same priority are divided into a group according to the node priority. The computing resources required for adjacent requests are compared according to the order in which the requests are initiated, and bubble sorting is performed in sequence to obtain the node computing power request data set.
[0029] S102, constructing a set of allocatable computing power of server nodes, and sorting the allocatable computing power of each server node in the set;
[0030] Each time a server is assigned a task, the available computing power (i.e., the allocable computing power) is updated in real time, and these available computing powers are sorted to obtain the sorted allocable computing power set of the server nodes.
[0031] When the computing power request includes a specific task type, a set of allocatable computing power is constructed for server nodes that can handle the specific task, and the allocatable computing power of the server nodes in the set is sorted.
[0032] When the computing power request contains a specific processing request, such as a login request, it is necessary to make a computing power request to the corresponding login service and build a corresponding collection for such servers used to process specific tasks. In this way, requests containing specific tasks will only be searched and matched in the corresponding collection to allocate computing power.
[0033] S103. In the same scheduling cycle, after sorting by node priority and required computing resources, each requesting node searches and matches in the allocatable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay;
[0034] The server will allocate computing power for all requests received within a scheduling cycle (for example, 30ms). The computing power requests received within the same scheduling cycle are generally allocated without distinguishing the order of time. However, when the available computing power is insufficient, the order of request time will be considered. For example, for requests of the same priority, requests with earlier time will be allocated first.
[0035] Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated;
[0036] In the process of searching and matching the requesting nodes, each requesting node is searched and matched according to the size of the required resources (i.e. the required computing power resources), from large to small. The node server with the smallest delay can be preferentially selected to allocate computing power. If the available computing power of the node server is less than the computing power required by the requesting node, the remaining unallocated part is reordered; or, computing power is allocated to each node in order from large to small, and the delay from the requesting node to the server is expressed as a distance value, and the matching method with the smallest distance is searched.
[0037] For example, the request of the first priority node is (A1, A2, A3), the required resources are (5, 3, 2), the second priority request is (B1, B2, B3, B4), the required resources are (7, 6, 4, 2), the node server is (S1, S2, S3, S4), and the available resources are (11, 10, 8, 4). Assuming that the delay from A1 to S1, S2, S3, and S4 is (0.21, 0.11, 0.15, and 0.09), the server S4 with the smallest delay can be selected first, and then A2, A3, and A4 are selected in turn. ’ 1 (A1 remaining unallocated resources); or, the delay between A and S is expressed as a distance, and algorithms such as random matching or fuzzy matching are used (to improve the efficiency of the algorithm, certain matching principles can be set, such as priority and matching with the smallest delay), to obtain the mapping relationship between the request node and the server, record the total distance of each matching scheme, and select the mapping method with the shortest distance.
[0038] Among them, for request nodes of the same priority, after being sorted according to the required computing resources, server node matching is performed in descending order; when the request resources of request nodes of the same priority are allocated, the server node matching corresponding to the request node of the next priority is performed.
[0039] Optionally, when the remaining capacity of the computing power that can be allocated by the server node is less than the computing resources required by each request node microservice, the corresponding request node is added to the queue to be allocated for waiting.
[0040] S104. Based on the mapping relationship, computing resources are allocated to each requesting node.
[0041] Based on the mapping relationship between the node server and the requesting node, computing resources are allocated to the requesting node.
[0042] In this embodiment, by sorting node requests and node servers, each requesting node searches for a match within the allocatable computing power set, and establishes a mapping relationship between the requesting node and the server node based on the minimum service delay constraint. This can greatly simplify the node computing power allocation process, while avoiding local computing power shortages, reducing scheduling development costs, and reducing service delays.
[0043] It should be understood that the serial numbers of the steps in the above embodiments do not imply a sequence of execution, and the execution sequence of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0044] Figure 2 A schematic diagram of the structure of a distributed computing power request scheduling system provided by an embodiment of the present invention, the system comprising:
[0045] A request receiving module 210 is used to receive a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources;
[0046] A set construction module 220 is used to construct a set of allocatable computing power of server nodes and sort the allocatable computing power of each server node in the set;
[0047] Optionally, when the computing power request includes a specific task type, a set of allocatable computing power is constructed for server nodes that can handle the specific task, and the allocatable computing power of the server nodes in the set is sorted.
[0048] Search and match module 230, used to search and match each requesting node in the allocatable computing power set after sorting by node priority and required computing resources in the same scheduling cycle, and establish a mapping relationship between the requesting node and the server node under the constraint of minimum service delay;
[0049] Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated;
[0050] Among them, for request nodes of the same priority, after being sorted according to the required computing resources, server node matching is performed in descending order; when the request resources of request nodes of the same priority are allocated, the server node matching corresponding to the request node of the next priority is performed.
[0051] Optionally, when the remaining capacity of the computing power that can be allocated by the server node is less than the computing resources required by each request node microservice, the corresponding request node is added to the queue to be allocated for waiting.
[0052] The computing power allocation module 240 is used to allocate computing power resources to each requesting node based on the mapping relationship.
[0053] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working process of the above-described system and module can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0054] Figure 3 1 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. The electronic device is used for scheduling and allocating server computing power. Figure 3 As shown, the electronic device 3 of this embodiment includes: a memory 310, a processor 320 and a system bus 330, wherein the memory 310 includes an executable program 3101 stored thereon, and those skilled in the art can understand that Figure 3 The electronic device structure shown in the figure does not constitute a limitation of the electronic device, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.
[0055] Combine the following Figure 3 A detailed introduction to the various components of electronic equipment:
[0056] The memory 310 can be used to store software programs and modules, and the processor 320 executes various functional applications and data processing of the electronic device by running the software programs and modules stored in the memory 310. The memory 310 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device (such as cache data), etc. In addition, the memory 310 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0057] The memory 310 includes an executable program 3101 of a network request method, and the executable program 3101 can be divided into one or more modules / units, which are stored in the memory 310 and executed by the processor 320 to perform computing power scheduling, etc. The one or more modules / units can be a series of computer program instruction segments that can complete specific functions, and the instruction segments are used to describe the execution process of the executable program 3101 in the electronic device 3. For example, the executable program 3101 can be divided into functional modules such as a request receiving module, a set building module, a search matching module, and a computing power allocation module.
[0058] The processor 320 is the control center of the electronic device. It uses various interfaces and lines to connect various parts of the entire electronic device. By running or executing software programs and / or modules stored in the memory 310, and calling data stored in the memory 310, it performs various functions of the electronic device and processes data, thereby monitoring the overall status of the electronic device. Optionally, the processor 320 may include one or more processing units; preferably, the processor 320 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, application programs, etc., and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 320.
[0059] The system bus 330 is used to connect the various functional components inside the computer, and can transmit data information, address information, and control information. Its types can be, for example, PCI bus, ISA bus, CAN bus, etc. The instructions of the processor 320 are transmitted to the memory 310 through the bus, and the memory 310 feeds back data to the processor 320. The system bus 330 is responsible for the data and instruction exchange between the processor 320 and the memory 310. Of course, the system bus 330 can also be connected to other devices, such as network interfaces, display devices, etc.
[0060] In the embodiment of the present invention, the executable program executed by the processor 320 included in the electronic device includes:
[0061] Receive a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources;
[0062] Construct a set of allocatable computing power for server nodes and sort the allocatable computing power for each server node in the set;
[0063] In the same scheduling cycle, after sorting by node priority and required computing resources, each requesting node searches and matches in the allocatable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay;
[0064] Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated;
[0065] Based on the mapping relationship, computing resources are allocated to each requesting node.
[0066] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and modules described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0067] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0068] As described above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A distributed computing power request scheduling method, characterized in that: include: Receive a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources; Construct a set of allocatable computing power for server nodes and sort the allocatable computing power for each server node in the set; In the same scheduling cycle, after sorting by node priority and required computing resources, each requesting node searches and matches in the allocatable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay; Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated; Based on the mapping relationship, computing resources are allocated to each requesting node.
2. The method according to claim 1, characterized in that The step of constructing a set of allocatable computing power of server nodes and sorting the allocatable computing power of each server node in the set further comprises: When the computing power request includes a specific task type, a set of allocatable computing power is constructed for the server nodes that can process the specific task, and the allocatable computing power of the server nodes in the set is sorted.
3. The method according to claim 1, characterized in that: Each requesting node searches and matches in the allocable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay, including: For request nodes of the same priority, they are sorted according to the required computing resources and then matched with server nodes from largest to smallest. When the resource allocation of the requesting nodes with the same priority is completed, the server node matching corresponding to the requesting node with the next priority is performed.
4. The method according to claim 1, characterized in that: Each requesting node searches and matches in the allocable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay, including: When the remaining capacity of the computing power that can be allocated by the server node is less than the computing resources required by the microservices of each request node, the corresponding request node is added to the queue to be allocated for waiting.
5. A distributed computing power request scheduling system, characterized in that: include: A request receiving module, configured to receive a computing power request from each requesting node, wherein the computing power request includes at least a node priority, a request time, and required computing resources; A collection construction module is used to construct a collection of allocatable computing power of server nodes and sort the allocatable computing power of each server node in the collection; The search and matching module is used to search and match each requesting node in the allocatable computing power set after sorting them by node priority and required computing resources in the same scheduling cycle, and establish a mapping relationship between the requesting node and the server node under the constraint of minimum service delay; Among them, when the computing resources required by the requesting node are greater than the computing power that can be allocated to the server node, the computing resources required by the requesting node are subtracted from the computing power that can be allocated to the server node, and the remaining required computing resources are sorted and searched and matched again. When the server nodes in the allocable computing power set are allocated computing power, the sorting of the server nodes in the allocable computing power set is updated; The computing power allocation module is used to allocate computing power resources to each requesting node based on the mapping relationship.
6. The system according to claim 5, characterized in that The step of constructing a set of allocatable computing power of server nodes and sorting the allocatable computing power of each server node in the set further comprises: When the computing power request includes a specific task type, a set of allocatable computing power is constructed for the server nodes that can process the specific task, and the allocatable computing power of the server nodes in the set is sorted.
7. The system according to claim 5, characterized in that Each requesting node searches and matches in the allocable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay, including: For request nodes of the same priority, they are sorted according to the required computing resources and then matched with server nodes from largest to smallest. When the resource allocation of the requesting nodes with the same priority is completed, the server node matching corresponding to the requesting node with the next priority is performed.
8. The system according to claim 5, characterized in that Each requesting node searches and matches in the allocable computing power set, and establishes a mapping relationship between the requesting node and the server node under the constraint of minimum service delay, including: When the remaining capacity of the computing power that can be allocated by the server node is less than the computing resources required by the microservices of each request node, the corresponding request node is added to the queue to be allocated for waiting.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of a distributed computing power request scheduling method as described in any one of claims 1 to 4 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed, the steps of a distributed computing power request scheduling method as described in any one of claims 1 to 4 are implemented.
