Task state generation system and method and electronic equipment
By establishing a task framework between the server and the client, updating and generating status description diagrams in real time, it solves the problem of users being unable to view task execution status in real time, and improves task status transparency and progress clarity.
Patent Information
- Application Number
- CN202410673936.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-28
- Publication Date
- 2024-08-30
AI Technical Summary
In the existing technology, users cannot view the specific status information of each step in the task execution process in real time, resulting in low transparency of the task status and unclear progress. The task status can only be judged through pop-up reminders on the server or background printing logs.
By establishing a task framework between the server and the client, including the step information and initial execution status information of the task, the target task framework is updated and sent to the client in real time, and the client generates a status description diagram to represent the execution of the task at each step. status, and adjust the chart based on updated execution status information.
It realizes real-time monitoring and feedback of task status, improves the transparency of task status, and allows users to understand the progress of task execution in real time, solving the problems of low transparency and unclear progress of task status.
Smart Images

Figure CN118567805A
Abstract
Description
Technical Field
[0001] The present application relates to the field of task monitoring, and in particular, to a system and method for generating a task status and an electronic device. Background Art
[0002] In the related art, when the cloud platform system or other web system executes related tasks, users can only judge the execution status of the task through the pop-up reminder or background print log sent by the server after the task is completed, which makes it impossible for users to view the specific status information of each step in the task execution process in real time, and there are problems such as low transparency of the task status and unclear progress on the server side. For example, when a user clicks a button, the server side will directly give the client a pop-up reminder of the success or failure of the operation, and there is a problem of long time consumption.
[0003] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0004] The embodiments of the present application provide a system, method and electronic device for generating a task status, so as to at least solve the technical problems that in the related technology, users can only judge the status of the task through pop-up reminders or log records, and cannot view the specific status of the task in each step in real time, resulting in low transparency of the task status and unclear progress.
[0005] According to one aspect of an embodiment of the present application, a task status generation system is provided, including: a server and a client; the server is used to receive a task request, and generate a task framework based on the task in the task request, wherein the task framework includes step information of the task and initial execution status information corresponding to each step in the step information, and the task framework is used to represent the association relationship between various data during the execution of the task; the task is processed according to the step information, and the initial execution status information of the task is updated to obtain a target task framework, wherein the target task framework includes at least the initial execution status information and the updated updated execution status information; the target task framework is sent to the client; the client is used to receive the target task framework sent by the server; a state description diagram of the task is generated according to the step information and the initial execution status information in the target task framework, wherein the state description diagram is used to represent the execution status of the task in each step; the state description diagram is adjusted according to the updated execution status information in the target task framework.
[0006] Optionally, before the server generates a task framework based on the task in the task request, it also includes: obtaining a preset task list, wherein the preset task list includes a preset task name and preset task steps corresponding to the preset task name; determining the similarity between the task name of the task and the preset task name corresponding to each task in the preset task list to obtain a similarity set; determining the task corresponding to the maximum value of the similarity in the similarity set as the target task; and determining the task step corresponding to the target task as the step information of the task.
[0007] Optionally, the server generates a task framework based on the task in the task request, including: obtaining the location information and step name of each step of the task in the step information; determining the task description information of the task based on the location information and the step name; determining the task node based on the task description information, and generating a task framework based on the task node.
[0008] Optionally, the task nodes are determined based on the task description information, and a task framework is generated based on the task nodes, including: parsing the task description information to obtain the connection relationship and connection direction between the task nodes; connecting the task nodes based on the connection relationship and connection direction to obtain the task framework.
[0009] Optionally, the server is also used to: encapsulate the target task framework through a visual database, wherein the visual database is used to standardize the data format in the target task framework; cache the encapsulated target task framework in the database middleware, and send the encapsulated target task framework to the client.
[0010] Optionally, the client is also used to: determine whether the task status of the task node in the target task framework is expired based on the updated execution status information in the target task framework, and obtain a judgment result; if the judgment result indicates that the task status of all task nodes in the target task framework is expired, delete the status description diagram; if the judgment result indicates that the task status of any task node in the target task framework has not expired, retain the status description diagram.
[0011] Optionally, the client and the server establish a communication connection through a websocket service.
[0012] According to another aspect of an embodiment of the present application, a method for generating a task status is also provided, including receiving a task request and generating a task framework based on the task in the task request, wherein the task framework includes step information and initial execution status information of the task, and the task framework is used to represent the association relationship between various data during the execution of the task; processing the task according to the step information, and updating the initial execution status information of the task to obtain a target task framework, wherein the target task framework includes at least the initial execution status information and the updated updated execution status information; sending the target task framework to a client, wherein the target task framework is used to generate a state description diagram, and the state description diagram is used to represent the execution status of the task at each step.
[0013] According to another aspect of an embodiment of the present application, another method for generating a task status is provided, including: receiving a target task framework sent by a server, wherein the target task framework includes step information of the task in the task request, initial execution status information and updated update execution status information; generating a status description diagram of the task based on the step information and initial execution status information in the target task framework; and adjusting the status description diagram based on the updated execution status information in the target task framework.
[0014] According to another aspect of an embodiment of the present application, there is also provided an electronic device, including: a memory and a processor; the memory is used to store program instructions; the processor is connected to the memory and is used to execute the method for generating the above-mentioned task state.
[0015] According to another aspect of the embodiments of the present application, a non-volatile storage medium is provided, which includes a stored computer program, wherein the device where the non-volatile storage medium is located executes the above-mentioned method for generating the task status by running the computer program.
[0016] According to another aspect of the embodiments of the present application, a computer program product is provided, including computer instructions, which implement the above-mentioned method for generating task status when executed by a processor.
[0017] In an embodiment of the present application, a task request is received by a server, and a task framework is generated according to the task in the task request, wherein the task framework includes step information of the task and initial execution status information corresponding to each step in the step information, and the task framework is used to represent the association relationship between various data during the execution of the task; the task is processed according to the step information, and the initial execution status information of the task is updated to obtain a target task framework, wherein the target task framework at least includes the initial execution status information and the updated updated execution status information; the target task framework is sent to the client; the client receives the target task framework sent by the server; a state description diagram of the task is generated according to the step information and the initial execution status information in the target task framework, wherein the state description diagram is used to represent the execution status of the task at each step; the state description diagram is adjusted according to the updated execution status information in the target task framework, so as to achieve the purpose of real-time monitoring of the task execution status, thereby realizing real-time feedback of the task status, and improving the technical effect of the transparency of the task status, thereby solving the technical problem that in the related technology, the user can only judge the status of the task through pop-up reminders or log records, and cannot view the specific status of the task at each step in real time, and there is low transparency of the task status and unclear progress. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0019] Figure 1 is a hardware structure diagram of a computer terminal for implementing a method for generating a task state according to an embodiment of the present application;
[0020] Figure 2 is a structural diagram of a task status generation system according to an embodiment of the present application;
[0021] Figure 3 is a task state description diagram according to an embodiment of the present application;
[0022] Figure 4 is a schematic diagram of a system for generating a task state according to an embodiment of the present application;
[0023] Figure 5 is a flowchart of a method for generating a task status according to an embodiment of the present application;
[0024] Figure 6 It is a flowchart of another method for generating task status according to an embodiment of the present application. DETAILED DESCRIPTION
[0025] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.
[0026] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0027] First, some nouns or terms that appear in the process of explaining the embodiments of the present application are subject to the following explanations:
[0028] Websocket service: A communication protocol that establishes a persistent connection between the server and the client, allowing full-duplex communication on a single TCP connection, providing an efficient two-way communication method, and enabling real-time data exchange.
[0029] Visual database: Present the data in the database in charts, graphs or other visual forms to intuitively understand the data, development trends and patterns, and make better decisions.
[0030] The information collected in the embodiments of the present application is information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of the relevant data comply with the relevant laws, regulations and standards of the relevant regions, take necessary confidentiality measures, do not violate public order and good morals, and provide corresponding operation entrances for users to choose to authorize or reject automated decision-making results; if the user chooses to reject, the expert decision-making process will be entered.
[0031] In order to solve the technical problems of low transparency and unclear progress of task status in the related art, the embodiment of the present application provides a method for generating task status, which can be run on Figure 1 In the computer terminal shown, the computer terminal is described below.
[0032] The task status generation method embodiment provided in the embodiment of the present application can be executed in a mobile terminal, a computer terminal or a similar computing device. Figure 1 FIG. 1 shows a hardware structure block diagram of a computer terminal for implementing a method for generating task status. Figure 1 As shown, the computer terminal 10 may include one or more (102a, 102b, ..., 102n are used to illustrate) processors (the processor may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA), a memory 104 for storing data, and a transmission module 106 for communication functions connected via a wired and / or wireless network. In addition, it may also include: a display, a keyboard, a cursor control device, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of the I / O interface), a network interface, and a BUS bus. Those skilled in the art can understand that Figure 1 The structure shown is only for illustration and does not limit the structure of the above electronic device. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations shown.
[0033] It should be noted that the one or more processors and / or other data processing circuits described above may generally be referred to herein as "data processing circuits". The data processing circuits may be embodied in whole or in part as software, hardware, firmware, or any other combination thereof. In addition, the data processing circuit may be a single independent processing module, or may be incorporated in whole or in part into any of the other components in the computer terminal 10. As described in the embodiments of the present application, the data processing circuit acts as a processor control (e.g., selection of a variable resistor terminal path connected to an interface).
[0034] The memory 104 can be used to store software programs and modules of application software, such as the program instructions / data storage device corresponding to the method for generating the task state in the embodiment of the present application. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory 104, that is, realizing the method for generating the task state described above. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the computer terminal 10 via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0035] The transmission module 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the computer terminal 10. In one example, the transmission module 106 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission module 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0036] The display may be, for example, a touch screen liquid crystal display (LCD) that enables a user to interact with a user interface of the computer terminal 10 .
[0037] It should be noted that, in some optional embodiments, the above Figure 1 The computer terminal shown may include hardware elements (including circuits), software elements (including computer code stored on a computer-readable medium), or a combination of hardware elements and software elements. It should be noted that Figure 1 This is merely one example of a particular embodiment and is intended to illustrate the types of components that may be present in the computer terminal described above.
[0038] In the above-mentioned operating environment, an embodiment of the present application provides an embodiment of a method for generating a task status. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0039] Figure 2 is a structural diagram of a task state generation system according to an embodiment of the present application, such as Figure 2 As shown, the task status generation system 20 includes a server 22 and a client 24, wherein:
[0040] The server 22 is used to receive a task request and generate a task framework according to the task in the task request, wherein the task framework includes the step information of the task and the initial execution status information corresponding to each step in the step information, and the task framework is used to represent the association relationship between various data during the execution of the task; process the task according to the step information, and update the initial execution status information of the task to obtain a target task framework, wherein the target task framework includes at least the initial execution status information and the updated updated execution status information; and send the target task framework to the client;
[0041] In the above process, the server performs tasks management, task execution, status update and information feedback operations, for example: by accepting the task request from the client and generating a task framework, the task framework includes the step information of the task and the initial execution status information corresponding to each step, thereby clarifying the basic structure and plan of the task, so that the server can process the task according to the step information, such as task migration, allocation, scheduling and other operations, to ensure that the task is carried out in the preset step sequence. At the same time, as the task is executed, the server will continue to update the execution status corresponding to each step in the task, and generate an updated task framework, that is, the above-mentioned target task framework, to ensure real-time update and feedback of the task status. Finally, the server will send the updated target task framework to the client, so that the client can generate a state description diagram of the task according to the data information in the target task framework and make corresponding state adjustments.
[0042] Optionally, before the server generates a task framework based on the task in the task request, it also includes: obtaining a preset task list, wherein the preset task list includes a preset task name and preset task steps corresponding to the preset task name; determining the similarity between the task name of the task and the preset task name corresponding to each task in the preset task list to obtain a similarity set; determining the task corresponding to the maximum value of the similarity in the similarity set as the target task; and determining the task step corresponding to the target task as the step information of the task.
[0043] In the embodiment of the present application, in order to provide accurate task execution guidance and task execution information, the step information in the task can be determined before generating the task framework, as follows:
[0044] 1. Get the preset list
[0045] First, a preset task list is obtained, which includes multiple preset task names and preset task steps corresponding to each preset task name. These preset tasks can be standard tasks pre-defined by the system, or they can be task lists dynamically generated based on historical task data or user needs.
[0046] 2. Calculate task name similarity
[0047] Determine the task name of the task to be executed in the received task request, and calculate the similarity between it and all the task names in the preset task list to obtain a similarity set. You can use a text similarity algorithm, such as edit distance, cosine similarity, etc., to compare the similarity between each task name.
[0048] 3. Determine the target tasks
[0049] Select the task that best matches the task to be performed from the preset task list, that is, select the task with the largest similarity value in the similarity set as the target task, which is the basic source for determining the subsequent step information.
[0050] 4. Determine the task step information
[0051] After determining the target task, obtain the preset step information corresponding to the target task from the preset task list and determine it as the step information of the task to be executed. The step information includes the various execution steps of the task and related information, such as execution order, required resources, etc., which provides the necessary basic information for the subsequent generation of the task framework.
[0052] Optionally, the server generates a task framework based on the task in the task request, including: obtaining the location information and step name of each step of the task in the step information; determining the task description information of the task based on the location information and the step name; determining the task node based on the task description information, and generating a task framework based on the task node.
[0053] Optionally, the task nodes are determined based on the task description information, and a task framework is generated based on the task nodes, including: parsing the task description information to obtain the connection relationship and connection direction between the task nodes; connecting the task nodes based on the connection relationship and connection direction to obtain the task framework.
[0054] In an embodiment of the present application, the server can generate a corresponding task framework according to the user's task request through methods such as field mapping and connection modeling, so as to understand the association relationship between various data during the execution of the task in real time.
[0055] The details are as follows:
[0056] 1. Field Mapping
[0057] The location information of each step and the step name of each step in the step information of the task are obtained, and the step information of the task (i.e., the location information and the step name of each step) is mapped to the overall description information of the task by means of field mapping, and the task description information may include the specific operation of the task, the required resources or the input and output information, etc. The field mapping process may involve a pre-mapped mapping rule, such as mapping the location information and the step name of the step to each field of the task description, etc.
[0058] 2. Connection Modeling
[0059] Parse the overall description information of the above tasks to generate multiple task nodes, which can include the operation information of each step. At the same time, determine the connection relationship and connection direction between each task node through the parsing result, where the connection relationship and connection direction are determined by the logical order and dependency of task execution. Finally, connect each task according to the connection relationship and connection direction of each task node to build a dedicated task framework, which includes the execution order, dependency and initial execution status of each step, so that subsequent tasks can be executed according to a certain framework plan.
[0060] Among them, during the generation process of the above-mentioned task framework, the border color of the task framework, the task node status and the connecting lines between the task contacts can be marked with custom colors. For example, if the task contact status is green, it can indicate that the task contact has been executed; if the task node status is red, it can indicate that the task node has not been executed yet.
[0061] Optionally, the server is also used to: encapsulate the target task framework through a visual database, wherein the visual database is used to standardize the data format in the target task framework; cache the encapsulated target task framework in the database middleware, and send the encapsulated target task framework to the client.
[0062] In an embodiment of the present application, the generated target task framework can be encapsulated by a visual database (such as echarts), and the target task framework can be encapsulated in a visual chart form, which helps users to more intuitively understand the structure and relationship of the task framework. Further, the server will cache the encapsulated target task framework in a database middleware or cache middleware (such as redis), and then send it to the client, so that the client can display and process the target task framework according to the agreed rules in the visual database, thereby presenting a clear task execution status.
[0063] The client 24 is used to receive the target task framework sent by the server; generate a state description diagram of the task based on the step information and initial execution status information in the target task framework, wherein the state description diagram is used to represent the execution status of the task at each step; and adjust the state description diagram based on the updated execution status information in the target task framework.
[0064] In the above process, the client performs task monitoring and status adjustment operations, for example, receiving the target task framework sent by the server, and generating a task status description diagram from the target task framework according to the agreed rules in the visual database, so as to intuitively display the execution status of the task at each step on the front-end page. At the same time, the client will also adjust the status description diagram to be generated, such as the color and text information in the frame, according to the updated execution status information corresponding to each step in the target task framework, to ensure that the status description diagram of the task is consistent with the latest task execution status.
[0065] Optionally, the client is also used to: determine whether the task status of the task node in the target task framework is expired based on the updated execution status information in the target task framework, and obtain a judgment result; if the judgment result indicates that the task status of all task nodes in the target task framework is expired, delete the status description diagram; if the judgment result indicates that the task status of any task node in the target task framework has not expired, retain the status description diagram.
[0066] In the embodiment of the present application, the client also involves real-time monitoring and processing of the task status in the target task framework, as follows:
[0067] 1. Determine whether the task status is expired
[0068] The updated execution status information in the target task framework is obtained, and whether the task node in the target task framework is expired is determined according to the updated execution status information. The expired task status indicates that the execution of the task node has been completed or is no longer required.
[0069] 2. Handle the situation where the task status expires
[0070] When the updated execution status information indicates that all task nodes in the target task framework have expired, the generated status description diagram is deleted from the page, indicating that the user's task request has been completed and the graphical information related to the task request is no longer needed.
[0071] In addition, you can also set a stay time (such as 30s) in the page, and delete the status description diagram in the page after the stay time is reached, so that users have enough time to browse and understand the status description diagram, thereby improving the user experience; and reducing frequent deletion requests to maintain the stability of the page.
[0072] 3. Handle the situation where the task status has not expired
[0073] When the updated execution status information indicates that the task status of any task node in the target task framework has not expired, the status description diagram in the page is retained, indicating that the task request has not been completed, and the client will continue to display the execution status of each step.
[0074] Taking the migration task as an example, the task description corresponding to the migration task is as follows: Figure 3 As shown, the task description information is "Physical machine H1 migrates from cluster C1 to cluster C2", the task step information is "status check", "resource placement", "migration", and the status information corresponding to each step is "status check 1-4", "resource placement 1-4", "migration 1-4". The step information of the migration task and the status information corresponding to each step are for each task node. When the status of all task nodes has been completed, the client will remove the task description diagram from the page; when the task status of any task node is not completed, the client will continue to display the updated task description diagram.
[0075] Optionally, in the above task status generation system, the client and the server establish a communication connection through a websocket service.
[0076] Figure 4 is a schematic diagram of a system for generating task status according to an embodiment of the present application. Figure 4 As shown, in an embodiment of the present application, taking the task request in the cloud platform environment as the prototype, a set of general back-end modeling (i.e., the execution process of the target task framework generated by the above-mentioned server) and front-end display (i.e., the execution process of the task description diagram generated by the above-mentioned client and the corresponding processing) framework is adopted, so that the client can monitor the execution status of each step of the task execution process of the server in real time. Among them, the two-way connection communication between the server and the client can be realized through the websocket service. The cloud platform system turns on the websocket service at startup to receive data information from the server; at the same time, the client will also establish a websocket listening service with the server after the user logs in to obtain data information from the server. For example, the server can synchronize the generated target task framework to the websocket service, and send the target task framework to the client through the websocket service, so that the system can respond to the user's task request in time and update the execution status of the task in real time. Among them, since the websocket service uses a persistent connection, the server and the client can directly transmit data, reducing the network load and the pressure on the server. Specifically:
[0077] The server accepts the user's task request, such as migrating virtual machines, background HA automatic recovery, virtual machine shutdown or other scheduled tasks, etc. The server generates a task framework based on the task in the task request, updates the execution status information of each step during the task execution, generates a target task framework, and synchronizes the execution status information to the websocket service. Subsequently, the client receives the target task framework sent by the websocket service, generates a task status description diagram, extracts the data information therein and determines whether the task status is expired, and deletes or retains the status description diagram according to the expired status.
[0078] It should be noted that after receiving the user's task request, the server will generate a uuid (global identifier) corresponding to the task request to ensure the uniqueness of the task request in the system. Specifically, on the server side, the server will store the task framework (step information and initial execution status information) corresponding to the task in the task request in the cache middleware (such as redis) according to the uuid. When executing each step, the server will update the execution status and other related information of the task corresponding to the uuid in the cache, and generate the target task framework. At the same time, any changes in the status of the task corresponding to the uuid will be synchronized to the websocket service to notify the client in time. On the client side, the client will find the target task framework corresponding to the task according to the uuid, and perform subsequent display and processing according to the updated status execution information.
[0079] Through the communication connection between the above-mentioned server and client, that is, receiving the task request through the server, and generating a task framework according to the task in the task request, wherein the task framework includes the step information of the task and the initial execution status information corresponding to each step in the step information, and the task framework is used to represent the association relationship between various data during the execution of the task; processing the task according to the step information, and updating the initial execution status information of the task, to obtain the target task framework, wherein the target task framework at least includes the initial execution status information and the updated updated execution status information; sending the target task framework to the client; the client receives the target task framework sent by the server; generating a state description diagram of the task according to the step information and the initial execution status information in the target task framework, wherein the state description diagram is used to represent the execution status of the task at each step; adjusting the state description diagram according to the updated execution status information in the target task framework, achieving the purpose of real-time monitoring of the task execution status, thereby realizing real-time feedback of the task status, and improving the technical effect of the transparency of the task status, thereby solving the technical problem that in the related technology, the user can only judge the status of the task through pop-up reminders or log records, and cannot view the specific status of the task at each step in real time, and there is low transparency of the task status and unclear progress.
[0080] Figure 5is a flowchart of a method for generating a task status according to an embodiment of the present application. The method can be applied to a server, such as Figure 5 As shown, the method includes:
[0081] Step S502, receiving a task request, and generating a task framework according to the task in the task request, wherein the task framework includes step information and initial execution state information of the task, and the task framework is used to represent the association relationship between various data during the execution of the task;
[0082] Step S504, processing the task according to the step information, and updating the initial execution state information of the task to obtain a target task framework, wherein the target task framework at least includes the initial execution state information and the updated execution state information after the update;
[0083] Step S506: sending the target task framework to the client, wherein the target task framework is used to generate a state description diagram, and the state description diagram is used to represent the execution state of the task in each step.
[0084] It should be noted that Figure 5 The execution process of the task generation method in Figure 2 The execution process of the server side in the generation system of the task state shown in the figure is the same, so the explanation about the server side in the generation system of the task state above also applies to Figure 5 The method of generating tasks in is not described here.
[0085] Figure 6 is a flowchart of a method for generating a task status according to an embodiment of the present application. The method can be applied to a client, such as Figure 6 As shown, the method includes:
[0086] Step S602, receiving a target task framework sent by the server, wherein the target task framework includes step information of the task in the task request, initial execution status information, and updated execution status information after update;
[0087] Step S604, generating a task state description diagram according to the step information and initial execution state information in the target task framework;
[0088] Step S606, adjusting the state description diagram according to the updated execution state information in the target task framework.
[0089] It should be noted that Figure 6 The execution process of the task generation method in Figure 2 The execution process of the client in the generation system of the task state shown is the same, so the explanation about the client in the generation system of the task state above also applies to Figure 6The method of generating tasks in is not described here.
[0090] An embodiment of the present application also provides an electronic device, including: a memory and a processor; the memory is used to store program instructions; the processor is connected to the memory and is used to execute the generation method of the above-mentioned task state.
[0091] An embodiment of the present application also provides a non-volatile storage medium, which includes a stored computer program, wherein the device where the non-volatile storage medium is located executes the above-mentioned method for generating the task status by running the computer program.
[0092] An embodiment of the present application also provides a computer program product, including computer instructions, which implement the above-mentioned method for generating task status when executed by a processor.
[0093] An embodiment of the present application also provides a computer program, which implements the above-mentioned method for generating task status when executed by a processor.
[0094] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0095] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.
[0096] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.
[0097] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0098] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0099] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, disk or optical disk and other media that can store program codes.
[0100] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. A task status generation system, characterized in that: include: Server and client; The server is used to receive a task request and generate a task framework according to the task in the task request, wherein the task framework includes step information of the task and initial execution status information corresponding to each step in the step information, and the task framework is used to represent the association relationship between various data during the execution of the task; process the task according to the step information, and update the initial execution status information of the task to obtain a target task framework, wherein the target task framework includes at least the initial execution status information and the updated update execution status information; send the target task framework to the client; The client is used to receive the target task framework sent by the server; generate a state description diagram of the task based on the step information in the target task framework and the initial execution status information, wherein the state description diagram is used to represent the execution status of the task in each step; and adjust the state description diagram based on the updated execution status information in the target task framework.
2. The system according to claim 1, characterized in that Before the server generates a task framework according to the task in the task request, the server also includes: Obtaining a preset task list, wherein the preset task list includes preset task names and preset task steps corresponding to the preset task names; Determine the similarity between the task name of the task and the preset task name corresponding to each task in the preset task list to obtain a similarity set; Determine the task corresponding to the maximum similarity value in the similarity set as the target task; The task step corresponding to the target task is determined as the step information of the task.
3. The system according to claim 1, characterized in that The server generates a task framework according to the task in the task request, including: Obtain the position information and step name of each step of the task in the step information; Determine task description information of the task according to the location information and the step name; The task node is determined according to the task description information, and the task framework is generated according to the task node.
4. The system according to claim 3, characterized in that Determining a task node according to the task description information, and generating the task framework according to the task node, including: Parsing the task description information to obtain the connection relationship and connection direction between the task nodes; The task nodes are connected according to the connection relationship and the connection direction to obtain the task framework.
5. The system according to claim 1, characterized in that The server is also used for: Encapsulating the target task framework through a visual database, wherein the visual database is used to standardize the data format in the target task framework; The encapsulated target task framework is cached in the database middleware, and the encapsulated target task framework is sent to the client.
6. The system according to claim 1, characterized in that The client is also used to: Determine whether the task status of the task node in the target task framework is expired according to the updated execution status information in the target task framework, and obtain a determination result; When the judgment result indicates that the task status of all task nodes in the target task framework has expired, deleting the state description diagram; When the judgment result indicates that the task status of any task node in the target task framework has not expired, the status description diagram is retained.
7. The system according to claim 1, characterized in that The client and the server establish a communication connection through the websocket service.
8. A method for generating a task status, characterized in that: include: Receive a task request, and generate a task framework according to the task in the task request, wherein the task framework includes step information and initial execution state information of the task, and the task framework is used to represent the association relationship between various data during the execution of the task; Processing the task according to the step information, and updating the initial execution state information of the task to obtain a target task framework, wherein the target task framework at least includes the initial execution state information and the updated execution state information after the update; The target task framework is sent to the client, wherein the target task framework is used to generate a state description diagram, and the state description diagram is used to represent the execution state of the task in each step.
9. A method for generating a task status, characterized in that: include: Receive a target task framework sent by the server, wherein the target task framework includes step information of the task in the task request, initial execution status information, and updated execution status information after update; Generate a state description diagram of the task according to the step information and initial execution state information in the target task framework; The state description graph is adjusted according to the updated execution state information in the target task framework.
10. An electronic device, characterized in that: include: Memory and processor; The memory is used to store program instructions; The processor is connected to the memory and is used to execute the method for generating the task status described in claim 8 or 9.
11. A non-volatile storage medium, characterized in that: The non-volatile storage medium includes a stored computer program, wherein the device where the non-volatile storage medium is located executes the method for generating the task status described in claim 8 or 9 by running the computer program.
12. A computer program product comprising computer instructions, characterized in that: When the computer instructions are executed by a processor, the method for generating a task state as described in claim 8 or 9 is implemented.
Citation Information
Cited By
Task execution management method and device, equipment and medium
CN119718588A
A task execution management method, device, apparatus, and medium
CN119718588B
Task model generation method and computer equipment
CN121029140A
Task model generation method and computer device
CN121029140B
