CN111831420A - Method and device for task scheduling, electronic equipment and computer-readable storage medium - Google Patents

Method and device for task scheduling, electronic equipment and computer-readable storage medium Download PDF

Info

Publication number
CN111831420A
CN111831420A CN202010697771.6A CN202010697771A CN111831420A CN 111831420 A CN111831420 A CN 111831420A CN 202010697771 A CN202010697771 A CN 202010697771A CN 111831420 A CN111831420 A CN 111831420A
Authority
CN
China
Prior art keywords
task
executed
execution
request
tasks
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN202010697771.6A
Other languages
Chinese (zh)
Other versions
CN111831420B (en
Inventor
路平
刘曾超前
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202010697771.6A priority Critical patent/CN111831420B/en
Publication of CN111831420A publication Critical patent/CN111831420A/en
Application granted granted Critical
Publication of CN111831420B publication Critical patent/CN111831420B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application discloses a method and a device for task scheduling, electronic equipment and a computer-readable storage medium, and relates to the technical field of computers, cloud computing, task scheduling, algorithms and task queue processing. The specific implementation scheme is as follows: the method comprises the steps of obtaining at least one type of task request information to be executed, generating tasks to be executed in a standard format according to the task request information, responding to the situation that a current scene meets a preset trigger condition, obtaining a plurality of tasks to be executed, generating a task execution queue, and sequentially sending the tasks to be executed in the task execution queue to a corresponding execution main body. The scheme provides a method for task scheduling, which can unify task request information of different categories to adapt to different operation requests and save operation resources.

Description

Method and device for task scheduling, electronic equipment and computer-readable storage medium
Technical Field
The overall disclosure relates to the technical field of computers, in particular to the technical field of cloud computing, task scheduling, algorithm and task queue processing.
Background
In an example life cycle of a cloud product, in order to achieve various different purposes, various tasks exist to assist in completing a plurality of transactions according to specific situations corresponding to the purposes, such as an order execution task, an automatic renewal task, a virtual machine deletion task, and the like.
When executing the task, it is necessary to schedule appropriate resources and select a processing policy corresponding to the task type to execute the task, depending on the type of the task.
Disclosure of Invention
The application provides a method and a device for task scheduling, electronic equipment and a storage medium.
In a first aspect, an embodiment of the present application provides a method for task scheduling, including: acquiring at least one type of task request information to be executed, and generating a task to be executed in a standard format according to the task request information; responding to the current scene meeting a preset trigger condition, and acquiring a plurality of to-be-executed tasks to generate a task execution queue; and sequentially sending the tasks to be executed in the task execution queue to the corresponding execution main bodies.
In a second aspect, an embodiment of the present application provides an apparatus for task scheduling, including: the request information acquisition unit is configured to acquire at least one type of task request information to be executed and generate a task to be executed in a standard format according to the task request information; the execution queue generating unit is configured to respond to the situation that the current scene meets a preset trigger condition, and acquire a plurality of task generation task execution queues to be executed; and the task sending unit is configured to send the tasks to be executed in the task execution queue to the corresponding execution main bodies in sequence.
In a third aspect, an embodiment of the present application provides an electronic device, including: 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 executable by the at least one processor to enable the at least one processor to perform the method for task scheduling as described in any implementation manner of the first aspect.
In a fourth aspect, embodiments of the present application provide a non-transitory computer readable storage medium having computer instructions stored thereon, comprising: the computer instructions are for causing the computer to perform a method for task scheduling as described in any implementation of the first aspect.
The method for task scheduling in the embodiment of the application obtains at least one type of task request information to be executed, generates corresponding tasks to be executed according to the task request information, responds to the situation that a current scene meets a preset trigger condition, obtains a plurality of tasks to be executed to generate a task execution queue, sequentially sends the tasks to be executed in the task execution queue to a corresponding execution main body, and can unify the task request information of different types to adapt to different operation requests and save operation resources.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present application, nor do they limit the scope of the present application. Other features of the present application will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not intended to limit the present application. Wherein:
FIG. 1 is an exemplary system architecture to which the present application may be applied;
FIG. 2 is a flow diagram for one embodiment of a method for task scheduling according to the present application;
FIG. 3 is a schematic diagram of an application scenario of a method for task scheduling according to the present application;
FIG. 4 is a schematic block diagram illustrating one embodiment of an apparatus for task scheduling according to the present application;
FIG. 5 is a block diagram of an electronic device suitable for use in implementing a method for task scheduling of an embodiment of the present application.
Detailed Description
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
Fig. 1 illustrates an exemplary system architecture 100 to which embodiments of the method, apparatus, electronic device, and computer-readable storage medium for task scheduling of the present application may be applied.
As shown in fig. 1, the system architecture 100 may include terminal devices 101, 102, 103, a network 104, and a server 105. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, 103 and the server 105. Network 104 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 101, 102, 103 to interact with the server 105 through the network 104 to receive or send task request information or the like. Various cloud client applications, such as a cloud playing application, a cloud storage application, a cloud development application, and the like, may be installed on the terminal devices 101, 102, and 103.
The terminal apparatuses 101, 102, and 103 may be hardware or software. When the terminal devices 101, 102, 103 are hardware, they may be various electronic devices with display screens, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like. When the terminal apparatuses 101, 102, 103 are software, they can be installed in the electronic apparatuses listed above. It may be implemented as a plurality of software or software modules (for example to implement a service for task scheduling) or as a single software or software module. And is not particularly limited herein.
The server 105 may be a server providing various services, for example, a server that generates tasks to be executed in a standard format according to task request information sent to the terminal devices 101, 102, and 103 that are shown and received by the user through the network 104, generates a task execution queue of multiple tasks to be executed in response to that a current scene meets a preset trigger condition, and sequentially sends the tasks to be executed in the task execution queue to corresponding execution subjects.
It should be noted that, the method for task scheduling provided in the following embodiments of the present application is generally performed by the server 105, and accordingly, the apparatus for task scheduling is generally disposed in the server 105.
It should be noted that the tasks to be executed may be stored locally in the server 105, or may be dispersedly stored in the terminal devices 101, 102, and 103 according to all possible storage special requirements in an actual application scenario, where the storage terminal devices 101, 102, and 103 may be original files or backup files, and are not specifically limited herein. The exemplary system architecture 100 may also not include the terminal devices 101, 102, 103 and the network 104 when the terminal devices 101, 102, 103 are virtual machines running on the server 105.
It should also be noted that applications for task scheduling may also be installed in the terminal devices 101, 102, and 103, and the terminal devices 101, 102, and 103 may also complete acquiring task request information, generate a task to be executed in a standard format according to the acquired request information, acquire a plurality of tasks to be executed to generate a task execution queue in response to that a current scene meets a preset trigger condition, and sequentially send the tasks to be executed in the task execution queue to the corresponding execution main bodies. In this case, the method for task scheduling may be executed by the terminal apparatuses 101, 102, and 103, and accordingly, the device for task scheduling may be provided in the terminal apparatuses 101, 102, and 103. At this point, the exemplary system architecture 100 may also not include the server 105 and the network 104.
The server 105 may be hardware or software. When the server 105 is hardware, it may be implemented as a distributed server cluster composed of a plurality of servers, or may be implemented as a single server. When the server is software, it may be implemented as a plurality of software or software modules (for example, for providing a push information service), or may be implemented as a single software or software module. And is not particularly limited herein.
It should be understood that the number of terminal devices, networks, and servers in fig. 1 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
With continued reference to FIG. 2, a flow 200 of one embodiment of a method for task scheduling according to the present application is shown. The method for task scheduling comprises the following steps:
step 201, at least one type of task request information to be executed is obtained, and a task to be executed in a standard format is generated according to the task request information.
In this embodiment, an execution subject (for example, the server 105 or the terminal devices 101, 102, 103 shown in fig. 1) for task scheduling may obtain task request information from a local or non-local human-computer interaction device (for example, the terminal devices 101, 102, 103 shown in fig. 1).
Specifically, at least one category of to-be-executed task request information can be acquired according to the use property of the product, and to-be-executed tasks in a standard format are correspondingly generated according to the to-be-executed task request information, so that the execution main bodies of task scheduling can uniformly process to-be-executed tasks obtained due to different categories of task request information by using the same strategy.
The task to be executed in the standard format refers to a type of task that can be regarded as the same type by the execution main body, or the execution main body can use the same or the same type of policy to process at the same time, and the execution main body of the task scheduling method can monitor the effectiveness of the task to be executed according to the content and the operation condition of the task to be executed in the standard format.
It should be understood that after the to-be-executed tasks in the standard format are generated, the corresponding category labels of the task request information may also be added to the to-be-executed tasks, so as to implement the distinction of the to-be-executed tasks.
It should be understood that, when the execution main body locally has a saving condition (for example, a storage device having a saving function is locally provided in the execution main body), the generated task to be executed may be saved locally in the execution main body, may also be saved in a pre-constructed database, and may also be saved in another independent storage medium independent from the execution main body, which is not limited in this application.
The exemplary order-type requested task information, automatic charging-type requested task information, and timing-type requested task information are all tasks having a retry property during execution, but cannot be scheduled uniformly due to different retry policies.
The order type task request information refers to request type information related to the use of order information, and generally refers to a request of a user for purchasing, managing and counting a specific commodity, and a common scenario is that, for example, a buyer places an order to a seller through a cloud system, and performs shopping or a warehouse manager realizes logistics management according to a purchase order and a shipment order.
The automatic fee-renewing task request information refers to a task request which is authorized by a buyer and automatically carries out service renewal and payment when a service period expires, and a common generation scenario is that in a payment authorization process, two parties automatically pay when the authorization expires after negotiation, so that an automatic fee-renewing task request is sent out when an authorization period interface is used.
The timing type task request information refers to a task request for automatically executing a corresponding task when a preset time point or interval time meets a preset time interval, a common scenario is that a rule is calculated according to a predetermined time, the corresponding task is executed when the rule is met, for example, the task is set to be No. 10 per month for paying electric charge, and when the time condition reaches No. 10 per month, request information for paying the electric charge is sent.
It can be seen that although the invoking policy is not necessarily required due to the change of data and the difference of task properties, the task request information is essentially the repeated invoking of the tasks, and the classifying invoking causes the waste of the computing resources.
Step 202, in response to that the current scene meets a preset trigger condition, acquiring a plurality of to-be-executed tasks to generate a task execution queue.
Specifically, the current scene may be different according to the task purpose and the cloud platform use, or a corresponding application scene may be set according to the actual requirements of the user, and when the scene is satisfied, the execution main body performs the task queue generating operation for acquiring the task to be executed.
The task queue may arrange a plurality of tasks to be executed according to a predetermined rule, such as an acquisition time rule, an urgency rule, a task category priority rule, and the like.
Illustratively, the generation time of the task one to be executed is 00:35, and the generation time of the task two to be executed is 00: 40, the generation time of the task three to be executed is 00:38, the time for obtaining the task operation to be executed this time is 01: 00, after the three to-be-executed tasks are obtained, sequentially arranging a plurality of to-be-executed tasks from far to near according to the time interval of the to-be-executed tasks, namely, sequentially arranging the to-be-executed tasks according to the time when the to-be-executed tasks are generated, and generating a task execution queue, wherein the sequence of the to-be-executed tasks in the queue is a first to-be-executed task, a third to-be-executed task and a second to-be-executed task.
In some optional implementations of the embodiments of the present application, the current scene at least includes: the current time interval is one of the time of last acquiring task request information, the number of tasks to be executed in the task execution queue, and the proportion or preset proportion of a class of tasks in the task execution queue.
Specifically, the application scene may be determined by referring to the time when the task request information is last obtained at the current time interval, the number of tasks to be executed in the task execution queue, and the proportion of one type of tasks in the task execution queue or the information of the preset proportion.
And step 203, sequentially sending the tasks to be executed in the task execution queue to the corresponding execution main bodies.
Specifically, after the task execution queue is generated, the task scheduling execution main body may sequentially extract the tasks to be executed from the task execution queue, and send the tasks to the corresponding execution main body according to the content of the tasks to be executed, thereby completing task scheduling.
Illustratively, an execution main body of task scheduling determines, according to content or a marking condition of a task, which task request information the task to be executed is generated from, determines a purpose of the task to be executed, then finds an execution main body executing the task to be executed through a service discovery function, obtains address information of the execution main body, and then performs communication connection with the execution main body based on a hypertext Transfer Protocol (HTTP) to perform sending work of the task to be executed.
The method for task scheduling provided by the embodiment of the application includes the steps of obtaining at least one type of task request information to be executed, generating corresponding tasks to be executed according to the task request information, responding to the situation that a current scene meets a preset trigger condition, obtaining a plurality of tasks to be executed to generate a task execution queue, and sequentially sending the tasks to be executed in the task execution queue to a corresponding execution main body. By the method for task scheduling, task request information of different categories can be unified to adapt to different operation requests, and operation resources are saved.
In some optional implementations of this embodiment, the method shown above further includes: and updating the execution time in the task to be executed to the next execution time in response to the fact that the task to be executed which is currently executed is generated according to the timing task request information.
Specifically, based on the above description, the timing-type request task usually has a continuous execution relationship during the execution process, for example, under the condition of a certain time interval, after the task to be executed corresponding to the timing-type request information is executed last time, the task to be executed corresponding to the timing-type request information is executed again after the certain time interval elapses, so that after the task to be executed corresponding to the timing-type request information is executed last time, the time for executing the next task to be executed can be determined based on the time point at which the last task to be executed is executed and the certain time interval, so as to update the execution time in the next task to be executed, thereby avoiding the repeated acquisition of the timing-type task request information and the waste of computing resources.
In some optional implementation manners of this embodiment, in response to that the current scenario satisfies a preset trigger condition, the obtaining a plurality of to-be-executed tasks to generate a task execution queue includes: and responding to the situation that the current scene meets the preset triggering condition, acquiring a plurality of tasks to be executed to generate a task execution queue, and extracting the tasks to be executed from a task list generated according to the tasks to be executed to generate the task execution queue.
Specifically, after the task to be executed is generated, the task scheduling execution main body can generate a corresponding task list according to the task to be executed, so that the task to be executed is summarized, the specific condition of the current task to be executed is known, the task to be executed is extracted from the task list to generate a task execution queue, and the overall process efficiency is improved.
In some optional implementation manners of this embodiment, sending the to-be-executed task to the corresponding execution main body according to the task execution queue further includes: and responding to the failure of sending the execution task to the corresponding execution main body, and sending a failure alarm.
Specifically, it may be determined whether the execution main body of the task schedule successfully sends the to-be-executed task to the corresponding execution main body, for example, when the execution main body fails to send the to-be-executed task to the corresponding execution main body, a failure alarm signal is sent, or a communication connection between the execution main body based on the task schedule and the corresponding execution main body is interacted, and after the sending is completed, the corresponding execution main body sends a response signal to feed back the sending condition to the execution main body of the task schedule, so as to determine whether the execution main body of the task schedule successfully sends the to-be-executed task to the corresponding execution main body.
And when the execution main body for task scheduling is judged not to successfully send the task to be executed to the corresponding execution main body, sending an alarm signal to prompt, so that the execution main body for task scheduling or a user can make a relevant strategy in time according to the result.
In some optional implementations of this embodiment, the method further includes: responding to the detected manual intervention request, and executing operation corresponding to the manual intervention request; wherein the manual intervention request comprises: and at least one of a request for adjusting an alarm receiver, a request for feeding back a task running record, a request for feeding back task information, a request for feeding back task statistical data and a request for adjusting a task execution sequence.
Specifically, when the presence of a manual intervention request signal is detected, the signal is responded to and the operation requested in the signal is resolved, for example, the operation requested in the signal may include at least one of the following requests: the method comprises the steps of adjusting an alarm receiver request to realize the feedback of task execution failure results to different supervisors, feeding back a task operation record request to realize the feedback of operation conditions, facilitating users to know operation processes, feeding back a task information request to realize the feedback of task request information, facilitating users to know the types and the quantities of task request information corresponding to tasks to be executed, feeding back a task statistical data request to facilitate users to acquire the quantity conditions of task execution, and adjusting task execution sequence requests to realize the adjustment and planning of the execution sequence of the tasks to be executed according to different requirements.
Based on this, the execution main body of task scheduling can analyze the result according to the request to realize corresponding operation, satisfies artifical corresponding demand to provide artificial interaction's mode, expand the function, can also feed back the condition of task scheduling, promote the suitability.
Further, to deepen understanding, the present application further provides an implementation scheme in another specific case in combination with a specific application scenario, as shown in fig. 3, in the practical application scenario, an execution agent a for executing the task scheduling method obtains an order-type task request B, an automatic renewal-type task request C, and a timing-type task request D from another agent a 1.
The executive agent A acquires the order task request B, the automatic renewal task request C and the timing task request D, respectively generates tasks to be executed E1, E2 and E3 in a standard format according to the content recorded in the order task request B, the automatic renewal task request C and the timing task request D, and sends the tasks to be executed E1, E2 and E3 in the standard format, E1, E2 and E3 and a task list G generated according to E1, E2 and E3 to the database F for storage.
Responding to the fact that the time interval of the last time of the current time to obtain the tasks to be executed is 5 seconds, obtaining the tasks to be executed E1, E2 and E3 from the database F according to the task list G, determining the time sequence of E1, E2 and E3 according to the time sequence of obtaining task request information B, C, D, determining the sequence of the tasks to be executed in the task queue, and generating a task execution queue H, wherein the sequence of the tasks in the task execution queue H is E1, E2 and E3.
The execution main body A is in communication connection with the execution main bodies L1, L2 and L3 which can be used for executing the tasks E1, E2 and E3 to be executed by the HTTP protocol after finding out the communication addresses of L1, L2 and L3.
According to the order in the task execution queue H, the tasks E1, E2, E3 are sent to the corresponding execution bodies L1, L2, L3, respectively.
And receiving feedback of the execution subjects L2 and L3 within the preset time, judging that the scheduling of the tasks L2 and L3 to be executed is completed, and failing to schedule the task E1 to be executed.
In response to determining that the scheduled task to be performed E1 failed, an alarm signal is issued to a pre-designated alarm recipient a.
The execution main body A responds to the manual intervention request sent by the first detection body, analyzes the manual intervention request, obtains an analysis result which is a request for changing the alarm receiving person B, and requests to feed back the task operation record and the information of the task E1 to be executed to the first.
And the execution main body responds to the request information in the manual intervention request, changes the alarm receiving manual B, and feeds back the task operation record and the information of the task E1 to be executed to the first.
According to the method for task scheduling shown in the specific application scenario, it can be clearly seen that an execution main body of the task scheduling method acquires three different types of task request information to be executed and generates corresponding tasks to be executed, when a current scenario meets a preset trigger condition, a plurality of tasks to be executed are acquired to generate a task execution queue, and the tasks to be executed in the task execution queue are sequentially sent to the corresponding execution main body. The task request information of different categories can be unified to adapt to different operation requests, and operation resources are saved.
With further reference to fig. 4, as an implementation of the methods shown in the above-mentioned figures, the present application provides an embodiment of an apparatus for task scheduling, where the embodiment of the apparatus corresponds to the embodiment of the method shown in fig. 2, and the apparatus may be specifically applied to various electronic devices.
As shown in fig. 4, the task scheduling apparatus 400 of the present embodiment may include: a request information obtaining unit 401, configured to obtain at least one type of task request information to be executed, and generate a task to be executed in a standard format according to the task request information; an execution queue generating unit 402, configured to, in response to that a current scene meets a preset trigger condition, obtain a plurality of to-be-executed task generation task execution queues; and a task sending unit 403 configured to send the tasks to be executed in the task execution queue to the corresponding execution main bodies in sequence.
In the present embodiment, the task scheduling apparatus 400 is used for: the specific processing of the request information obtaining unit 401, the execution queue generating unit 402, and the task sending unit 403 and the technical effects thereof can refer to the related descriptions of step 201 and step 203 in the corresponding embodiment of fig. 2, which are not described herein again.
In some optional implementations of this embodiment, the category of the request information in the request information obtaining unit 401 includes at least one of the following: order type task request information, automatic charging type task request information and timing type task request information.
In some optional implementations of this embodiment, the apparatus shown above further includes: and the task information updating unit is configured to respond to the fact that the currently executed task to be executed is generated according to the timing task request information, and update the execution time of the task to be executed to the next execution time.
In some optional implementations of this embodiment, the current scene in the execution queue generating unit 402 at least includes: the current time interval is one of the time for acquiring the task request information last time, the number of the tasks to be executed in the task execution queue, and the proportion of a class of tasks in the task execution queue or a preset proportion.
In some optional implementations of this embodiment, the execution queue generating unit 402 is further configured to: and responding to the situation that the current scene meets the preset triggering condition, acquiring a plurality of tasks to be executed to generate a task execution queue, and extracting the tasks to be executed from a task list generated according to the tasks to be executed to generate the task execution queue.
In some optional implementations of this embodiment, the apparatus shown above further includes: an alarm subunit configured to issue a failure alarm in response to determining that sending the execution task to the corresponding execution subject failed.
In some optional implementations of this embodiment, the apparatus shown above further includes: a manual intervention response unit 404 configured to, in response to detecting the manual intervention request, execute an operation corresponding to the manual intervention request; wherein the manual intervention request comprises: and at least one of a request for adjusting an alarm receiver, a request for feeding back a task running record, a request for feeding back task information, a request for feeding back task statistical data and a request for adjusting a task execution sequence.
The present embodiment exists as an apparatus embodiment corresponding to the above method embodiment, and the same contents refer to the description of the above method embodiment, which is not repeated herein. By the device for task scheduling, task request information of different categories can be unified to adapt to different operation requests, and operation resources are saved.
According to an embodiment of the present application, an electronic device and a readable storage medium are also provided.
Fig. 5 is a block diagram of an electronic device for a method for task scheduling according to an embodiment of the present application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the present application that are described and/or claimed herein.
As shown in fig. 5, the electronic apparatus includes: one or more processors 501, memory 502, and interfaces for connecting the various components, including high-speed interfaces and low-speed interfaces. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions for execution within the electronic device, including instructions stored in or on the memory to display graphical information of a GUI on an external input/output apparatus (such as a display device coupled to the interface). In other embodiments, multiple processors and/or multiple buses may be used, along with multiple memories and multiple memories, as desired. Also, multiple electronic devices may be connected, with each device providing portions of the necessary operations (e.g., as a server array, a group of blade servers, or a multi-processor system). In fig. 5, one processor 501 is taken as an example.
Memory 502 is a non-transitory computer readable storage medium as provided herein. The memory stores instructions executable by at least one processor to cause the at least one processor to perform the method for task scheduling provided by the present application. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to perform the methods for task scheduling provided herein.
The memory 502, which is a non-transitory computer-readable storage medium, may be used to store non-transitory software programs, non-transitory computer-executable programs, and modules, such as program instructions/modules corresponding to the method for task scheduling in the embodiment of the present application (for example, the request information acquiring unit 401, the execution queue generating unit 402, and the task transmitting unit 403 shown in fig. 4). The processor 501 executes various functional applications of the server and data processing by running non-transitory software programs, instructions, and modules stored in the memory 502, that is, implements the method for task scheduling in the above method embodiments.
The memory 502 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to use of the electronic device that pushes the information, and the like. Further, the memory 502 may include high speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, memory 502 may optionally include memory located remotely from processor 501, which may be connected to an information-pushing electronic device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The electronic device of the method for task scheduling may further include: an input device 503 and an output device 504. The processor 501, the memory 502, the input device 503 and the output device 504 may be connected by a bus or other means, and fig. 5 illustrates the connection by a bus as an example.
The input device 503 may receive input numeric or character information and generate key signal inputs related to user settings and function control of the electronic apparatus for task scheduling, such as an input device such as a touch screen, a keypad, a mouse, a track pad, a touch pad, a pointing stick, one or more mouse buttons, a track ball, a joystick, or the like. The output devices 504 may include a display device, auxiliary lighting devices (e.g., LEDs), and haptic feedback devices (e.g., vibrating motors), among others. The display device may include, but is not limited to, a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display, and a plasma display. In some implementations, the display device can be a touch screen.
Various implementations of the systems and techniques described here can be realized in digital electronic circuitry, integrated circuitry, application specific ASICs (application specific integrated circuits), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
These computer programs (also known as programs, software applications, or code) include machine instructions for a programmable processor, and may be implemented using high-level procedural and/or object-oriented programming languages, and/or assembly/machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, Programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present application may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present application can be achieved, and the present invention is not limited herein.
The above-described embodiments should not be construed as limiting the scope of the present application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (16)

1. A method for task scheduling, comprising:
acquiring at least one type of task request information to be executed, and generating a task to be executed in a standard format according to the task request information;
responding to the current scene meeting a preset trigger condition, and acquiring a plurality of to-be-executed tasks to generate a task execution queue;
and sequentially sending the tasks to be executed in the task execution queue to a corresponding execution main body.
2. The method of claim 1, wherein the category of task request information includes at least one of:
order type request task information, automatic renewal type task request information and timing type task request information.
3. The method of claim 2, further comprising:
and updating the execution time in the task to be executed to the next execution time in response to the fact that the task to be executed which is currently executed is generated according to the timing task request information.
4. The method of claim 1, wherein the current scene comprises at least:
the current time interval is one of the time for acquiring the task request information last time, the number of the tasks to be executed in the task execution queue, and the proportion of a class of tasks in the task execution queue or a preset proportion.
5. The method of claim 1, wherein the obtaining a plurality of to-be-executed task generation task execution queues in response to a current scenario satisfying a preset trigger condition comprises:
and responding to the situation that the current scene meets a preset trigger condition, acquiring a plurality of to-be-executed tasks to generate task execution queues, and extracting the to-be-executed tasks from a task list generated according to the to-be-executed tasks to generate the task execution queues.
6. The method of claim 1, wherein the sending the to-be-executed task to the corresponding execution subject in accordance with the task execution queue further comprises:
and sending a failure alarm in response to determining that the sending of the execution task to the corresponding execution main body fails.
7. The method of claims 1-6, further comprising:
responding to the detected manual intervention request, and executing operation corresponding to the manual intervention request; wherein the manual intervention request comprises: and at least one of a request for adjusting an alarm receiver, a request for feeding back a task running record, a request for feeding back task information, a request for feeding back task statistical data and a request for adjusting a task execution sequence.
8. An apparatus for task scheduling, comprising:
the system comprises a request information acquisition unit, a task execution unit and a task execution unit, wherein the request information acquisition unit is configured to acquire at least one type of task request information to be executed and generate tasks to be executed in a standard format according to the task request information;
the execution queue generating unit is configured to respond to the situation that a current scene meets a preset trigger condition, and acquire a plurality of to-be-executed task generation task execution queues;
and the task sending unit is configured to send the tasks to be executed in the task execution queue to the corresponding execution main bodies in sequence.
9. The apparatus according to claim 8, wherein the category of the request information in the request information obtaining unit includes at least one of:
order type task request information, automatic charging type task request information and timing type task request information.
10. The apparatus of claim 9, further comprising:
and the task information updating unit is configured to respond to the fact that the currently executed task to be executed is generated according to the timing task request information, and update the execution time in the task to be executed to the next execution time.
11. The apparatus of claim 8, wherein the current scene in the execution queue generating unit comprises at least:
the current time interval is one of the time for acquiring the task request information last time, the number of the tasks to be executed in the task execution queue, and the proportion of a class of tasks in the task execution queue or a preset proportion.
12. The apparatus of claim 8, wherein the execution queue generation unit is further configured to:
and responding to the situation that the current scene meets a preset trigger condition, acquiring a plurality of to-be-executed tasks to generate task execution queues, and extracting the to-be-executed tasks from a task list generated according to the to-be-executed tasks to generate the task execution queues.
13. The apparatus of claim 8, wherein the task transmission unit further comprises:
an alarm subunit configured to issue a failure alarm in response to determining that sending the execution task to the corresponding execution subject failed.
14. The apparatus of claims 8-13, further comprising:
the manual intervention response unit is configured to respond to the detection of the manual intervention request and execute the operation corresponding to the manual intervention request; wherein the manual intervention request comprises: and at least one of a request for adjusting an alarm receiver, a request for feeding back a task running record, a request for feeding back task information, a request for feeding back task statistical data and a request for adjusting a task execution sequence.
15. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-7.
16. A non-transitory computer readable storage medium storing computer instructions, comprising: the computer instructions are for causing the computer to perform the method of any one of claims 1-7.
CN202010697771.6A 2020-07-20 2020-07-20 Method for task scheduling, related device and computer program product Active CN111831420B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010697771.6A CN111831420B (en) 2020-07-20 2020-07-20 Method for task scheduling, related device and computer program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010697771.6A CN111831420B (en) 2020-07-20 2020-07-20 Method for task scheduling, related device and computer program product

Publications (2)

Publication Number Publication Date
CN111831420A true CN111831420A (en) 2020-10-27
CN111831420B CN111831420B (en) 2023-08-08

Family

ID=72924144

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010697771.6A Active CN111831420B (en) 2020-07-20 2020-07-20 Method for task scheduling, related device and computer program product

Country Status (1)

Country Link
CN (1) CN111831420B (en)

Cited By (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112367205A (en) * 2020-11-12 2021-02-12 深圳前海微众银行股份有限公司 Processing method and scheduling system for HTTP scheduling request
CN112486648A (en) * 2020-11-30 2021-03-12 北京百度网讯科技有限公司 Task scheduling method, device, system, electronic equipment and storage medium
CN112561326A (en) * 2020-12-15 2021-03-26 青岛海尔科技有限公司 Task execution method and device, storage medium and electronic device
CN112836987A (en) * 2021-03-01 2021-05-25 拉扎斯网络科技(上海)有限公司 Freight note scheduling method and device, computer storage medium and electronic equipment
CN112905314A (en) * 2021-01-27 2021-06-04 北京百度网讯科技有限公司 Asynchronous processing method and device, electronic equipment, storage medium and road side equipment
CN113342665A (en) * 2021-06-17 2021-09-03 北京百度网讯科技有限公司 Task allocation method and device, electronic equipment and computer readable medium
CN113407329A (en) * 2021-07-15 2021-09-17 北京百度网讯科技有限公司 Task execution method, device, equipment and storage medium
CN113806058A (en) * 2021-10-09 2021-12-17 京东科技控股股份有限公司 Task management method and device, storage medium and electronic equipment
CN113835859A (en) * 2021-09-24 2021-12-24 成都质数斯达克科技有限公司 Task scheduling method, device and equipment and readable storage medium
CN113867916A (en) * 2021-09-28 2021-12-31 北京百度网讯科技有限公司 Task processing method and device and electronic equipment
CN113986497A (en) * 2021-10-27 2022-01-28 北京百度网讯科技有限公司 Queue scheduling method, device and system based on multi-tenant technology
CN114185612A (en) * 2021-11-30 2022-03-15 北京百度网讯科技有限公司 Data updating method, device, equipment and storage medium
CN114757278A (en) * 2022-04-15 2022-07-15 北京科杰科技有限公司 Invalid task processing method and device, computer equipment and storage medium
CN115080205A (en) * 2022-05-27 2022-09-20 北京百度网讯科技有限公司 Task execution method and device, electronic equipment and readable storage medium
CN115665369A (en) * 2022-09-09 2023-01-31 北京百度网讯科技有限公司 Video processing method and device, electronic equipment and storage medium
CN115756798A (en) * 2022-11-25 2023-03-07 中电金信软件有限公司 Task scheduling method and device, electronic equipment and computer readable storage medium
CN115756800A (en) * 2022-11-28 2023-03-07 中电金信软件有限公司 Task scheduling method and task scheduling device

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106126354A (en) * 2016-06-21 2016-11-16 中国建设银行股份有限公司 A kind of asynchronous batch processing method and system
WO2018072687A1 (en) * 2016-10-19 2018-04-26 华为技术有限公司 Resource scheduling method and apparatus, and filtered scheduler
CN108958922A (en) * 2017-05-17 2018-12-07 北京京东尚科信息技术有限公司 Method and apparatus for executing task
CN109743390A (en) * 2019-01-04 2019-05-10 深圳壹账通智能科技有限公司 Method for scheduling task, device, computer equipment and storage medium
WO2019237593A1 (en) * 2018-06-13 2019-12-19 平安科技(深圳)有限公司 Task processing method and apparatus, and computer device and storage medium
EP3598302A1 (en) * 2018-07-20 2020-01-22 Fujitsu Limited Method and apparatus for managing effectiveness of information processing task
CN111158888A (en) * 2019-12-31 2020-05-15 北京明略软件系统有限公司 Multi-task scheduling method and device
CN111221638A (en) * 2020-01-03 2020-06-02 北京字节跳动网络技术有限公司 Scheduling processing method, device, equipment and medium for concurrent tasks

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106126354A (en) * 2016-06-21 2016-11-16 中国建设银行股份有限公司 A kind of asynchronous batch processing method and system
WO2018072687A1 (en) * 2016-10-19 2018-04-26 华为技术有限公司 Resource scheduling method and apparatus, and filtered scheduler
CN108958922A (en) * 2017-05-17 2018-12-07 北京京东尚科信息技术有限公司 Method and apparatus for executing task
WO2019237593A1 (en) * 2018-06-13 2019-12-19 平安科技(深圳)有限公司 Task processing method and apparatus, and computer device and storage medium
EP3598302A1 (en) * 2018-07-20 2020-01-22 Fujitsu Limited Method and apparatus for managing effectiveness of information processing task
CN109743390A (en) * 2019-01-04 2019-05-10 深圳壹账通智能科技有限公司 Method for scheduling task, device, computer equipment and storage medium
CN111158888A (en) * 2019-12-31 2020-05-15 北京明略软件系统有限公司 Multi-task scheduling method and device
CN111221638A (en) * 2020-01-03 2020-06-02 北京字节跳动网络技术有限公司 Scheduling processing method, device, equipment and medium for concurrent tasks

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
R. VENKATESAN等: "Scheduling framework for queuing and advanced reservation using TBRA in grid computing environments: Trust based resource agent", 2011 IEEE 3RD INTERNATIONAL CONFERENCE ON COMMUNICATION SOFTWARE AND NETWORKS *
李宇;: "用于云存储数据服务器的I/O请求调度算法", 西南交通大学学报, no. 04 *
王卓昊;杨冬菊;徐晨阳;: "基于ISE算法的分布式ETL任务调度策略研究", 计算机科学, no. 12 *
陈思颖;郭跃;胡欢波;: "移动云计算随机任务序列的执行调度", 电脑知识与技术, no. 21 *

Cited By (28)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112367205B (en) * 2020-11-12 2023-04-18 深圳前海微众银行股份有限公司 Processing method and scheduling system for HTTP scheduling request
CN112367205A (en) * 2020-11-12 2021-02-12 深圳前海微众银行股份有限公司 Processing method and scheduling system for HTTP scheduling request
CN112486648A (en) * 2020-11-30 2021-03-12 北京百度网讯科技有限公司 Task scheduling method, device, system, electronic equipment and storage medium
CN112561326A (en) * 2020-12-15 2021-03-26 青岛海尔科技有限公司 Task execution method and device, storage medium and electronic device
CN112905314A (en) * 2021-01-27 2021-06-04 北京百度网讯科技有限公司 Asynchronous processing method and device, electronic equipment, storage medium and road side equipment
CN112836987A (en) * 2021-03-01 2021-05-25 拉扎斯网络科技(上海)有限公司 Freight note scheduling method and device, computer storage medium and electronic equipment
CN112836987B (en) * 2021-03-01 2022-12-09 拉扎斯网络科技(上海)有限公司 Freight note scheduling method and device, computer storage medium and electronic equipment
CN113342665B (en) * 2021-06-17 2023-10-20 北京百度网讯科技有限公司 Task allocation method and device, electronic equipment and computer readable medium
CN113342665A (en) * 2021-06-17 2021-09-03 北京百度网讯科技有限公司 Task allocation method and device, electronic equipment and computer readable medium
CN113407329A (en) * 2021-07-15 2021-09-17 北京百度网讯科技有限公司 Task execution method, device, equipment and storage medium
CN113407329B (en) * 2021-07-15 2024-01-30 北京百度网讯科技有限公司 Task execution method, device, equipment and storage medium
CN113835859B (en) * 2021-09-24 2023-12-26 成都质数斯达克科技有限公司 Task scheduling method, device, equipment and readable storage medium
CN113835859A (en) * 2021-09-24 2021-12-24 成都质数斯达克科技有限公司 Task scheduling method, device and equipment and readable storage medium
CN113867916B (en) * 2021-09-28 2024-05-07 北京百度网讯科技有限公司 Task processing method and device and electronic equipment
CN113867916A (en) * 2021-09-28 2021-12-31 北京百度网讯科技有限公司 Task processing method and device and electronic equipment
CN113806058A (en) * 2021-10-09 2021-12-17 京东科技控股股份有限公司 Task management method and device, storage medium and electronic equipment
CN113986497A (en) * 2021-10-27 2022-01-28 北京百度网讯科技有限公司 Queue scheduling method, device and system based on multi-tenant technology
CN114185612B (en) * 2021-11-30 2023-08-08 北京百度网讯科技有限公司 Method, device, equipment and storage medium for updating data
CN114185612A (en) * 2021-11-30 2022-03-15 北京百度网讯科技有限公司 Data updating method, device, equipment and storage medium
CN114757278B (en) * 2022-04-15 2022-12-16 北京科杰科技有限公司 Invalid task processing method and device, computer equipment and storage medium
CN114757278A (en) * 2022-04-15 2022-07-15 北京科杰科技有限公司 Invalid task processing method and device, computer equipment and storage medium
CN115080205B (en) * 2022-05-27 2023-07-25 北京百度网讯科技有限公司 Task execution method, device, electronic equipment and readable storage medium
CN115080205A (en) * 2022-05-27 2022-09-20 北京百度网讯科技有限公司 Task execution method and device, electronic equipment and readable storage medium
CN115665369A (en) * 2022-09-09 2023-01-31 北京百度网讯科技有限公司 Video processing method and device, electronic equipment and storage medium
CN115665369B (en) * 2022-09-09 2023-11-03 北京百度网讯科技有限公司 Video processing method, device, electronic equipment and storage medium
CN115756798A (en) * 2022-11-25 2023-03-07 中电金信软件有限公司 Task scheduling method and device, electronic equipment and computer readable storage medium
CN115756800A (en) * 2022-11-28 2023-03-07 中电金信软件有限公司 Task scheduling method and task scheduling device
CN115756800B (en) * 2022-11-28 2024-04-09 中电金信软件有限公司 Task scheduling method and task scheduling device

Also Published As

Publication number Publication date
CN111831420B (en) 2023-08-08

Similar Documents

Publication Publication Date Title
CN111831420A (en) Method and device for task scheduling, electronic equipment and computer-readable storage medium
US11233873B2 (en) Dynamic weighting for cloud-based provisioning systems
US10142174B2 (en) Service deployment infrastructure request provisioning
US10503493B2 (en) Distributed versioning of applications using cloud-based systems
US9961017B2 (en) Demand policy-based resource management and allocation system
CN105357038B (en) Monitor the method and system of cluster virtual machine
US20190245757A1 (en) Enhancing resource allocation for application deployment
CN107729139B (en) Method and device for concurrently acquiring resources
CN102783129B (en) Systems and methods to process a request received at an application program interface
KR20170063757A (en) Managing change events for devices in an enterprise system
US10732964B2 (en) Systems and methods for updating multi-tier cloud-based application stacks
US11876817B2 (en) Modeling queue-based message-oriented middleware relationships in a security system
US8898641B2 (en) Managing transactions within a middleware container
CN113220420A (en) Service monitoring method, device, equipment, storage medium and computer program product
WO2016022925A2 (en) Policy based resource management and allocation system
CN111782341B (en) Method and device for managing clusters
EP3386151B1 (en) System of actions for iot devices
CN111770176A (en) Traffic scheduling method and device
US11243979B1 (en) Asynchronous propagation of database events
CN112102099A (en) Policy data processing method and device, electronic equipment and storage medium
US20210141668A1 (en) Background job scheduling restrictions
CN110750419A (en) Offline task processing method and device, electronic equipment and storage medium
CN110895777A (en) Method and device for processing overtime service list
US20220276901A1 (en) Batch processing management
CN111597026B (en) Method and device for acquiring information

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant