Task uploading method and system and electronic equipment

By generating verification information and confirming its consistency with the server's information, the client can re-upload the task when it fails, thus solving the problem of data loss or corruption caused by task upload failure and improving the success rate and integrity of task uploads.

CN121396397APending Publication Date: 2026-01-23ZUOYEBANG EDUCATION TECH (BEIJING) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202511365749.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-23
Publication Date
2026-01-23

AI Technical Summary

Technical Problem

In existing technologies, if a task upload fails, the task may be lost or corrupted, leading to a decrease in the success rate of the upload and an inability to guarantee the integrity of the task data.

Method used

By generating verification information and confirming its consistency with the server's information, the client can re-upload the task when it fails, ensuring the accuracy and completeness of the task upload.

Benefits of technology

This improved the success rate of task uploads and ensured the integrity of task data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121396397A_ABST
    Figure CN121396397A_ABST
Patent Text Reader

Abstract

The invention provides a task uploading method and system and electronic equipment, and the method comprises the steps: obtaining a to-be-uploaded task, and generating verification information of the to-be-uploaded task; the verification information and the to-be-uploaded task are uploaded to a server through a preset path, so that the server receives the to-be-uploaded task and the verification information, corresponding confirmation information is generated according to the received to-be-uploaded task, and feedback information is sent according to a consistency judgment result of the confirmation information and the verification information; the client receives feedback information sent by the server, and determines the task state of the task to be uploaded according to the feedback information; when it is determined that the task state is task failure, the to-be-uploaded task is uploaded again; the feedback information is sent according to the consistency judgment result of the confirmation information and the inspection information, the task state is determined according to the feedback information, and the to-be-uploaded task with the failed task is re-uploaded, so that the task uploading success rate is improved, and the task uploading completeness is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the field of information technology, and particularly relates to a task uploading method and system and an electronic device. BACKGROUND

[0002] With the development of computer network technology, task uploading is widely used in task management systems, network data transmission systems, storage systems and the like.

[0003] In the related art, for tasks that fail to be uploaded in task uploading, a retransmission strategy is used for processing. However, in actual application, there are still cases of task loss or damage, which causes the success rate of task uploading to decrease, and thus the integrity of task data cannot be guaranteed. SUMMARY

[0004] The present disclosure provides a task uploading method and system and an electronic device to solve the problems in the related art. The method uploads a to-be-uploaded task and corresponding verification information through a preset path, determines a target channel for task uploading, guarantees the order of the to-be-uploaded task transmitted from a client to a server, and generates confirmation information based on the to-be-uploaded task received by the server. The server sends feedback information after consistency judgment based on the verification information, and the client determines the task state according to the feedback information, guarantees the accuracy of the to-be-uploaded task in the uploading process, avoids the problem of invalid uploading caused by data deviation, and improves the success rate of task uploading by re-uploading the to-be-uploaded task when the task state is determined to be task failure, thereby ensuring the integrity of task uploading.

[0005] According to a first aspect of the present disclosure, a task uploading method is provided, which is used for a client and includes the following steps.

[0006] Obtaining a to-be-uploaded task and generating verification information of the to-be-uploaded task;

[0007] Uploading the verification information and the to-be-uploaded task to a server through a preset path, so that the server receives the to-be-uploaded task and the verification information, generates corresponding confirmation information according to the received to-be-uploaded task, and sends feedback information according to the consistency judgment result of the confirmation information and the verification information;

[0008] In response to receiving the feedback information sent by the server, determining the task state of the to-be-uploaded task according to the feedback information, wherein the feedback information is used to represent the consistency of the confirmation information and the verification information;

[0009] In a case where the task state is determined to be task failure, re-uploading the to-be-uploaded task.

[0010] In some embodiments of the present disclosure, the method further comprises:

[0011] determining whether the number of the to-be-uploaded tasks is greater than the number of preset paths; wherein one of the to-be-uploaded tasks corresponds to one of the preset paths;

[0012] in a case where it is determined that the number of the to-be-uploaded tasks is less than or equal to the number of the preset paths, assigning the to-be-uploaded tasks with the preset paths;

[0013] in a case where it is determined that the number of the to-be-uploaded tasks is greater than the number of the preset paths, generating a backup path by a path generation method, assigning the to-be-uploaded tasks with the preset paths according to the number of the preset paths, and assigning the to-be-uploaded tasks not assigned with the preset paths with the backup path.

[0014] In some embodiments of the present disclosure, in a case where it is determined that the task state is task failure, the re-uploading of the to-be-uploaded tasks comprises:

[0015] in a case where it is determined that the task state is task failure, obtaining a backup task and re-uploading the backup task; wherein the backup task is obtained by locally backing up the to-be-uploaded tasks.

[0016] In some embodiments of the present disclosure, the method further comprises:

[0017] in a case where it is determined that the task state is task success or task failure, recording uploading information of the to-be-uploaded tasks in the uploading process; wherein the uploading information at least comprises the task state, the number of retries, the confirmation information, and the verification information.

[0018] generating exception information when detecting that the to-be-uploaded tasks have an exception in the uploading process.

[0019] In some embodiments of the present disclosure, the task state comprises to-be-uploaded, uploading, task success, and task failure, and the task state of the to-be-uploaded tasks is marked, and the marking method comprises:

[0020] marking the task state of the to-be-uploaded tasks not started uploading as to-be-uploaded;

[0021] marking the task state of the to-be-uploaded tasks being uploaded as uploading;

[0022] marking the task state of the to-be-uploaded tasks uploaded successfully as task success;

[0023] marking the task state of the to-be-uploaded tasks uploaded unsuccessfully as task failure.

[0024] In some embodiments of the present disclosure, after the obtaining of the task to be uploaded, the method further comprises:

[0025] locally backing up the task to be uploaded to obtain a backup task, and adding the task to be uploaded to a task queue for management.

[0026] In some embodiments of the present disclosure, before the obtaining of the task to be uploaded, the method comprises:

[0027] determining whether a network state meets a preset condition for obtaining the task to be uploaded;

[0028] in a case where it is determined that the network state meets the preset condition, obtaining the task to be uploaded;

[0029] in a case where it is determined that the network state does not meet the preset condition, waiting until the network state meets the preset condition, and then obtaining the task to be uploaded.

[0030] According to a second aspect of the present disclosure, a task uploading method is provided, which is used for a server and comprises:

[0031] receiving a task to be uploaded and verification information, and generating confirmation information corresponding to the task to be uploaded; wherein the verification information is generated according to the task to be uploaded;

[0032] obtaining feedback information according to a consistency determination result of the confirmation information and the verification information;

[0033] sending the feedback information to a client, so that the client determines a task state of the task to be uploaded according to the feedback information.

[0034] According to a third aspect of the present disclosure, a task uploading device is provided, which is applied to a client and comprises:

[0035] a first obtaining unit configured to obtain a task to be uploaded;

[0036] a first generating unit configured to generate verification information of the task to be uploaded;

[0037] an uploading unit configured to upload the verification information and the task to be uploaded to a server through a preset path, so that the server receives the task to be uploaded and the verification information, generates corresponding confirmation information according to the received task to be uploaded, and sends feedback information according to a consistency determination result of the confirmation information and the verification information;

[0038] a receiving unit, configured to determine a task state of the to-be-uploaded task according to the feedback information in response to receiving the feedback information sent by the server, wherein the feedback information is used to represent consistency of the confirmation information and the check information;

[0039] a retransmission unit, configured to re-upload the to-be-uploaded task in a case where it is determined that the task state is task failure.

[0040] In some embodiments of the present disclosure, the apparatus further comprises:

[0041] a first determining unit, configured to determine whether the number of the to-be-uploaded tasks is greater than the number of preset paths, wherein one to-be-uploaded task corresponds to one preset path;

[0042] a first allocating unit, configured to allocate the preset paths to the to-be-uploaded tasks in a case where it is determined that the number of the to-be-uploaded tasks is less than or equal to the number of the preset paths;

[0043] a second allocating unit, configured to generate a backup path by a path generation apparatus, allocate the preset paths to the to-be-uploaded tasks according to the number of the preset paths, and allocate the backup path to the to-be-uploaded tasks that are not allocated the preset paths in a case where it is determined that the number of the to-be-uploaded tasks is greater than the number of the preset paths.

[0044] In some embodiments of the present disclosure, the retransmission unit comprises:

[0045] an obtaining module, configured to obtain a backup task in a case where it is determined that the task state is task failure;

[0046] a retransmission module, configured to re-upload the backup task, wherein the backup task is obtained by locally backing up the to-be-uploaded task.

[0047] In some embodiments of the present disclosure, the apparatus further comprises:

[0048] a recording unit, configured to record uploading information of the to-be-uploaded task in an uploading process in a case where it is determined that the task state is task success or task failure, wherein the uploading information at least comprises the task state, a retry number, the confirmation information, and the check information;

[0049] a second generation unit, configured to generate exception information when detecting that an exception occurs in the uploading process of the to-be-uploaded task.

[0050] In some embodiments of the present disclosure, the task state comprises to-be-uploaded, uploading, task success, and task failure, and the apparatus further comprises a marking unit, wherein the marking unit comprises:

[0051] a first marking module, configured to mark the task state of the to-be-uploaded task which has not started uploading as the to-be-uploaded;

[0052] a second marking module, configured to mark the task state of the to-be-uploaded task which is being uploaded as the uploading;

[0053] a third marking module, configured to mark the task state of the to-be-uploaded task which has been uploaded successfully as the task success;

[0054] a fourth marking module, configured to mark the task state of the to-be-uploaded task which has failed in uploading as the task failure.

[0055] In some embodiments of the present disclosure, the device further comprises:

[0056] a backup unit, configured to backup the to-be-uploaded task locally after the first obtaining unit obtains the to-be-uploaded task, to obtain the backup task;

[0057] a management unit, configured to add the to-be-uploaded task to a task queue for management.

[0058] In some embodiments of the present disclosure, the device further comprises:

[0059] a second judging unit, configured to judge whether a network state meets a preset condition for obtaining the to-be-uploaded task before the first obtaining unit obtains the to-be-uploaded task;

[0060] a second obtaining unit, configured to obtain the to-be-uploaded task if it is determined that the network state meets the preset condition;

[0061] a third obtaining unit, configured to obtain the to-be-uploaded task after waiting for the network state to meet the preset condition if it is determined that the network state does not meet the preset condition.

[0062] According to a fourth aspect of the present disclosure, a device for uploading a task is provided, which is applied to a server and comprises:

[0063] a third generating unit, configured to receive a to-be-uploaded task and verification information, and generate confirmation information corresponding to the to-be-uploaded task, wherein the verification information is generated according to the to-be-uploaded task;

[0064] a determining unit, configured to obtain feedback information according to a consistency judgment result of the confirmation information and the verification information;

[0065] The sending unit is configured to send the feedback information to the client, so that the client determines the task state of the to-be-uploaded task according to the feedback information.

[0066] According to a fifth aspect of the present disclosure, a system for task uploading is provided, and the system includes a client and a server, and includes:

[0067] The client is configured to obtain a to-be-uploaded task and generate verification information of the to-be-uploaded task.

[0068] The client is further configured to upload the verification information and the to-be-uploaded task to the server through a preset path.

[0069] The server is configured to receive the to-be-uploaded task and the verification information, generate corresponding confirmation information according to the received to-be-uploaded task, and send feedback information according to a consistency judgment result of the confirmation information and the verification information.

[0070] The client is further configured to receive the feedback information and determine a task state of the to-be-uploaded task according to the feedback information, wherein the feedback information is used to represent consistency of the confirmation information and the verification information.

[0071] The client is further configured to re-upload the to-be-uploaded task when it is determined that the task state is a task failure.

[0072] According to a sixth aspect of the present disclosure, an electronic device is provided, and includes:

[0073] at least one processor; and

[0074] a memory connected with the at least one processor in communication; wherein

[0075] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method of the first aspect or the second aspect.

[0076] According to a seventh aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the method of the first aspect or the second aspect.

[0077] According to an eighth aspect of the present disclosure, a computer program product is provided, including a computer program, which, when executed by a processor, implements the method of the first aspect or the second aspect.

[0078] In summary, the task uploading method and system and the electronic device provided by the present disclosure, the method comprises: obtaining a task to be uploaded, and generating verification information of the task to be uploaded; uploading the verification information and the task to be uploaded to a server through a preset path, so that the server receives the task to be uploaded and the verification information, generates corresponding confirmation information according to the received task to be uploaded, and sends feedback information according to the consistency judgment result of the confirmation information and the verification information; the client receives the feedback information sent by the server, determines the task state of the task to be uploaded according to the feedback information; in the case of determining that the task state is task failure, re-uploading the task to be uploaded; sending feedback information through the consistency judgment result of the confirmation information and the verification information, determining the task state according to the feedback information, and re-uploading the task to be uploaded which fails, which improves the success rate of task uploading, thereby ensuring the integrity of task uploading.

[0079] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present application, nor is it used to limit the scope of the present application. Other features of the present application will become apparent from the following description. BRIEF DESCRIPTION OF DRAWINGS

[0080] The accompanying drawings are used to better understand the present scheme and do not limit the present disclosure. Among them:

[0081] Figure 1 A flowchart of a task uploading method provided by an embodiment of the present disclosure;

[0082] Figure 2 A flowchart of another task uploading method provided by an embodiment of the present disclosure;

[0083] Figure 3 A flowchart of another task uploading method provided by an embodiment of the present disclosure;

[0084] Figure 4 A flowchart of another task uploading method provided by an embodiment of the present disclosure;

[0085] Figure 5 A flowchart of another task uploading method provided by an embodiment of the present disclosure;

[0086] Figure 6 A flowchart of another task uploading method provided by an embodiment of the present disclosure;

[0087] Figure 7 A flowchart of another task uploading method provided by an embodiment of the present disclosure;

[0088] Figure 8 A structure diagram of a task uploading device provided by an embodiment of the present disclosure;

[0089] Figure 9 Another structural schematic diagram of a device for task uploading provided by an embodiment of the present disclosure is provided.

[0090] Figure 10 Another structural schematic diagram of a device for task uploading provided by an embodiment of the present disclosure is provided.

[0091] Figure 11 Another structural schematic diagram of a device for task uploading provided by an embodiment of the present disclosure is provided.

[0092] Figure 12 A schematic block diagram of an example electronic device provided by an embodiment of the present disclosure is provided. DETAILED DESCRIPTION

[0093] Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, which include various details of the embodiments of the present disclosure to assist in understanding, which should be considered in a descriptive sense only. Thus, it will be apparent to one of ordinary skill in the art that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Also, for the sake of brevity and clarity, descriptions of well-known functions and constructions are omitted from the following description.

[0094] With the development of computer network technology, task uploading is widely used in task management systems, network data transmission systems, storage systems and other scenarios.

[0095] In related technologies, for tasks that fail to be uploaded in task uploading, a retransmission strategy is used for processing. However, in actual applications, there are still cases of task loss or damage, which causes the success rate of task uploading to decrease, thereby failing to guarantee the integrity of task data.

[0096] Therefore, in order to solve the problems in related technologies, the present disclosure provides a method for task uploading, which includes: obtaining a task to be uploaded, and generating verification information of the task to be uploaded; uploading the verification information and the task to be uploaded to a server through a preset path, so that the server receives the task to be uploaded and the verification information, generates corresponding confirmation information according to the received task to be uploaded, and sends feedback information according to the consistency judgment result of the confirmation information and the verification information; the client receives the feedback information sent by the server, determines the task state of the task to be uploaded according to the feedback information; in the case of determining that the task state is task failure, the task to be uploaded is re-uploaded; the feedback information is sent according to the consistency judgment result of the confirmation information and the verification information, the task state is determined according to the feedback information, and the task to be uploaded that fails is re-uploaded, which improves the success rate of task uploading, thereby guaranteeing the integrity of task uploading.

[0097] The embodiments of the present disclosure are not exhaustive, but only illustrate some embodiments, and are not specific limitations on the protection scope of the present disclosure. In the case of no contradiction, each step in an embodiment can be implemented as an independent embodiment, and the steps can be combined arbitrarily, for example, the scheme after removing part of the steps in an embodiment can also be implemented as an independent embodiment, and the order of the steps in an embodiment can be exchanged arbitrarily, in addition, the optional implementation manners in an embodiment can be combined arbitrarily; in addition, the embodiments can be combined arbitrarily, for example, part or all steps of different embodiments can be combined arbitrarily, an embodiment can be combined with optional implementation manners of other embodiments.

[0098] In each embodiment of the present disclosure, the terms and / or descriptions between the embodiments are consistent if there is no special description and logical conflict, and can be referred to each other, and the technical features in different embodiments can be combined to form new embodiments according to their inherent logical relationship.

[0099] The terms used in the embodiments of the present disclosure are only for the purpose of describing the specific embodiments, and not as a limitation on the present disclosure.

[0100] In the embodiments of the present disclosure, unless otherwise specified, the elements expressed in singular form, such as "one", "a", "the", "above", "said", "preceding", "this" and the like, can represent "one and only one", also can represent "one or more", "at least one" and the like. For example, in the case of using articles such as "a", "an", "the" and the like in English, the noun after the article can be understood as singular expression, also can be understood as plural expression.

[0101] In some embodiments, the terms "in response to", "in response to determining", "in the case of", "when", "when", "if", "if" and the like can be replaced with each other.

[0102] In some embodiments, the terms "greater than", "greater than or equal to", "not less than", "more than", "more than or equal to", "not less than", "higher than", "higher than or equal to", "not lower than", "above" and the like can be replaced with each other, and the terms "less than", "less than or equal to", "not greater than", "less than", "less than or equal to", "not more than", "lower than", "lower than or equal to", "not higher than", "below" and the like can be replaced with each other.

[0103] The prefix of "first", "second", and the like in the embodiments of the present disclosure are merely used to distinguish different description objects, and do not constitute limitation on the position, order, priority, quantity, or content of the description objects. The description of the description objects should refer to the description in the context of the claims or embodiments, and should not constitute redundant limitation because of the use of the prefix.

[0104] In the embodiments of the present disclosure, "a plurality of" refers to two or more.

[0105] In the embodiments of the present disclosure, the terms of "import", "input", "read in", and the like can be replaced with each other.

[0106] In some embodiments, the apparatus and the like can be interpreted as entities, and can also be interpreted as virtual, and the name thereof is not limited to the name recorded in the embodiments. The terms of "apparatus", "equipment", "device", "circuit", "network element", "node", "function", "unit", "section", "system", "network", "chip", "chip system", "entity", "subject", and the like can be replaced with each other.

[0107] In some embodiments, the terms of "terminal", "terminal device", "user equipment", "user terminal", "mobile station", "mobile terminal", "mobile unit", "subscriber unit", "wireless unit", "remote unit", "mobile device", "wireless device", "wireless communication device", "remote device", "mobile subscriber station", "access terminal", "mobile terminal", "wireless terminal", "remote terminal", "handset", "user agent", "mobile client", "client", and the like can be replaced with each other.

[0108] The following description, with reference to the accompanying drawings, describes a method, system, and electronic device for uploading tasks according to embodiments of the present disclosure.

[0109] Figure 1 This is a flowchart illustrating a method for uploading tasks provided in an embodiment of this disclosure.

[0110] like Figure 1 As shown, this method is applied to the client, and the method for uploading the task includes steps 101-104.

[0111] Step 101: Obtain the task to be uploaded and generate the verification information of the task to be uploaded.

[0112] In this embodiment, the task to be uploaded is business data that the client needs to transmit to the server. Corresponding verification information is generated for the business data. This verification information is used to verify the integrity of the task to be uploaded. Taking Message-Digest Algorithm 5 (MD5) as an example, the client calls the MD5 calculation interface to perform traversal operations on the binary data of the task to be uploaded, generating a 32-bit hexadecimal string. This string is the verification information corresponding to the task to be uploaded. Multiple calculations of the same task to be uploaded will generate consistent verification information. If the data of the task to be uploaded is modified or corrupted, the generated verification information will be completely different, thus clarifying the source of the task to be uploaded and ensuring that the task to be uploaded is indeed the business data that the client needs to transmit. Simultaneously, the generated verification information can serve as a benchmark for verifying the integrity of the task to be uploaded, providing data support for determining whether the task upload is accurate. It should be noted that the above examples are merely illustrative and do not limit the specific content.

[0113] Step 102: Upload the verification information and the task to be uploaded to the server through a preset path, so that the server can receive the task to be uploaded and the verification information, generate corresponding confirmation information based on the received task to be uploaded, and send feedback information based on the consistency judgment result between the confirmation information and the verification information.

[0114] The client-generated check information and the to-be-uploaded task are packaged into a data packet for transmission, and the data packet is sent to the server according to a preset path. After receiving the data packet, the server first parses and separates the to-be-uploaded task and the check information, and then calculates the separated to-be-uploaded task using the same hash algorithm (such as the MD5 algorithm) to generate server corresponding confirmation information (hash characters). The server-generated confirmation information is compared with the client-generated check information. If the hash characters of the two are completely consistent, feedback information representing consistency (such as status code "00", text information "check consistent", etc.) is generated. If there is a difference between the hash characters, feedback information representing inconsistency (such as status code "01", text information "check inconsistent") is generated, and the generated feedback information is sent to the client through the preset path.

[0115] The preset path provides a fixed channel for data transmission between the client and the server, avoiding data loss or transmission errors caused by path confusion during transmission. The server generates confirmation information based on the same hash algorithm and compares it with the check information, which can determine whether the to-be-uploaded task remains complete during transmission.

[0116] Step 103, in response to receiving the feedback information sent by the server, determining the task status of the to-be-uploaded task according to the feedback information; wherein the feedback information is used to represent the consistency of the confirmation information and the check information.

[0117] The client receives the feedback information sent by the server, parses the feedback information after receiving it, and determines the task status of the to-be-uploaded task according to the consistency result of the confirmation information and the check information represented by the feedback information: if the feedback information is information representing consistency (such as status code "00"), it is determined that the task status of the to-be-uploaded task is task success, indicating that the to-be-uploaded task has been completely transmitted to the server; if the feedback information is information representing inconsistency (such as status code "01"), it is determined that the task status of the to-be-uploaded task is task failure, indicating that the to-be-uploaded task may have data damage or loss during transmission and has not arrived at the server completely.

[0118] The client can accurately determine the upload result of the to-be-uploaded task based on the explicit information feedback by the server, avoiding misjudgment of the task status due to lack of judgment basis, and ensuring clear understanding of the task upload situation.

[0119] Step 104, in the case where the task status is determined to be task failure, re-uploading the to-be-uploaded task.

[0120] The client determines that the task state of the to-be-uploaded task is task failure, and automatically triggers a reupload instruction. After the instruction is triggered, the client uploads the to-be-uploaded task again according to the preset path, and simultaneously re-executes the generation process of the verification information, and transmits the re-generated verification information and the to-be-uploaded task to the server. The server re-executes the generation, consistency judgment and feedback information sending process of the confirmation information, and the client re-determines the task state based on the new feedback information.

[0121] The retransmission mechanism is provided for the task upload failure scenario, the to-be-uploaded task can be transmitted to the server again through the reupload operation, the task upload failure caused by single transmission exception is reduced, and the success rate of uploading the to-be-uploaded task is improved.

[0122] In summary, the method for uploading a task provided by the present disclosure comprises: obtaining a to-be-uploaded task and generating verification information of the to-be-uploaded task; uploading the verification information and the to-be-uploaded task to a server through a preset path, so that the server receives the to-be-uploaded task and the verification information, generates corresponding confirmation information according to the received to-be-uploaded task, and sends feedback information according to the consistency judgment result of the confirmation information and the verification information; the client receives the feedback information sent by the server, determines the task state of the to-be-uploaded task according to the feedback information; in the case of determining that the task state is task failure, reuploading the to-be-uploaded task; sending feedback information through the consistency judgment result of the confirmation information and the verification information, determining the task state according to the feedback information, and reuploading the to-be-uploaded task in task failure, which improves the success rate of task uploading, thereby ensuring the integrity of task uploading.

[0123] Figure 2 Further, a flowchart of a method for uploading a task provided by an embodiment of the present disclosure is shown. Based on the embodiment shown in Figure 1 , the embodiment can include the following steps: Figure 2

[0124] Step 201, determining whether the number of to-be-uploaded tasks is greater than the number of preset paths; wherein one to-be-uploaded task corresponds to one preset path.

[0125] ​The number of to-be-uploaded tasks is obtained by the client counting the current to-be-processed uploading tasks, for example, the task management module of the client traverses the local to-be-uploaded task list, counts the total number of tasks in the list, if the user selects four corrected homework pictures as to-be-uploaded tasks at one time through the client, the number of to-be-uploaded tasks is four; the preset path is a fixed uploading path pre-configured by the server and delivered to the client, each preset path corresponds to an independent cloud storage address, which is used to avoid data coverage caused by multiple to-be-uploaded tasks sharing the same address, the number of preset paths is the total number of fixed paths currently obtained by the client, for example, the server pre-allocates three preset paths for the client, so the number of preset paths is three; the client performs a judgment operation by comparing the number of to-be-uploaded tasks with the number of preset paths, if the number of to-be-uploaded tasks is greater than the number of preset paths, it is determined that the number of to-be-uploaded tasks is greater than the number of preset paths, if the number of to-be-uploaded tasks is less than or equal to the number of preset paths, it is determined that the number of to-be-uploaded tasks is less than or equal to the number of preset paths.

[0126] Step 202, in the case where it is determined that the number of to-be-uploaded tasks is less than or equal to the number of preset paths, the to-be-uploaded tasks are allocated the preset paths.

[0127] After the client determines that the number of to-be-uploaded tasks is less than or equal to the number of preset paths, the path allocation logic is started, and the allocation method includes but is not limited to allocation according to the creation time of the to-be-uploaded tasks or allocation according to the serial number of the to-be-uploaded tasks: for example, if the number of to-be-uploaded tasks is two and the number of preset paths is three, the client first sorts the two to-be-uploaded tasks according to the creation time from early to late, obtaining task A (creation time 10:00) and task B (creation time 10:05), then sorts the preset paths according to the acquisition order, obtaining path 1, path 2 and path 3, then allocates task A to path 1 and task B to path 2, and the remaining path 3 is reserved for subsequent use when there is a new to-be-uploaded task; if the number of to-be-uploaded tasks is two and the number of preset paths is two, the two to-be-uploaded tasks are sorted according to the creation time from early to late, obtaining task C (creation time 10:00) and task D (creation time 10:05), then the preset paths are sorted according to the acquisition order, obtaining path 4 and path 5, then task C is allocated to path 4 and task D is allocated to path 5; after the allocation is completed, the client records the correspondence between each to-be-uploaded task and the allocated preset path. It should be noted that the above examples are only illustrative and do not limit the specific content.

[0128] In step 203, in a case where it is determined that the number of the to-be-uploaded tasks is greater than the number of the preset paths, a backup path is generated by a path generation method, the preset paths are allocated to the to-be-uploaded tasks according to the number of the preset paths, and the backup path is allocated to the to-be-uploaded tasks that are not allocated to the preset paths.

[0129] After the client determines that the number of to-be-uploaded tasks is greater than the number of preset paths, the backup path generation operation is first performed, for example, a rule of "preset path base prefix / to-be-uploaded task ID_timestamp" is generated, if the preset path base prefix is "http: / / server-domain / upload / backup", the to-be-uploaded task ID is "task_005", and the timestamp is "1695201600000", the generated backup path is "http: / / server-domain / upload / backup / task_005_1695201600000". The number of generated backup paths is consistent with the part of the number of to-be-uploaded tasks that exceeds the number of preset paths, for example, the number of to-be-uploaded tasks is 5, the number of preset paths is 3, and the excess part is 2, then 2 backup paths are generated, and the allocation operation is performed: the first 3 to-be-uploaded tasks are allocated to the preset paths according to the number of preset paths, and the remaining 2 to-be-uploaded tasks that do not obtain the preset paths are allocated to the generated 2 backup paths. When allocating, the correspondence between "to-be-uploaded task ID-backup path" is recorded to ensure that each to-be-uploaded task corresponds to a unique upload path. It should be noted that the above examples are only illustrative and do not limit the specific content.

[0130] The number is first determined to determine whether the preset path meets the current to-be-uploaded task requirement, to avoid path shortage or waste caused by blind allocation; the preset path is directly allocated when the preset path is sufficient, to ensure the path use efficiency; the backup path is generated to supplement when the preset path is insufficient, to ensure that each to-be-uploaded task can obtain a unique upload path, to avoid uploading blockage caused by path loss, and to prevent data overlay caused by uploading of different tasks to the same address by the rule of "one task corresponding to one path", to ensure the orderliness and integrity of task uploading.

[0131] In order to improve the success rate of uploading of the to-be-uploaded task, in some embodiments, the method is further used for obtaining a backup task and re-uploading the backup task in a case where it is determined that the task state is the task failure; wherein the backup task is obtained by locally backing up the to-be-uploaded task.

[0132] The generation timing of the backup task is after the client obtains the to-be-uploaded task and before the first upload operation is performed. After obtaining the to-be-uploaded task (such as a user-selected corrected homework picture), the client starts a local backup process: a copy of the to-be-uploaded task is stored in a preset backup directory of the client, a mapping relationship between the to-be-uploaded task ID and the backup task storage path is established, and is recorded in a local configuration file or a database, so that each to-be-uploaded task corresponds to a unique backup task, and the data content of the backup task is completely consistent with that of the to-be-uploaded task. When the client determines that the task state of the to-be-uploaded task is task failure, the client triggers a backup task acquisition process: according to the recorded mapping relationship between the to-be-uploaded task ID and the backup task storage path, the backup task storage path corresponding to the current failed task is found, then a local file reading interface is called to read the complete data of the backup task from the path, and the acquisition of the backup task is completed. After the backup task is acquired, the client uploads the acquired backup task and the corresponding verification information to the server according to the same process as the first upload (through a preset path or an allocated backup path), and performs a re-upload operation. If the task state is still failure after re-uploading, the client can repeat the process of "acquiring a backup task-re-uploading" until the task is successfully uploaded or the configured preset retry number is reached.

[0133] Figure 3 Further, a flowchart of a task uploading method provided by the embodiment of the present disclosure is shown, Figure 3 The method can include the following steps:

[0134] In step 301, the uploading information of the to-be-uploaded task in the uploading process is recorded in a case where the task state is task success or the task failure; wherein the uploading information at least includes the task state, the retry number, the confirmation information, and the verification information.

[0135] The client determines that the task state of the to-be-uploaded task is task success or task failure (that is, receives feedback information sent by the server to indicate that the confirmation information and the verification information are consistent or the confirmation information and the verification information are inconsistent), records the uploading information of the to-be-uploaded task in the uploading process, and the uploading information includes but is not limited to the task state, the retry number, the confirmation information, and the verification information. At the same time, the backup data is cleaned up after determining that the task state is task success.

[0136] In step 302, when it is detected that the to-be-uploaded task appears an exception in the uploading process, an exception information is generated.

[0137] If an exception occurs during the upload process of a task to be uploaded, such as network interruption, transmission timeout, server return of an exception status code, or failure to read local task data, the client will generate exception information, including the time of the exception and the ID of the task to be uploaded. It should be noted that the above examples are for illustrative purposes only and do not limit the specific content.

[0138] Complete recording of successful upload information enables traceability of the upload process. When it is necessary to verify the upload details (such as whether retry was performed or whether the data is consistent), the corresponding information can be quickly retrieved by the task ID without having to interact with the server again. Real-time detection and recording of upload anomalies can clearly identify the time, type, and specific scenario of the anomaly, providing a basis for troubleshooting the cause of the anomaly (such as distinguishing between network and server issues) and reducing the time required to locate the problem.

[0139] Figure 4 A flowchart illustrating a task uploading method provided in an embodiment of this disclosure is further shown. Based on Figure 1 The embodiment shown, Figure 4 This may include the following steps:

[0140] Step 401: Mark the task status of the task to be uploaded that has not yet started uploading as "to be uploaded".

[0141] In this embodiment of the disclosure, "not started uploading" means that the task to be uploaded has been acquired by the client (e.g., local reading has been completed, user confirmation of selection, etc.), but no operation to transmit data to the server has been initiated. The determination is based on the fact that the task has not entered the execution process of the upload instruction and has not generated any transmission interaction with the server. After acquiring the task to be uploaded, the client marks the task status of the task to be uploaded as pending upload.

[0142] Step 402: Mark the task status of the task to be uploaded as "uploading".

[0143] "Uploading" means that the client has triggered an upload command, and the data of the task to be uploaded is in the process of being transmitted to the server. The criteria for determination are: the upload interface call is successful, and the data transmission progress is between 0% and 100% (not all transmission is completed). The task status of the task to be uploaded is marked as "uploading".

[0144] Step 403: Mark the task status of the successfully uploaded task as "task successful".

[0145] The uploading success means that the data of the to-be-uploaded task has been completely transmitted to the server, and the client receives the feedback information sent by the server, and the feedback information is consistent with the check information. The determination basis is that the transmission progress reaches 100% and the feedback information represents consistency. The task state of the to-be-uploaded task is marked as task success.

[0146] Step 404, marking the task state of the to-be-uploaded task as task failure.

[0147] The uploading failure means that the data of the to-be-uploaded task is not completely transmitted (for example, the transmission is terminated due to network interruption), or the client receives the feedback information sent by the server after the transmission is completed, and the feedback information is inconsistent with the check information. The determination basis is that the transmission progress does not reach 100% and an exception is detected, or the feedback information does not represent consistency. The task state of the to-be-uploaded task is marked as task failure.

[0148] Through the above method, the client sets a clear and unique task state marking rule for the to-be-uploaded task at different stages (to-be-uploaded, uploading, task success, and task failure). Each task state is associated with the to-be-uploaded task through the to-be-uploaded task ID, and accurate tracking of the to-be-uploaded task is realized.

[0149] In order to deal with the data loss of the to-be-uploaded task before uploading due to local storage exception, in some embodiments, the to-be-uploaded task is also locally backed up to obtain the backup task, and the to-be-uploaded task is added to the task queue for management.

[0150] First, the local backup is performed. The client copies the complete data of the to-be-uploaded task obtained by the client to a local preset backup storage area, and at the same time, a mapping relationship between the unique identifier of the to-be-uploaded task and the storage address of the backup task is established and saved locally. It is ensured that each to-be-uploaded task corresponds to a unique backup task, and the data content of the backup task is completely consistent with that of the to-be-uploaded task, without data loss or tampering. After completing the local backup, the client performs a task queue adding operation, and the basic information (such as the task unique identifier, the task state, etc.) of the to-be-uploaded task is recorded into a preset task queue. The task queue serves as a unified task management carrier, and will sort and store the to-be-uploaded tasks added according to a preset rule, and maintain the update of the task state in real time. For example, when the to-be-uploaded task enters the uploading, task success, or task failure state, the queue synchronously updates the corresponding task state.

[0151] Figure 5 Further, a flowchart of a task uploading method provided by the embodiments of the present disclosure is shown. Based on the embodiments shown in Figure 1 Figure 5 may include the following steps:

[0152] ​Step 501, judging whether the network state meets the preset condition for obtaining the to-be-uploaded task.

[0153] The network state is the current network connection of the client, and the preset condition is the network standard pre-configured by the client for judging whether it is suitable to obtain the to-be-uploaded task. The standard can be set according to business requirements, for example, the network upload rate is not less than 1 Mbps, the network delay is not more than 200 ms, etc. The client obtains the connection type, upload rate, delay and other parameters of the current network in real time by calling the network interface, and then compares the parameters with the preset condition. If all parameters meet the preset condition (such as the upload rate ≥ 1 Mbps), it is determined that the network state meets the preset condition. If any parameter does not meet the condition (such as the network delay exceeds 200 ms), it is determined that the network state does not meet the preset condition. It should be noted that the above examples are only illustrative and do not limit the specific content.

[0154] Step 502, obtaining the to-be-uploaded task when it is determined that the network state meets the preset condition.

[0155] When the network state indeed meets the preset condition, the client immediately starts the acquisition process of the to-be-uploaded task, and obtains the to-be-uploaded task by reading local business data, responding to user operations, calling storage directory, etc. to ensure that the obtained to-be-uploaded task is valid data.

[0156] Step 503, obtaining the to-be-uploaded task after waiting for the network state to meet the preset condition when it is determined that the network state does not meet the preset condition.

[0157] When it is determined that the network state does not meet the preset condition, the client suspends the acquisition of the to-be-uploaded task, and monitors the network state change through timing detection or listening. When it is detected that the network state meets the preset condition, the to-be-uploaded task is obtained again.

[0158] Figure 6 A flowchart of a task uploading method provided by an embodiment of the present disclosure.

[0159] As shown in Figure 6 The method is applied to a server, and the task uploading method comprises steps 601-603.

[0160] Step 601, receiving a to-be-uploaded task and verification information, and generating confirmation information corresponding to the to-be-uploaded task; wherein the verification information is generated according to the to-be-uploaded task.

[0161] The server listens to the uploading request of the client through a preset network interface. When the client sends the uploading task and the check information, the server analyzes the request data packet, separates the uploading task and the check information, confirms that the generation logic of the information is consistent with the logic of the client for generating the check information, and calculates the separated uploading task by using the same algorithm to obtain the result as the corresponding check information of the uploading task.

[0162] In step 602, the feedback information is obtained according to the consistency judgment result of the check information and the check information.

[0163] The server compares the check information with the check information sent by the client. If the contents of the two are completely consistent, it is determined that the consistency is established, and the feedback information (such as status code "00", text information "check success") is generated. If there is a difference between the two, it is determined that the consistency is not established, and the feedback information (such as status code "01", text information "check failure") is generated.

[0164] In step 603, the feedback information is sent to the client, so that the client determines the task state of the uploading task according to the feedback information.

[0165] After the server generates the feedback information, the feedback information is sent to the client through a preset path through the network connection established with the client. After the client receives it, the consistency result represented in the feedback information can be directly used to determine the task state (such as task success or task failure) of the uploading task, and the closed-loop interaction between the server and the client is completed.

[0166] Through the above method, the server receives the task data and generates the check information, and compares the check information with the check information of the client, forming a two-way verification mechanism of data integrity, ensuring that the uploading task is not tampered or lost in the transmission process, and improving the accuracy and reliability of the task uploading.

[0167] In summary, the method for uploading the task provided by the present disclosure includes: receiving an uploading task and check information, generating check information corresponding to the uploading task; wherein the check information is generated according to the uploading task; obtaining feedback information according to the consistency judgment result of the check information and the check information; sending the feedback information to the client, so that the client determines the task state of the uploading task according to the feedback information; sending the feedback information through the consistency judgment result of the check information and the check information, determining the task state according to the feedback information, and re-uploading the uploading task that fails, which improves the success rate of the task uploading, thereby ensuring the integrity of the task uploading.

[0168] In some embodiments, Figure 7 A flowchart of a method for uploading a task provided by an embodiment of the present disclosure is shown. The steps S1-S9 include:

[0169] S1: After the process starts, initialization is performed; the initialization operation completes the initialization of resources and configurations related to task management (initializing the ID of the task to be uploaded, preset conditions and preset paths);

[0170] S2: Monitor network status;

[0171] S3: Determine whether the network status meets the preset conditions for obtaining the task to be uploaded;

[0172] If the network status meets the preset conditions for obtaining the task to be uploaded, then execute S3a; if the network status does not meet the preset conditions for obtaining the task to be uploaded, then execute S3b.

[0173] S3a: Get tasks to be uploaded;

[0174] S3b: Waiting for the network status to meet the preset conditions;

[0175] In the scenario of grading assignments, when there is a trigger action to submit the image of the grading question (to be uploaded), S4 will be executed;

[0176] S4: Submit the graded question images (task to be uploaded);

[0177] S5: Determine if the number of tasks to be uploaded is greater than the number of preset paths.

[0178] If the number of tasks to be uploaded is less than or equal to the number of preset paths, then execute S6; if the number of tasks to be uploaded is greater than the number of preset paths, then execute S5a.

[0179] S5a: Generate alternative paths using path generation methods;

[0180] S6: Check local tasks awaiting upload;

[0181] S7: Perform local backup of the upload task to obtain the backup task;

[0182] S8: Generate verification information for the task to be uploaded, upload the verification information and the task to be uploaded to the server through a preset path, so that the server can receive the task to be uploaded and the verification information, generate corresponding confirmation information based on the received task to be uploaded, and send feedback information to the client based on the consistency judgment result of the confirmation information and the verification information; the client receives the feedback information and determines the task status of the task to be uploaded based on the feedback information.

[0183] S9: Determine the task status of the task to be uploaded;

[0184] If the task status is "task successful", then execute S9a; if the task status is "task failed", then execute S9b.

[0185] S9a: cleaning up the backup task of the local backup;

[0186] S9b: re-uploading the to-be-uploaded task; and continuing to perform S8 through a preset retransmission number of times.

[0187] For detailed descriptions of steps S1-S9, refer to the related detailed descriptions of the above embodiments.

[0188] The beneficial effects that can be achieved in the embodiments of the present disclosure are as follows:

[0189] 1. High success rate and reliability of the uploaded task: through network state detection, execution of different task states of the to-be-uploaded task, and a retransmission mechanism, the problem of upload failure caused by unstable network is solved, and the success rate of task uploading is improved.

[0190] 2. Guarantee mechanism for task non-loss: task queue management, identification and tracking of task state, local data backup, and result confirmation, and the like, guarantee that task data will not be lost, and even in abnormal conditions, the task execution can be recovered.

[0191] 3. Data consistency and integrity check: consistency check is performed on the confirmation information through the check information, to ensure that the data is not damaged or lost in the data transmission process.

[0192] 4. Efficient task log and abnormality management: the uploading information in the uploading process is recorded, abnormal feedback and retry processing are provided, and the traceability and reliability of the to-be-uploaded task execution are ensured.

[0193] Corresponding to the above-mentioned task uploading method, the present disclosure further provides a task uploading device. Since the device embodiment of the present disclosure corresponds to the above-mentioned method embodiment, for details not disclosed in the device embodiment, refer to the above-mentioned method embodiment, which will not be described herein again.

[0194] Figure 8 A structural schematic diagram of a task uploading device provided in the embodiments of the present disclosure is shown in FIG. 1, which is applied to a client and includes a first acquisition unit 41, a first generation unit 42, an uploading unit 43, a receiving unit 44, and a retransmission unit 45. Figure 8 The first acquisition unit 41 is configured to acquire a to-be-uploaded task.

[0195] The first generation unit 42 is configured to generate check information of the to-be-uploaded task.

[0196] The uploading unit 43 is configured to upload the to-be-uploaded task to a server through a network.

[0197] The receiving unit 44 is configured to receive a result of the to-be-uploaded task from the server. The retransmission unit 45 is configured to retransmit the to-be-uploaded task when the result of the to-be-uploaded task is not correct.The uploading unit 43 is configured to upload the check information and the to-be-uploaded task to a server through a preset path, so that the server receives the to-be-uploaded task and the check information, generates corresponding confirmation information according to the received to-be-uploaded task, and sends feedback information according to a consistency determination result of the confirmation information and the check information.

[0198] The receiving unit 44 is configured to determine a task state of the to-be-uploaded task according to the feedback information in response to receiving the feedback information sent by the server, where the feedback information is used to represent the consistency of the confirmation information and the check information.

[0199] The re-uploading unit 45 is configured to re-upload the to-be-uploaded task in a case where the task state is determined to be task failure.

[0200] In summary, the device for uploading a task provided in the present disclosure includes: obtaining a to-be-uploaded task and generating check information of the to-be-uploaded task; uploading the check information and the to-be-uploaded task to a server through a preset path, so that the server receives the to-be-uploaded task and the check information, generates corresponding confirmation information according to the received to-be-uploaded task, and sends feedback information according to a consistency determination result of the confirmation information and the check information; a client receives the feedback information sent by the server, and determines a task state of the to-be-uploaded task according to the feedback information; and in a case where the task state is determined to be task failure, the to-be-uploaded task is re-uploaded; the feedback information is sent according to the consistency determination result of the confirmation information and the check information, the task state is determined according to the feedback information, and the to-be-uploaded task that fails in the task is re-uploaded, thereby improving the success rate of task uploading and ensuring the integrity of task uploading.

[0201] Further, in a possible implementation manner of an embodiment of the present disclosure, as shown in Figure 9 the device further includes:

[0202] The first determination unit 46 is configured to determine whether the number of to-be-uploaded tasks is greater than the number of preset paths; one to-be-uploaded task corresponds to one preset path.

[0203] The first allocation unit 47 is configured to allocate the preset paths to the to-be-uploaded tasks in a case where the number of to-be-uploaded tasks is determined to be less than or equal to the number of preset paths.

[0204] The second allocation unit 48 is configured to generate a standby path through a path generation device in a case where the number of to-be-uploaded tasks is determined to be greater than the number of preset paths, allocate the preset paths to the to-be-uploaded tasks according to the number of preset paths, and allocate the standby path to the to-be-uploaded tasks that are not allocated the preset paths.

[0205] Further, in a possible implementation form of the embodiment of the present disclosure, as shown in Figure 9 The retransmission unit 45 comprises:

[0206] The acquisition module 451 is configured to acquire a backup task in a case where it is determined that the task status is the task failure.

[0207] The retransmission module 452 is configured to reupload the backup task, wherein the backup task is obtained by locally backing up the to-be-uploaded task.

[0208] Further, in a possible implementation form of the embodiment of the present disclosure, as shown in Figure 9 The apparatus further comprises:

[0209] The recording unit 49 is configured to record uploading information of the to-be-uploaded task in an uploading process in a case where it is determined that the task status is the task success or the task failure, wherein the uploading information at least comprises the task status, a retry number, the confirmation information and the check information.

[0210] The second generation unit 410 is configured to generate exception information when it is detected that the to-be-uploaded task appears an exception in the uploading process.

[0211] Further, in a possible implementation form of the embodiment of the present disclosure, as shown in Figure 9 The task status comprises to-be-uploaded, uploading, task success and task failure, and the apparatus further comprises a marking unit 411, which comprises:

[0212] The first marking module 4111 is configured to mark the task status of the to-be-uploaded task which has not started uploading as the to-be-uploaded.

[0213] The second marking module 4112 is configured to mark the task status of the to-be-uploaded task which is being uploaded as the uploading.

[0214] The third marking module 4113 is configured to mark the task status of the to-be-uploaded task which has successfully uploaded as the task success.

[0215] The fourth marking module 4114 is configured to mark the task status of the to-be-uploaded task which has failed to upload as the task failure.

[0216] Further, in a possible implementation form of the embodiment of the present disclosure, as shown in Figure 9 The apparatus further comprises:

[0217] The backup unit 412 is configured to backup the to-be-uploaded task locally to obtain the backup task after the first obtaining unit 41 obtains the to-be-uploaded task.

[0218] The management unit 413 is configured to add the to-be-uploaded task to a task queue for management.

[0219] Further, in a possible implementation of the embodiment of the present disclosure, as shown in Figure 9 The device further includes:

[0220] The second judging unit 414 is configured to judge whether a network state meets a preset condition for obtaining the to-be-uploaded task before the first obtaining unit 41 obtains the to-be-uploaded task.

[0221] The second obtaining unit 415 is configured to obtain the to-be-uploaded task when it is determined that the network state meets the preset condition.

[0222] The third obtaining unit 416 is configured to obtain the to-be-uploaded task after the network state meets the preset condition when it is determined that the network state does not meet the preset condition.

[0223] Figure 10 A structural diagram of a task uploading device provided by the embodiment of the present disclosure is shown in Figure 10 The device is applied to a server and includes a third generating unit 51, a determining unit 52, and a sending unit 53.

[0224] The third generating unit 51 is configured to receive a to-be-uploaded task and verification information, and generate confirmation information corresponding to the to-be-uploaded task, wherein the verification information is generated according to the to-be-uploaded task.

[0225] The determining unit 52 is configured to obtain feedback information according to a consistency judgment result of the confirmation information and the verification information.

[0226] The sending unit 53 is configured to send the feedback information to a client, so that the client determines a task state of the to-be-uploaded task according to the feedback information.

[0227] To sum up, according to the task uploading device provided by the present disclosure, the device comprises: receiving a task to be uploaded and verification information, and generating confirmation information corresponding to the task to be uploaded; wherein the verification information is generated according to the task to be uploaded; obtaining feedback information according to the consistency judgment result of the confirmation information and the verification information; sending the feedback information to the client, so that the client determines the task state of the task to be uploaded according to the feedback information; sending the feedback information through the consistency judgment result of the confirmation information and the verification information, determining the task state according to the feedback information, and re-uploading the task to be uploaded which fails to improve the success rate of task uploading, thereby ensuring the integrity of task uploading.

[0228] It should be noted that the foregoing explanation and description of the method embodiments also apply to the device of the present disclosure, and the principles are the same, which are not limited in the present disclosure.

[0229] Figure 11 A structural schematic diagram of a task uploading system provided by the present disclosure is provided, and the system comprises a client 61 and a server 62, comprising:

[0230] The client 61 is configured to obtain a task to be uploaded and generate verification information of the task to be uploaded.

[0231] The client 61 is further configured to upload the verification information and the task to be uploaded to the server through a preset path.

[0232] The server 62 is configured to receive the task to be uploaded and the verification information, generate corresponding confirmation information according to the received task to be uploaded, and send feedback information according to the consistency judgment result of the confirmation information and the verification information.

[0233] The client 61 is further configured to receive the feedback information and determine the task state of the task to be uploaded according to the feedback information; wherein the feedback information is used to represent the consistency of the confirmation information and the verification information.

[0234] The client 61 is further configured to re-upload the task to be uploaded in the case of determining that the task state is task failure.

[0235] According to the embodiments of the present disclosure, the present disclosure further provides an electronic device, a readable storage medium and a computer program product.

[0236] Figure 12A schematic block diagram of an example electronic device 700 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptops, desktops, tablets, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown here, their connections and relationships, and their functions, are meant to be examples only, and are not intended to limit the implementations of the present disclosure described and / or claimed in this document.

[0237] As shown, Figure 12 The electronic device 700 includes a computing unit 701 that can perform various appropriate actions and processes in accordance with a computer program stored in a ROM (Read-Only Memory) 702 or a computer program loaded into a RAM (Random Access Memory) 703 from a storage unit 708. Various programs and data required for the operation of the electronic device 700 can also be stored in the RAM 703. The computing unit 701, the ROM 702, and the RAM 703 are connected to each other through a bus 704. An I / O (Input / Output) interface 705 is also connected to the bus 704.

[0238] Various components in the electronic device 700 are connected to the I / O interface 705, including an input unit 706, such as a keyboard, a mouse, and the like; an output unit 707, such as various types of displays, speakers, and the like; a storage unit 708, such as a magnetic disk, an optical disk, and the like; and a communication unit 709, such as a network card, a modem, a wireless communication transceiver, and the like. The communication unit 709 allows the electronic device 700 to exchange information / data with other devices through a computer network, such as the Internet, and / or various telecommunication networks.

[0239] The computing unit 701 can be various general and / or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a CPU (Central Processing Unit), a GPU (Graphic Processing Units), various special-purpose AI (Artificial Intelligence) computing chips, various computing units running machine learning model algorithms, a DSP (Digital Signal Processor), and any appropriate processor, controller, microcontroller, etc. The computing unit 701 performs various methods and processes described above, such as the method of task uploading. For example, in some embodiments, the method of task uploading can be implemented as a computer software program, which is tangibly embodied in a machine-readable medium, such as the storage unit 708. In some embodiments, part or all of the computer program can be loaded and / or installed onto the electronic device 700 via the ROM 702 and / or the communication unit 709. When the computer program is loaded onto the RAM 703 and executed by the computing unit 701, one or more steps of the methods described above can be performed. Alternatively, in other embodiments, the computing unit 701 can be configured to perform the aforementioned method of task uploading by any other appropriate means, such as by means of firmware.

[0240] Various implementations of the systems and techniques described above herein can be realized in digital electronic circuitry, integrated circuitry, a Field Programmable Gate Array (FPGA), an Application-Specific Integrated Circuit (ASIC), an Application Specific Standard Product (ASSP), a System on Chip (SOC), a Complex Programmable Logic Device (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.

[0241] Program code for carrying out methods of the present disclosure can be written in any combination of one or more programming languages. The program code can be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the program code, when executed by the processor or controller, produces the functions / operations specified in the flowcharts and / or the block diagrams. The program code can be executed entirely on a machine, partially on a machine, partially on a machine as a stand-alone software package, partially on a machine and partially on a remote machine or entirely on a remote machine or server.

[0242] In the context of the present disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include but is not limited to an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of the machine-readable storage medium would include one or more lines of electrical connections, portable computer disks, hard disk drives, RAM, ROM, EPROM (Electrically Programmable Read-Only-Memory), or flash memory, fiber optics, CD-ROM (Compact Disc Read-Only Memory), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0243] 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 the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can be used to provide for interaction with a user as well; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form, including acoustic, speech, or tactile input.

[0244] 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 a LAN (Local Area Network), a WAN (Wide Area Network), the Internet, and a blockchain network.

[0245] The computer system can 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 is generally established using computer programs running on the respective computers and having a client-server relationship to each other. A server can be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system, to solve the defects of large management difficulty and weak business scalability in traditional physical host and VPS service ("Virtual Private Server", or simply "VPS"). The server can also be a server of a distributed system, or a server combined with a blockchain.

[0246] It should be noted that artificial intelligence is a discipline that studies enabling computers to simulate some thinking processes and intelligent behaviors of people (such as learning, reasoning, thinking, planning, etc.), both hardware and software technologies. Artificial intelligence hardware technology generally includes technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing, etc.; artificial intelligence software technology mainly includes computer vision technology, speech recognition technology, natural language processing technology, and machine learning / deep learning, big data processing technology, knowledge graph technology, etc. several major directions.

[0247] It should be understood that various forms of flow shown above can be used to reorder, add or delete steps. For example, each step described in the present disclosure can be executed in parallel, sequentially or in a different order, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, which is not limited herein.

[0248] The above detailed description does not limit the scope of the disclosure. Various modifications, combinations, sub-combinations and alternatives can be made to the detailed description. Any modification, equivalent replacement and improvement etc. made within the spirit and principle of the disclosure shall be included in the scope of the disclosure.

Claims

1. A method of task uploading, characterized by, The method is applied to a client and comprises: obtaining a task to be uploaded and generating verification information of the task to be uploaded; uploading the verification information and the task to be uploaded to a server through a preset path, so that the server receives the task to be uploaded and the verification information, generates corresponding confirmation information according to the received task to be uploaded, and sends feedback information according to a consistency judgment result of the confirmation information and the verification information; in response to receiving the feedback information sent by the server, determining a task state of the task to be uploaded according to the feedback information; wherein the feedback information is used to represent the consistency of the confirmation information and the verification information; in a case where it is determined that the task state is a task failure, re-uploading the task to be uploaded.

2. The method of claim 1, wherein, The method further comprises: determining whether the number of the tasks to be uploaded is greater than the number of preset paths; wherein one task to be uploaded corresponds to one preset path; in a case where it is determined that the number of the tasks to be uploaded is less than or equal to the number of the preset paths, allocating the preset paths to the tasks to be uploaded; in a case where it is determined that the number of the tasks to be uploaded is greater than the number of the preset paths, generating a standby path through a path generation method, allocating the preset paths to the tasks to be uploaded according to the number of the preset paths, and allocating the standby path to the tasks to be uploaded which are not allocated the preset paths.

3. The method of claim 1, wherein, The re-uploading of the task to be uploaded in a case where it is determined that the task state is a task failure comprises: in a case where it is determined that the task state is the task failure, obtaining a backup task and re-uploading the backup task; wherein the backup task is obtained by locally backing up the task to be uploaded.

4. The method according to claim 1 or 3, characterized in that, The method further comprises: in a case where it is determined that the task state is a task success or the task failure, recording upload information of the task to be uploaded in an uploading process; wherein the upload information at least comprises the task state, a retry number, the confirmation information and the verification information; generating exception information when detecting that an exception occurs in the uploading process of the task to be uploaded.

5. The method of claim 1, wherein, The task state comprises a task to be uploaded, an uploading in progress, a task success and a task failure, and the task state of the task to be uploaded is marked, and the marking method comprises: marking the task state of the task to be uploaded which has not started uploading as the task to be uploaded; marking the task state of the task to be uploaded which is being uploaded as the uploading in progress; marking the task state of the task to be uploaded which has been uploaded successfully as the task success; marking the task state of the task to be uploaded which has failed to be uploaded as the task failure.

6. The method of claim 1, wherein, After the task to be uploaded is obtained, the method further comprises: locally backing up the task to be uploaded to obtain the backup task, and adding the task to be uploaded to a task queue for management.

7. The method of claim 1, wherein, Before the task to be uploaded is obtained, the method comprises: determining whether a network state meets a preset condition for obtaining the task to be uploaded; in a case where it is determined that the network state meets the preset condition, obtaining the task to be uploaded; In a case where it is determined that the network state does not meet the preset condition, the method further comprises: waiting until the network state meets the preset condition, and then obtaining the to-be-uploaded task.

8. A method of task uploading, characterized by, The method is applied to a server, and comprises: receiving a to-be-uploaded task and verification information, and generating confirmation information corresponding to the to-be-uploaded task; wherein the verification information is generated according to the to-be-uploaded task; obtaining feedback information according to a consistency determination result of the confirmation information and the verification information; sending the feedback information to a client, so that the client determines a task state of the to-be-uploaded task according to the feedback information.

9. A system for task uploading, characterized by The system comprises a client and a server, and comprises: the client is configured to obtain a to-be-uploaded task, and generate verification information of the to-be-uploaded task; the client is further configured to upload the verification information and the to-be-uploaded task to the server through a preset path; the server is configured to receive the to-be-uploaded task and the verification information, generate corresponding confirmation information according to the received to-be-uploaded task, and send feedback information according to a consistency determination result of the confirmation information and the verification information; the client is further configured to receive the feedback information, and determine a task state of the to-be-uploaded task according to the feedback information; wherein the feedback information is used to represent the consistency of the confirmation information and the verification information; the client is further configured to re-upload the to-be-uploaded task in a case where it is determined that the task state is task failure.

10. An electronic device, comprising: comprise: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method of any one of claims 1-7 or claim 8.

Citation Information

Patent Citations

  • File processing method and device and computer readable storage medium

    CN109756568A

  • File transaction transmission method and system, readable storage medium and server

    CN111866120A

  • File uploading information processing method and device, computer equipment and storage medium

    CN114143308A

  • Large file uploading method and device, computer equipment and storage medium

    CN116192838A

  • File transmission verification method, file transmission system, electronic equipment and storage medium

    CN119583538A