WO2022222567A1 - Task scheduling method and apparatus, and computer-readable storage medium - Google Patents

Task scheduling method and apparatus, and computer-readable storage medium Download PDF

Info

Publication number
WO2022222567A1
WO2022222567A1 PCT/CN2022/074659 CN2022074659W WO2022222567A1 WO 2022222567 A1 WO2022222567 A1 WO 2022222567A1 CN 2022074659 W CN2022074659 W CN 2022074659W WO 2022222567 A1 WO2022222567 A1 WO 2022222567A1
Authority
WO
WIPO (PCT)
Prior art keywords
execution
dependency
task
stage
subtask
Prior art date
Application number
PCT/CN2022/074659
Other languages
French (fr)
Chinese (zh)
Inventor
李松
金学文
田丰
冀乃庚
查骏
Original Assignee
中国银联股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中国银联股份有限公司 filed Critical 中国银联股份有限公司
Publication of WO2022222567A1 publication Critical patent/WO2022222567A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/485Task life-cycle, e.g. stopping, restarting, resuming execution

Definitions

  • the present invention belongs to the field of computers, and in particular relates to a task scheduling method, a device and a computer-readable storage medium.
  • complex scheduling tasks can be split into multiple subtasks, and each subtask can be dispatched to different nodes for execution to improve scheduling efficiency.
  • problems due to the limitations of business processes and deployment resources, there are problems such as high complexity and difficulty in the execution sequence, task scheduling management and efficient execution of multiple subtasks obtained by split scheduling tasks.
  • the present invention provides the following solutions.
  • a task scheduling method which includes: dividing a scheduling task to be scheduled into multiple subtasks, arranging the multiple subtasks into multiple stages, and configuring task dependencies and multiple subtasks among the multiple subtasks.
  • the stage dependency between stages in response to the execution instruction of the current stage, obtain all subtasks of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node, wherein the preset execution conditions are based on stage dependencies
  • the relationship, task dependency, and task execution state are determined; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
  • the method further includes: monitoring the task execution state; and, when monitoring that all subtasks of the previous stage of the current stage are executed and completed, generating an execution instruction of the current stage; and/or, when When it is monitored that all subtasks of the current stage are executed and completed, the execution instruction of the subsequent stage is generated.
  • arranging multiple subtasks in stages further includes: grouping and arranging multiple subtasks in the stage to obtain multiple task groups of the stage; and, when the current stage includes multiple task groups , executes multiple task groups of the current stage in parallel.
  • it also includes delivering subtasks to be executed that meet preset execution conditions to execution nodes based on a load balancing strategy, specifically including: preconfiguring the expected load of each subtask, the load of each execution node Threshold; when the current stage is executed, determine the expected load of the subtasks to be executed, and calculate the current load of each execution node; determine the subtasks to be executed according to the load threshold and current load of each execution node, and the expected load of the subtasks to be executed.
  • a list of available nodes for the task and, delivering the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
  • the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful, failed, terminated, and abnormal.
  • the dependency types of the stage dependency and the task dependency include: strong dependency, weak dependency, and no dependency; wherein, each dependency type and the execution state of one or more subtasks have a preset Mapping relations.
  • the current stage depends on the predecessor stage based on the configured stage dependencies; wherein, if the stage dependency is a strong dependency, all subtasks of the current stage depend on the predecessor stage to be successfully executed; if the stage If the dependency is weak, the current stage depends on the predecessor stage and all subtasks are executed without exception; if the stage dependency is no dependency, the execution of the current stage does not depend on the execution status of the subtasks in the predecessor stage.
  • the subtask to be executed depends on at least one specified subtask based on a configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency; wherein, if the task If the dependency is a strong dependency, the subtask to be executed depends on at least one specified subtask to execute successfully; if the task dependency is a weak dependency, the subtask to be executed depends on at least one specified subtask to execute successfully or fail; if the task dependency is No dependencies, subtasks to be executed depend on at least one specified subtask to execute successfully, fail, terminate or exception.
  • the method further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is a strong dependency or a weak dependency, judging whether the current stage satisfies the preset execution condition, if not, setting the The execution status of all subtasks in the current stage is abnormal. If satisfied, all subtasks in the current stage are sequentially delivered using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
  • the method further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is no dependency, judging whether each subtask of the current stage satisfies the preset execution condition, if not The execution status of the subtask is set as abnormal, and if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
  • the method further includes preconfiguring a plurality of configuration information, where the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; the following one or more configuration items of each subtask : The scheduling task ID of the scheduling task to which it belongs, the stage ID of the stage it belongs to, the stage dependency of the stage it belongs to, the group ID of the task group it belongs to, the subtask ID, the task dependency relationship, the expected load, the timeout time, and the execution module ID; One or more of the following configuration items: Execution node ID, Execution node load threshold, Execution node list.
  • the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; the following one or more configuration items of each subtask : The scheduling task ID of the scheduling task to which it belongs, the stage ID of the stage it belongs to, the stage dependency of the stage it belongs to, the group ID of the task group it belongs to, the subtask ID, the task dependency relationship, the expected load, the timeout time, and the execution
  • a task scheduling device comprising: a configuration module for dividing a scheduling task to be scheduled into multiple sub-tasks, arranging the multiple sub-tasks into multiple stages, and configuring tasks between the multiple sub-tasks Dependency relationship and stage dependency relationship between multiple stages; the scheduling module is used to obtain all subtasks of the current stage in response to the execution instruction of the current stage, and deliver the to-be-executed subtasks that meet the preset execution conditions to the execution node , wherein the preset execution condition is determined according to the phase dependency, the task dependency and the task execution state; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
  • the device further includes a monitoring module, configured to: monitor the task execution state; and, when it is monitored that all subtasks of the previous stage of the current stage are executed and completed, generate an execution instruction of the current stage; And/or, when it is monitored that all subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
  • a monitoring module configured to: monitor the task execution state; and, when it is monitored that all subtasks of the previous stage of the current stage are executed and completed, generate an execution instruction of the current stage; And/or, when it is monitored that all subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
  • the configuration module is further configured to: group and arrange multiple subtasks in the stage to obtain multiple task groups of the stage; and, when the current stage includes multiple task groups, execute the current stage in parallel groupings of multiple tasks.
  • the scheduling module is further configured to deliver the subtasks to be executed that meet the preset execution conditions to the execution node based on the load balancing strategy, and is specifically used for: preconfiguring the expected load of each subtask, each subtask The load threshold of the execution node; when the current stage is executed, determine the expected load of the subtasks to be executed, and calculate the current load of each execution node; according to the load threshold and current load of each execution node, and the expected load of the subtasks to be executed Determine the list of available nodes of the subtask to be executed; and deliver the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
  • the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful, failed, terminated, and abnormal.
  • the dependency types of the stage dependency and the task dependency include: strong dependency, weak dependency, and no dependency; wherein, each dependency type and the execution state of one or more subtasks have a preset Mapping relations.
  • the current stage depends on the predecessor stage based on the configured stage dependencies; wherein, if the stage dependency is a strong dependency, all subtasks of the current stage depend on the predecessor stage to be successfully executed; if the stage If the dependency is weak, the current stage depends on the predecessor stage and all subtasks are executed without exception; if the stage dependency is no dependency, the execution of the current stage does not depend on the execution status of the subtasks in the predecessor stage.
  • the subtask to be executed depends on at least one specified subtask based on a configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency; wherein, if the task If the dependency is a strong dependency, the subtask to be executed depends on at least one specified subtask to execute successfully; if the task dependency is a weak dependency, the subtask to be executed depends on at least one specified subtask to execute successfully or fail; if the task dependency is No dependencies, subtasks to be executed depend on at least one specified subtask to execute successfully, fail, terminate or exception.
  • the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is a strong dependency or a weak dependency, judging whether the current stage satisfies the preset execution condition, if not, setting the The execution status of all subtasks in the current stage is abnormal. If satisfied, all subtasks in the current stage are sequentially delivered using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
  • the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is no dependency, judging whether each subtask of the current stage satisfies the preset execution condition, if not The execution status of the subtask is set as abnormal, and if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
  • the configuration module is further configured to pre-configure a plurality of configuration information, and the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; one or more of the following for each subtask Configuration items: scheduling task ID of the scheduling task to which it belongs, stage ID of the stage to which it belongs, stage dependency of the stage to which it belongs, group ID of the task group to which it belongs, subtask ID, task dependency, expected load, timeout, and execution module ID; execution One or more of the following configuration items for the module: execution node identification, execution node load threshold, execution node list.
  • a task scheduling apparatus which is characterized by comprising: at least one processor; and a memory connected in communication with the at least one processor; wherein the memory stores an instruction that can be executed by the at least one processor, and the instruction Executed by at least one processor to enable the at least one processor to execute: the method of claims 1-11.
  • a computer-readable storage medium stores a program, and when the program is executed by a multi-core processor, the multi-core processor executes the method according to any one of claims 1-11.
  • the above-mentioned at least one technical solution adopted in the embodiments of the present application can achieve the following beneficial effects: by dividing the scheduling task into multiple subtasks, arranging the multiple subtasks in stages into multiple stages of orderly execution, and by comprehensively maintaining the subtasks
  • the task dependencies between tasks and the stage dependencies between stages can more effectively manage the execution process of multiple sub-tasks of scheduling tasks, better meet task scheduling in various complex business scenarios, and effectively improve task scheduling performance.
  • FIG. 1 is a schematic flowchart of a task scheduling method according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of arranging scheduling tasks in stages according to an embodiment of the present invention
  • FIG. 3 is a schematic flowchart of a task scheduling method according to another embodiment of the present invention.
  • FIG. 4 is a schematic diagram of a task scheduling system according to an embodiment of the present invention.
  • FIG. 5 is a schematic flowchart of a task scheduling method according to another embodiment of the present invention.
  • FIG. 6 is a schematic structural diagram of a task scheduling apparatus according to an embodiment of the present invention.
  • FIG. 7 is a schematic structural diagram of a task scheduling apparatus according to yet another embodiment of the present invention.
  • A/B can mean A or B; "and/or” in this text is only an association relationship to describe related objects, indicating that there can be three kinds of relationships, For example, A and/or B can mean that A exists alone, A and B exist at the same time, and B exists alone.
  • first”, “second”, etc. are used for descriptive purposes only, and should not be construed as indicating or implying relative importance or implying the number of indicated technical features. Thus, a feature defined as “first”, “second”, etc., may expressly or implicitly include one or more of that feature. In the description of the embodiments of the present application, unless otherwise specified, "plurality" means two or more.
  • FIG. 1 is a schematic flowchart of a task scheduling method according to an embodiment of the present application, which is used to schedule and execute complex tasks.
  • the execution subject may be one or more electronic devices; from a program perspective, In other words, the execution body may be a program mounted on these electronic devices accordingly.
  • the method provided by this embodiment may include the following steps:
  • FIG. 2 it shows a schematic diagram of arranging scheduling tasks in stages.
  • the scheduling task to be scheduled is divided into multiple sub-tasks, and the multiple sub-tasks are arranged into n stages, each stage. It includes several subtasks, and the subtasks in each stage can be executed in stages.
  • the arrangement can be performed according to the association relationship between the split subtasks, for example, two or more subtasks with temporal associations are arranged in different stages, and each stage includes several subtasks. There is no such relationship between them.
  • dependencies between multiple subtasks and between multiple stages can be configured according to the task execution state.
  • the task execution status can mainly include scheduling/subtask execution status.
  • Task dependencies are used to indicate dependencies between subtasks.
  • the start of execution of a subtask needs to depend on the execution status of another or more subtasks.
  • the start of execution of the first subtask may depend on the success/failure of execution of the second subtask.
  • the start of execution of the third subtask may depend on the unexecuted state of the fourth subtask, and so on.
  • Phase dependencies are used to indicate dependencies between phases, in other words, the start of a phase needs to depend on the execution status of all subtasks in another or more phases.
  • the start of execution of the first stage may depend on the success/failure of all subtasks of the second stage.
  • the start of execution of the third stage may depend on the success of all subtasks of the fourth stage and the success of the fifth stage. All subtasks of are not executed, and so on, which is not specifically limited in this application.
  • the preset execution condition may be determined according to the phase dependency, the task dependency, and the task execution state.
  • the current stage is stage 2
  • all subtasks in stage 2 are obtained at this time: subtask 2-1-1, subtask 2-2-2, ..., subtask 2-1-t 21 . It is judged whether each subtask satisfies a preset execution condition, and the preset execution condition may include the stage execution condition of the current stage and the task execution condition of each subtask.
  • the execution result fed back by the execution node may indicate the execution success/failure/termination/abnormality of the subtask to be executed.
  • S101-S102 are the configuration work before executing the scheduling task
  • S103-S104 are the scheduling work of each current stage of the specific execution of the scheduling task.
  • the task arrangement result shown in FIG. 2 can be configured, and the phase dependencies and task dependencies can be configured accordingly.
  • the phases 1 to n in FIG. When each stage is the current stage, the above-mentioned work of S103-S104 is executed until the execution of stage n ends.
  • stage dependency relationship can more effectively manage the execution process of multiple subtasks of the scheduling task, which can better meet the task scheduling in various complex business scenarios, and effectively improve the task scheduling performance.
  • the execution status of the subtask may include multiple execution statuses such as pending, executing, successful, failed, terminated, and abnormal.
  • the execution status is "to be executed” when it is not executed, the execution status is "executing” after it has been successfully distributed to the execution node, and the execution status after it has been successfully executed by the execution node.
  • the execution status is "success”, the execution status after it has been executed by the execution node and failed to be executed is "failed”, and the execution status after it has been terminated by the execution node is "terminated", and one of several abnormal conditions occurs.
  • the subsequent execution state is "abnormal".
  • Table 1 presents a refined subtask state machine.
  • the execution state of the scheduled task may include initial and execution.
  • Table 2 provides a scheduling task state machine, wherein, when the scheduling task is executed, the scheduling task execution status of the recording scheduling task is identified as "execution", and the execution stage is identified as the current stage identification; the subtask execution status is identified as the current
  • the execution state of the subtask and the execution node of the subtask are the execution node information of the subtask currently executing the subtask; after the task ends, the execution state of the recorded scheduling task is marked as "initial".
  • the dependency types of the phase dependency and the task dependency may include: strong dependency, weak dependency, and no dependency.
  • Each dependency type has a preset mapping relationship with the execution state of one or more subtasks.
  • Table 3 shows a mapping relationship between dependencies and state machines. According to the above subtask state machine, the stage dependencies between stages, the task dependencies between subtasks and subtasks, and the dependencies can be refined. Can include: strong dependencies, weak dependencies, and no dependencies.
  • this embodiment can provide more refined task status management (to be executed, executing, successful, failed, terminated, abnormal) and task dependency relationship management (strong dependency, weak dependency, no dependency) . It can meet the needs of various business scenarios.
  • the stage dependency relationship can be one of: strong dependency, weak dependency and no dependency. More specifically, if the stage dependency is strong dependency, all subtasks of the current stage depend on the predecessor stage to be executed successfully; if the stage dependency is weak dependency, all subtasks of the current stage depend on the predecessor stage to be executed without exception; If the stage dependency is no dependency, the execution of the current stage does not need to depend on the execution status of the subtasks of the previous stage.
  • a subtask to be executed depends on at least one specified subtask based on a task dependency relationship, and the task dependency relationship is one of strong dependency, weak dependency, and no dependency. More specifically, if the task dependency is strong, the subtask to be executed depends on at least one specified subtask to be executed successfully; if the task dependency is weak dependency, the subtask to be executed depends on at least one specified subtask to be executed successfully or Failed; if the task dependency is no dependency, the subtask to be executed depends on the success, failure, termination or exception of at least one specified subtask.
  • stage dependency of the current stage is strong or weak, judge whether the current stage satisfies the preset execution conditions. If not, set the execution status of all subtasks in the current stage as abnormal. If so, use the load balancing strategy to execute the Send all the subtasks in the current stage and update the execution status of the subtasks after they are issued to executing.
  • stage dependency of the current stage is no dependency, judge whether each subtask of the current stage satisfies the preset execution conditions. If not, set the execution status of the subtask to be abnormal. The execution status of subsequent subtasks is executing.
  • the following scheme can be adopted: if the stage dependency of the current stage is a strong dependency or a weak dependency, the task dependency of each subtask of the current stage of the configuration is ignored ; If the stage dependency of the current stage is no dependency, the task dependency of each subtask of the current stage of the configuration is supported.
  • This embodiment supports the user to configure phase dependencies and subtask dependencies respectively.
  • stage dependencies of a certain stage are strong/weak dependencies, it is not necessary to further verify whether each subtask in this stage satisfies the preset execution conditions based on their respective task dependencies, but only needs to verify whether the stage satisfies the stage-based dependencies. If the preset execution conditions are met, each subtask in this stage can be directly issued.
  • the phase dependency of a certain stage is non-dependent, it is necessary to verify whether each subtask in this stage satisfies the preset execution conditions based on their respective task dependencies. If so, the subtasks that meet the preset execution conditions are issued Task, if one or more subtasks in this stage are not configured with task dependencies, they can be defaulted to meet the preset execution conditions.
  • the type of phase dependency of phase n is weak dependency. Therefore, when phase n satisfies the phase execution condition based on phase dependency, all subtasks of phase n are executed, otherwise, phase n is executed. The execution status of all subtasks of is updated to Exception.
  • the type of the phase dependency in phase 2 is no dependency, so it can be further verified whether the task 2-1-2 in phase 2 satisfies the task execution conditions based on its task dependency.
  • the task dependency of task 2-1-2 is specifically: : Task 2-1-2 depends on subtask 1-1-2 and is strongly dependent, and task 2-1-2 depends on subtask 1-2-1 and is weakly dependent.
  • the task execution status can be monitored.
  • an execution instruction of the current stage is generated; and/or, when it is monitored that all the subtasks of the current stage have been executed and completed, it is further judged whether there are any more subtasks in the current stage. In the subsequent stage, if there is, the execution instruction of the subsequent stage will be generated, if not, the task will be ended.
  • the multiple subtasks may be further finely arranged.
  • S101 it is also possible to: group and arrange the multiple subtasks in the stage , to obtain multiple task groups of the stage; and, when the current stage contains multiple task groups, execute the multiple task groups of the current stage in parallel.
  • FIG. 2 shows a schematic diagram of a fine-grained staged grouped task scheduling, wherein dependencies can be configured from stage and subtask dimensions.
  • the multiple subtasks contained in each stage are further grouped and arranged, and the concurrency of subtasks is controlled in detail from the parallel grouping dimension.
  • the implementation method is as follows: when subtasks are arranged, the stage numbers are 1, 2, ... n according to the execution order, and the concurrent group numbers 1, 2, ... n are set in the same stage, and each subtask number n-1 is set in the group. -1, n-1-2, ...n-1-tn.
  • This model supports subtasks in the same stage to be grouped and configured according to concurrency requirements. Different groups of the same stage can execute concurrently. Multiple subtasks within the same group of the same stage are executed sequentially.
  • the distribution process based on the load balancing strategy is as follows: in S31 , when adding a scheduling task, it is necessary to configure an expected load for the subtask, and configure a load threshold for the execution node. Users can evaluate the expected load according to the expected resource consumption of subtasks in production, and evaluate the load threshold according to the actual available resources of the execution node.
  • the resources here include CPU, memory, etc.
  • S32 before the subtask is issued, a list of execution nodes corresponding to the subtask is obtained, all subtasks currently being executed by each execution node are queried, and the current load sum wn of the execution node is calculated.
  • This embodiment proposes a real-time task distribution strategy, which requires pre-evaluation of the load threshold of the execution node and the weight of each subtask.
  • the optimal execution node is comprehensively selected to execute the task compared with the load threshold.
  • the interaction complexity is low, ensuring that the execution node will not be overloaded, and has better versatility and security.
  • the method further includes pre-configuring a variety of configuration information, where the configuration information includes: a scheduling task identifier of the scheduling task; one or more of the following configuration items of each subtask: the scheduling task identifier of the scheduling task to which it belongs. , the stage ID of the stage to which it belongs, the stage dependency of the stage to which it belongs, the group ID of the task group to which it belongs, subtask ID, task dependency, expected load, timeout, and execution module ID; one or more of the following configuration items of the execution module : Execution node ID, execution node load threshold, and execution node list.
  • the configuration information includes: a scheduling task identifier of the scheduling task; one or more of the following configuration items of each subtask: the scheduling task identifier of the scheduling task to which it belongs. , the stage ID of the stage to which it belongs, the stage dependency of the stage to which it belongs, the group ID of the task group to which it belongs, subtask ID, task dependency, expected load, timeout, and execution module ID; one or more of the
  • a task scheduling system which mainly includes a configuration module 400, a visual interface 401, a scheduling module 402, a monitoring module 403, a storage module 404, and an execution module 405.
  • Each module specifically performs the following tasks:
  • the configuration module 400 is configured to generate configuration information related to task scheduling.
  • the configuration module 400 inputs the configuration information through the visual interface 401 , and optionally the configuration information can also be input through the background, which is not specifically limited in this application.
  • the visual interface 401 is used to provide the user with an interactive interface for operating the related process of the task scheduling, which can be performed on the visual interface 401: adding/deleting/updating tasks, adding configuration information, querying the execution status of scheduling/subtasks, manual triggering/terminating Scheduling tasks, etc.
  • adding/deleting/updating tasks adding configuration information
  • querying the execution status of scheduling/subtasks manual triggering/terminating Scheduling tasks, etc.
  • the visual interface 401 stores the configuration information to the storage module 404
  • the visual interface 401 sends an instruction to the scheduling module 402 to manually trigger/terminate the scheduling task.
  • the scheduling module 402 is configured to start scheduling task scheduling in response to a trigger condition (either manually triggered or automatically triggered), and is responsible for issuing subtasks and maintaining task execution status.
  • the scheduling module 402 obtains the configuration information and execution status of the scheduling/subtasks from the storage module 404, and in (5), the subtasks that satisfy the preset execution conditions are delivered to the execution nodes in the execution module 405 , in (6) the execution result fed back by the execution node is received, and in (7) the execution state of the corresponding subtask is updated according to the execution result.
  • the monitoring module 403 is used to monitor the progress of all currently executing scheduling/subtasks, and drive the task flow to continue to execute or end the task.
  • the monitoring module 403 obtains the configuration information and execution status of the scheduling/subtask from the storage module 404, in (9) the monitoring module 403 monitors the progress of the currently executing scheduling/subtask, and in (10) The module 403 sends the task execution instruction of the subsequent stage to the scheduling module 402 after monitoring the completion of the current stage subtask execution and when there is a subsequent stage, in (11), the monitoring module 403 monitors that the current stage subtask execution is completed and does not exist. End the scheduling task scheduling in the subsequent stage.
  • the storage module 404 is used to store the configuration information of the scheduling/subtask and the task execution state.
  • the execution module 405 includes several execution nodes, each execution node is responsible for executing subtasks, and the execution node is generally a module of each business system.
  • FIG. 5 it shows a flow interaction diagram for performing task scheduling based on the scheduling result in FIG. 2 and using the task scheduling device shown in FIG. 4 .
  • the scheduling module 402 acquires all the subtasks of stage 1.
  • stage 1 is the initial stage, there is no stage dependency and sub-task dependency, and the scheduling module 402 can sequentially deliver each sub-task of this stage 1; in S503, if the delivery is successful, the execution state of the sub-task is recorded In S504, after the execution of the subtask is completed, the scheduling module 402 receives the execution result fed back by the execution node of the execution module 405; in S505, the scheduling module 402 executes the execution according to the feedback from the execution node As a result, the execution state of the corresponding subtask is updated in the storage module 404, which can be "success", "failure", "abnormal”, etc.; at S506, the monitoring module 403 monitors and obtains the execution state of the subtask in stage 1; at S507, When all the subtasks in stage 1 have been executed (not “to be executed” or "executed"), the monitoring module 403 further judges whether there are subtasks to be executed in the next stage, if not, it is considered that
  • step (a) may also be included, which specifically includes: if the current group has a sub-task to be executed, then continue to execute the current sub-task of the next group. , if all grouping subtasks in the current stage have been completed, and there is a task to be executed in the next stage, then execute S507.
  • first and second are only used for descriptive purposes, and should not be construed as indicating or implying relative importance or implying the number of indicated technical features. Thus, a feature delimited with “first”, “second” may expressly or implicitly include at least one of that feature.
  • plurality means at least two, such as two, three, etc., unless otherwise expressly and specifically defined.
  • FIG. 6 is a schematic structural diagram of a task scheduling apparatus according to an embodiment of the present invention.
  • the device 60 includes:
  • the configuration module 400 is used for splitting the scheduling task to be scheduled into multiple subtasks, arranging the multiple subtasks into multiple stages, and configuring the task dependency relationship between the multiple subtasks and the stage dependency relationship between the multiple stages ;
  • the scheduling module 402 is configured to, in response to the execution instruction of the current stage, obtain all subtasks of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node, wherein the preset execution conditions are based on the stage dependencies, tasks The dependency relationship and the task execution state are determined; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
  • the device further includes a monitoring module, configured to: monitor the task execution state; and, when it is monitored that all subtasks of the previous stage of the current stage are executed and completed, generate an execution instruction of the current stage; And/or, when it is monitored that all subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
  • a monitoring module configured to: monitor the task execution state; and, when it is monitored that all subtasks of the previous stage of the current stage are executed and completed, generate an execution instruction of the current stage; And/or, when it is monitored that all subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
  • the configuration module 400 is further configured to: group and arrange multiple subtasks in the stage to obtain multiple task groups of the stage; and, when the current stage includes multiple task groups, execute the current stage in parallel Multiple task groupings for stages.
  • the scheduling module 402 is further configured to deliver the to-be-executed subtasks that meet the preset execution conditions to the execution node based on the load balancing strategy, and is specifically configured to: preconfigure the expected load of each subtask, each subtask The load threshold of each execution node; when the current stage is executed, the expected load of the subtask to be executed is determined, and the current load of each execution node is calculated; according to the load threshold and current load of each execution node, and the expected load of the subtask to be executed The load determines the list of available nodes of the subtask to be executed; and delivers the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
  • the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful, failed, terminated, and abnormal.
  • the dependency types of the stage dependency and the task dependency include: strong dependency, weak dependency, and no dependency; wherein, each dependency type and the execution state of one or more subtasks have a preset Mapping relations.
  • the current stage depends on the predecessor stage based on the configured stage dependencies; wherein, if the stage dependency is a strong dependency, all subtasks of the current stage depend on the predecessor stage to be successfully executed; if the stage If the dependency is weak, the current stage depends on the predecessor stage and all subtasks are executed without exception; if the stage dependency is no dependency, the execution of the current stage does not depend on the execution status of the subtasks in the predecessor stage.
  • the subtask to be executed depends on at least one specified subtask based on a configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency; wherein, if the task If the dependency is a strong dependency, the subtask to be executed depends on at least one specified subtask to execute successfully; if the task dependency is a weak dependency, the subtask to be executed depends on at least one specified subtask to execute successfully or fail; if the task dependency is No dependencies, subtasks to be executed depend on at least one specified subtask to execute successfully, fail, terminate or exception.
  • the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is a strong dependency or a weak dependency, judging whether the current stage satisfies the preset execution condition, if not, setting the The execution status of all subtasks in the current stage is abnormal. If satisfied, all subtasks in the current stage are sequentially delivered using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
  • the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is no dependency, judging whether each subtask of the current stage satisfies the preset execution condition, if not The execution status of the subtask is set as abnormal, and if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
  • the configuration module 400 is further configured to preconfigure a plurality of configuration information, and the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; the following one or more of each subtask Configuration items: the scheduling task identifier of the scheduling task to which it belongs, the stage identifier of the phase to which it belongs, the phase dependency of the phase to which it belongs, the group identifier of the task group to which it belongs, the subtask identifier, the task dependency, the expected load, the timeout period, and the execution module identifier; One or more of the following configuration items of the execution module: the identification of the execution node, the load threshold of the execution node, and the list of execution nodes.
  • the task scheduling apparatus in the embodiment of the present application can implement each process of the foregoing embodiments of the task scheduling method, and achieve the same effects and functions, which will not be repeated here.
  • FIG. 7 is a task scheduling apparatus according to an embodiment of the present application, for executing the task scheduling method shown in FIG. 1 , the apparatus includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the methods described in the above embodiments.
  • a non-volatile computer storage medium of a task scheduling method is provided, and computer-executable instructions are stored thereon, and the computer-executable instructions are configured to be executed when run by a processor: the above-mentioned embodiments method described.
  • the apparatuses, devices, and computer-readable storage media and methods provided in the embodiments of the present application are in one-to-one correspondence. Therefore, the apparatuses, devices, and computer-readable storage media also have beneficial technical effects similar to those of the corresponding methods.
  • the beneficial technical effects of the method have been described in detail, therefore, the beneficial technical effects of the apparatus, equipment and computer-readable storage medium will not be repeated here.
  • embodiments of the present invention may be provided as a method, system or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
  • computer-usable storage media including, but not limited to, disk storage, CD-ROM, optical storage, etc.
  • These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions
  • the apparatus implements the functions specified in the flow or flow of the flowcharts and/or the block or blocks of the block diagrams.
  • a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
  • processors CPUs
  • input/output interfaces network interfaces
  • memory volatile and non-volatile memory
  • Memory may include forms of non-persistent memory, random access memory (RAM) and/or non-volatile memory in computer readable media, such as read only memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
  • RAM random access memory
  • ROM read only memory
  • flash RAM flash memory
  • Computer-readable media includes both persistent and non-permanent, removable and non-removable media, and storage of information may be implemented by any method or technology.
  • Information may be computer readable instructions, data structures, modules of programs, or other data.
  • Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), Flash Memory or other memory technology, Compact Disc Read Only Memory (CD-ROM), Digital Versatile Disc (DVD) or other optical storage, Magnetic tape cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission medium that can be used to store information that can be accessed by a computing device.
  • PRAM phase-change memory
  • SRAM static random access memory
  • DRAM dynamic random access memory
  • RAM random access memory
  • ROM read only memory
  • EEPROM Electrically Erasable Programmable Read Only Memory

Abstract

Provided in the present invention are a task scheduling method, apparatus and system, and a computer-readable storage medium. The method comprises: splitting a scheduling task, to be scheduled, into a plurality of sub-tasks, and arranging the plurality of sub-tasks into a plurality of stages; configuring a task dependency relationship between the plurality of sub-tasks and a stage dependency relationship between the plurality of stages; in response to an execution instruction of the current stage, acquiring all the sub-tasks of the current stage, and issuing, to an execution node, a sub-task to be executed that meets a preset execution condition, wherein the preset execution condition is determined according to the stage dependency relationship, the task dependency relationship and a task execution state; and updating an execution state of said sub-task according to an execution result fed back by the execution node. By means of the method, an execution flow of a plurality of sub-tasks of a scheduling task can be managed more effectively, and task scheduling in various complex service scenarios is better satisfied, thereby effectively improving task scheduling performance.

Description

一种任务调度方法、装置及计算机可读存储介质A task scheduling method, device and computer-readable storage medium
本申请要求于2021年04月22日提交的、申请号为202110436537.2、标题为“一种任务调度方法、装置及计算机可读存储介质”的中国专利申请的优先权,该中国专利申请的公开内容以引用的方式并入本文。This application claims the priority of the Chinese patent application with the application number of 202110436537.2, which was filed on April 22, 2021, and entitled "A Task Scheduling Method, Device, and Computer-readable Storage Medium", and the disclosure content of the Chinese patent application Incorporated herein by reference.
技术领域technical field
本发明属于计算机领域,具体涉及一种任务调度方法、装置及计算机可读存储介质。The present invention belongs to the field of computers, and in particular relates to a task scheduling method, a device and a computer-readable storage medium.
背景技术Background technique
本部分旨在为权利要求书中陈述的本发明的实施方式提供背景或上下文。此处的描述不因为包括在本部分中就承认是现有技术。This section is intended to provide a background or context for the embodiments of the invention that are recited in the claims. The descriptions herein are not admitted to be prior art by inclusion in this section.
分布式、微服务应用场景下,可以将复杂的调度任务拆分成多个子任务,并将各个子任务下发到不同的节点中执行以提高调度效率。然而,由于受业务流程和部署资源限制,拆分调度任务得到的多个子任务之间的执行先后顺序、任务调度管理以及高效执行存在复杂度高、难度大等问题。In distributed and microservice application scenarios, complex scheduling tasks can be split into multiple subtasks, and each subtask can be dispatched to different nodes for execution to improve scheduling efficiency. However, due to the limitations of business processes and deployment resources, there are problems such as high complexity and difficulty in the execution sequence, task scheduling management and efficient execution of multiple subtasks obtained by split scheduling tasks.
发明内容SUMMARY OF THE INVENTION
针对上述现有技术中存在的问题,提出了一种任务调度方法、装置及计算机可读存储介质,利用这种方法、装置及计算机可读存储介质,能够解决上述问题。Aiming at the problems existing in the above-mentioned prior art, a task scheduling method, device and computer-readable storage medium are proposed, and the above-mentioned problems can be solved by using the method, device and computer-readable storage medium.
本发明提供了以下方案。The present invention provides the following solutions.
第一方面,提供一种任务调度方法,包括:将待调度的调度任务拆分为多个子任务,将多个子任务编排为多个阶段,并配置多个子任务之间的任务依赖关系和多个阶段之间的阶段依赖关系;响应于当前阶段的执行指令,获取当前阶段的全部子任务,将满足预设执行条件的待执行子任务下发到执行节点,其中,预设执行条件根据阶段依赖关系、任务依赖关系以及任务执行状态确定;并根据执行节点反馈的执行结果更新待执行子任务的执行状态。In a first aspect, a task scheduling method is provided, which includes: dividing a scheduling task to be scheduled into multiple subtasks, arranging the multiple subtasks into multiple stages, and configuring task dependencies and multiple subtasks among the multiple subtasks. The stage dependency between stages; in response to the execution instruction of the current stage, obtain all subtasks of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node, wherein the preset execution conditions are based on stage dependencies The relationship, task dependency, and task execution state are determined; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
在一种可能的实施方式中,方法还包括:监控任务执行状态;以及,当监控到当前阶段的前一阶段的全部子任务均执行完成时,生成当前阶段的执行指令;和/或,当监控到当前阶段的全部子任务均执行完成时,生成后续阶段的执行指令。In a possible implementation manner, the method further includes: monitoring the task execution state; and, when monitoring that all subtasks of the previous stage of the current stage are executed and completed, generating an execution instruction of the current stage; and/or, when When it is monitored that all subtasks of the current stage are executed and completed, the execution instruction of the subsequent stage is generated.
在一种可能的实施方式中,对多个子任务进行分阶段编排,还包括:对阶段中的多个子任务进行分组编排,得到阶段的多个任务分组;以及,当当前阶段包含多个任务分组时,并行执行当前阶段的多个任务分组。In a possible implementation manner, arranging multiple subtasks in stages further includes: grouping and arranging multiple subtasks in the stage to obtain multiple task groups of the stage; and, when the current stage includes multiple task groups , executes multiple task groups of the current stage in parallel.
在一种可能的实施方式中,还包括基于负载均衡策略将满足预设执行条件的待执行子任务下发到执行节点,具体包括:预先配置每个子任务的预期负载、每个执行节点的负载阈值;当前阶段执行时,确定待执行子任务的预期负载,并计算每个执行节点的当前负载;根据每个执行节点的负载阈值和当前负载,和待执行子任务的预期负载确定待执行子任务的可用节点列表;以及,将待执行子任务下发至可用节点列表中负载率最低的执行节点。In a possible implementation, it also includes delivering subtasks to be executed that meet preset execution conditions to execution nodes based on a load balancing strategy, specifically including: preconfiguring the expected load of each subtask, the load of each execution node Threshold; when the current stage is executed, determine the expected load of the subtasks to be executed, and calculate the current load of each execution node; determine the subtasks to be executed according to the load threshold and current load of each execution node, and the expected load of the subtasks to be executed. A list of available nodes for the task; and, delivering the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
在一种可能的实施方式中,任务执行状态至少包括子任务的执行状态,子任务的执行状态包括:待执行、执行中、成功、失败、终止、异常。In a possible implementation manner, the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful, failed, terminated, and abnormal.
在一种可能的实施方式中,阶段依赖关系和任务依赖关系的依赖关系类型包括:强依赖、弱依赖和无依赖;其中,每种依赖关系类型和一个或多个子任务的执行状态具有预设映射关系。In a possible implementation, the dependency types of the stage dependency and the task dependency include: strong dependency, weak dependency, and no dependency; wherein, each dependency type and the execution state of one or more subtasks have a preset Mapping relations.
在一种可能的实施方式中,当前阶段基于配置的阶段依赖关系而依赖于前继阶段;其中,若阶段依赖关系为强依赖,当前阶段依赖于前继阶段全部子任务均执行成功;若阶段依赖关系为弱依赖,当前阶段依赖于前继阶段全部子任务均执行无异常;若阶段依赖关系为无依赖,当前阶段的开始执行不依赖前继阶段的子任务的执行状态。In a possible implementation, the current stage depends on the predecessor stage based on the configured stage dependencies; wherein, if the stage dependency is a strong dependency, all subtasks of the current stage depend on the predecessor stage to be successfully executed; if the stage If the dependency is weak, the current stage depends on the predecessor stage and all subtasks are executed without exception; if the stage dependency is no dependency, the execution of the current stage does not depend on the execution status of the subtasks in the predecessor stage.
在一种可能的实施方式中,待执行子任务基于配置的任务依赖关系而依赖于至少一个指定子任务,任务依赖关系包括:强依赖、弱依赖和无依赖中的一种;其中,若任务依赖关系为强依赖,待执行子任务依赖于至少一个指定子任务均执行成功;若任务依赖关系为弱依赖,待执行子任务依赖于至少一个指定子任务执行成功或失败;若任务依赖关系为无依赖,待执行子任务依赖于至少一个指定子任务执行成功、失败、终止或异常。In a possible implementation manner, the subtask to be executed depends on at least one specified subtask based on a configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency; wherein, if the task If the dependency is a strong dependency, the subtask to be executed depends on at least one specified subtask to execute successfully; if the task dependency is a weak dependency, the subtask to be executed depends on at least one specified subtask to execute successfully or fail; if the task dependency is No dependencies, subtasks to be executed depend on at least one specified subtask to execute successfully, fail, terminate or exception.
在一种可能的实施方式中,方法还包括判断是否满足执行条件,具体包括:若当前阶段的阶段依赖关系为强依赖或弱依赖,判断当前阶段是否满足预设执行条件,若不满足则置当前阶段的全部子任务的执行状态为异常,若满足则利用负载均衡策略依次下发当前阶段的全部子任务并更新下发后的子任务的执行状态为执行中。In a possible implementation, the method further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is a strong dependency or a weak dependency, judging whether the current stage satisfies the preset execution condition, if not, setting the The execution status of all subtasks in the current stage is abnormal. If satisfied, all subtasks in the current stage are sequentially delivered using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
在一种可能的实施方式中,方法还包括判断是否满足执行条件,具体包括:若当前阶段的阶段依赖关系为无依赖,则判断当前阶段的每个子任务是否满足预设执行条件,若不满足则置子任务的执行状态为异常,若满足则下发子任务,并更新下发后的子任务的执行状态为执行中。In a possible implementation manner, the method further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is no dependency, judging whether each subtask of the current stage satisfies the preset execution condition, if not The execution status of the subtask is set as abnormal, and if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
在一种可能的实施方式中,方法还包括预先配置多个配置信息,配置信息包括以下中的一种或多种:调度任务的调度任务标识;每个子任务的以下一种或多种配置项:所属调度任务的调度任务标识、所属阶段的阶段标识、所属阶段的阶段依赖关系、所属任务分组的分组标识、子任务标识、任务依赖关系、预期负载、超时时间、执行模块标识;执行模块的以下一种或多种配置项:执行节点标识、执行节点的负载阈值、执行节点列表。In a possible implementation manner, the method further includes preconfiguring a plurality of configuration information, where the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; the following one or more configuration items of each subtask : The scheduling task ID of the scheduling task to which it belongs, the stage ID of the stage it belongs to, the stage dependency of the stage it belongs to, the group ID of the task group it belongs to, the subtask ID, the task dependency relationship, the expected load, the timeout time, and the execution module ID; One or more of the following configuration items: Execution node ID, Execution node load threshold, Execution node list.
第二方面,提供一种任务调度装置,包括:配置模块,用于将待调度的调度任务拆分为多个子任务,将多个子任务编排为多个阶段,并配置多个子任务之间的任务依赖关系和多个阶段之间的阶段依赖关系;调度模块,用于响应于当前阶段的执行指令,获取当前阶段的全部子任务,将满足预设执行条件的待执行子任务下发到执行节点,其中,预设执行条件根据阶段依赖关系、任务依赖关系以及任务执行状态确定;并根据执行节点反馈的执行结果更新待执行子任务的执行状态。In a second aspect, a task scheduling device is provided, comprising: a configuration module for dividing a scheduling task to be scheduled into multiple sub-tasks, arranging the multiple sub-tasks into multiple stages, and configuring tasks between the multiple sub-tasks Dependency relationship and stage dependency relationship between multiple stages; the scheduling module is used to obtain all subtasks of the current stage in response to the execution instruction of the current stage, and deliver the to-be-executed subtasks that meet the preset execution conditions to the execution node , wherein the preset execution condition is determined according to the phase dependency, the task dependency and the task execution state; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
在一种可能的实施方式中,装置还包括监控模块,用于:监控任务执行状态;以及,当监控到当前阶段的前一阶段的全部子任务均执行完成时,生成当前阶段的执行指令;和/或,当监控到当前阶段的全部子任务均执行完成时,生成后续阶段的执行指令。In a possible implementation manner, the device further includes a monitoring module, configured to: monitor the task execution state; and, when it is monitored that all subtasks of the previous stage of the current stage are executed and completed, generate an execution instruction of the current stage; And/or, when it is monitored that all subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
在一种可能的实施方式中,配置模块还用于:对阶段中的多个子任务进行分组编排,得到阶段的多个任务分组;以及,当当前阶段包含多个任务分组时,并行执行当前阶段的多个任务分组。In a possible implementation, the configuration module is further configured to: group and arrange multiple subtasks in the stage to obtain multiple task groups of the stage; and, when the current stage includes multiple task groups, execute the current stage in parallel groupings of multiple tasks.
在一种可能的实施方式中,调度模块还用于基于负载均衡策略将满足预设执行条件的待执行子任务下发到执行节点,具体用于:预先配置每个子任务的预期负载、每个执行节点的负载阈值;当前阶段执行时,确定待执行子任务的预期负载,并计算每个执行节点的当前负载;根据每个执行节点的负载阈值和当前负载,和待执行子任务的预期负载确定待执行子任务的可用节点列表;以及,将待执行子任务下发至可用节点列表中负载率最低的执行节点。In a possible implementation manner, the scheduling module is further configured to deliver the subtasks to be executed that meet the preset execution conditions to the execution node based on the load balancing strategy, and is specifically used for: preconfiguring the expected load of each subtask, each subtask The load threshold of the execution node; when the current stage is executed, determine the expected load of the subtasks to be executed, and calculate the current load of each execution node; according to the load threshold and current load of each execution node, and the expected load of the subtasks to be executed Determine the list of available nodes of the subtask to be executed; and deliver the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
在一种可能的实施方式中,任务执行状态至少包括子任务的执行状态,子任务的执行状态包括:待执行、执行中、成功、失败、终止、异常。In a possible implementation manner, the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful, failed, terminated, and abnormal.
在一种可能的实施方式中,阶段依赖关系和任务依赖关系的依赖关系类型包括:强依赖、弱依赖和无依赖;其中,每种依赖关系类型和一个或多个子任务的执行状态具有预设映射关系。In a possible implementation, the dependency types of the stage dependency and the task dependency include: strong dependency, weak dependency, and no dependency; wherein, each dependency type and the execution state of one or more subtasks have a preset Mapping relations.
在一种可能的实施方式中,当前阶段基于配置的阶段依赖关系而依赖于前继阶段;其中,若阶段依赖关系为强依赖,当前阶段依赖于前继阶段全部子任务均执行成功;若阶段依赖关系为弱依赖,当前阶段依赖于前继阶段全部子任务均执行无异常;若阶段依赖关系为无依赖,当前阶段的开始执行不依赖前继阶段的子任务的执行状态。In a possible implementation, the current stage depends on the predecessor stage based on the configured stage dependencies; wherein, if the stage dependency is a strong dependency, all subtasks of the current stage depend on the predecessor stage to be successfully executed; if the stage If the dependency is weak, the current stage depends on the predecessor stage and all subtasks are executed without exception; if the stage dependency is no dependency, the execution of the current stage does not depend on the execution status of the subtasks in the predecessor stage.
在一种可能的实施方式中,待执行子任务基于配置的任务依赖关系而依赖于至少一个指定子任务,任务依赖关系包括:强依赖、弱依赖和无依赖中的一种;其中,若任务依赖关系为强依赖,待执行子任务依赖于至少一个指定子任务均执行成功;若任务依赖关系为弱依赖,待执行子任务依赖于至少一个指定子任务执行成功或失败;若任务依赖关系为无依赖,待执行子任务依赖于至少一个指定子任务执行成功、失败、终止或异常。In a possible implementation manner, the subtask to be executed depends on at least one specified subtask based on a configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency; wherein, if the task If the dependency is a strong dependency, the subtask to be executed depends on at least one specified subtask to execute successfully; if the task dependency is a weak dependency, the subtask to be executed depends on at least one specified subtask to execute successfully or fail; if the task dependency is No dependencies, subtasks to be executed depend on at least one specified subtask to execute successfully, fail, terminate or exception.
在一种可能的实施方式中,装置还包括判断是否满足执行条件,具体包括:若当前阶段的阶段依赖关系为强依赖或弱依赖,判断当前阶段是否满足预设执行条件,若不满足则置当前阶段的全部子任务的执行状态为异常,若满足则利用负载均衡策略依次下发当前阶段的全部子任务并更新下发后的子任务的执行状态为执行中。In a possible implementation manner, the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is a strong dependency or a weak dependency, judging whether the current stage satisfies the preset execution condition, if not, setting the The execution status of all subtasks in the current stage is abnormal. If satisfied, all subtasks in the current stage are sequentially delivered using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
在一种可能的实施方式中,装置还包括判断是否满足执行条件,具体包括:若当前阶段的阶段依赖关系为无依赖,则判断当前阶段的每个子任务是否满足预设执行条件,若不满足则置子任务的执行状态为异常,若满足则下发子任务,并更新下发后的子任务的执行状态为执行中。In a possible implementation manner, the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is no dependency, judging whether each subtask of the current stage satisfies the preset execution condition, if not The execution status of the subtask is set as abnormal, and if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
在一种可能的实施方式中,配置模块还用于预先配置多个配置信息,配置信息包括以下中的一种或多种:调度任务的调度任务标识;每个子任务的以下一种或多种配置项:所属调度任务的调度任务标识、所属阶段的阶段标识、所属阶段的阶段依赖关系、所属任务分组的分组标识、子任务标识、任务依赖关系、预期负载、超时时间、执行模块标识;执行模块的以下一种或多种配置项:执行节点标识、执行节点的负载阈值、执行节点列表。In a possible implementation manner, the configuration module is further configured to pre-configure a plurality of configuration information, and the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; one or more of the following for each subtask Configuration items: scheduling task ID of the scheduling task to which it belongs, stage ID of the stage to which it belongs, stage dependency of the stage to which it belongs, group ID of the task group to which it belongs, subtask ID, task dependency, expected load, timeout, and execution module ID; execution One or more of the following configuration items for the module: execution node identification, execution node load threshold, execution node list.
第三方面,提供一种任务调度装置,其特征在于,包括:至少一个处理器;以及,与至少一个处理器通信连接的存储器;其中,存储器存储有可被至少一个处理器执行的指令,指令被至少一个处理器执行,以使至少一个处理器能够执行:如权利要求1-11的方法。In a third aspect, a task scheduling apparatus is provided, which is characterized by comprising: at least one processor; and a memory connected in communication with the at least one processor; wherein the memory stores an instruction that can be executed by the at least one processor, and the instruction Executed by at least one processor to enable the at least one processor to execute: the method of claims 1-11.
第四方面,提供一种计算机可读存储介质,计算机可读存储介质存储有程序,当程序被多核处理器执行时,使得多核处理器执行如权利要求1-11中任一项的方法。In a fourth aspect, a computer-readable storage medium is provided, the computer-readable storage medium stores a program, and when the program is executed by a multi-core processor, the multi-core processor executes the method according to any one of claims 1-11.
本申请实施例采用的上述至少一个技术方案能够达到以下有益效果:通过将调度任务拆分为多个子任务、将多个子任务分阶段编排成有序执行的多个阶段,以及通过综合维护子任务之间的任务依赖关系和阶段之间的阶段依赖关系,能够更有效地管理调度任务的多个子任务的执行流程,更满足各种复杂业务场景下的任务调度,有效提升任务调度性能。The above-mentioned at least one technical solution adopted in the embodiments of the present application can achieve the following beneficial effects: by dividing the scheduling task into multiple subtasks, arranging the multiple subtasks in stages into multiple stages of orderly execution, and by comprehensively maintaining the subtasks The task dependencies between tasks and the stage dependencies between stages can more effectively manage the execution process of multiple sub-tasks of scheduling tasks, better meet task scheduling in various complex business scenarios, and effectively improve task scheduling performance.
应当理解,上述说明仅是本发明技术方案的概述,以便能够更清楚地了解本发明的技术手段,从而可依照说明书的内容予以实施。为了让本发明的上述和其它目的、特征和优点能够更明显易懂,以下特举例说明本发明的具体实施方式。It should be understood that the above description is only an overview of the technical solutions of the present invention, so that the technical means of the present invention can be more clearly understood, and thus can be implemented in accordance with the contents of the description. In order to make the above-mentioned and other objects, features and advantages of the present invention more apparent and comprehensible, specific embodiments of the present invention are illustrated below.
附图说明Description of drawings
通过阅读下文的示例性实施例的详细描述,本领域普通技术人员将明白本文所述的优点和益处以及其他优点和益处。附图仅用于示出示例性实施例的目的,而并不认为是对本发明的限制。而且在整个附图中,用相同的标号表示相同的部件。在附图中:The advantages and benefits described herein, as well as other advantages and benefits, will become apparent to those of ordinary skill in the art upon reading the following detailed description of the exemplary embodiments. The drawings are for purposes of illustrating exemplary embodiments only and are not to be considered limiting of the invention. Also, the same components are denoted by the same reference numerals throughout the drawings. In the attached image:
图1为根据本发明一实施例的任务调度方法的流程示意图;FIG. 1 is a schematic flowchart of a task scheduling method according to an embodiment of the present invention;
图2为根据本发明一实施例的对调度任务进行分阶段编排的示意图;2 is a schematic diagram of arranging scheduling tasks in stages according to an embodiment of the present invention;
图3为根据本发明又一实施例的任务调度方法的流程示意图;3 is a schematic flowchart of a task scheduling method according to another embodiment of the present invention;
图4为根据本发明一实施例的任务调度系统的示意图;4 is a schematic diagram of a task scheduling system according to an embodiment of the present invention;
图5为根据本发明又一实施例的任务调度方法的流程示意图;5 is a schematic flowchart of a task scheduling method according to another embodiment of the present invention;
图6为根据本发明一实施例的任务调度装置的结构示意图;6 is a schematic structural diagram of a task scheduling apparatus according to an embodiment of the present invention;
图7为根据本发明又一实施例的任务调度装置的结构示意图;7 is a schematic structural diagram of a task scheduling apparatus according to yet another embodiment of the present invention;
在附图中,相同或对应的标号表示相同或对应的部分。In the drawings, the same or corresponding reference numerals denote the same or corresponding parts.
具体实施方式Detailed ways
下面将参照附图更详细地描述本公开的示例性实施例。虽然附图中显示了本公开的示例性实施例,然而应当理解,可以以各种形式实现本公开而不应被这里阐述的实施例所限制。相反,提供这些实施例是为了能够更透彻地理解本公开,并且能够将本公开的范围完整的传达给本领域的技术人员。Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided so that the present disclosure will be more thoroughly understood, and will fully convey the scope of the present disclosure to those skilled in the art.
在本申请实施例的描述中,应理解,诸如“包括”或“具有”等术语旨在指示本说明书中所公开的特征、数字、步骤、行为、部件、部分或其组合的存在,并且不旨在排除一个或多个其他特征、数字、步骤、行为、部件、部分或其组合存在的可能性。In the description of the embodiments of the present application, it should be understood that terms such as "comprising" or "having" are intended to indicate the presence of features, numbers, steps, acts, components, parts or combinations thereof disclosed in this specification, and do not The intention is to exclude the possibility of the presence of one or more other features, numbers, steps, acts, components, parts, or combinations thereof.
除非另有说明,“/”表示或的意思,例如,A/B可以表示A或B;本文中的“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。Unless otherwise specified, "/" means or, for example, A/B can mean A or B; "and/or" in this text is only an association relationship to describe related objects, indicating that there can be three kinds of relationships, For example, A and/or B can mean that A exists alone, A and B exist at the same time, and B exists alone.
术语“第一”、“第二”等仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”等的特征可以明示或者隐含地包括一个或者更多个该特征。在本申请实施例的描述中,除非另有说明,“多个”的含义是两个或两个以上。The terms "first", "second", etc. are used for descriptive purposes only, and should not be construed as indicating or implying relative importance or implying the number of indicated technical features. Thus, a feature defined as "first", "second", etc., may expressly or implicitly include one or more of that feature. In the description of the embodiments of the present application, unless otherwise specified, "plurality" means two or more.
另外还需要说明的是,在不冲突的情况下,本发明中的实施例及实施例中的特征可以相互组合。下面将参考附图并结合实施例来详细说明本发明。In addition, it should be noted that the embodiments of the present invention and the features of the embodiments may be combined with each other without conflict. The present invention will be described in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
图1为根据本申请一实施例的任务调度方法的流程示意图,用于调度执行复杂任务,在该流程中,从设备角度而言,执行主体可以是一个或者多个电子设备;从程序角度而言,执行主体相应地可以是搭载于这些电子设备上的程序。FIG. 1 is a schematic flowchart of a task scheduling method according to an embodiment of the present application, which is used to schedule and execute complex tasks. In this process, from a device perspective, the execution subject may be one or more electronic devices; from a program perspective, In other words, the execution body may be a program mounted on these electronic devices accordingly.
如图1所示,本实施例提供的方法可以包括以下步骤:As shown in FIG. 1, the method provided by this embodiment may include the following steps:
S101、将待调度的调度任务拆分为多个子任务,将多个子任务编排为多个阶段;S101. Divide the scheduling task to be scheduled into multiple subtasks, and arrange the multiple subtasks into multiple stages;
一个示例中,参考图2,示出了一种对调度任务进行分阶段编排的示意图,将待调度的调度任务拆分为多个子任务,并将多个子任务编排为了n个阶段,每个阶段中包括若干个子任务,可以按阶段执行每个阶段中的子任务。可选地,可以根据拆分出的多个子任务之间的关联关系进行该编排,比如具有时间关联关系的两个或以上子任务分别编排到不同的阶段中,每个阶段包括的若干个子任务之间不具有上述关联关系。In an example, referring to FIG. 2 , it shows a schematic diagram of arranging scheduling tasks in stages. The scheduling task to be scheduled is divided into multiple sub-tasks, and the multiple sub-tasks are arranged into n stages, each stage. It includes several subtasks, and the subtasks in each stage can be executed in stages. Optionally, the arrangement can be performed according to the association relationship between the split subtasks, for example, two or more subtasks with temporal associations are arranged in different stages, and each stage includes several subtasks. There is no such relationship between them.
S102、配置多个子任务之间的任务依赖关系和多个阶段之间的阶段依赖关系;S102, configure task dependencies between multiple subtasks and stage dependencies between multiple stages;
具体可以根据任务执行状态配置多个子任务之间、多个阶段之间的依赖关系。任务执行状态主要可以包含调度/子任务执行状态。Specifically, dependencies between multiple subtasks and between multiple stages can be configured according to the task execution state. The task execution status can mainly include scheduling/subtask execution status.
任务依赖关系用于指示子任务之间的依赖关系,换言之,某个子任务的开始执行需要依赖于另一个或多个子任务的执行状态。例如,第一子任务的开始执行可以依赖于第二子任务执行成功/失败。又例如,第三子任务的开始执行可以依赖于第四子任务的未执行状态,诸如此类。Task dependencies are used to indicate dependencies between subtasks. In other words, the start of execution of a subtask needs to depend on the execution status of another or more subtasks. For example, the start of execution of the first subtask may depend on the success/failure of execution of the second subtask. As another example, the start of execution of the third subtask may depend on the unexecuted state of the fourth subtask, and so on.
阶段依赖关系用于指示阶段之间的依赖关系,换言之,某个阶段的开始执行需要依赖于另一个或多个阶段中全部子任务的执行状态。例如,第一阶段的开始执行可以依赖于第二阶段的全部子任务均执行成功/失败,又例如,第三阶段的开始执行可以依赖于第四阶段的全部子任务均执行成功且第五阶段的全部子任务均未执行,诸如此类,本申请对此不作具体限制。Phase dependencies are used to indicate dependencies between phases, in other words, the start of a phase needs to depend on the execution status of all subtasks in another or more phases. For example, the start of execution of the first stage may depend on the success/failure of all subtasks of the second stage. For another example, the start of execution of the third stage may depend on the success of all subtasks of the fourth stage and the success of the fifth stage. All subtasks of are not executed, and so on, which is not specifically limited in this application.
S103、响应于当前阶段的执行指令,获取当前阶段的全部子任务,将满足预设执行条件的待执行子任务下发到执行节点,S103, in response to the execution instruction of the current stage, obtain all the subtasks of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node,
具体地,预设执行条件可以根据阶段依赖关系、任务依赖关系以及任务执行状态确定。Specifically, the preset execution condition may be determined according to the phase dependency, the task dependency, and the task execution state.
仍参考图2,假设当前阶段为阶段2,此时获取阶段2中的全部子任务:子任务2-1-1、子任务2-2-2,…,子任务2-1-t 21,判断每个子任务是否满足预设执行条件,该预设执行条件可以包括当前阶段的阶段执行条件和每个子任务的任务执行条件。举例来说,可以先判断当前阶段是否满足基于阶段依赖关系和任务执行状态确定的阶段执行条件,再进一步判断当前阶段的每个子任务是否满足基于任务依赖关系和任务执行状态确定的任务执行条件,若均满足,则认为该子任务满足该预设执行条件,可以依据负载均衡策略下发到执行节点,并将 子任务执行状态更新为执行中。否则,则认为该子任务不满足预设执行条件,可以将子任务执行状态更新为异常。 Still referring to FIG. 2 , assuming that the current stage is stage 2, all subtasks in stage 2 are obtained at this time: subtask 2-1-1, subtask 2-2-2, ..., subtask 2-1-t 21 , It is judged whether each subtask satisfies a preset execution condition, and the preset execution condition may include the stage execution condition of the current stage and the task execution condition of each subtask. For example, it is possible to first judge whether the current stage satisfies the stage execution conditions determined based on the stage dependencies and the task execution status, and then further judge whether each subtask of the current stage satisfies the task execution conditions determined based on the task dependencies and the task execution status, If all are satisfied, it is considered that the subtask satisfies the preset execution condition, and can be delivered to the execution node according to the load balancing policy, and the execution status of the subtask is updated to be executing. Otherwise, it is considered that the subtask does not meet the preset execution condition, and the execution status of the subtask can be updated to abnormal.
S104、根据执行节点反馈的执行结果更新待执行子任务的执行状态。S104. Update the execution state of the subtask to be executed according to the execution result fed back by the execution node.
具体地,该执行节点反馈的执行结果可以是指示该待执行子任务执行成功/失败/终止/异常。Specifically, the execution result fed back by the execution node may indicate the execution success/failure/termination/abnormality of the subtask to be executed.
可以理解,上述S101-S102为执行调度任务之前的配置工作,S103-S104为具体执行该调度任务的每个当前阶段的调度工作。例如,依据上述S101-S102可以配置出如图2所示出的任务编排结果,并相应配置阶段依赖关系和任务依赖关系,在实际执行时,可以顺序执行图2中的阶段1-阶段n,其中每个阶段作为当前阶段时均执行上述S103-S104的工作,直至阶段n执行结束。It can be understood that the above S101-S102 are the configuration work before executing the scheduling task, and S103-S104 are the scheduling work of each current stage of the specific execution of the scheduling task. For example, according to the above S101-S102, the task arrangement result shown in FIG. 2 can be configured, and the phase dependencies and task dependencies can be configured accordingly. During actual execution, the phases 1 to n in FIG. When each stage is the current stage, the above-mentioned work of S103-S104 is executed until the execution of stage n ends.
在本实施例中,通过将调度任务拆分为多个子任务、将多个子任务分阶段编排成有序执行的多个阶段,以及通过综合维护子任务之间的任务依赖关系和阶段之间的阶段依赖关系,能够更有效地管理调度任务的多个子任务的执行流程,更满足各种复杂业务场景下的任务调度,有效提升任务调度性能。In this embodiment, by dividing the scheduling task into multiple subtasks, arranging the multiple subtasks in stages into multiple stages of orderly execution, and by comprehensively maintaining the task dependency between the subtasks and the relationship between the stages The stage dependency relationship can more effectively manage the execution process of multiple subtasks of the scheduling task, which can better meet the task scheduling in various complex business scenarios, and effectively improve the task scheduling performance.
在一些可能的实施方式中,子任务的执行状态可以包括:待执行、执行中、成功、失败、终止、异常等多种执行状态。例如,针对任意一个子任务,在其未执行时的执行状态为“待执行”、在其已经成功分发到执行节点之后的执行状态为“执行中”,在其已被执行节点成功执行之后的执行状态为“成功”,在其已被执行节点执行失败之后的执行状态为“失败”,在其已被执行节点终止执行之后的执行状态为“终止”,在其发生若干种异常情况之一后的执行状态为“异常”,可以理解的是,根据实际的任务场景,当然还可以设置其他的执行状态,而不仅限于上述所列举的执行状态。本实施例中,通过采用设置上述多种执行状态,相较于传统方案中仅设置“已执行”和“未执行”具有更为精细化的状态管理方案。In some possible implementations, the execution status of the subtask may include multiple execution statuses such as pending, executing, successful, failed, terminated, and abnormal. For example, for any subtask, the execution status is "to be executed" when it is not executed, the execution status is "executing" after it has been successfully distributed to the execution node, and the execution status after it has been successfully executed by the execution node. The execution status is "success", the execution status after it has been executed by the execution node and failed to be executed is "failed", and the execution status after it has been terminated by the execution node is "terminated", and one of several abnormal conditions occurs. The subsequent execution state is "abnormal". It can be understood that, according to the actual task scenario, other execution states can of course be set, and are not limited to the execution states listed above. In this embodiment, by adopting and setting the above-mentioned multiple execution states, a more refined state management solution is provided compared to only setting "executed" and "unexecuted" in the traditional solution.
一个示例中,表1给出一种精细化的子任务状态机。In an example, Table 1 presents a refined subtask state machine.
表1:Table 1:
Figure PCTCN2022074659-appb-000001
Figure PCTCN2022074659-appb-000001
Figure PCTCN2022074659-appb-000002
Figure PCTCN2022074659-appb-000002
在一些可能的实施方式中,调度任务的执行状态可以包括初始和执行。In some possible implementations, the execution state of the scheduled task may include initial and execution.
表2给出一种调度任务状态机,其中,调度任务执行时,记录调度任务的调度任务执行状态标识为“执行”、执行阶段标识为当前在执行的阶段标识;子任务执行状态标识为当前该子任务的执行状态、子任务执行节点为当前执行该子任务的执行节点信息;任务结束后,记录调度任务执行状态标识为“初始”。Table 2 provides a scheduling task state machine, wherein, when the scheduling task is executed, the scheduling task execution status of the recording scheduling task is identified as "execution", and the execution stage is identified as the current stage identification; the subtask execution status is identified as the current The execution state of the subtask and the execution node of the subtask are the execution node information of the subtask currently executing the subtask; after the task ends, the execution state of the recorded scheduling task is marked as "initial".
表2:Table 2:
状态state 含义meaning
初始initial 调度任务未执行Scheduled task not executed
执行implement 调度任务处于执行状态Scheduled task is executing
在一些可能的实施方式中,为了进一步精细化该调度方法,阶段依赖关系和任务依赖关系的依赖关系类型可以包括:强依赖、弱依赖和无依赖。每种依赖关系类型和一个或多个子任务的执行状态具有预设映射关系。In some possible implementations, in order to further refine the scheduling method, the dependency types of the phase dependency and the task dependency may include: strong dependency, weak dependency, and no dependency. Each dependency type has a preset mapping relationship with the execution state of one or more subtasks.
表3给出一种依赖关系和状态机的映射关系表,根据上述子任务状态机,可以细化阶段与阶段之间的阶段依赖关系、子任务与子任务之间的任务依赖关系,依赖关系可以包含:强依赖、弱依赖、无依赖。Table 3 shows a mapping relationship between dependencies and state machines. According to the above subtask state machine, the stage dependencies between stages, the task dependencies between subtasks and subtasks, and the dependencies can be refined. Can include: strong dependencies, weak dependencies, and no dependencies.
表3:table 3:
依赖关系dependencies 满足关系的状态列表List of states that satisfy the relationship
强依赖strong dependence 成功success
弱依赖weak dependency 成功、失败success failure
无依赖no dependency 成功、失败、终止、异常success, failure, termination, exception
相比于现有的方案,本实施例可以提供更为精细的任务状态管理(待执行、执行中、成功、失败、终止、异常)和任务依赖关系管理(强依赖、弱依赖、无依赖)。可满足各类业务场景的需求。Compared with the existing solution, this embodiment can provide more refined task status management (to be executed, executing, successful, failed, terminated, abnormal) and task dependency relationship management (strong dependency, weak dependency, no dependency) . It can meet the needs of various business scenarios.
在一些可能的实施方式中,假设当前阶段基于阶段依赖关系而依赖于前继阶段,阶段依赖关系可以是:强依赖、弱依赖和无依赖中的一种。更为具体地,若阶段依赖关系为强依赖,当前阶段依赖于前继阶段全部子任务均执行成功;若阶段依赖关系为弱依赖,当前阶段 依赖于前继阶段全部子任务均执行无异常;若阶段依赖关系为无依赖,当前阶段的开始执行无需依赖前继阶段的子任务的执行状态。In some possible implementations, it is assumed that the current stage depends on the predecessor stage based on the stage dependency relationship, and the stage dependency relationship can be one of: strong dependency, weak dependency and no dependency. More specifically, if the stage dependency is strong dependency, all subtasks of the current stage depend on the predecessor stage to be executed successfully; if the stage dependency is weak dependency, all subtasks of the current stage depend on the predecessor stage to be executed without exception; If the stage dependency is no dependency, the execution of the current stage does not need to depend on the execution status of the subtasks of the previous stage.
在一些可能的实施方式中,假设待执行子任务基于任务依赖关系而依赖于至少一个指定子任务,任务依赖关系为强依赖、弱依赖和无依赖中的一种。更为具体地,若任务依赖关系为强依赖,待执行子任务依赖于至少一个指定子任务均执行成功;若任务依赖关系为弱依赖,待执行子任务依赖于至少一个指定子任务执行成功或失败;若任务依赖关系为无依赖,待执行子任务依赖于至少一个指定子任务执行成功、失败、终止或异常。In some possible implementations, it is assumed that a subtask to be executed depends on at least one specified subtask based on a task dependency relationship, and the task dependency relationship is one of strong dependency, weak dependency, and no dependency. More specifically, if the task dependency is strong, the subtask to be executed depends on at least one specified subtask to be executed successfully; if the task dependency is weak dependency, the subtask to be executed depends on at least one specified subtask to be executed successfully or Failed; if the task dependency is no dependency, the subtask to be executed depends on the success, failure, termination or exception of at least one specified subtask.
在一些可能的实施方式中,在S103中,还可以判断是否满足执行条件,具体包括:In some possible implementations, in S103, it can also be judged whether the execution conditions are met, specifically including:
若当前阶段的阶段依赖关系为强依赖或弱依赖,判断当前阶段是否满足预设执行条件,若不满足则置当前阶段的全部子任务的执行状态为异常,若满足则利用负载均衡策略依次下发当前阶段的全部子任务并更新下发后的子任务的执行状态为执行中。If the stage dependency of the current stage is strong or weak, judge whether the current stage satisfies the preset execution conditions. If not, set the execution status of all subtasks in the current stage as abnormal. If so, use the load balancing strategy to execute the Send all the subtasks in the current stage and update the execution status of the subtasks after they are issued to executing.
若当前阶段的阶段依赖关系为无依赖,判断当前阶段的每个子任务是否满足预设执行条件,若不满足则置子任务的执行状态为异常,若满足则下发子任务,并更新下发后的子任务的执行状态为执行中。If the stage dependency of the current stage is no dependency, judge whether each subtask of the current stage satisfies the preset execution conditions. If not, set the execution status of the subtask to be abnormal. The execution status of subsequent subtasks is executing.
换言之,为了进一步降低判断每个子任务是否可以执行的复杂度,可以采用下述方案:若当前阶段的阶段依赖关系为强依赖或弱依赖,则忽略配置的当前阶段的每个子任务的任务依赖关系;若当前阶段的阶段依赖关系为无依赖,则支持配置的当前阶段的每个子任务的任务依赖关系。In other words, in order to further reduce the complexity of judging whether each subtask can be executed, the following scheme can be adopted: if the stage dependency of the current stage is a strong dependency or a weak dependency, the task dependency of each subtask of the current stage of the configuration is ignored ; If the stage dependency of the current stage is no dependency, the task dependency of each subtask of the current stage of the configuration is supported.
本实施例支持用户分别配置阶段依赖关系和子任务依赖关系。当某个阶段的阶段依赖关系为强依赖/弱依赖时,无需进一步验证该阶段中每个子任务是否满足基于各自任务依赖关系的预设执行条件,而仅需验证该阶段是否满足基于阶段依赖关系的预设执行条件,若满足,则可以直接下发该阶段中的每个子任务。相反,若某个阶段的阶段依赖关系为无依赖时,则需要验证该阶段中每个子任务是否满足基于各自任务依赖关系的预设执行条件,若满足,则下发满足预设执行条件的子任务,如果该阶段中的某一个或多个子任务并未配置任务依赖关系则可默认其满足预设执行条件。This embodiment supports the user to configure phase dependencies and subtask dependencies respectively. When the stage dependencies of a certain stage are strong/weak dependencies, it is not necessary to further verify whether each subtask in this stage satisfies the preset execution conditions based on their respective task dependencies, but only needs to verify whether the stage satisfies the stage-based dependencies. If the preset execution conditions are met, each subtask in this stage can be directly issued. On the contrary, if the phase dependency of a certain stage is non-dependent, it is necessary to verify whether each subtask in this stage satisfies the preset execution conditions based on their respective task dependencies. If so, the subtasks that meet the preset execution conditions are issued Task, if one or more subtasks in this stage are not configured with task dependencies, they can be defaulted to meet the preset execution conditions.
一个示例中,参考图2,阶段n的阶段依赖关系的类型为弱依赖,由此,当阶段n满足基于阶段依赖关系的阶段执行条件时,则执行阶段n的全部子任务,否则将阶段n的全部子任务的执行状态更新为异常。阶段2的阶段依赖关系的类型为无依赖,由此可以进一步验证阶段2中任务2-1-2是否满足基于其任务依赖关系的任务执行条件,任务2-1-2的任务依赖关系具体为:任务2-1-2依赖于子任务1-1-2且为强依赖,并且任务2-1-2依赖于子任务1-2-1且为弱依赖。因此,结合表3所示出的映射关系,只有当子任务1-1-2的执行状态为 成功时,且任务2-1-2的执行状态为成功或失败时,可以执行该任务2-1-2。针对阶段2中的其他子任务,由于并未配置任务依赖关系,因此无需进一步执行验证即可直接执行。In an example, referring to FIG. 2 , the type of phase dependency of phase n is weak dependency. Therefore, when phase n satisfies the phase execution condition based on phase dependency, all subtasks of phase n are executed, otherwise, phase n is executed. The execution status of all subtasks of is updated to Exception. The type of the phase dependency in phase 2 is no dependency, so it can be further verified whether the task 2-1-2 in phase 2 satisfies the task execution conditions based on its task dependency. The task dependency of task 2-1-2 is specifically: : Task 2-1-2 depends on subtask 1-1-2 and is strongly dependent, and task 2-1-2 depends on subtask 1-2-1 and is weakly dependent. Therefore, combined with the mapping relationship shown in Table 3, only when the execution status of subtask 1-1-2 is successful, and the execution status of task 2-1-2 is successful or failed, the task 2-1-2 can be executed. 1-2. For other subtasks in phase 2, since no task dependencies are configured, they can be executed directly without further validation.
在一些可能的实施方式中,为监控当前所有正在执行任务的进度,进一步驱动任务流继续向下执行或结束任务,可以监控任务执行状态。当监控到当前阶段的前一阶段的全部子任务均执行完成时,生成当前阶段的执行指令;和/或,当监控到当前阶段的全部子任务均执行完成时,进一步判断当前阶段是否还有后续阶段,若有,则生成后续阶段的执行指令,若无,则结束任务。In some possible implementations, in order to monitor the progress of all currently executing tasks, and further drive the task flow to continue to execute or end the task, the task execution status can be monitored. When it is monitored that all the subtasks of the previous stage of the current stage are executed and completed, an execution instruction of the current stage is generated; and/or, when it is monitored that all the subtasks of the current stage have been executed and completed, it is further judged whether there are any more subtasks in the current stage. In the subsequent stage, if there is, the execution instruction of the subsequent stage will be generated, if not, the task will be ended.
在一些可能的实施方式中,为了对同一阶段内的多个子任务进行并发执行,可以对多个子任务进行进一步的精细化编排,在S101中,还可以:对阶段中的多个子任务进行分组编排,得到阶段的多个任务分组;以及,当当前阶段包含多个任务分组时,并行执行当前阶段的多个任务分组。In some possible implementations, in order to perform concurrent execution of multiple subtasks in the same stage, the multiple subtasks may be further finely arranged. In S101, it is also possible to: group and arrange the multiple subtasks in the stage , to obtain multiple task groups of the stage; and, when the current stage contains multiple task groups, execute the multiple task groups of the current stage in parallel.
一个示例中,仍参见图2,其示出了一种精细化的分阶段分组的任务调度的示意图,其中,可从阶段和子任务维度进行依赖配置。将每个阶段中包含的多个子任务进一步进行分组编排,从并分组维度细化控制子任务并发。其实现方式如下:在子任务编排时,按执行顺序分别为阶段编号1、2、…n,同阶段内设置并发分组编号1、2、…n,组内分别为各子任务编号n-1-1、n-1-2、…n-1-tn。该模型支持同阶段内的子任务根据并发需求进行分组配置。同一阶段的不同分组之间可以并发执行。同一阶段的同一分组内的多个子任务顺序执行。In an example, still referring to FIG. 2 , it shows a schematic diagram of a fine-grained staged grouped task scheduling, wherein dependencies can be configured from stage and subtask dimensions. The multiple subtasks contained in each stage are further grouped and arranged, and the concurrency of subtasks is controlled in detail from the parallel grouping dimension. The implementation method is as follows: when subtasks are arranged, the stage numbers are 1, 2, ... n according to the execution order, and the concurrent group numbers 1, 2, ... n are set in the same stage, and each subtask number n-1 is set in the group. -1, n-1-2, ...n-1-tn. This model supports subtasks in the same stage to be grouped and configured according to concurrency requirements. Different groups of the same stage can execute concurrently. Multiple subtasks within the same group of the same stage are executed sequentially.
在一些可能的实施方式中,参考图3,在S103中,为进一步提高执行节点的负载均衡,还可以执行以下步骤:In some possible implementations, referring to FIG. 3, in S103, in order to further improve the load balancing of the execution node, the following steps may also be performed:
S31、预先配置每个子任务的预期负载、每个执行节点的负载阈值;S31, preconfigure the expected load of each subtask and the load threshold of each execution node;
S32、当前阶段执行时,确定待执行子任务的预期负载,并计算每个执行节点的当前负载;S32, when the current stage is executed, determine the expected load of the subtask to be executed, and calculate the current load of each execution node;
S33、根据每个执行节点的负载阈值和当前负载,和待执行子任务的预期负载确定待执行子任务的可用节点列表;以及,S33, determine the available node list of the subtask to be executed according to the load threshold and current load of each execution node, and the expected load of the subtask to be executed; and,
S34、将待执行子任务下发至可用节点列表中负载率最低的执行节点。S34. Deliver the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
一个示例中,基于负载均衡策略的分发流程如下:在S31中,添加调度任务时,需要为子任务配置预期负载,为执行节点配置负载阈值。用户可根据子任务在生产上的预计资源损耗评估预期负载、根据执行节点的实际可利用资源评估负载阈值。该此处资源包括CPU、内存等。在S32中,子任务下发前,获取该子任务对应的执行节点列表,并查询每个执行节点当前正在执行的所有子任务,并计算该执行节点当前的负载总和w n。在S33中,记当前待执行子任务预期负载为w,执行节点负载阈值为w max,如果w+w n小于配置的负载阈值w max, 则将此节点放到可用节点列表。在S34中,计算负载率[(w+w n)/w max]并排序,选择负载率最低的可用节点进行子任务下发。相反,如果无可用节点,则记该子任务执行状态“异常”。 In an example, the distribution process based on the load balancing strategy is as follows: in S31 , when adding a scheduling task, it is necessary to configure an expected load for the subtask, and configure a load threshold for the execution node. Users can evaluate the expected load according to the expected resource consumption of subtasks in production, and evaluate the load threshold according to the actual available resources of the execution node. The resources here include CPU, memory, etc. In S32, before the subtask is issued, a list of execution nodes corresponding to the subtask is obtained, all subtasks currently being executed by each execution node are queried, and the current load sum wn of the execution node is calculated. In S33, record the expected load of the current subtask to be executed as w, and the load threshold of the execution node as w max , if w+ wn is less than the configured load threshold w max , put the node on the available node list. In S34, the load ratio [(w+w n )/w max ] is calculated and sorted, and the available node with the lowest load ratio is selected to issue subtasks. On the contrary, if there is no available node, record the execution status of the subtask as "abnormal".
传统方案中难以规避执行节点因负载过高宕机的风险。本实施例提出了一种实时的任务下发策略,要求预先评估执行节点的负载阈值和每个子任务的权重。在进行任务下发时,通过实时计算当前所有可用节点的实际负载,与负载阈值相比,综合选择最优的执行节点执行任务。相比于现有方案,交互复杂度低,确保执行节点不会超负载,具有更好的通用性和安全性。In the traditional scheme, it is difficult to avoid the risk of the execution node going down due to excessive load. This embodiment proposes a real-time task distribution strategy, which requires pre-evaluation of the load threshold of the execution node and the weight of each subtask. When the task is issued, the actual load of all currently available nodes is calculated in real time, and the optimal execution node is comprehensively selected to execute the task compared with the load threshold. Compared with the existing solutions, the interaction complexity is low, ensuring that the execution node will not be overloaded, and has better versatility and security.
在一些可能的实施方式中,方法还包括预先配置多种配置信息,该配置信息包括:调度任务的调度任务标识;每个子任务的以下一种或多种配置项:所属调度任务的调度任务标识、所属阶段的阶段标识、所属阶段的阶段依赖关系、所属任务分组的分组标识、子任务标识、任务依赖关系、预期负载、超时时间、执行模块标识;执行模块的以下一种或多种配置项:执行节点标识、执行节点的负载阈值、执行节点列表。In some possible implementations, the method further includes pre-configuring a variety of configuration information, where the configuration information includes: a scheduling task identifier of the scheduling task; one or more of the following configuration items of each subtask: the scheduling task identifier of the scheduling task to which it belongs. , the stage ID of the stage to which it belongs, the stage dependency of the stage to which it belongs, the group ID of the task group to which it belongs, subtask ID, task dependency, expected load, timeout, and execution module ID; one or more of the following configuration items of the execution module : Execution node ID, execution node load threshold, and execution node list.
一个示例中,参考图4,示出一种任务调度系统,主要可以包含配置模块400、可视化界面401、调度模块402、监控模块403、存储模块404、执行模块405,各个模块具体执行如下工作:配置模块400用于生成任务调度相关的配置信息。例如,参考图4,在(1)中配置模块400通过可视化界面401输入配置信息,可选地也可以通过后台输入该配置信息,本申请对此不作具体限制。可视化界面401用于为用户提供操作该任务调度相关流程的交互界面,可以在该可视化界面401执行:添加/删除/更新任务、添加配置信息、查询调度/子任务的执行状态、手动触发/终止调度任务等功能。例如,参考图4,在(2)中可视化界面401将配置信息存储到存储模块404,在(3)中可视化界面401向调度模块402发生手动触发/终止调度任务的指令。调度模块402用于响应于触发条件(手动触发或自动触发均可)启动调度任务调度,同时负责子任务下发并维护任务执行状态。例如,在(4)中调度模块402从存储模块404获取调度/子任务的配置信息和执行状态,在(5)中将满足预设执行条件的子任务下发到执行模块405中的执行节点,在(6)中接收执行节点反馈的执行结果,在(7)中根据执行结果更新对应子任务的执行状态。监控模块403用于监控当前所有正在执行的调度/子任务的进度,驱动任务流继续向下执行或结束任务。在(8)中监控模块403从存储模块404获取调度/子任务的配置信息及执行状态,在(9)中监控模块403监控当前正在执行的调度/子任务的进度,在(10)中监控模块403在监控到当前阶段子任务执行完成之后且存在后继阶段时向调度模402发送后继阶段的任务执行指令,在(11)中监控模块403在监控到当前阶段子任务执行完成之后且不存在后继阶段时结束该调度任务调度。存储模块404 用于存储调度/子任务的配置信息和任务执行状态。执行模块405包括若干个执行节点,每个执行节点均用于负责执行子任务,该执行节点一般是各业务系统的模块。In an example, referring to FIG. 4 , a task scheduling system is shown, which mainly includes a configuration module 400, a visual interface 401, a scheduling module 402, a monitoring module 403, a storage module 404, and an execution module 405. Each module specifically performs the following tasks: The configuration module 400 is configured to generate configuration information related to task scheduling. For example, referring to FIG. 4 , in (1), the configuration module 400 inputs the configuration information through the visual interface 401 , and optionally the configuration information can also be input through the background, which is not specifically limited in this application. The visual interface 401 is used to provide the user with an interactive interface for operating the related process of the task scheduling, which can be performed on the visual interface 401: adding/deleting/updating tasks, adding configuration information, querying the execution status of scheduling/subtasks, manual triggering/terminating Scheduling tasks, etc. For example, referring to FIG. 4, in (2) the visual interface 401 stores the configuration information to the storage module 404, and in (3) the visual interface 401 sends an instruction to the scheduling module 402 to manually trigger/terminate the scheduling task. The scheduling module 402 is configured to start scheduling task scheduling in response to a trigger condition (either manually triggered or automatically triggered), and is responsible for issuing subtasks and maintaining task execution status. For example, in (4), the scheduling module 402 obtains the configuration information and execution status of the scheduling/subtasks from the storage module 404, and in (5), the subtasks that satisfy the preset execution conditions are delivered to the execution nodes in the execution module 405 , in (6) the execution result fed back by the execution node is received, and in (7) the execution state of the corresponding subtask is updated according to the execution result. The monitoring module 403 is used to monitor the progress of all currently executing scheduling/subtasks, and drive the task flow to continue to execute or end the task. In (8), the monitoring module 403 obtains the configuration information and execution status of the scheduling/subtask from the storage module 404, in (9) the monitoring module 403 monitors the progress of the currently executing scheduling/subtask, and in (10) The module 403 sends the task execution instruction of the subsequent stage to the scheduling module 402 after monitoring the completion of the current stage subtask execution and when there is a subsequent stage, in (11), the monitoring module 403 monitors that the current stage subtask execution is completed and does not exist. End the scheduling task scheduling in the subsequent stage. The storage module 404 is used to store the configuration information of the scheduling/subtask and the task execution state. The execution module 405 includes several execution nodes, each execution node is responsible for executing subtasks, and the execution node is generally a module of each business system.
一个示例中,参考图5,示出基于图2中的编排结果并利用图4所示出任务调度装置来执行任务调度的流程交互图,具体来说,当通过可视化界面发出手动触发指令或基于后台发出自动触发指令时,待调度的调度任务满足触发条件,进一步在S501,调度模块402获取阶段1的全部子任务。在S502,由于阶段1为起始阶段,因此无阶段依赖和子任务依赖,调度模块402可以依次下发该阶段1的每个子任务;在S503,若下发成功,则记该子任务的执行状态为“执行中”,否则记为“异常”;在S504,在子任务执行完成后,调度模块402接收执行模块405的执行节点反馈的执行结果;在S505,调度模块402根据执行节点反馈的执行结果,在存储模块404中更新对应子任务的执行状态,可以是“成功”、“失败”、“异常”等;在S506,由监控模块403监控获取阶段1的子任务执行状态;在S507,当阶段1的所有子任务均执行结束(非“待执行”或“执行中”状态),监控模块403进一步判断是否存在下阶段待执行子任务,若不存在,则认为调度任务已完成执行,否则更新阶段标识;在S508、监控模块403生成并发送阶段1的下阶段,也即阶段2的执行指令;在S509,调度模块402获取当前的全部子任务的执行状态和阶段2的全部子任务;在S510,调度模块402根据配置的阶段依赖关系,判断阶段2是否满足执行条件,若不满足,则置该阶段2所有子任务执行状态为“异常”,否则依次执行该阶段所有子任务;在S511,在阶段2的子任务执行前,如果阶段2的阶段依赖关系为无依赖,调度模块402根据子任务依赖配置,判断待处理子任务是否满足执行条件;在S512,若待处理子任务不满足执行条件,则将该子任务执行状态更新为“异常”,否则按照S502进行任务下发。依次循环上述步骤S502-S512,直至阶段n执行完成。可选地,针对阶段内可能存在的多个任务分组,在S506和S507之间,还可以包括步骤(a),具体包括:若当前分组有待执行子任务,则继续执行当前分组下一子任务,若当前阶段内所有分组子任务都已完成,且存在下阶段待执行任务则执行该S507。In an example, referring to FIG. 5 , it shows a flow interaction diagram for performing task scheduling based on the scheduling result in FIG. 2 and using the task scheduling device shown in FIG. 4 . When an automatic triggering instruction is issued in the background, the scheduling task to be scheduled meets the triggering condition, and further in S501, the scheduling module 402 acquires all the subtasks of stage 1. In S502, since stage 1 is the initial stage, there is no stage dependency and sub-task dependency, and the scheduling module 402 can sequentially deliver each sub-task of this stage 1; in S503, if the delivery is successful, the execution state of the sub-task is recorded In S504, after the execution of the subtask is completed, the scheduling module 402 receives the execution result fed back by the execution node of the execution module 405; in S505, the scheduling module 402 executes the execution according to the feedback from the execution node As a result, the execution state of the corresponding subtask is updated in the storage module 404, which can be "success", "failure", "abnormal", etc.; at S506, the monitoring module 403 monitors and obtains the execution state of the subtask in stage 1; at S507, When all the subtasks in stage 1 have been executed (not "to be executed" or "executed"), the monitoring module 403 further judges whether there are subtasks to be executed in the next stage, if not, it is considered that the scheduling task has completed execution, Otherwise, the stage identification is updated; in S508, the monitoring module 403 generates and sends the next stage of stage 1, that is, the execution instruction of stage 2; in S509, the scheduling module 402 obtains the current execution status of all subtasks and all subtasks of stage 2 At S510, scheduling module 402 judges whether stage 2 satisfies the execution condition according to the stage dependency of configuration, if not, then puts all subtask execution states of this stage 2 as "abnormal", otherwise executes all subtasks of this stage successively; In S511, before the subtasks of stage 2 are executed, if the stage dependency of stage 2 is no dependency, the scheduling module 402 determines whether the subtasks to be processed satisfy the execution conditions according to the subtask dependency configuration; in S512, if the subtasks to be processed If the execution conditions are not met, the execution status of the subtask is updated to "abnormal", otherwise, the task is issued according to S502. The above steps S502-S512 are cycled in sequence until the execution of stage n is completed. Optionally, for multiple task groups that may exist in the stage, between S506 and S507, step (a) may also be included, which specifically includes: if the current group has a sub-task to be executed, then continue to execute the current sub-task of the next group. , if all grouping subtasks in the current stage have been completed, and there is a task to be executed in the next stage, then execute S507.
在本说明书的描述中,参考术语“一些可能的实施方式”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本发明的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不必须针对的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任一个或多个实施例或示例中以合适的方式结合。此外,在不相互矛盾的情况下,本领域的技术人员可以将本说明书中描述的不同实施例或示例以及不同实施例或示例的特征进行结合和组合。In the description of this specification, reference to description of the terms "some possible implementations", "some embodiments", "example", "specific example", or "some examples" etc. means that the description in connection with the embodiment or example A particular feature, structure, material or characteristic is included in at least one embodiment or example of the present invention. In this specification, schematic representations of the above terms are not necessarily directed to the same embodiment or example. Furthermore, the particular features, structures, materials or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, those skilled in the art may combine and combine the different embodiments or examples described in this specification, as well as the features of the different embodiments or examples, without conflicting each other.
此外,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。在本发明的描述中,“多个”的含义是至少两个,例如两个,三个等,除非另有明确具体的限定。In addition, the terms "first" and "second" are only used for descriptive purposes, and should not be construed as indicating or implying relative importance or implying the number of indicated technical features. Thus, a feature delimited with "first", "second" may expressly or implicitly include at least one of that feature. In the description of the present invention, "plurality" means at least two, such as two, three, etc., unless otherwise expressly and specifically defined.
流程图中或在此以其他方式描述的任何过程或方法描述可以被理解为,表示包括一个或更多个用于实现特定逻辑功能或过程的步骤的可执行指令的代码的模块、片段或部分,并且本发明的优选实施方式的范围包括另外的实现,其中可以不按所示出或讨论的顺序,包括根据所涉及的功能按基本同时的方式或按相反的顺序,来执行功能,这应被本发明的实施例所属技术领域的技术人员所理解。Any description of a process or method in the flowcharts or otherwise described herein may be understood to represent a module, segment or portion of code comprising one or more executable instructions for implementing a specified logical function or step of the process , and the scope of the preferred embodiments of the invention includes alternative implementations in which the functions may be performed out of the order shown or discussed, including performing the functions substantially concurrently or in the reverse order depending upon the functions involved, which should It is understood by those skilled in the art to which the embodiments of the present invention belong.
关于本申请实施例的方法流程图,将某些操作描述为以一定顺序执行的不同的步骤。这样的流程图属于说明性的而非限制性的。可以将在本文中所描述的某些步骤分组在一起并且在单个操作中执行、可以将某些步骤分割成多个子步骤、并且可以以不同于在本文中所示出的顺序来执行某些步骤。可以由任何电路结构和/或有形机制(例如,由在计算机设备上运行的软件、硬件(例如,处理器或芯片实现的逻辑功能)等、和/或其任何组合)以任何方式来实现在流程图中所示出的各个步骤。With regard to the method flowcharts of the embodiments of the present application, certain operations are described as different steps performed in a certain order. Such flowcharts are illustrative and not restrictive. Certain steps described herein may be grouped together and performed in a single operation, certain steps may be split into sub-steps, and certain steps may be performed in a different order than shown herein . may be implemented in any manner by any circuit structure and/or tangible mechanism (eg, by software running on a computer device, hardware (eg, logical functions implemented by a processor or chip), etc., and/or any combination thereof) The individual steps shown in the flowchart.
基于相同的技术构思,本发明实施例还提供一种任务调度装置,用于执行上述任一实施例所提供的任务调度方法。图6为本发明实施例提供的一种任务调度装置结构示意图。Based on the same technical concept, an embodiment of the present invention further provides a task scheduling apparatus for executing the task scheduling method provided by any of the foregoing embodiments. FIG. 6 is a schematic structural diagram of a task scheduling apparatus according to an embodiment of the present invention.
如图6所示,该装置60包括:As shown in Figure 6, the device 60 includes:
配置模块400,用于将待调度的调度任务拆分为多个子任务,将多个子任务编排为多个阶段,并配置多个子任务之间的任务依赖关系和多个阶段之间的阶段依赖关系;The configuration module 400 is used for splitting the scheduling task to be scheduled into multiple subtasks, arranging the multiple subtasks into multiple stages, and configuring the task dependency relationship between the multiple subtasks and the stage dependency relationship between the multiple stages ;
调度模块402用于响应于当前阶段的执行指令,获取当前阶段的全部子任务,将满足预设执行条件的待执行子任务下发到执行节点,其中,预设执行条件根据阶段依赖关系、任务依赖关系以及任务执行状态确定;并根据执行节点反馈的执行结果更新待执行子任务的执行状态。The scheduling module 402 is configured to, in response to the execution instruction of the current stage, obtain all subtasks of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node, wherein the preset execution conditions are based on the stage dependencies, tasks The dependency relationship and the task execution state are determined; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
在一种可能的实施方式中,装置还包括监控模块,用于:监控任务执行状态;以及,当监控到当前阶段的前一阶段的全部子任务均执行完成时,生成当前阶段的执行指令;和/或,当监控到当前阶段的全部子任务均执行完成时,生成后续阶段的执行指令。In a possible implementation manner, the device further includes a monitoring module, configured to: monitor the task execution state; and, when it is monitored that all subtasks of the previous stage of the current stage are executed and completed, generate an execution instruction of the current stage; And/or, when it is monitored that all subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
在一种可能的实施方式中,配置模块400还用于:对阶段中的多个子任务进行分组编排,得到阶段的多个任务分组;以及,当当前阶段包含多个任务分组时,并行执行当前阶段的多个任务分组。In a possible implementation, the configuration module 400 is further configured to: group and arrange multiple subtasks in the stage to obtain multiple task groups of the stage; and, when the current stage includes multiple task groups, execute the current stage in parallel Multiple task groupings for stages.
在一种可能的实施方式中,调度模块402还用于基于负载均衡策略将满足预设执行条件的待执行子任务下发到执行节点,具体用于:预先配置每个子任务的预期负载、每个执行节点的负载阈值;当前阶段执行时,确定待执行子任务的预期负载,并计算每个执行节点的当前负载;根据每个执行节点的负载阈值和当前负载,和待执行子任务的预期负载确定待执行子任务的可用节点列表;以及,将待执行子任务下发至可用节点列表中负载率最低的执行节点。In a possible implementation, the scheduling module 402 is further configured to deliver the to-be-executed subtasks that meet the preset execution conditions to the execution node based on the load balancing strategy, and is specifically configured to: preconfigure the expected load of each subtask, each subtask The load threshold of each execution node; when the current stage is executed, the expected load of the subtask to be executed is determined, and the current load of each execution node is calculated; according to the load threshold and current load of each execution node, and the expected load of the subtask to be executed The load determines the list of available nodes of the subtask to be executed; and delivers the subtask to be executed to the execution node with the lowest load rate in the list of available nodes.
在一种可能的实施方式中,任务执行状态至少包括子任务的执行状态,子任务的执行状态包括:待执行、执行中、成功、失败、终止、异常。In a possible implementation manner, the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful, failed, terminated, and abnormal.
在一种可能的实施方式中,阶段依赖关系和任务依赖关系的依赖关系类型包括:强依赖、弱依赖和无依赖;其中,每种依赖关系类型和一个或多个子任务的执行状态具有预设映射关系。In a possible implementation, the dependency types of the stage dependency and the task dependency include: strong dependency, weak dependency, and no dependency; wherein, each dependency type and the execution state of one or more subtasks have a preset Mapping relations.
在一种可能的实施方式中,当前阶段基于配置的阶段依赖关系而依赖于前继阶段;其中,若阶段依赖关系为强依赖,当前阶段依赖于前继阶段全部子任务均执行成功;若阶段依赖关系为弱依赖,当前阶段依赖于前继阶段全部子任务均执行无异常;若阶段依赖关系为无依赖,当前阶段的开始执行不依赖前继阶段的子任务的执行状态。In a possible implementation, the current stage depends on the predecessor stage based on the configured stage dependencies; wherein, if the stage dependency is a strong dependency, all subtasks of the current stage depend on the predecessor stage to be successfully executed; if the stage If the dependency is weak, the current stage depends on the predecessor stage and all subtasks are executed without exception; if the stage dependency is no dependency, the execution of the current stage does not depend on the execution status of the subtasks in the predecessor stage.
在一种可能的实施方式中,待执行子任务基于配置的任务依赖关系而依赖于至少一个指定子任务,任务依赖关系包括:强依赖、弱依赖和无依赖中的一种;其中,若任务依赖关系为强依赖,待执行子任务依赖于至少一个指定子任务均执行成功;若任务依赖关系为弱依赖,待执行子任务依赖于至少一个指定子任务执行成功或失败;若任务依赖关系为无依赖,待执行子任务依赖于至少一个指定子任务执行成功、失败、终止或异常。In a possible implementation manner, the subtask to be executed depends on at least one specified subtask based on a configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency; wherein, if the task If the dependency is a strong dependency, the subtask to be executed depends on at least one specified subtask to execute successfully; if the task dependency is a weak dependency, the subtask to be executed depends on at least one specified subtask to execute successfully or fail; if the task dependency is No dependencies, subtasks to be executed depend on at least one specified subtask to execute successfully, fail, terminate or exception.
在一种可能的实施方式中,装置还包括判断是否满足执行条件,具体包括:若当前阶段的阶段依赖关系为强依赖或弱依赖,判断当前阶段是否满足预设执行条件,若不满足则置当前阶段的全部子任务的执行状态为异常,若满足则利用负载均衡策略依次下发当前阶段的全部子任务并更新下发后的子任务的执行状态为执行中。In a possible implementation manner, the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is a strong dependency or a weak dependency, judging whether the current stage satisfies the preset execution condition, if not, setting the The execution status of all subtasks in the current stage is abnormal. If satisfied, all subtasks in the current stage are sequentially delivered using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
在一种可能的实施方式中,装置还包括判断是否满足执行条件,具体包括:若当前阶段的阶段依赖关系为无依赖,则判断当前阶段的每个子任务是否满足预设执行条件,若不满足则置子任务的执行状态为异常,若满足则下发子任务,并更新下发后的子任务的执行状态为执行中。In a possible implementation manner, the apparatus further includes judging whether the execution condition is satisfied, specifically including: if the stage dependency of the current stage is no dependency, judging whether each subtask of the current stage satisfies the preset execution condition, if not The execution status of the subtask is set as abnormal, and if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
在一种可能的实施方式中,配置模块400还用于预先配置多个配置信息,配置信息包括以下中的一种或多种:调度任务的调度任务标识;每个子任务的以下一种或多种配置项:所属调度任务的调度任务标识、所属阶段的阶段标识、所属阶段的阶段依赖关系、所属任务 分组的分组标识、子任务标识、任务依赖关系、预期负载、超时时间、执行模块标识;执行模块的以下一种或多种配置项:执行节点标识、执行节点的负载阈值、执行节点列表。In a possible implementation manner, the configuration module 400 is further configured to preconfigure a plurality of configuration information, and the configuration information includes one or more of the following: the scheduling task identifier of the scheduling task; the following one or more of each subtask Configuration items: the scheduling task identifier of the scheduling task to which it belongs, the stage identifier of the phase to which it belongs, the phase dependency of the phase to which it belongs, the group identifier of the task group to which it belongs, the subtask identifier, the task dependency, the expected load, the timeout period, and the execution module identifier; One or more of the following configuration items of the execution module: the identification of the execution node, the load threshold of the execution node, and the list of execution nodes.
需要说明的是,本申请实施例中的任务调度装置可以实现前述任务调度方法的实施例的各个过程,并达到相同的效果和功能,这里不再赘述。It should be noted that, the task scheduling apparatus in the embodiment of the present application can implement each process of the foregoing embodiments of the task scheduling method, and achieve the same effects and functions, which will not be repeated here.
图7为根据本申请一实施例的任务调度装置,用于执行图1所示出的任务调度方法,该装置包括:至少一个处理器;以及,与至少一个处理器通信连接的存储器;其中,存储器存储有可被至少一个处理器执行的指令,指令被至少一个处理器执行,以使至少一个处理器能够执行上述实施例所述的方法。FIG. 7 is a task scheduling apparatus according to an embodiment of the present application, for executing the task scheduling method shown in FIG. 1 , the apparatus includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the methods described in the above embodiments.
根据本申请的一些实施例,提供了任务调度方法的非易失性计算机存储介质,其上存储有计算机可执行指令,该计算机可执行指令设置为在由处理器运行时执行:上述实施例所述的方法。According to some embodiments of the present application, a non-volatile computer storage medium of a task scheduling method is provided, and computer-executable instructions are stored thereon, and the computer-executable instructions are configured to be executed when run by a processor: the above-mentioned embodiments method described.
本申请中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于装置、设备和计算机可读存储介质实施例而言,由于其基本相似于方法实施例,所以其描述进行了简化,相关之处可参见方法实施例的部分说明即可。Each embodiment in this application is described in a progressive manner, and the same and similar parts between the various embodiments may be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the apparatus, device, and computer-readable storage medium embodiments, since they are basically similar to the method embodiments, the description thereof is simplified, and reference may be made to the partial descriptions of the method embodiments for related parts.
本申请实施例提供的装置、设备和计算机可读存储介质与方法是一一对应的,因此,装置、设备和计算机可读存储介质也具有与其对应的方法类似的有益技术效果,由于上面已经对方法的有益技术效果进行了详细说明,因此,这里不再赘述装置、设备和计算机可读存储介质的有益技术效果。The apparatuses, devices, and computer-readable storage media and methods provided in the embodiments of the present application are in one-to-one correspondence. Therefore, the apparatuses, devices, and computer-readable storage media also have beneficial technical effects similar to those of the corresponding methods. The beneficial technical effects of the method have been described in detail, therefore, the beneficial technical effects of the apparatus, equipment and computer-readable storage medium will not be repeated here.
本领域内的技术人员应明白,本发明的实施例可提供为方法、系统或计算机程序产品。因此,本发明可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each process and/or block in the flowchart illustrations and/or block diagrams, and combinations of processes and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to the processor of a general purpose computer, special purpose computer, embedded processor or other programmable data processing device to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing device produce Means for implementing the functions specified in a flow or flow of a flowchart and/or a block or blocks of a block diagram.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的 制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions The apparatus implements the functions specified in the flow or flow of the flowcharts and/or the block or blocks of the block diagrams.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded on a computer or other programmable data processing device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process such that The instructions provide steps for implementing the functions specified in the flow or blocks of the flowcharts and/or the block or blocks of the block diagrams.
在一个典型的配置中,计算设备包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。Memory may include forms of non-persistent memory, random access memory (RAM) and/or non-volatile memory in computer readable media, such as read only memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁带磁磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。此外,尽管在附图中以特定顺序描述了本发明方法的操作,但是,这并非要求或者暗示必须按照该特定顺序来执行这些操作,或是必须执行全部所示的操作才能实现期望的结果。附加地或备选地,可以省略某些步骤,将多个步骤合并为一个步骤执行,和/或将一个步骤分解为多个步骤执行。Computer-readable media includes both persistent and non-permanent, removable and non-removable media, and storage of information may be implemented by any method or technology. Information may be computer readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), Flash Memory or other memory technology, Compact Disc Read Only Memory (CD-ROM), Digital Versatile Disc (DVD) or other optical storage, Magnetic tape cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission medium that can be used to store information that can be accessed by a computing device. Furthermore, although the operations of the methods of the present invention are depicted in the figures in a particular order, this does not require or imply that the operations must be performed in the particular order, or that all illustrated operations must be performed to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined to be performed as one step, and/or one step may be decomposed into multiple steps to be performed.
虽然已经参考若干具体实施方式描述了本发明的精神和原理,但是应该理解,本发明并不限于所公开的具体实施方式,对各方面的划分也不意味着这些方面中的特征不能组合以进行受益,这种划分仅是为了表述的方便。本发明旨在涵盖所附权利要求的精神和范围内所包括的各种修改和等同布置。While the spirit and principles of the present invention have been described with reference to a number of specific embodiments, it should be understood that the invention is not limited to the specific embodiments disclosed, nor does the division of aspects imply that features of these aspects cannot be combined to perform Benefit, this division is only for convenience of presentation. The invention is intended to cover various modifications and equivalent arrangements included within the spirit and scope of the appended claims.

Claims (24)

  1. 一种任务调度方法,其特征在于,包括:A task scheduling method, comprising:
    将待调度的调度任务拆分为多个子任务,将所述多个子任务编排为多个阶段,并配置所述多个子任务之间的任务依赖关系和所述多个阶段之间的阶段依赖关系;Split the scheduling task to be scheduled into multiple subtasks, arrange the multiple subtasks into multiple stages, and configure the task dependency between the multiple subtasks and the stage dependency between the multiple stages ;
    响应于当前阶段的执行指令,获取当前阶段的全部子任务,将满足预设执行条件的待执行子任务下发到执行节点,其中,所述预设执行条件根据所述阶段依赖关系、所述任务依赖关系以及任务执行状态确定;并根据所述执行节点反馈的执行结果更新所述待执行子任务的执行状态。In response to the execution instruction of the current stage, obtain all the subtasks of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node, wherein the preset execution conditions are based on the stage dependencies, the The task dependency relationship and the task execution state are determined; and the execution state of the to-be-executed subtask is updated according to the execution result fed back by the execution node.
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:监控任务执行状态;以及,The method according to claim 1, wherein the method further comprises: monitoring task execution status; and,
    当监控到所述当前阶段的前一阶段的全部子任务均执行完成时,生成所述当前阶段的执行指令;和/或,When it is monitored that all subtasks of the previous stage of the current stage are executed and completed, an execution instruction of the current stage is generated; and/or,
    当监控到所述当前阶段的全部子任务均执行完成时,生成后续阶段的执行指令。When it is monitored that all the subtasks of the current stage are executed and completed, an execution instruction of the subsequent stage is generated.
  3. 根据权利要求1或2所述的方法,其特征在于,对所述多个子任务进行分阶段编排,还包括:The method according to claim 1 or 2, wherein the multiple subtasks are arranged in stages, further comprising:
    对所述阶段中的多个子任务进行分组编排,得到所述阶段的多个任务分组;以及,当所述当前阶段包含所述多个任务分组时,并行执行所述当前阶段的所述多个任务分组。grouping and arranging a plurality of subtasks in the stage to obtain a plurality of task groups in the stage; and, when the current stage includes the plurality of task groups, executing the plurality of task groups in the current stage in parallel Task grouping.
  4. 根据权利要求1-3中任一项所述的方法,其特征在于,还包括基于负载均衡策略将满足预设执行条件的所述待执行子任务下发到执行节点,具体包括:The method according to any one of claims 1-3, further comprising, based on a load balancing strategy, delivering the subtasks to be executed that meet preset execution conditions to the execution node, specifically including:
    预先配置每个所述子任务的预期负载、每个所述执行节点的负载阈值;pre-configuring the expected load of each of the subtasks and the load threshold of each of the execution nodes;
    所述当前阶段执行时,确定所述待执行子任务的所述预期负载,并计算每个所述执行节点的当前负载;When the current stage is executed, the expected load of the subtask to be executed is determined, and the current load of each execution node is calculated;
    根据每个所述执行节点的所述负载阈值和所述当前负载,和所述待执行子任务的预期负载确定所述待执行子任务的可用节点列表;以及,Determine the available node list of the subtask to be executed according to the load threshold and the current load of each of the execution nodes, and the expected load of the subtask to be executed; and,
    将所述待执行子任务下发至所述可用节点列表中负载率最低的所述执行节点。The to-be-executed subtask is delivered to the execution node with the lowest load rate in the available node list.
  5. 根据权利要求1-4中任一项所述的方法,其特征在于,所述任务执行状态至少包括所述子任务的执行状态,所述子任务的执行状态包括:待执行、执行中、成功、失败、终止、异常。The method according to any one of claims 1-4, wherein the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful , failure, termination, exception.
  6. 根据权利要求5所述的方法,其特征在于,所述阶段依赖关系和所述任务依赖关系的依赖关系类型包括:强依赖、弱依赖和无依赖;The method according to claim 5, wherein the dependency types of the phase dependency and the task dependency include: strong dependency, weak dependency, and no dependency;
    其中,每种所述依赖关系类型和一个或多个子任务的执行状态具有预设映射关系。Wherein, each type of dependency relationship and the execution state of one or more subtasks have a preset mapping relationship.
  7. 根据权利要求6所述的方法,其特征在于,The method of claim 6, wherein:
    所述当前阶段基于配置的所述阶段依赖关系而依赖于前继阶段;the current stage is dependent on a predecessor stage based on the configured stage dependencies;
    其中,若所述阶段依赖关系为所述强依赖,所述当前阶段依赖于前继阶段全部子任务均执行成功;若所述阶段依赖关系为所述弱依赖,所述当前阶段依赖于前继阶段全部子任务均执行无异常;若所述阶段依赖关系为所述无依赖,所述当前阶段的开始执行不依赖前继阶段的子任务的执行状态。Wherein, if the stage dependency is the strong dependency, the current stage depends on the success of all subtasks in the predecessor stage; if the stage dependency is the weak dependency, the current stage depends on the predecessor stage All subtasks of the stage are executed without exception; if the stage dependency is the no dependency, the start execution of the current stage does not depend on the execution state of the subtasks of the previous stage.
  8. 根据权利要求6或7所述的方法,其特征在于,The method according to claim 6 or 7, wherein,
    所述待执行子任务基于配置的所述任务依赖关系而依赖于至少一个指定子任务,所述任务依赖关系包括:强依赖、弱依赖和无依赖中的一种;The subtask to be executed depends on at least one specified subtask based on the configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency;
    其中,若所述任务依赖关系为所述强依赖,所述待执行子任务依赖于所述至少一个指定子任务均执行成功;若所述任务依赖关系为所述弱依赖,所述待执行子任务依赖于所述至少一个指定子任务执行成功或失败;若所述任务依赖关系为所述无依赖,所述待执行子任务依赖于所述至少一个指定子任务执行成功、失败、终止或异常。Wherein, if the task dependency is the strong dependency, the to-be-executed subtask depends on the at least one specified subtask to be successfully executed; if the task dependency is the weak dependency, the to-be-executed subtask is executed successfully; The task depends on the at least one specified subtask to execute successfully or fails; if the task dependency is the no dependency, the to-be-executed subtask depends on the at least one specified subtask to execute successfully, fail, terminate or abnormally .
  9. 根据权利要求6-8中任一项所述的方法,其特征在于,所述方法还包括判断是否满足所述执行条件,具体包括:The method according to any one of claims 6-8, characterized in that the method further comprises judging whether the execution condition is satisfied, specifically comprising:
    若所述当前阶段的所述阶段依赖关系为强依赖或弱依赖,判断所述当前阶段是否满足所述预设执行条件,若不满足则置所述当前阶段的全部子任务的执行状态为异常,若满足则利用负载均衡策略依次下发所述当前阶段的全部子任务并更新下发后的子任务的执行状态为执行中。If the phase dependency of the current phase is a strong dependency or a weak dependency, determine whether the current phase satisfies the preset execution condition, and if not, set the execution status of all subtasks in the current phase as abnormal , if satisfied, all subtasks in the current stage are sequentially delivered by using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
  10. 根据权利要求8或9所述的方法,其特征在于,所述方法还包括判断是否满足所述执行条件,具体包括:The method according to claim 8 or 9, characterized in that, the method further comprises judging whether the execution condition is satisfied, specifically comprising:
    若所述当前阶段的所述阶段依赖关系为无依赖,则判断所述当前阶段的每个所述子任务是否满足所述预设执行条件,若不满足则置所述子任务的执行状态为异常,若满足则下发所述子任务,并更新下发后的所述子任务的执行状态为执行中。If the phase dependency of the current phase is no dependency, then determine whether each of the subtasks in the current phase satisfies the preset execution condition, and if not, set the execution status of the subtask to be If it is abnormal, if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
  11. 根据权利要求1-10中任一项所述的方法,其特征在于,所述方法还包括预先配置多个配置信息,所述配置信息包括以下中的一种或多种:所述调度任务的调度任务标识;每个所述子任务的以下一种或多种配置项:所属调度任务的所述调度任务标识、所属阶段的阶段标识、所属阶段的所述阶段依赖关系、所属任务分组的分组标识、子任务标识、所述任务依赖关系、预期负载、超时时间、执行模块标识;执行模块的以下一种或多种配置项:执行节点标识、所述执行节点的负载阈值、执行节点列表。The method according to any one of claims 1-10, wherein the method further comprises preconfiguring a plurality of configuration information, the configuration information including one or more of the following: Scheduling task identifier; one or more of the following configuration items for each subtask: the scheduling task identifier of the scheduling task to which it belongs, the phase identifier of the phase to which it belongs, the phase dependency of the phase to which it belongs, and the grouping of the task group to which it belongs. Identification, subtask identification, task dependency, expected load, timeout time, execution module identification; one or more of the following configuration items of the execution module: execution node identification, load threshold of the execution node, and execution node list.
  12. 一种任务调度装置,其特征在于,包括:A task scheduling device, characterized in that it includes:
    配置模块,用于将待调度的调度任务拆分为多个子任务,将所述多个子任务编排为多个阶段,并配置所述多个子任务之间的任务依赖关系和所述多个阶段之间的阶段依赖关系;The configuration module is used to split the scheduling task to be scheduled into multiple subtasks, arrange the multiple subtasks into multiple stages, and configure the task dependency between the multiple subtasks and the relationship between the multiple stages. stage dependencies between;
    调度模块,用于响应于当前阶段的执行指令,获取当前阶段的全部子任务,将满足预设执行条件的待执行子任务下发到执行节点,其中,所述预设执行条件根据所述阶段依赖关系、所述任务依赖关系以及任务执行状态确定;并根据所述执行节点反馈的执行结果更新所述待执行子任务的执行状态。The scheduling module is used to obtain all subtasks of the current stage in response to the execution instruction of the current stage, and deliver the subtasks to be executed that meet the preset execution conditions to the execution node, wherein the preset execution conditions are based on the stage The dependency relationship, the task dependency relationship and the task execution state are determined; and the execution state of the subtask to be executed is updated according to the execution result fed back by the execution node.
  13. 根据权利要求12所述的装置,其特征在于,所述装置还包括监控模块,用于:The device according to claim 12, wherein the device further comprises a monitoring module for:
    监控任务执行状态;以及,monitor task execution status; and,
    当监控到所述当前阶段的前一阶段的全部子任务均执行完成时,生成所述当前阶段的执行指令;和/或,当监控到所述当前阶段的全部子任务均执行完成时,生成后续阶段的执行指令。When it is monitored that all the subtasks of the previous stage of the current stage are executed and completed, the execution instruction of the current stage is generated; and/or, when it is monitored that all the subtasks of the current stage are executed and completed, the execution instruction of the current stage is generated. Execution instructions in subsequent stages.
  14. 根据权利要求12或13所述的装置,其特征在于,所述配置模块还用于:The device according to claim 12 or 13, wherein the configuration module is further configured to:
    对所述阶段中的多个子任务进行分组编排,得到所述阶段的多个任务分组;以及,当所述当前阶段包含所述多个任务分组时,并行执行所述当前阶段的所述多个任务分组。grouping and arranging a plurality of subtasks in the stage to obtain a plurality of task groups in the stage; and, when the current stage includes the plurality of task groups, executing the plurality of task groups in the current stage in parallel Task grouping.
  15. 根据权利要求12-14中任一项所述的装置,其特征在于,所述调度模块还用于基于负载均衡策略将满足预设执行条件的所述待执行子任务下发到执行节点,具体用于:The device according to any one of claims 12 to 14, wherein the scheduling module is further configured to deliver the subtasks to be executed that meet preset execution conditions to the execution nodes based on a load balancing strategy, specifically Used for:
    预先配置每个所述子任务的预期负载、每个所述执行节点的负载阈值;pre-configuring the expected load of each of the subtasks and the load threshold of each of the execution nodes;
    所述当前阶段执行时,确定所述待执行子任务的所述预期负载,并计算每个所述执行节点的当前负载;When the current stage is executed, the expected load of the subtask to be executed is determined, and the current load of each execution node is calculated;
    根据每个所述执行节点的所述负载阈值和所述当前负载,和所述待执行子任务的预期负载确定所述待执行子任务的可用节点列表;以及,Determine the available node list of the subtask to be executed according to the load threshold and the current load of each of the execution nodes, and the expected load of the subtask to be executed; and,
    将所述待执行子任务下发至所述可用节点列表中负载率最低的所述执行节点。The to-be-executed subtask is delivered to the execution node with the lowest load rate in the available node list.
  16. 根据权利要求12-15中任一项所述的装置,其特征在于,所述任务执行状态至少包括所述子任务的执行状态,所述子任务的执行状态包括:待执行、执行中、成功、失败、终止、异常。The apparatus according to any one of claims 12-15, wherein the task execution status includes at least the execution status of the subtask, and the execution status of the subtask includes: pending, executing, successful , failure, termination, exception.
  17. 根据权利要求16所述的装置,其特征在于,所述阶段依赖关系和所述任务依赖关系的依赖关系类型包括:强依赖、弱依赖和无依赖;The apparatus according to claim 16, wherein the dependency types of the phase dependency and the task dependency include: strong dependency, weak dependency, and no dependency;
    其中,每种所述依赖关系类型和一个或多个子任务的执行状态具有预设映射关系。Wherein, each type of dependency relationship and the execution state of one or more subtasks have a preset mapping relationship.
  18. 根据权利要求17所述的装置,其特征在于,The apparatus of claim 17, wherein:
    所述当前阶段基于配置的所述阶段依赖关系而依赖于前继阶段;the current stage is dependent on a predecessor stage based on the configured stage dependencies;
    其中,若所述阶段依赖关系为所述强依赖,所述当前阶段依赖于前继阶段全部子任务均执行成功;若所述阶段依赖关系为所述弱依赖,所述当前阶段依赖于前继阶段全部子任务均执行无异常;若所述阶段依赖关系为所述无依赖,所述当前阶段的开始执行不依赖前继阶段的子任务的执行状态。Wherein, if the stage dependency is the strong dependency, the current stage depends on the success of all subtasks in the predecessor stage; if the stage dependency is the weak dependency, the current stage depends on the predecessor stage All subtasks of the stage are executed without exception; if the stage dependency is the no dependency, the start execution of the current stage does not depend on the execution state of the subtasks of the previous stage.
  19. 根据权利要求17或18所述的装置,其特征在于,The device according to claim 17 or 18, characterized in that,
    所述待执行子任务基于配置的所述任务依赖关系而依赖于至少一个指定子任务,所述任务依赖关系包括:强依赖、弱依赖和无依赖中的一种;The subtask to be executed depends on at least one specified subtask based on the configured task dependency relationship, and the task dependency relationship includes: one of strong dependency, weak dependency and no dependency;
    其中,若所述任务依赖关系为所述强依赖,所述待执行子任务依赖于所述至少一个指定子任务均执行成功;若所述任务依赖关系为所述弱依赖,所述待执行子任务依赖于所述至少一个指定子任务执行成功或失败;若所述任务依赖关系为所述无依赖,所述待执行子任务依赖于所述至少一个指定子任务执行成功、失败、终止或异常。Wherein, if the task dependency is the strong dependency, the to-be-executed subtask depends on the at least one specified subtask to be successfully executed; if the task dependency is the weak dependency, the to-be-executed subtask is executed successfully; The task depends on the at least one specified subtask to execute successfully or fails; if the task dependency is the no dependency, the to-be-executed subtask depends on the at least one specified subtask to execute successfully, fail, terminate or abnormally .
  20. 根据权利要求17-19中任一项所述的装置,其特征在于,所述装置还包括判断是否满足所述执行条件,具体包括:The device according to any one of claims 17-19, wherein the device further comprises judging whether the execution condition is satisfied, specifically comprising:
    若所述当前阶段的所述阶段依赖关系为强依赖或弱依赖,判断所述当前阶段是否满足所述预设执行条件,若不满足则置所述当前阶段的全部子任务的执行状态为异常,若满足则利用负载均衡策略依次下发所述当前阶段的全部子任务并更新下发后的子任务的执行状态为执行中。If the phase dependency of the current phase is a strong dependency or a weak dependency, determine whether the current phase satisfies the preset execution condition, and if not, set the execution status of all subtasks in the current phase as abnormal , if satisfied, all subtasks in the current stage are sequentially delivered by using the load balancing strategy, and the execution status of the delivered subtasks is updated to be executing.
  21. 根据权利要求17-20中任一项所述的装置,其特征在于,所述装置还包括判断是否满足所述执行条件,具体包括:The apparatus according to any one of claims 17-20, wherein the apparatus further comprises judging whether the execution condition is satisfied, specifically comprising:
    若所述当前阶段的所述阶段依赖关系为无依赖,则判断所述当前阶段的每个所述子任务是否满足所述预设执行条件,若不满足则置所述子任务的执行状态为异常,若满足则下发所述子任务,并更新下发后的所述子任务的执行状态为执行中。If the phase dependency of the current phase is no dependency, then determine whether each of the subtasks in the current phase satisfies the preset execution condition, and if not, set the execution status of the subtask to be If it is abnormal, if it is satisfied, the subtask is issued, and the execution status of the issued subtask is updated to be executing.
  22. 根据权利要求12-21中任一项所述的装置,其特征在于,所述装置还包括预先配置多个配置信息,所述配置信息包括以下中的一种或多种:所述调度任务的调度任务标识;每个所述子任务的以下一种或多种配置项:所属调度任务的所述调度任务标识、所属阶段的阶段标识、所属阶段的所述阶段依赖关系、所属任务分组的分组标识、子任务标识、所述任务依赖关系、预期负载、超时时间、执行模块标识;执行模块的以下一种或多种配置项:执行节点标识、所述执行节点的负载阈值、执行节点列表。The apparatus according to any one of claims 12-21, wherein the apparatus further comprises preconfigured multiple pieces of configuration information, the configuration information comprising one or more of the following: Scheduling task identifier; one or more of the following configuration items for each subtask: the scheduling task identifier of the scheduling task to which it belongs, the phase identifier of the phase to which it belongs, the phase dependency of the phase to which it belongs, and the grouping of the task group to which it belongs. Identification, subtask identification, task dependency, expected load, timeout time, execution module identification; one or more of the following configuration items of the execution module: execution node identification, load threshold of the execution node, and execution node list.
  23. 一种任务调度装置,其特征在于,包括:A task scheduling device, characterized in that it includes:
    至少一个处理器;以及,与至少一个处理器通信连接的存储器;其中,存储器存储有可被至少一个处理器执行的指令,指令被至少一个处理器执行,以使至少一个处理器能够执行:如权利要求1-11所述的方法。at least one processor; and, a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to execute: such as The method of claims 1-11.
  24. 一种计算机可读存储介质,所述计算机可读存储介质存储有程序,当所述程序被多核处理器执行时,使得所述多核处理器执行如权利要求1-11中任一项所述的方法。A computer-readable storage medium, the computer-readable storage medium stores a program, when the program is executed by a multi-core processor, the multi-core processor is made to execute the method according to any one of claims 1-11 method.
PCT/CN2022/074659 2021-04-22 2022-01-28 Task scheduling method and apparatus, and computer-readable storage medium WO2022222567A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110436537.2A CN113238838B (en) 2021-04-22 2021-04-22 Task scheduling method and device and computer readable storage medium
CN202110436537.2 2021-04-22

Publications (1)

Publication Number Publication Date
WO2022222567A1 true WO2022222567A1 (en) 2022-10-27

Family

ID=77128847

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/074659 WO2022222567A1 (en) 2021-04-22 2022-01-28 Task scheduling method and apparatus, and computer-readable storage medium

Country Status (3)

Country Link
CN (1) CN113238838B (en)
TW (1) TWI791389B (en)
WO (1) WO2022222567A1 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115640102A (en) * 2022-11-16 2023-01-24 武汉大学 Distributed task based re-executable computing method, system and medium
CN115816441A (en) * 2022-10-31 2023-03-21 实时侠智能控制技术有限公司 Robot control method and device based on task description and readable medium
CN115955481A (en) * 2022-12-12 2023-04-11 支付宝(杭州)信息技术有限公司 Emergency response method and device
CN116501474A (en) * 2023-06-08 2023-07-28 之江实验室 System, method and device for processing batch homogeneous tasks
CN117806806A (en) * 2024-02-28 2024-04-02 湖南科技大学 Task part unloading scheduling method, terminal equipment and storage medium

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113238838B (en) * 2021-04-22 2023-01-24 中国银联股份有限公司 Task scheduling method and device and computer readable storage medium
CN113641476B (en) * 2021-08-16 2023-07-14 腾讯科技(深圳)有限公司 Task scheduling method, game engine, device and storage medium
CN113741872B (en) * 2021-09-03 2024-04-23 上海新炬网络信息技术股份有限公司 Automatic software application publishing method based on job scheduling
CN113835892B (en) * 2021-09-27 2024-02-13 苏州浪潮智能科技有限公司 Unified storage device, service management method and module thereof, and readable storage medium
CN116069388A (en) * 2021-10-30 2023-05-05 华为技术有限公司 Task processing method and electronic device
CN114167766A (en) * 2021-11-15 2022-03-11 成都四方伟业软件股份有限公司 Method and device for issuing and executing instructions during multi-association equipment
CN114416346B (en) * 2021-12-23 2023-03-24 广州市玄武无线科技股份有限公司 Multi-node task scheduling method, device, equipment and storage medium
CN114327819B (en) * 2021-12-24 2023-02-03 北京百度网讯科技有限公司 Task management method, device, equipment and storage medium
CN114358649B (en) * 2022-01-17 2022-09-13 安徽君鲲科技有限公司 Maritime affair site supervision method and system
CN115328639B (en) * 2022-10-13 2022-12-13 北京云枢创新软件技术有限公司 Task scheduling system based on chip verification regression
CN116107724B (en) * 2023-04-04 2023-07-18 山东浪潮科学研究院有限公司 AI (advanced technology attachment) acceleration core scheduling management method, device, equipment and storage medium
CN116723225A (en) * 2023-06-16 2023-09-08 广州银汉科技有限公司 Automatic allocation method and system for game tasks

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130036425A1 (en) * 2011-08-04 2013-02-07 Microsoft Corporation Using stages to handle dependencies in parallel tasks
CN104915260A (en) * 2015-06-19 2015-09-16 北京搜狐新媒体信息技术有限公司 Hadoop cluster management task distributing method and system
CN108287756A (en) * 2018-01-25 2018-07-17 联动优势科技有限公司 A kind of method and device of processing task
CN109725995A (en) * 2018-06-15 2019-05-07 中国平安人寿保险股份有限公司 Data pick-up task executing method, device, equipment and readable storage medium storing program for executing
CN110516971A (en) * 2019-08-29 2019-11-29 杭州网易再顾科技有限公司 Method, apparatus, medium and the calculating equipment of abnormality detection
CN112559156A (en) * 2020-12-23 2021-03-26 百果园技术(新加坡)有限公司 Multi-dependency task grouping management method, device, equipment and storage medium
CN112596876A (en) * 2020-12-17 2021-04-02 平安普惠企业管理有限公司 Task scheduling method, device and related equipment
CN112631751A (en) * 2020-12-22 2021-04-09 平安普惠企业管理有限公司 Task scheduling method and device, computer equipment and storage medium
CN113238838A (en) * 2021-04-22 2021-08-10 中国银联股份有限公司 Task scheduling method and device and computer readable storage medium

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108491254A (en) * 2018-02-07 2018-09-04 链家网(北京)科技有限公司 A kind of dispatching method and device of data warehouse
CN110895484A (en) * 2018-09-12 2020-03-20 北京奇虎科技有限公司 Task scheduling method and device
EP3851970A4 (en) * 2018-09-30 2021-10-27 Huawei Technologies Co., Ltd. Computational accelerator, exchanger, task scheduling method, and processing system
CN110134499A (en) * 2019-03-29 2019-08-16 新智云数据服务有限公司 Method for scheduling task, task scheduling system, storage medium and computer equipment
CN110287052B (en) * 2019-06-25 2022-01-28 深圳前海微众银行股份有限公司 Root cause task determination method and device for abnormal task
CN111708628A (en) * 2020-06-23 2020-09-25 中国平安财产保险股份有限公司 Task scheduling management method, device, equipment and storage medium
CN112114956A (en) * 2020-09-29 2020-12-22 中国银行股份有限公司 Task scheduling method, device and system
CN112667383B (en) * 2020-12-31 2024-02-09 北京高途云集教育科技有限公司 Task execution and scheduling method, system, device, computing equipment and medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130036425A1 (en) * 2011-08-04 2013-02-07 Microsoft Corporation Using stages to handle dependencies in parallel tasks
CN104915260A (en) * 2015-06-19 2015-09-16 北京搜狐新媒体信息技术有限公司 Hadoop cluster management task distributing method and system
CN108287756A (en) * 2018-01-25 2018-07-17 联动优势科技有限公司 A kind of method and device of processing task
CN109725995A (en) * 2018-06-15 2019-05-07 中国平安人寿保险股份有限公司 Data pick-up task executing method, device, equipment and readable storage medium storing program for executing
CN110516971A (en) * 2019-08-29 2019-11-29 杭州网易再顾科技有限公司 Method, apparatus, medium and the calculating equipment of abnormality detection
CN112596876A (en) * 2020-12-17 2021-04-02 平安普惠企业管理有限公司 Task scheduling method, device and related equipment
CN112631751A (en) * 2020-12-22 2021-04-09 平安普惠企业管理有限公司 Task scheduling method and device, computer equipment and storage medium
CN112559156A (en) * 2020-12-23 2021-03-26 百果园技术(新加坡)有限公司 Multi-dependency task grouping management method, device, equipment and storage medium
CN113238838A (en) * 2021-04-22 2021-08-10 中国银联股份有限公司 Task scheduling method and device and computer readable storage medium

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115816441A (en) * 2022-10-31 2023-03-21 实时侠智能控制技术有限公司 Robot control method and device based on task description and readable medium
CN115816441B (en) * 2022-10-31 2023-08-08 实时侠智能控制技术有限公司 Robot control method and device based on task description and readable medium
CN115640102A (en) * 2022-11-16 2023-01-24 武汉大学 Distributed task based re-executable computing method, system and medium
CN115955481A (en) * 2022-12-12 2023-04-11 支付宝(杭州)信息技术有限公司 Emergency response method and device
CN116501474A (en) * 2023-06-08 2023-07-28 之江实验室 System, method and device for processing batch homogeneous tasks
CN116501474B (en) * 2023-06-08 2023-09-22 之江实验室 System, method and device for processing batch homogeneous tasks
CN117806806A (en) * 2024-02-28 2024-04-02 湖南科技大学 Task part unloading scheduling method, terminal equipment and storage medium

Also Published As

Publication number Publication date
TWI791389B (en) 2023-02-01
CN113238838B (en) 2023-01-24
CN113238838A (en) 2021-08-10
TW202242643A (en) 2022-11-01

Similar Documents

Publication Publication Date Title
WO2022222567A1 (en) Task scheduling method and apparatus, and computer-readable storage medium
US10268513B2 (en) Computing resource allocation optimization
CN108845884B (en) Physical resource allocation method, device, computer equipment and storage medium
Rajguru et al. A comparative performance analysis of load balancing algorithms in distributed system using qualitative parameters
US20080030764A1 (en) Server parallel aggregation
WO2019037203A1 (en) Application program performance testing method, device, computer equipment, and storage medium
Chard et al. Cost-aware cloud provisioning
JP2017142824A (en) Real-time optimization of compute infrastructure in virtualized environment
Delamare et al. SpeQuloS: a QoS service for BoT applications using best effort distributed computing infrastructures
US11182217B2 (en) Multilayered resource scheduling
US10067793B2 (en) Data processing method and apparatus for executing task code using reservation instruction and release instruction
CN110928655A (en) Task processing method and device
KR20120082598A (en) Cost based scheduling algorithm for multiple workflow in cloud computing and system of the same
CN111078396A (en) Distributed data access method and system based on multitask instances
JP2020502641A (en) Compute resource allocation
CN106528288A (en) Resource management method, device and system
WO2018133821A1 (en) Memory-aware plan negotiation in query concurrency control
Tavakoli et al. Log-assisted straggler-aware I/O scheduler for high-end computing
US8316375B2 (en) Load-balancing of processes based on inertia
CN112181661B (en) Task scheduling method
JP6477260B2 (en) Method and resource manager for executing an application
Jayadivya et al. Qos based scheduling of workflows in cloud computing
CN106598726A (en) Multi-task management system and distributed deployment method thereof
Thai et al. Algorithms for optimising heterogeneous Cloud virtual machine clusters
US11354154B2 (en) Timer task ownership determination in a cluster based on a common cluster member selection algorithm

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22790677

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 22790677

Country of ref document: EP

Kind code of ref document: A1