Task scheduling method and computer program product

CN122946142APending Publication Date: 2026-10-20HANGZHOU ROBAM APPLIANCES CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611149590.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-30
Publication Date
2026-10-20

AI Technical Summary

Technical Problem

[0003]然而,对于任务与节点固定绑定的调度方式,有可能造成部分执行节点资源过载,而部分执行节点资源闲置浪费的情况

Benefits of technology

[0015]本申请提供一种任务调度方法及计算机程序产品,其中任务调度方法,通过动态采集待调度任务到达时各节点的资源可用指标和历史运行效能指标,为后续动态智能选取目标执行节点提供可靠保障;通过引入历史运行效能指标和资源可用指标,综合确定各执行节点分别与待调度任务的适配度,实现对节点资源承载及节点执行时效的多维度综合评估。本申请提供的多维度综合评估机制从资源承载能力和执行时效两大维度综合评估任务与执行节点的适配度,评估依据更全面、且更贴合任务实际的执行需求,将待调度任务匹配至资源承载能力、任务执行效能均最优的目标执行节点,能够有效提升任务分配的精准度。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure FT_1
    Figure FT_1
  • Figure FT_2
    Figure FT_2
  • Figure FT_3
    Figure FT_3
Patent Text Reader

Abstract

This application discloses a task scheduling method and computer program product, relating to the field of distributed task scheduling platform technology. By dynamically collecting the resource availability indicators and historical performance indicators of each execution node when the task to be scheduled arrives, a reliable guarantee is provided for the subsequent dynamic intelligent selection of the optimal execution node. Based on the historical performance indicators and resource availability indicators, the suitability of each execution node with the task to be scheduled is determined, and the target execution node with the best resource carrying capacity and task execution performance is automatically matched to the task to be scheduled. While intelligently and automatically allocating tasks, the method ensures accurate task scheduling, thereby improving the operating performance of the task scheduling platform.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure generally relates to the field of distributed task scheduling platform technology, and more particularly to a task scheduling method and computer program product. Background Technology

[0002] In enterprise-level business systems and distributed architectures, the task scheduling platform is a core component ensuring the automation and efficient operation of business processes. Existing task scheduling platforms typically employ either static node allocation strategies or dynamic load balancing strategies for task distribution. Static node allocation strategies distribute new tasks directly to the corresponding execution nodes based on a fixed binding relationship between tasks and execution nodes. Dynamic load balancing strategies, on the other hand, dynamically determine the optimal execution node based on the real-time load of the execution nodes, and then distribute new tasks to this determined optimal execution node, such as the execution node with the lowest current resource load.

[0003] However, a scheduling method that fixes tasks to nodes may result in some execution nodes being overloaded while others remain idle and wasted. On the other hand, a scheduling method that selects the optimal execution node based on real-time load, considering only the remaining load of nodes, can easily lead to insufficient accuracy in task allocation. Summary of the Invention

[0004] In view of the above-mentioned defects or deficiencies in the existing technology, it is desirable to provide a task scheduling method and computer program product. By dynamically collecting the resource availability indicators and historical operating performance indicators of each execution node when the task to be scheduled arrives, a reliable guarantee is provided for the subsequent dynamic intelligent selection of the optimal execution node. Based on the historical operating performance indicators and resource availability indicators, the adaptability of each execution node to the task to be scheduled is determined, and the target execution node with the best resource carrying capacity and task execution performance is automatically matched to the task to be scheduled. While intelligently and automatically allocating tasks, the method ensures accurate task scheduling, thereby improving the operating performance of the task scheduling platform.

[0005] Firstly, this application provides a task scheduling method. The method includes: The resource availability indicators and historical performance indicators of each execution node when the task to be scheduled arrives are obtained, and the adaptability of each execution node to the task to be scheduled is determined based on the resource availability indicators and the historical performance indicators. The adaptability is used to characterize the degree of matching between the corresponding execution node and the task to be scheduled in terms of resource load carrying capacity and task execution timeliness. Based on the relationship between the multiple adaptability values, the target execution node corresponding to the task to be scheduled is determined, and the task to be scheduled is dispatched to the target execution node to start the execution process of the task to be scheduled.

[0006] In conjunction with the first aspect, in one possible implementation, determining the suitability of each execution node with the task to be scheduled includes: The compatibility between each execution node and the task to be scheduled is determined based on the node's available resource score, node's historical success rate score, task execution time adaptation score, task priority adaptation score, and the weight of each score. The node available resource score, the node historical success rate score, the task execution time adaptation score, and the task priority adaptation score are used to measure the idle level of the corresponding execution node, the reliability of executing similar tasks, the efficiency of executing similar tasks, and the degree of priority adaptation with the task to be scheduled, respectively.

[0007] In conjunction with the first aspect, in one possible implementation, determining the available resource score of the node includes: The available resource score of the node is determined based on the CPU availability, memory availability, and available slot ratio contained in the resource availability indicators, as well as the weight of each indicator. The available slot ratio is the ratio of the number of currently idle task slots of the corresponding execution node to the total number of slots for the maximum parallel tasks of the execution node.

[0008] In conjunction with the first aspect, in one possible implementation, the determination of the node's historical success rate score and task execution time adaptation score includes: The historical success rate score of the node is determined based on the success rate of performing similar tasks in the past N days, which are included in the historical operational efficiency indicators; N is a positive integer greater than 0. The task execution time adaptation score is determined based on the average time taken to execute similar tasks over the past N days, which are included in the historical operational efficiency indicators.

[0009] In conjunction with the first aspect, in one possible implementation, determining the task priority adaptation score includes: The task priority level is parsed from the task script information carried by the task to be scheduled, and the task priority adaptation score is determined according to the relationship between the weight of the task priority level and the weight of the priority level of the execution node.

[0010] In conjunction with the first aspect, in one possible implementation, determining the target execution node corresponding to the task to be scheduled based on the magnitude relationship of multiple fitness levels includes: When the target execution node includes a primary execution node and a backup execution node, the multiple adaptation scores are sorted from largest to smallest, the execution node with the highest adaptation score is selected as the primary execution node, and the execution node with the second highest adaptation score is selected as the backup execution node.

[0011] In conjunction with the first aspect, in one possible implementation, dispatching the task to be scheduled to the target execution node includes: If the number of concurrent tasks on the primary execution node does not reach the preset threshold, the task to be scheduled will be dispatched to the primary execution node. If the number of concurrent tasks on the node reaches the preset threshold, the task to be scheduled will be dispatched to the standby execution node.

[0012] In conjunction with the first aspect, in one possible implementation, the method further includes: If an anomaly is detected in the primary execution node during the execution of the scheduled task, a rescheduling flag is added to the scheduled task, and the scheduled task is reassigned to the backup execution node for re-execution.

[0013] In conjunction with the first aspect, in one possible implementation, dispatching the task to be scheduled to the target execution node includes: If there are multiple tasks to be scheduled, each task to be scheduled will be simultaneously dispatched to the corresponding target execution node to initiate a distributed parallel scheduling and execution process for multiple tasks to be scheduled.

[0014] Secondly, this application also provides a computer program product. This computer program product includes instructions that, when executed, cause the task scheduling method as described in the first aspect to be implemented.

[0015] This application provides a task scheduling method and a computer program product. The task scheduling method dynamically collects resource availability indicators and historical performance indicators of each node when a task arrives, providing a reliable guarantee for subsequent dynamic intelligent selection of target execution nodes. By introducing historical performance indicators and resource availability indicators, it comprehensively determines the suitability of each execution node with the task to be scheduled, achieving a multi-dimensional comprehensive evaluation of node resource capacity and execution timeliness. The multi-dimensional comprehensive evaluation mechanism provided by this application comprehensively evaluates the suitability between tasks and execution nodes from two dimensions: resource capacity and execution timeliness. The evaluation basis is more comprehensive and more in line with the actual execution needs of the task, matching the task to be scheduled to the target execution node with the optimal resource capacity and task execution performance, effectively improving the accuracy of task allocation.

[0016] Furthermore, precise matching of tasks to be scheduled with execution nodes not only ensures that tasks are allocated to execution nodes with reasonable load and good operating efficiency, but also avoids node overload or idleness, reduces scheduling failures, and ensures the overall stable operation of the platform. In high-concurrency, large-batch task scenarios, precise matching can also balance the load of each execution node, enabling the task scheduling platform to handle more concurrent task scheduling, enhancing the scheduling scalability of the task scheduling platform, and improving the overall system resource utilization of the task scheduling platform. Attached Figure Description

[0017] Other features, objects, and advantages of this application will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings: Figure 1 This is one of the flowcharts illustrating a task scheduling method in one embodiment; Figure 2 This is a schematic diagram of the target execution node determination process in one embodiment; Figure 3 This is a second flowchart illustrating a task scheduling method in one embodiment; Figure 4 This is a schematic diagram illustrating the process of determining the primary / standby execution node in one embodiment; Figure 5 This is the third flowchart of a task scheduling method in one embodiment; Figure 6 This is a schematic diagram of primary / standby execution node switching in one embodiment; Figure 7 This is a schematic diagram of the automatic fault migration process in one embodiment; Figure 8 This is a schematic diagram of the task scheduling process in one embodiment; Figure 9 Here is an overall flowchart of the task scheduling method in one embodiment; Figure 10 This is a schematic diagram of the structure of an electronic device in one embodiment. Detailed Implementation

[0018] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and not intended to limit it. Furthermore, it should be noted that, for ease of description, only the parts relevant to the invention are shown in the accompanying drawings.

[0019] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. The present application will now be described in detail with reference to the accompanying drawings and embodiments. Furthermore, the term "and / or" in this document is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. The terms "first" and "second," etc., in the specification and claims of the embodiments of this application are used to distinguish different objects, not to describe a specific order of objects.

[0020] In enterprise-level business systems and distributed architectures, the task scheduling platform is a core component ensuring the automation and efficient operation of business processes. Existing task scheduling platforms typically employ either static node allocation strategies or dynamic load balancing strategies for task distribution. Static node allocation strategies distribute new tasks directly to the corresponding execution nodes based on a fixed binding relationship between tasks and execution nodes. Dynamic load balancing strategies, on the other hand, dynamically determine the optimal execution node based on the real-time load of the execution nodes, and then distribute new tasks to this determined optimal execution node, such as the execution node with the lowest current resource load.

[0021] However, a scheduling method that fixes tasks to nodes may result in some execution nodes being overloaded while others remain idle and wasted. On the other hand, a scheduling method that selects the optimal execution node based on real-time load, considering only the remaining load of nodes, can easily lead to insufficient accuracy in task allocation.

[0022] To address the aforementioned technical problems, this application provides a task scheduling method and computer program product to solve the problem of unintelligent scheduling strategies in existing task scheduling platforms, such as static resource allocation and uneven resource allocation. This application dynamically collects the resource availability indicators and historical performance indicators of each execution node when the task to be scheduled arrives, providing a reliable guarantee for subsequent dynamic intelligent selection of the optimal execution node. Based on the historical performance indicators and resource availability indicators, the suitability of each execution node with the task to be scheduled is determined, and the target execution node with the optimal resource carrying capacity and task execution performance is automatically matched to the task to be scheduled. While intelligently and automatically allocating tasks, the method ensures accurate task scheduling, thereby improving the operating performance of the task scheduling platform.

[0023] The task scheduling method provided in this application is executed by a task scheduling platform, which can be a software program running on a server or electronic device, or a background service, etc. This application does not make any specific limitations in this regard.

[0024] Reference Figure 1The task scheduling method provided in this application includes the following steps 101 and 102.

[0025] Step 101: Obtain the resource availability indicators and historical operating performance indicators of each execution node when the task to be scheduled arrives, and determine the suitability of each execution node with the task to be scheduled based on the resource availability indicators and historical operating performance indicators.

[0026] Among them, the resource availability index is used to characterize the current idle resources of the execution node and the remaining load capacity that can be used to handle scheduled tasks; the resource availability index can measure the real-time resource idleness and load carrying capacity of the execution node.

[0027] Historical operational performance metrics are used to reflect the operational stability and timeliness of execution nodes when handling similar tasks. Operational stability reflects the probability of task execution anomalies or interruptions; execution timeliness reflects the overall time consumption and response speed of task execution. One possible implementation involves statistically analyzing the operational data of execution nodes handling similar tasks over historical periods to obtain characteristic metrics. These metrics can quantify the operational stability and timeliness of execution nodes from different dimensions.

[0028] For example, obtain the number of anomalies, task failure rate, frequency of running lag, and number of task interruptions of similar historical tasks to generate characteristic indicators of operational stability; and generate characteristic indicators of execution timeliness by analyzing the average time consumption, response latency, and task completion time fluctuation of similar historical tasks.

[0029] The execution nodes mentioned in step 101 can be available execution nodes, normal execution nodes, or idle execution nodes. Available execution nodes are those that meet basic operating conditions, such as normal network connectivity and no node downtime. Normal execution nodes meet both basic and additional operating conditions, with the additional condition being the absence of any operational anomalies. Idle execution nodes are those currently without any tasks running.

[0030] Adaptability is used to characterize the degree of matching between the execution node and the task to be scheduled in two dimensions: resource load carrying capacity and task execution timeliness.

[0031] Specifically, the task scheduling platform is logically divided into a node status acquisition layer and a dynamic allocation decision layer. The node status acquisition layer is configured to periodically and proactively collect node data from execution nodes. For example, it proactively collects data every 10 seconds.

[0032] For example, node data includes, but is not limited to, the node health status, resource availability metrics, and historical performance metrics of the execution node. The data collection method combines heartbeat reporting and active data retrieval to ensure data real-time performance and accuracy. Each collected node data set is uniformly stored in a pre-built metadata database; and for the same execution node, the node data collected in the i-th iteration (where i is an integer greater than or equal to 1) will overwrite the node data collected in the (i-1)-th iteration for that execution node, providing real-time node data for subsequent selection of the optimal execution node.

[0033] The dynamic allocation decision layer is configured to calculate the fit between each execution node and the task to be scheduled based on the resource availability index and historical performance index of each execution node when the task to be scheduled arrives, using a weighted scoring algorithm model. Based on the calculated fit, the target execution node with the best fit is selected.

[0034] For example, the metadata database pre-stores a node data information table. The first row of the node data information table includes a node health status field, a resource availability indicator field, and a historical operation indicator field. The first column of the node data information table includes node numbers 1, 2, 3, ... Each time node data is collected, it is written into the node data information table according to the node number and the corresponding fields to provide real-time node data to the dynamic allocation decision-making layer.

[0035] Node health status includes, but is not limited to, idle, normal, overloaded, and offline.

[0036] It should be noted that the node status acquisition layer, which periodically and proactively collects data from each node, includes not only node health status, resource availability metrics, and historical performance metrics, but also basic node information. This basic information includes, but is not limited to, the node server name, the node's Internet Protocol (IP) address, the node's priority level (high / medium / low), and the node's operating status. The node server name is a unique identifier for the executing node, used to distinguish each executing node. For example, the node status acquisition layer collects node data from node (node)-007 with the IP address 192.168.1.101; node-007 is the unique identifier for this executing node.

[0037] Node operating status includes, but is not limited to, available and unavailable. Unavailable includes node failure, node network interruption, node resource overload, etc.; node failure can be due to hardware or software abnormalities of the node itself, such as node memory corruption or node file system corruption.

[0038] When a task to be scheduled arrives at the task scheduling platform, the dynamic allocation decision layer can form a list of available nodes based on the health status and / or running status of all execution nodes; each execution node in the list of available nodes participates in the subsequent adaptation calculation.

[0039] For example, the dynamic allocation decision layer can read the node health status of all execution nodes from the metadata database, and then select execution nodes with normal or idle health status from all node health statuses to form a list of available nodes.

[0040] Alternatively, the dynamic allocation decision layer can extract the node running status of all execution nodes from the metadata database, filter out invalid nodes from all node running statuses, and form a list of available nodes based on the remaining execution nodes; here, invalid nodes are execution nodes whose node running status is unavailable.

[0041] Alternatively, the dynamic allocation decision layer can filter out invalid nodes from the health status and running status of all nodes, and form a list of available nodes based on the remaining execution nodes; here, invalid nodes include: execution nodes whose running status is unavailable, and execution nodes whose health status is overloaded or offline.

[0042] For each execution node in the available node list, a suitability score is generated for each execution node. Specifically, the dynamic allocation decision layer can also extract real-time node data for each execution node from the metadata database, and extract resource availability indicators and historical performance indicators from the real-time node data. Furthermore, a weighted scoring algorithm model is used to calculate the suitability score of each execution node with the task to be scheduled, so as to select the optimal target execution node based on the suitability score of each execution node.

[0043] Step 102: Based on the relationship between multiple fitness levels, determine the target execution node corresponding to the task to be scheduled, and dispatch the task to be scheduled to the target execution node to start the execution process of the task to be scheduled.

[0044] Specifically, the dynamic allocation decision layer can select the execution node with the highest fitness as the target execution node based on the relationship between multiple fitness levels; or, it can select the first execution node whose fitness level reaches or exceeds the minimum fitness threshold as the target execution node by setting a minimum fitness threshold in advance.

[0045] For example, suppose the list of available nodes includes node A, node B, and node C, refer to Figure 2The target execution node determination process, as shown, involves a dynamic allocation decision layer calculating the fit (X1) between node A and the task to be scheduled, the fit (X2) between node B and the task to be scheduled, and the fit (X3) between node C and the task to be scheduled, based on the latest collected resource availability indicators and historical operational efficiency indicators of nodes A, B, and C, respectively. These three fits (X1, X2, and X3) are then sorted from largest to smallest, resulting in a ranking of X1 > X3 > X2. Node A, corresponding to the highest fit (X1), is then selected as the target execution node. The task execution dispatch layer dispatches the task to be scheduled via Remote Procedure Call (RPC), distributing it to node A.

[0046] It should be noted that the task scheduling platform also deploys a task dispatch execution layer. The dynamic allocation decision layer, upon determining the target execution node, instructs the task dispatch execution layer to assign the task to be scheduled to the target execution node in real time and initiates the task execution process. The task execution process includes: pushing the task to be scheduled to the target execution node via RPC, completing task dispatch; and the target execution node, upon receiving the task, creating an execution process and starting it.

[0047] In addition, the task scheduling platform also deploys a scheduling effect feedback layer. This layer is configured to automatically collect execution result data after task execution and send it to the weighted scoring algorithm model for continuous iterative optimization. Specifically, it automatically adjusts the parameters in the weighted scoring algorithm model based on the execution result data, such as adjusting parameters involved in the fit calculation (e.g., weights), to ensure that subsequent scheduling allocation becomes increasingly accurate and efficient.

[0048] For example, the execution result data includes, but is not limited to, the actual execution time of the task, resource usage, execution result (success / failure / timeout), node load changes, task queuing time, allocation time, and abnormal reasons such as node failure, insufficient resources, and incomplete prerequisite tasks.

[0049] The task scheduling method provided in this application dynamically collects resource availability indicators and historical performance indicators of each node when a task to be scheduled arrives, providing a reliable guarantee for subsequent dynamic and intelligent selection of target execution nodes. By introducing historical performance indicators and resource availability indicators, the method comprehensively determines the suitability of each execution node with the task to be scheduled, achieving a multi-dimensional comprehensive evaluation of node resource capacity and execution timeliness. The multi-dimensional comprehensive evaluation mechanism provided in this application comprehensively evaluates the suitability between tasks and execution nodes from two dimensions: resource capacity and execution timeliness. The evaluation basis is more comprehensive and more in line with the actual execution needs of the task, matching the task to be scheduled to the target execution node with the best resource capacity and task execution performance, which can effectively improve the accuracy of task allocation decisions.

[0050] Furthermore, precise matching of tasks to be scheduled with execution nodes not only ensures that tasks are allocated to execution nodes with reasonable load and good operating efficiency, but also avoids node overload or idleness, reduces scheduling failures, and ensures the overall stable operation of the platform. In high-concurrency, large-batch task scenarios, precise matching can also balance the load of each execution node, enabling the task scheduling platform to handle more concurrent task scheduling, enhancing the scheduling scalability of the task scheduling platform, and improving the overall system resource utilization of the task scheduling platform.

[0051] Based on the above Figure 1 In one embodiment of the method shown, step 101, "determining the suitability of each execution node with the task to be scheduled," specifically includes: Based on the node's available resource score, node's historical success rate score, task execution time adaptation score, and task priority adaptation score, as well as the weight of each score, the adaptation degree of each execution node to the task to be scheduled is determined.

[0052] The node available resource score measures the idle level of the execution node; the node historical success rate score measures the reliability of the execution node in performing similar tasks; and the task execution time adaptation score measures the efficiency of the execution node in performing similar tasks. "Similar tasks" refers to tasks of the same type as the task to be scheduled.

[0053] Task priority fit score is used to measure the degree of fit between the priority of the execution node and the priority of the task to be scheduled.

[0054] Specifically, for each execution node in the available node list, the dynamic allocation decision layer can comprehensively evaluate the execution node based on indicators such as CPU availability, memory availability, and the percentage of available slots to obtain a node available resource score S1; it can determine a task priority matching score S2 based on the relationship between the task priority level weight of the task to be scheduled and the node priority level weight; it can determine a node historical success rate score S3 based on the success rate of the execution node in executing similar tasks in the recent period; and it can determine a task execution time matching score S4 for each execution node in the available node list based on the average execution time of all execution nodes in executing similar tasks in the recent period and the average execution time of each execution node in the available node list in executing similar tasks in the recent period.

[0055] Furthermore, the weights of node available resource scores, node historical success rate scores, task execution time adaptation scores, and task priority adaptation scores are used to adjust the importance of the corresponding scores to the adaptation calculation results. By adjusting the weights of each scoring indicator, the final calculated adaptation score is made to better reflect the scheduling needs of the actual business scenario. In one possible implementation, the task scheduling platform provides a system configuration interface, which includes weight configuration items, allowing for flexible adjustment of the weights of each scoring indicator.

[0056] In another possible implementation, the weights of each scoring indicator can be obtained based on the mapping relationship between the business scenario and the scoring weights of different dimensions. Table 1 shows one possible mapping relationship.

[0057] Table 1

[0058] In Table 1, the resource weight is the weight of the node's available resource score, the priority weight is the weight of the task priority adaptation score, the success rate weight is the weight of the node's historical success rate score, and the time consumption weight is the weight of the task execution time adaptation score.

[0059] Based on the business scenario of the task to be scheduled, obtain the weight w1 of node available resource score S1, the weight w2 of task priority adaptation score S2, the weight w3 of node historical success rate score S3, and the weight w4 of task execution time adaptation score S4 from Table 1, and calculate the adaptation degree S of each execution node with the task to be scheduled according to formula (1).

[0060] S=S1 w1+S2 w2+ S3 w3+S4 w4(1) It should be noted that the calculated fit scores can be normalized and weighted, converting them into scores ranging from 0 to 100. Furthermore, as shown in Table 1, resource weights, priority weights, success rate weights, and time consumption weights can all be adjusted according to the business scenario, ensuring algorithm flexibility. A higher fit score indicates a more suitable execution node for the current scheduled task.

[0061] The task scheduling method provided in this application introduces a multi-dimensional weighted scoring mechanism to comprehensively evaluate the matching degree between the execution node and the task to be scheduled from four dimensions: the idle level of the execution node, its historical reliability, its historical efficiency level, and its suitability with the priority of the task. The entire comprehensive evaluation process not only considers the idle resource status of the execution node, avoiding resource overload, but also takes into account the historical operational reliability of the execution node, reducing the risk of task execution failure and providing a reliable guarantee for subsequently determining the optimal execution node, thereby significantly improving the accuracy, efficiency, and stability of task scheduling.

[0062] In one embodiment, determining the available resource score of a node can be achieved through the following steps: determining the available resource score of a node based on the resource availability indicators, including the availability of the Central Processing Unit (CPU), memory availability, and the percentage of available slots, as well as the weight of each indicator.

[0063] The weights for each metric are: CPU availability, memory availability, and the percentage of available slots. A slot is a logical unit within an execution node used to run a single task; each slot has the capability to run one task.

[0064] The available slot ratio is the ratio of the number of currently idle task slots on the execution node to the maximum total number of parallel task slots.

[0065] CPU availability is used to quantify the idle state of CPU resources on an execution node. It can be the ratio of currently idle CPUs on the execution node to the total CPUs. A higher CPU availability means that the execution node has sufficient CPU resources and can handle more computationally intensive tasks.

[0066] Memory availability is used to quantify the degree of idleness of the execution node's memory resources. It can be the ratio of the execution node's currently unused memory to the node's total memory. Unused memory can be memory resources that can be used to carry out tasks to be scheduled.

[0067] The weights of each metric include the CPU weight corresponding to CPU availability, the memory weight corresponding to memory availability, and the slot weight corresponding to the percentage of available slots.

[0068] Specifically, the execution node can periodically calculate its own CPU availability, memory availability, and available slot bit ratio, integrate them into resource availability indicators, and then periodically report them to the node status collection layer.

[0069] For example, CPU availability, memory availability and available slot bit percentage are calculated using equations (2) to (4).

[0070] CPU availability = (Total CPU on the node - CPU currently in use) / Total CPU on the node 100% (2) Memory availability = (Total node memory - Used memory) / Total node memory 100% (3) Available slot bit percentage = (Maximum task concurrency - Current task concurrency) / Maximum task concurrency 100% (4) In equations (2) to (4), (total CPU of the node - CPU used) represents the currently idle CPU of the execution node, (total memory of the node - memory used) represents the unused memory of the execution node that can currently be used to carry the scheduled tasks; the current task concurrency number represents the number of slots of the currently running tasks of the execution node, that is, the number of slots currently occupied; the maximum task concurrency number represents the total number of slots of the maximum parallel tasks of the execution node.

[0071] When the dynamic allocation decision layer obtains the resource availability indicators of each execution node from the metadata database, and the resource availability indicators include CPU availability, memory availability and available slot bit ratio, the node available resource score S1 of each execution node is calculated by formula (5).

[0072] S1 = (CPU availability) CPU weight + memory availability Memory weight + percentage of available slots Slot weight) 100 (5) In equation (5), CPU weight, memory weight, and slot weight are sub-weights within the resource dimension, which can be adjusted according to business needs. For example, sub-weights of 0.4, 0.4, and 0.2 are used.

[0073] The more remaining resources an execution node has, the higher its available resource score S1 will be; conversely, the fewer remaining resources an execution node has, the lower its available resource score S1 will be.

[0074] The task scheduling method provided in this application incorporates three key parameters—CPU availability, memory availability, and the percentage of available slots—along with their respective weights, into a comprehensive evaluation of node available resource scores. This ensures that the entire evaluation process can comprehensively assess the computing power, storage capacity, and task concurrency carrying capacity of the execution node, significantly improving the accuracy of node available resource scores. Consequently, it can comprehensively and accurately reflect the actual idle resource status of the execution node, providing a more reliable foundation for subsequent adaptation calculations.

[0075] In one embodiment, it can be achieved by... Figure 3 Steps 201 and 202 shown determine the node's historical success rate score and task execution time adaptation score.

[0076] Step 201: Determine the historical success rate score of the node based on the success rate of performing similar tasks in the past N days, which are included in the historical operational efficiency indicators; N is a positive integer greater than 0.

[0077] Step 202: Determine the task execution time adaptation score based on the average time taken to execute similar tasks in the past N days, which are included in the historical operational efficiency indicators.

[0078] Among them, "same type of task" refers to tasks of the same type as the task to be scheduled.

[0079] It should be noted that steps 201 and 202 can be executed simultaneously or sequentially.

[0080] Specifically, considering that historical operational performance indicators are collected and reported to the node status collection layer by the execution nodes at regular intervals, the execution nodes can periodically calculate their own success rate in performing similar tasks in the past N days, as well as the average time spent in performing similar tasks in the past N days, integrate them into historical operational performance indicators, and then report them to the node status collection layer at regular intervals.

[0081] For example, the node historical success rate score S3 and the task execution time adaptation score S4 of the execution node are calculated by equations (6) to (7).

[0082] S3 = (Number of successful executions of the same type of task by the node in the past N days / Total number of executions of the same type of task by the node in the past N days) 100% 100 (6) S4 = (Average time spent by all execution nodes on similar tasks in the past N days / Average time spent by the target node on similar tasks in the past N days) 100% 100 (7) In equations (6) to (7), the average time taken by all execution nodes to perform the same type of task in the past N days is specifically the sum of the average time taken by each execution node in the available node list to perform the same type of task in the past N days; the nodes in equation (6) and the target node in equation (7) are any execution node in the available node list. For example, N=7.

[0083] It should be noted that if the average time of all execution nodes performing the same type of task in the past N days is less than the average time of the target node performing the same type of task in the past N days, then the task execution time adaptation score S4 = 100; conversely, if the average time of all execution nodes performing the same type of task in the past N days is greater than or equal to the average time of the target node performing the same type of task in the past N days, then the task execution time adaptation score S4 is calculated by formula (7).

[0084] The task scheduling method provided in this application generates a corresponding score based on the success rate of nodes recently executing similar tasks in historical performance indicators. This not only reflects the recent actual operating status of the execution nodes but also quantifies the reliability of the execution nodes in handling specific types of tasks. By comparing the average efficiency of a single node recently executing similar tasks with the overall average efficiency of all nodes recently executing similar tasks, a corresponding score is generated. This effectively evaluates the efficiency level of the execution nodes in handling similar tasks, solves the problem that efficiency cannot be judged by relying solely on the time consumed by a single node, and provides a reliable guarantee for the accurate calculation of subsequent adaptability.

[0085] In one embodiment, determining the task priority adaptation score can be achieved through the following steps: The task priority level is parsed from the task script information carried by the task to be scheduled, and the task priority adaptation score is determined according to the relationship between the weight of the task priority level and the weight of the priority level of the execution node.

[0086] The task script information describes the execution logic and configuration data of the task to be scheduled, and includes the metadata of the task to be scheduled, such as the task identifier (ID), task name, task type and task priority level (high / medium / low).

[0087] Specifically, the task scheduling platform also deploys a task feature parsing layer. This layer is configured to, when a task enters the platform, obtain the task script information carried by the task, and perform structured parsing and feature extraction on the script information to obtain task feature information. This task feature information includes, but is not limited to, task ID, task name, task type, and task priority level; furthermore, this information is also stored in a metadata database.

[0088] In this embodiment, the metadata database stores a task feature information table in addition to the node data information table. The first row of the task feature information table includes a task ID field, a task name field, a task type field, and a task priority level field. The first column of the task feature information table is the task number 1, 2, 3, ... The task feature information of the tasks to be scheduled can be written into the task feature information table to provide the required task data, such as the task priority level, to the dynamic allocation decision layer.

[0089] In addition, the basic node information in the node data includes, but is not limited to: node server name, node IP address, node priority level (high / medium / low), and node running status. When the dynamic allocation decision layer fills the node data of the execution nodes into the node data information table, the node priority level of each execution node can be obtained by searching the metadata database.

[0090] Subsequently, the node priority level weight of each execution node is compared with the task priority level weight of the task to be scheduled.

[0091] If the node priority level weight is greater than or equal to the task priority level weight, then the task priority adaptation score S2 = 100; otherwise, if the node priority level weight is less than the task priority level weight, then the task priority adaptation score S2 is calculated by formula (8).

[0092] S2 = Node priority level weight / Task priority level weight 100 (8) It should be noted that the higher the match between the priority of the task to be scheduled and the priority of the execution node, the higher the corresponding task priority adaptation score S2. In addition, the weight values ​​corresponding to the priority level (high / medium / low) can be adjusted according to business needs. For example, a 10-point weight system can be used for quantitative representation, as shown in Tables 2 and 3.

[0093] Table 2

[0094] Table 3

[0095] If the list of available nodes contains execution node 1, execution node 2, and execution node 3, and execution node 1, execution node 2, and execution node 3 are respectively denoted as node1, node2, and node3, and the tasks to be scheduled are task1 and task2, then the complete calculation process of the task priority adaptation score S2 can be referred to Table 4.

[0096] Table 4

[0097] In Table 4, node1 has a priority level weight of 9.2 (high priority). If task1 also has a priority level weight of 9.2 (high priority), then S2 = 100.00 (because 9.2 = 9.2). If task2 has a priority level weight of 7.0, then S2 = 100.00 (because 9.2 > 7.0).

[0098] If node2 has a priority level weight of 7.2 (medium priority), and task1 has a priority level weight of 9.2 (high priority), then S2 = (7.0 / 9.2) × 100 ≈ 76.09 (because 7.0 < 9.2); if task2 has a priority level weight of 7.0 (medium priority), then S2 = 100.00 (because 7.0 = 7.0).

[0099] If node3 has a priority level weight of 4.5 (low priority), and task1 has a priority level weight of 9.2 (high priority), then S2 = (4.5 / 9.2) × 100 ≈ 48.91 (because 4.5 < 9.2); if task2 has a priority level weight of 7.0 (medium priority), then S2 = (4.5 / 7.0) × 100 ≈ 64.29 (because 4.5 < 7.0).

[0100] The task scheduling method provided in this application introduces a task priority level calculation mechanism, which enables the task priority adaptation score to accurately reflect the matching degree between the execution node and the task to be scheduled in the priority dimension. This not only improves the accuracy of the overall adaptation calculation of the execution node, but also ensures that high-priority tasks are intelligently matched to the optimal execution node, effectively avoiding delays caused by node mismatch, thereby significantly improving the rationality and reliability of task scheduling.

[0101] Based on the above Figure 1 In one embodiment of the method shown, step 102, "determining the target execution node corresponding to the task to be scheduled based on the relationship between multiple fitness levels," can be implemented through the following steps: When the target execution node includes a primary execution node and a backup execution node, the multiple adaptation scores are sorted from largest to smallest. The execution node with the highest adaptation score is selected as the primary execution node, and the execution node with the second highest adaptation score is selected as the backup execution node.

[0102] In one possible implementation, the default primary execution node is the node that prioritizes executing the tasks to be scheduled.

[0103] When the primary execution node fails to meet the execution conditions, the standby execution node takes over the execution of the scheduled task from the primary execution node. For example, failing to meet the execution conditions may include, but is not limited to, the following situations: the node's concurrent resources reach a threshold, a runtime failure occurs, or the task execution is abnormal.

[0104] For example, one primary execution node and at least two backup execution nodes can be set up.

[0105] Specifically, after calculating the fit between each execution node and the task to be scheduled, the dynamic allocation decision layer can sort multiple fits from largest to smallest according to their scores.

[0106] After sorting, the execution node corresponding to Top 1 is selected as the primary execution node, and the execution nodes corresponding to Top 2 to Top 3 are selected as backup execution nodes. Here, Top 1 refers to the node with the highest score, Top 2 refers to the node with the second highest score, and Top 3 refers to the node with the third highest score.

[0107] For example, Figure 4 A schematic diagram illustrating the process of determining the primary / standby execution node. (Example) Figure 4 As shown, when the available node list contains nodes A, B, C, and D, and the fit scores of nodes A, B, C, and D with the task to be scheduled are 95, 88, 75, and 92 respectively, these four fit scores are sorted from largest to smallest, resulting in the sorting result: 95 > 92 > 88 > 75. At this point, Top1 is 95, Top2 is 92, and Top3 is 88. Therefore, node A corresponding to Top1 is designated as the primary execution node, and node B corresponding to Top2 and node D corresponding to Top3 are designated as backup execution nodes.

[0108] The task scheduling method provided in this application, when determining the target execution node of a task to be scheduled, no longer selects only a single optimal execution node, but simultaneously selects a primary execution node and a backup execution node. This dual-node selection mechanism significantly enhances the fault tolerance and reliability of task scheduling, thereby ensuring that the task to be scheduled can start in a timely and smooth manner, and improving the stability of task execution.

[0109] In one embodiment, the step 102 of "dispatching the task to be scheduled to the target execution node" can be achieved through... Figure 5 Steps 301 and 302 shown are implemented as follows: Step 301: If the number of concurrent tasks on the primary execution node does not reach the preset threshold, the tasks to be scheduled will be dispatched to the primary execution node.

[0110] Step 302: If the number of concurrent tasks on the primary execution node reaches the preset threshold, the tasks to be scheduled will be dispatched to the backup execution node.

[0111] The number of concurrent tasks on a node is dynamic and reflects the current actual workload of the primary execution node. In one possible implementation, the number of concurrent tasks on a node represents the total number of tasks currently running on the primary execution node. Tasks currently running do not include queued tasks, completed tasks, or tasks that terminated abnormally.

[0112] The preset quantity threshold is the maximum number of tasks that can be processed simultaneously.

[0113] Specifically, when determining the primary and backup execution nodes based on the relationship between multiple adaptability scores, the first step is to obtain the number of concurrent tasks on the primary execution node. One possible implementation involves the task manager within the primary execution node continuously counting the number of concurrent tasks, or periodically querying the number of active tasks on the primary execution node through a task scheduling platform to obtain the total number of concurrent tasks.

[0114] Subsequently, the number of concurrent tasks on the primary execution node is compared with a preset threshold. If the number of concurrent tasks on the primary execution node has not yet reached the preset threshold, it indicates that the primary execution node still has sufficient resources and capacity to handle the tasks to be scheduled. In this case, the task dispatching execution layer directly dispatches the tasks to be scheduled to the primary execution node.

[0115] Conversely, if the number of concurrent tasks on the primary execution node has reached the preset threshold, it means that the primary execution node is currently under high load. Continuing to dispatch tasks to it may easily lead to overload, affecting the normal operation of existing tasks and the execution efficiency of tasks to be scheduled. In this case, the task dispatching execution layer does not dispatch tasks to be scheduled to the primary execution node, but dispatches tasks to be scheduled to the backup execution node to avoid the execution node from running under overload.

[0116] For example, Figure 6 A diagram illustrating the primary / standby execution node switching process, as shown below. Figure 6 As shown, for the primary and backup execution nodes issued by the dynamic allocation decision layer, the task dispatch execution layer first obtains the number of concurrent tasks reported by the primary execution node, and determines whether to dispatch the task to be scheduled to the primary execution node or the backup execution node based on the relationship between the number of concurrent tasks and the preset threshold.

[0117] The task scheduling method provided in this application dynamically judges the real-time load status of the primary execution node. If the primary execution node is not fully loaded, its high adaptability is prioritized to ensure efficient task operation. If the load of the primary execution node reaches a preset threshold, the task to be scheduled is transferred to a backup execution node to avoid performance degradation or execution instability caused by overload of the primary execution node. The entire dynamic judgment mechanism effectively distributes task pressure while making full use of highly adaptable execution node resources and avoiding resource waste, ensuring the stability of the task scheduling platform and the quality of task execution, and achieving more refined, intelligent, and reasonable task scheduling decisions.

[0118] In one embodiment, considering the risk of exceptions during task execution by the primary execution node, the lack of corresponding exception handling and rescheduling mechanisms in the event of an exception can easily lead to task execution interruption, affecting the normal completion of the task. To address this issue, embodiments of this application employ the following steps.

[0119] If an anomaly is detected on the primary execution node during the execution of a scheduled task, a rescheduling flag is added to the scheduled task, and the task is reassigned to a standby execution node for re-execution.

[0120] Typically, a task scheduling platform has a built-in scheduling engine responsible for managing scheduling decision logic. The scheduling engine not only deploys a node status acquisition layer, a task feature parsing layer, a dynamic allocation decision layer, a task dispatch execution layer, and a scheduling effect feedback layer, but also a status monitoring and fault migration layer.

[0121] The status monitoring and fault migration layer continuously monitors the node's heartbeat and task execution status during the execution of scheduled tasks on the primary execution node, and determines whether the primary execution node has experienced interruptions, timeouts, or other faults during task execution. Once a fault is detected during task execution, a rescheduling flag is added to the scheduled task, and the task is reassigned to a backup execution node for re-execution.

[0122] For example, Figure 7 This is a schematic diagram of the automatic fault migration process, such as... Figure 7 As shown, during the execution of a scheduled task, the primary execution node can report heartbeat information and task execution status to the status monitoring and fault migration layer in real time. Alternatively, the status monitoring and fault migration layer can monitor the heartbeat information and task execution status of the primary execution node in real time. Based on the reported or monitored content, the status monitoring and fault migration layer can determine whether a fault has occurred in the primary execution node during task execution. In case of a fault, a "pending rescheduling" flag is added to the task, such as updating its task status from "in execution" to "abnormal and awaiting retry," resulting in a task marked with the "pending rescheduling" flag.

[0123] Subsequently, the status monitoring and fault migration layer sends the marked task to the task dispatch and execution layer, instructing the task dispatch and execution layer to re-dispatch the task to be scheduled; the task dispatch and execution layer receives the marked task and re-dispatches the task to be scheduled to the backup execution node for re-execution. The entire automatic fault migration process requires no manual intervention.

[0124] For example, when the task scheduling platform has a built-in scheduling engine, it can refer to... Figure 8 The diagram shows a task scheduling process. Figure 8 In this context, the execution nodes are node A and node B, and the task to be scheduled is task a. When task a arrives at the task scheduling platform, the task feature parsing layer parses the task priority from the task script information carried by task a. Figure 8 Each layer in the process employs the functions described in the preceding embodiments to complete the distribution and execution of task a, as well as the collection and feedback of execution result data.

[0125] The task scheduling method provided in this application, by introducing an automatic node fault detection and automatic task migration mechanism, can promptly identify operational faults in the primary execution node and quickly restore task execution by relying on the backup execution node. This fully leverages the redundancy and fault tolerance capabilities of the backup execution node, significantly improving the reliability, robustness, and operational efficiency of task scheduling, ensuring business continuity, and enhancing the availability of the task scheduling platform.

[0126] In one embodiment, the step 102 of "dispatching the task to be scheduled to the target execution node" can be achieved through the following steps: If there are multiple tasks to be scheduled, each task will be dispatched to the corresponding target execution node simultaneously to initiate a distributed parallel scheduling and execution process for multiple tasks.

[0127] Specifically, to cope with the concurrent scheduling needs of tens of thousands of tasks during peak business periods, the task scheduling platform can detect the queue length of tasks to be scheduled and count the number of tasks currently entering the task scheduling platform to be scheduled.

[0128] If there are multiple tasks to be scheduled, the target execution node corresponding to each task is determined through step 101 above. All tasks and their corresponding target execution nodes are then encapsulated into a batch message and sent to the task dispatch execution layer. After parsing the batch message, the task dispatch execution layer simultaneously sends all tasks to their respective target execution nodes.

[0129] Once all tasks to be scheduled have been dispatched, each target execution node runs tasks independently and concurrently. By synchronously starting the task execution process across multiple execution nodes, the overall task completion time can be significantly shortened, effectively improving scheduling response speed.

[0130] The task scheduling method provided in this application introduces a distributed parallel scheduling strategy to distribute a large number of tasks to be scheduled to multiple target execution nodes for parallel execution. This can improve the overall concurrent processing capability of the task scheduling platform, make full use of the processing capability of each target execution node, enable each target execution node to run tasks with the maximum reasonable concurrency, avoid tasks queuing up, thereby reducing waiting time, improving scheduling throughput and execution efficiency, and supporting large-scale task scheduling scenarios.

[0131] For example, refer to Figure 9 The overall flowchart of the task scheduling method shown is as follows: Figure 9 In this context, resource status and health information belong to node data; the metadata database stores two node metadata tables: one is a node data information table, and the other is a task feature information table. Figure 9 The feature vectorization in this process specifically involves the dynamic allocation decision layer extracting resource availability indicators and historical operational efficiency indicators from real-time node data, and extracting node priority levels from formatted task data (such as task features written in different fields of a task feature information table). The specific processes involved can be referred to in the aforementioned embodiments, and will not be elaborated upon here.

[0132] The task scheduling method provided in this application comprehensively improves the capabilities of the task scheduling platform in multiple dimensions, including resource utilization, system stability, task execution efficiency, and manual maintenance costs, by real-time sensing of node status, intelligent selection of the optimal node, automatic task dispatch, and optimized scheduling strategies. This makes the enterprise's distributed business system run more stably, efficiently, and flexibly. The specific beneficial effects are as follows: First, improve system resource utilization: achieve dynamic matching of tasks and nodes, avoid node overload or idleness, and effectively improve the overall utilization of server resources.

[0133] Second, enhance business continuity and stability: tasks can be automatically migrated when a node fails, greatly reducing business interruption time and ensuring stable system operation and service quality.

[0134] Third, improve scheduling accuracy and execution efficiency: intelligent allocation based on comprehensive task characteristics and node status makes tasks more suitable for execution on corresponding nodes, reducing overall execution time and improving scheduling throughput.

[0135] Fourth, reduce manual operation and maintenance costs: There is no need to manually configure the binding relationship between tasks and nodes. New nodes and new tasks can be automatically adapted, reducing the workload of operation and maintenance and the probability of human error.

[0136] Fifth, enhance system scalability: support horizontal node scaling and large-scale task concurrent scheduling, adapting to the needs of continuous business growth and system expansion.

[0137] It should be noted that although the operations of the method of this application are described in a specific order in the accompanying drawings, this does not require or imply that these operations must be performed in that specific order, or that all the operations shown must be performed to achieve the desired result. On the contrary, the steps depicted in the flowchart can be performed in a different order. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0138] Figure 10 A schematic diagram of a hardware architecture suitable for implementing embodiments of this application is shown, such as... Figure 10 As shown, the electronic device specifically includes a processor 401, a communication interface 402, a memory 403, and a communication bus 404. The processor 401, communication interface 402, and memory 403 communicate with each other via the communication bus 404. The memory 403 stores programs that can be executed by the processor 401. The processor 401 executes the programs stored in the memory 403 to implement… Figure 1 The steps of the method shown are as follows.

[0139] The communication bus 404 mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus 404 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 10The bus is represented by a single thick line, but this does not imply that there is only one bus or one type of bus. Communication interface 402 is used for communication between the aforementioned electronic device and other devices. Memory 403 may include random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor 401. The aforementioned processor 401 may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc., or it may be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0140] In another embodiment of this application, a computer program product is also provided, which stores a computer program that, when run on a computer, causes the computer to perform the actions described in the above embodiments. Figure 1 The steps of the method shown are as follows.

[0141] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. This computer program product includes one or more computer instructions. When these computer instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another, for example, computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape, etc.), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid-state drive), etc.

[0142] The above description is merely a preferred embodiment of this application and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in this application is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the inventive concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features with similar functions disclosed in this application.

Claims

1. A task scheduling method, characterized in that, The method includes: The resource availability indicators and historical performance indicators of each execution node when the task to be scheduled arrives are obtained, and the adaptability of each execution node to the task to be scheduled is determined based on the resource availability indicators and the historical performance indicators. The adaptability is used to characterize the degree of matching between the corresponding execution node and the task to be scheduled in terms of resource load carrying capacity and task execution timeliness. Based on the relationship between the multiple adaptability values, the target execution node corresponding to the task to be scheduled is determined, and the task to be scheduled is dispatched to the target execution node to start the execution process of the task to be scheduled.

2. The method according to claim 1, characterized in that, Determining the compatibility between each execution node and the task to be scheduled includes: The compatibility between each execution node and the task to be scheduled is determined based on the node's available resource score, node's historical success rate score, task execution time adaptation score, task priority adaptation score, and the weight of each score. The node available resource score, the node historical success rate score, the task execution time adaptation score, and the task priority adaptation score are used to measure the idle level of the corresponding execution node, the reliability of executing similar tasks, the efficiency of executing similar tasks, and the degree of priority adaptation with the task to be scheduled, respectively.

3. The method according to claim 2, characterized in that, Determining the available resource score of the node includes: The available resource score of the node is determined based on the CPU availability, memory availability, and available slot ratio contained in the resource availability indicators, as well as the weight of each indicator. The available slot ratio is the ratio of the number of currently idle task slots of the corresponding execution node to the total number of slots for the maximum parallel tasks of the execution node.

4. The method according to claim 2, characterized in that, The historical success rate score and task execution time adaptation score of the node are determined, including: The historical success rate score of the node is determined based on the success rate of performing similar tasks in the past N days, which are included in the historical operational efficiency indicators; N is a positive integer greater than 0. The task execution time adaptation score is determined based on the average time taken to execute similar tasks over the past N days, which are included in the historical operational efficiency indicators.

5. The method according to claim 2, characterized in that, Determining the task priority adaptation score includes: The task priority level is parsed from the task script information carried by the task to be scheduled, and the task priority adaptation score is determined according to the relationship between the weight of the task priority level and the weight of the priority level of the execution node.

6. The method according to claim 1, characterized in that, The step of determining the target execution node corresponding to the task to be scheduled based on the relationship between the multiple fitness scores includes: When the target execution node includes a primary execution node and a backup execution node, the multiple adaptation scores are sorted from largest to smallest, the execution node with the highest adaptation score is selected as the primary execution node, and the execution node with the second highest adaptation score is selected as the backup execution node.

7. The method according to claim 6, characterized in that, The step of dispatching the task to be scheduled to the target execution node includes: If the number of concurrent tasks on the primary execution node does not reach the preset threshold, the task to be scheduled will be dispatched to the primary execution node. If the number of concurrent tasks on the node reaches the preset threshold, the task to be scheduled will be dispatched to the standby execution node.

8. The method according to claim 6, characterized in that, The method further includes: If an anomaly is detected in the primary execution node during the execution of the scheduled task, a rescheduling flag is added to the scheduled task, and the scheduled task is reassigned to the backup execution node for re-execution.

9. The method according to claim 1, characterized in that, The step of dispatching the task to be scheduled to the target execution node includes: If there are multiple tasks to be scheduled, each task to be scheduled will be simultaneously dispatched to the corresponding target execution node to initiate a distributed parallel scheduling and execution process for multiple tasks to be scheduled.

10. A computer program product, characterized in that, The computer program product includes instructions that, when executed, cause the method as described in any one of claims 1-9 to be implemented.