CN103995745B - IP hard disk task execution method and IP hard disk - Google Patents

IP hard disk task execution method and IP hard disk Download PDF

Info

Publication number
CN103995745B
CN103995745B CN201410219794.0A CN201410219794A CN103995745B CN 103995745 B CN103995745 B CN 103995745B CN 201410219794 A CN201410219794 A CN 201410219794A CN 103995745 B CN103995745 B CN 103995745B
Authority
CN
China
Prior art keywords
hard disk
external node
execution result
work
node
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201410219794.0A
Other languages
Chinese (zh)
Other versions
CN103995745A (en
Inventor
雷晓松
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201410219794.0A priority Critical patent/CN103995745B/en
Publication of CN103995745A publication Critical patent/CN103995745A/en
Application granted granted Critical
Publication of CN103995745B publication Critical patent/CN103995745B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本发明实施例公开了一种IP硬盘任务执行方法,用于避免硬盘执行结果数据的浪费。本发明实施例方法包括:接收外部节点发送的工作任务与工作标识,所述工作标识用于标识所述工作任务;判断所述外部节点是否为可用的外部节点;当所述外部节点为可用的外部节点时,获取所述工作标识对应的中间执行结果,所述中间执行结果是所述工作任务对应的中间执行结果;根据所述中间执行结果,完成对所述工作任务的执行,得到所述工作任务对应的最终执行结果;将所述最终执行结果发送给所述外部节点。本发明实施例还提供了相关的IP硬盘。

The embodiment of the invention discloses an IP hard disk task execution method, which is used to avoid waste of hard disk execution result data. The method in the embodiment of the present invention includes: receiving a work task and a work identification sent by an external node, where the work identification is used to identify the work task; judging whether the external node is an available external node; when the external node is available For an external node, obtain the intermediate execution result corresponding to the work identifier, the intermediate execution result is the intermediate execution result corresponding to the work task; complete the execution of the work task according to the intermediate execution result, and obtain the The final execution result corresponding to the work task; sending the final execution result to the external node. The embodiment of the present invention also provides a related IP hard disk.

Description

一种IP硬盘任务执行方法以及IP硬盘IP hard disk task execution method and IP hard disk

技术领域technical field

本发明涉及通信领域,尤其涉及一种IP硬盘任务执行方法以及IP硬盘。The invention relates to the communication field, in particular to an IP hard disk task execution method and an IP hard disk.

背景技术Background technique

随着科学技术的发展,云存储技术日益兴起,加速了基于Key-Value方式接口的应用。业界已出现了基于Key-Value语义的网络间互连协议(IP,Internet Protocol)硬盘,抛弃传统的SCSI接口与协议标准,转而采用IP来进行外部通信。With the development of science and technology, cloud storage technology is rising day by day, which accelerates the application of Key-Value-based interfaces. The Internet Protocol (IP, Internet Protocol) hard disk based on Key-Value semantics has emerged in the industry, abandoning the traditional SCSI interface and protocol standards, and using IP for external communication.

当前发布的IP硬盘提供开放式Key-Value语义接口,此外还可支持更多的服务能力,例如硬盘内置压缩、加密、全盘完整性检查。因为IP硬盘内置了一定的计算能力,同时不通过传统直连方式与外界处理器互连,因此部分外界处理器对硬盘的操作可以转移到硬盘上来操作,例如杀毒、针对局部数据的压缩、重删、全盘校验等,这类操作可通过外界处理器以移动虚拟机或移动代码方式动态加载、或本地Firmware静态加载到IP硬盘的计算单元上执行,并告诉外界处理器执行结果。Currently released IP hard disks provide an open Key-Value semantic interface, and can also support more service capabilities, such as hard disk built-in compression, encryption, and full-disk integrity check. Because the IP hard disk has a certain built-in computing power and is not interconnected with the external processor through the traditional direct connection method, some operations of the external processor on the hard disk can be transferred to the hard disk for operation, such as anti-virus, compression for local data, and reloading. Delete, full-disk verification, etc., such operations can be dynamically loaded by the external processor by means of mobile virtual machine or mobile code, or local Firmware can be statically loaded to the computing unit of the IP hard disk for execution, and the external processor will be notified of the execution result.

但是,由于IP硬盘在执行上述操作时与外界处理器脱离,所以当IP硬盘执行上述操作时间较长时,外界处理器可能已离线或失效。此时若IP硬盘得到中间执行结果需要通知外部节点,将无法完成通知外部节点的操作。这就导致了IP硬盘的中间执行结果不能输出甚至丢失,造成了执行结果数据的浪费。However, since the IP hard disk is separated from the external processor when performing the above operations, when the IP hard disk performs the above operations for a long time, the external processor may be offline or invalid. At this time, if the IP hard disk needs to notify the external node of the intermediate execution result, the operation of notifying the external node will not be completed. This leads to the inability to output or even lose the intermediate execution results of the IP hard disk, resulting in waste of execution result data.

发明内容Contents of the invention

本发明实施例提供了一种IP硬盘任务执行方法以及IP硬盘,可以避免IP硬盘执行结果数据的浪费。Embodiments of the present invention provide an IP hard disk task execution method and an IP hard disk, which can avoid waste of IP hard disk execution result data.

本发明实施例的第一方面提供了一种IP硬盘任务执行方法,包括:The first aspect of the embodiments of the present invention provides a method for executing an IP hard disk task, including:

网络间互连协议IP硬盘接收外部节点发送的工作任务与工作标识,所述工作标识用于标识所述工作任务;The network interconnection protocol IP hard disk receives the work task and the work identification sent by the external node, and the work identification is used to identify the work task;

判断所述外部节点是否为可用的外部节点;judging whether the external node is an available external node;

当所述外部节点为可用的外部节点时,获取所述工作标识对应的中间执行结果,所述中间执行结果是所述工作任务对应的中间执行结果;When the external node is an available external node, acquire an intermediate execution result corresponding to the work identifier, where the intermediate execution result is an intermediate execution result corresponding to the work task;

根据所述中间执行结果,完成对所述工作任务的执行,得到所述工作任务对应的最终执行结果;completing the execution of the work task according to the intermediate execution result, and obtaining a final execution result corresponding to the work task;

将所述最终执行结果发送给所述外部节点。Send the final execution result to the external node.

结合本发明实施例的第一方面,本发明实施例的第一方面的第一种实现方式中,所述工作任务包括多个执行步骤,所述IP硬盘接收外部节点发送的工作任务与工作标识之前还包括:In combination with the first aspect of the embodiments of the present invention, in the first implementation manner of the first aspect of the embodiments of the present invention, the work task includes multiple execution steps, and the IP hard disk receives the work task and the work identification sent by the external node Previously also included:

执行所述多个执行步骤中的至少一个所述执行步骤,得到所述中间执行结果;Executing at least one of the execution steps in the plurality of execution steps to obtain the intermediate execution result;

保存所述工作标识与所述中间执行结果的对应关系。The corresponding relationship between the job identifier and the intermediate execution result is saved.

结合本发明实施例的第一方面,本发明实施例的第一方面的第二种实现方式中,所述外部节点具有节点标识;With reference to the first aspect of the embodiments of the present invention, in the second implementation manner of the first aspect of the embodiments of the present invention, the external node has a node identifier;

所述判断所述外部节点是否为可用的外部节点包括:The judging whether the external node is an available external node includes:

将所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点。Comparing the node identifier of the external node with the node identifier of the available external node preset by the IP hard disk, if the node identifier of the external node is the same as the node identifier of the available external node preset by the IP hard disk , it is determined that the external node is an available external node.

结合本发明实施例的第一方面、第一方面的第一种实现方式与第一方面的第二种实现方式,本发明实施例的第一方面的第三种实现方式中,所述工作任务包括关联标识,所述关联标识用于标识与所述工作任务相关联的其它任务;所述方法还包括:Combining the first aspect of the embodiments of the present invention, the first implementation of the first aspect and the second implementation of the first aspect, in the third implementation of the first aspect of the embodiments of the present invention, the task An association identifier is included, and the association identifier is used to identify other tasks associated with the work task; the method further includes:

保存所述最终执行结果与所述关联标识之间的对应关系,以便于与所述工作任务相关联的其它任务根据所述关联标识获得所述最终执行结果,并且以所述最终执行结果为执行条件,执行与所述工作任务相关联的其它任务包含的执行步骤。Save the corresponding relationship between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the final execution result according to the association identifier, and use the final execution result as the execution condition, execute the execution steps included in other tasks associated with the work task.

本发明实施例的第二方面提供了一种IP硬盘,包括:A second aspect of the embodiments of the present invention provides an IP hard disk, including:

接收模块,用于接收外部节点发送的工作任务与工作标识,所述工作标识用于标识所述工作任务;A receiving module, configured to receive a work task and a work identification sent by an external node, and the work identification is used to identify the work task;

判断模块,用于判断所述外部节点是否为可用的外部节点;A judging module, configured to judge whether the external node is an available external node;

获取模块,用于当所述外部节点为可用的外部节点时,获取所述工作标识对应的中间执行结果,所述中间执行结果是所述工作任务对应的中间执行结果;An acquisition module, configured to acquire an intermediate execution result corresponding to the work identifier when the external node is an available external node, where the intermediate execution result is an intermediate execution result corresponding to the work task;

结果执行模块,用于根据所述中间执行结果,完成对所述工作任务的执行,得到所述工作任务对应的最终执行结果;A result execution module, configured to complete the execution of the work task according to the intermediate execution result, and obtain a final execution result corresponding to the work task;

输出模块,用于将所述最终执行结果发送给所述外部节点。An output module, configured to send the final execution result to the external node.

结合本发明实施例的第二方面,本发明实施例的第二方面的第一种实现方式中,所述工作任务包括多个执行步骤,所述IP硬盘还包括:In conjunction with the second aspect of the embodiments of the present invention, in the first implementation manner of the second aspect of the embodiments of the present invention, the work task includes multiple execution steps, and the IP hard disk further includes:

中间执行模块,用于执行所述多个执行步骤中的至少一个所述执行步骤,得到所述中间执行结果;an intermediate execution module, configured to execute at least one of the execution steps in the plurality of execution steps, and obtain the intermediate execution result;

保存模块,用于保存所述工作标识与所述中间执行结果的对应关系。A saving module, configured to save the corresponding relationship between the job identifier and the intermediate execution result.

结合本发明实施例的第二方面,本发明实施例的第二方面的第二种实现方式中,所述外部节点具有节点标识;With reference to the second aspect of the embodiments of the present invention, in a second implementation manner of the second aspect of the embodiments of the present invention, the external node has a node identifier;

所述判断模块具体用于:The judgment module is specifically used for:

将所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点。Comparing the node identifier of the external node with the node identifier of the available external node preset by the IP hard disk, if the node identifier of the external node is the same as the node identifier of the available external node preset by the IP hard disk , it is determined that the external node is an available external node.

结合本发明实施例的第二方面、第二方面的第一种实现方式与第二方面的第二种实现方式,本发明实施例的第二方面的第三种实现方式中,所述工作任务包括关联标识,所述关联标识用于标识与所述工作任务相关联的其它任务;所述保存模块还用于:Combining the second aspect of the embodiments of the present invention, the first implementation of the second aspect and the second implementation of the second aspect, in the third implementation of the second aspect of the embodiments of the present invention, the task Including an association identifier, the association identifier is used to identify other tasks associated with the work task; the saving module is also used for:

保存所述最终执行结果与所述关联标识之间的对应关系,以便于与所述工作任务相关联的其它任务根据所述关联标识获得所述最终执行结果,并且以所述最终执行结果为执行条件,执行与所述工作任务相关联的其它任务包含的执行步骤。Save the corresponding relationship between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the final execution result according to the association identifier, and use the final execution result as the execution condition, execute the execution steps included in other tasks associated with the work task.

从以上技术方案可以看出,本发明实施例中,IP硬盘接收外部节点发送的工作任务与工作标识;判断所述外部节点是否是可用的外部节点;当所述外部节点是可用的外部节点时,根据所述工作标识获得中间执行结果;根据所述中间执行结果,完成对所述工作任务对应的所有执行步骤,得到所述工作任务对应的最终执行结果;将最终执行结果发送给所述外部节点。其中,本发明实施例中IP硬盘在接收了外部节点发送的工作任务与工作标识后,可以根据工作标识获取该工作任务的中间执行结果,使得IP硬盘可以在后续的操作中继续使用该第一中间执行结果。这样就保证了IP硬盘中保存的中间执行结果可以在IP硬盘与可用节点建立连接后继续被使用,使得IP硬盘的中间执行结果可以输出而不会丢失,避免了IP硬盘执行结果数据的浪费。As can be seen from the above technical solutions, in the embodiment of the present invention, the IP hard disk receives the work task and the work identification sent by the external node; judges whether the external node is an available external node; when the external node is an available external node , obtain an intermediate execution result according to the work identification; complete all execution steps corresponding to the work task according to the intermediate execution result, and obtain the final execution result corresponding to the work task; send the final execution result to the external node. Among them, in the embodiment of the present invention, after the IP hard disk receives the work task and the work identification sent by the external node, it can obtain the intermediate execution result of the work task according to the work identification, so that the IP hard disk can continue to use the first task in subsequent operations. Intermediate execution results. This ensures that the intermediate execution results saved in the IP hard disk can continue to be used after the IP hard disk establishes a connection with an available node, so that the intermediate execution results of the IP hard disk can be output without being lost, and the waste of execution result data on the IP hard disk is avoided.

附图说明Description of drawings

图1为本发明实施例中IP硬盘任务执行方法一个实施例流程图;Fig. 1 is a flow chart of an embodiment of an IP hard disk task execution method in an embodiment of the present invention;

图2为本发明实施例中IP硬盘任务执行方法另一个实施例流程图;Fig. 2 is the flow chart of another embodiment of the IP hard disk task execution method in the embodiment of the present invention;

图3为本发明实施例中IP硬盘一个实施例结构图;Fig. 3 is an embodiment structural diagram of IP hard disk in the embodiment of the present invention;

图4为本发明实施例中IP硬盘另一个实施例结构图;Fig. 4 is another embodiment structural diagram of IP hard disk in the embodiment of the present invention;

图5为本发明实施例中IP硬盘另一个实施例结构图。Fig. 5 is a structural diagram of another embodiment of the IP hard disk in the embodiment of the present invention.

具体实施方式detailed description

本发明实施例提供了一种IP硬盘任务执行方法,可以避免IP硬盘执行结果数据的浪费。本发明实施例还提供了相关的IP硬盘,以下将分别进行描述。The embodiment of the present invention provides an IP hard disk task execution method, which can avoid the waste of IP hard disk execution result data. The embodiment of the present invention also provides a related IP hard disk, which will be described separately below.

本发明实施例提供的IP硬盘任务执行方法的基本流程请参见图1,包括:Please refer to Figure 1 for the basic flow of the IP hard disk task execution method provided by the embodiment of the present invention, including:

101、接收外部节点发送的工作任务与工作标识;101. Receive the work task and work identification sent by the external node;

本发明实施例中所述的外部节点用于向IP硬盘发送工作任务等信息,并接收IP硬盘执行工作任务所得到的执行结果。其中,外部节点包括但不限于PC机、服务器、中央处理器等各种具有运算、处理或任务下发功能的装置。当该外部节点与IP硬盘连接时,将工作任务与该工作任务的工作标识下发给IP硬盘,其中,工作标识用于标识工作任务。The external nodes described in the embodiments of the present invention are used to send information such as work tasks to the IP hard disk, and receive execution results obtained by executing the work tasks on the IP hard disk. Wherein, the external nodes include, but are not limited to, PCs, servers, central processing units, and other devices with computing, processing, or task delivery functions. When the external node is connected to the IP hard disk, the work task and the work identification of the work task are sent to the IP hard disk, wherein the work identification is used to identify the work task.

IP接收外部节点发送的工作任务与工作标识。The IP receives the work task and the work identification sent by the external node.

102、判断该外部节点是否为可用的外部节点;102. Determine whether the external node is an available external node;

IP硬盘在接受了外部节点发送的工作任务后,需要判断该外部节点是否为可用的外部节点。具体的判断方法有很多,将在后面的实施例中详述,此处不做限定。After receiving the work task sent by the external node, the IP hard disk needs to judge whether the external node is an available external node. There are many specific judgment methods, which will be described in detail in the following embodiments, and are not limited here.

103、当该外部节点为可用的外部节点时,获取该工作标识对应的中间执行结果;103. When the external node is an available external node, obtain an intermediate execution result corresponding to the work identifier;

在IP硬盘接受外部节点发送的工作任务之前,IP硬盘有可能接收了其他节点下发的该工作任务,并执行了该工作任务的部分执行步骤,得到了中间执行结果,然后保存了该中间执行结果与该工作任务的工作标识的对应关系。但由于该其他节点失效,导致该中间执行结果不能输出。Before the IP hard disk accepts the work task sent by the external node, the IP hard disk may receive the work task sent by other nodes, and execute some execution steps of the work task, obtain the intermediate execution result, and then save the intermediate execution The corresponding relationship between the result and the work ID of the work task. However, due to the failure of the other node, the intermediate execution result cannot be output.

本实施例中,IP硬盘与外部节点建立了连接,并接收了外部节点发送的工作任务与工作标识,如果IP硬盘在此之前执行过其他节点下发的该工作任务,则可以根据工作标识来获取该工作标识对应的中间执行结果。其中,中间执行结果是IP硬盘保存的该工作任务对应的中间执行结果。In this embodiment, the IP hard disk establishes a connection with the external node, and receives the work task and the work identification sent by the external node. If the IP hard disk has executed the work task sent by other nodes before, it can be determined according to the work identification. Get the intermediate execution result corresponding to the job identifier. Wherein, the intermediate execution result is an intermediate execution result corresponding to the work task stored in the IP hard disk.

104、根据中间执行结果,完成对工作任务的执行,得到该工作任务对应的最终执行结果;104. Complete the execution of the work task according to the intermediate execution result, and obtain the final execution result corresponding to the work task;

IP硬盘获取了该中间执行结果后,根据该中间执行结果,完成对工作任务的执行,得到该工作任务对应的最终执行结果。优选地,由于该中间执行结果为该IP硬盘执行该工作任务的部分执行步骤所得到,所以IP硬盘只要执行该工作任务剩余未执行的步骤,就可以得到该最终执行结果。特别地,若该中间执行结果即为该IP硬盘执行该工作任务的所有执行步骤所得到,则IP硬盘将该中间执行结果作为最终执行结果。After obtaining the intermediate execution result, the IP hard disk completes the execution of the work task according to the intermediate execution result, and obtains the final execution result corresponding to the work task. Preferably, since the intermediate execution result is obtained by the IP hard disk executing part of the execution steps of the work task, the IP hard disk can obtain the final execution result only by executing the remaining unexecuted steps of the work task. In particular, if the intermediate execution result is obtained by the IP hard disk executing all execution steps of the work task, the IP hard disk takes the intermediate execution result as the final execution result.

105、将最终执行结果发送给该外部节点。105. Send the final execution result to the external node.

IP硬盘得到了最终执行结果后,将该最终执行结果发送给该外部节点。After obtaining the final execution result, the IP hard disk sends the final execution result to the external node.

本实施例中,IP硬盘接收外部节点发送的工作任务与工作标识;判断所述外部节点是否是可用的外部节点;当所述外部节点是可用的外部节点时,根据所述工作标识获得中间执行结果;根据所述中间执行结果,完成对所述工作任务对应的所有执行步骤,得到所述工作任务对应的最终执行结果;将最终执行结果发送给所述外部节点。其中,本实施例中IP硬盘在接收了外部节点发送的工作任务与工作标识后,可以根据工作标识获取该工作任务的中间执行结果,使得IP硬盘可以在后续的操作中继续使用该第一中间执行结果。这样就保证了IP硬盘中保存的中间执行结果可以在IP硬盘与可用节点建立连接后继续被使用,使得IP硬盘的中间执行结果可以输出而不会丢失,避免了IP硬盘执行结果数据的浪费。In this embodiment, the IP hard disk receives the work task and the work identification sent by the external node; judges whether the external node is an available external node; when the external node is an available external node, obtains the intermediate execution according to the work identification Result; complete all execution steps corresponding to the work task according to the intermediate execution result, and obtain a final execution result corresponding to the work task; send the final execution result to the external node. Wherein, in this embodiment, after the IP hard disk receives the work task and the work identification sent by the external node, it can obtain the intermediate execution result of the work task according to the work identification, so that the IP hard disk can continue to use the first intermediate execution result in subsequent operations. Results of the. This ensures that the intermediate execution results saved in the IP hard disk can continue to be used after the IP hard disk establishes a connection with an available node, so that the intermediate execution results of the IP hard disk can be output without being lost, and the waste of execution result data on the IP hard disk is avoided.

图1所示的实施例给出了本发明提供的IP硬盘任务执行方法的基本流程,其中IP硬盘在接收了外部节点发送的工作标识与工作任务后,根据该工作任务的中间执行结果,完成对该工作任务的执行。下面的实施例将给出IP硬盘获取该工作任务的中间执行结果的具体流程,请参见图2,本发明提供的又一种IP硬盘任务执行方法包括:The embodiment shown in Figure 1 provides the basic flow of the IP hard disk task execution method provided by the present invention, wherein the IP hard disk, after receiving the work identification and the work task sent by the external node, completes the task according to the intermediate execution result of the work task. Execution of the work task. The following embodiments will provide the specific flow for the IP hard disk to obtain the intermediate execution result of the work task. Referring to FIG. 2, another IP hard disk task execution method provided by the present invention includes:

201、执行工作任务的多个执行步骤中的至少一个执行步骤,得到中间执行结果;201. Execute at least one of the multiple execution steps of the work task to obtain an intermediate execution result;

本实施例中,工作任务包括多个执行步骤。IP硬盘首先执行该多个执行步骤的至少一个执行步骤,得到中间执行结果。In this embodiment, the work task includes multiple execution steps. The IP hard disk first executes at least one execution step of the multiple execution steps to obtain an intermediate execution result.

本步骤中,该工作任务可以任何节点下发给该IP硬盘,此处不做限定。优选地,IP硬盘在接收到该工作任务时,可以同时接收该工作任务的工作标识,或为该工作任务指定工作标识,此处不做限定。In this step, the work task can be delivered to the IP hard disk by any node, which is not limited here. Preferably, when the IP hard disk receives the work task, it can simultaneously receive the work identification of the work task, or assign a work identification to the work task, which is not limited here.

优选地,IP硬盘得到了中间执行结果后,保存该中间执行结果。Preferably, after obtaining the intermediate execution result, the IP hard disk saves the intermediate execution result.

202、保存所述工作标识与所述中间执行结果的对应关系;202. Save the correspondence between the work identifier and the intermediate execution result;

IP硬盘在得到了中间执行结果后,保存该中间执行结果与工作标识的对应关系。After obtaining the intermediate execution result, the IP hard disk saves the corresponding relationship between the intermediate execution result and the work ID.

其中,步骤201与步骤202在执行的过程中,将该工作任务下发给IP硬盘的节点可以与IP硬盘保持连接,也可以与该IP硬盘脱离,本实施例中不做限定。Wherein, during the execution of step 201 and step 202, the node that sends the work task to the IP hard disk may remain connected to the IP hard disk, or may be disconnected from the IP hard disk, which is not limited in this embodiment.

203、接收外部节点发送的工作任务与工作标识;203. Receive the work task and the work identification sent by the external node;

其中,该外部节点可以与步骤201中将工作任务下发给IP硬盘的节点为同一节点,也可以不为同一节点,本实施例中不做限定。Wherein, the external node may or may not be the same node as the node that issues the work task to the IP hard disk in step 201, which is not limited in this embodiment.

204、判断该外部节点是否为可用的外部节点;204. Determine whether the external node is an available external node;

IP硬盘在接受了外部节点发送的工作任务后,需要判断该外部节点是否为可用的外部节点。具体的判断方法有很多,包括:该外部节点具有节点标识,IP硬盘内预置有可用的外部节点的节点标识,IP硬盘将外部节点的节点标识与IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点。After receiving the work task sent by the external node, the IP hard disk needs to judge whether the external node is an available external node. There are many specific judgment methods, including: the external node has a node ID, the IP hard disk is preset with the node ID of the available external node, and the IP hard disk combines the node ID of the external node with the node ID of the available external node preset in the IP hard disk The identification is compared, and if the node identification of the external node is the same as the node identification of the available external node preset in the IP hard disk, it is determined that the external node is an available external node.

其中,节点标识的形式有很多,如节点的IP地址,节点的URL等,也可以为其他形式,此处不做限定。Among them, there are many forms of the node identification, such as the IP address of the node, the URL of the node, etc., and may also be in other forms, which are not limited here.

IP硬盘判断该外部节点是否为可用的外部节点也可以为其他方法,本实施例中不做限定。Other methods may also be used for the IP hard disk to determine whether the external node is an available external node, which is not limited in this embodiment.

205、当该外部节点为可用的外部节点时,获取该工作标识对应的中间执行结果;205. When the external node is an available external node, obtain an intermediate execution result corresponding to the work identifier;

IP硬盘确定了该外部节点为可用的外部节点时,根据该外部节点提供的工作标识,获取该工作标识对应的中间执行结果。该中间执行结果由IP硬盘在步骤201中得到。When the IP hard disk determines that the external node is an available external node, according to the work identification provided by the external node, the intermediate execution result corresponding to the work identification is obtained. The intermediate execution result is obtained by the IP hard disk in step 201 .

206、根据中间执行结果,完成对工作任务的执行,得到该工作任务对应的最终执行结果;206. Complete the execution of the work task according to the intermediate execution result, and obtain the final execution result corresponding to the work task;

由于IP硬盘在获取中间执行结果时,只执行了该工作任务的多个执行步骤中的至少一个执行步骤,所以IP硬盘只要执行该工作任务剩余未执行的步骤,就可以得到该最终执行结果。特别地,若该中间执行结果为IP硬盘执行该工作任务的所有执行步骤所得到,则IP硬盘将该中间执行结果作为最终执行结果。Since the IP hard disk only executes at least one execution step among the multiple execution steps of the work task when obtaining the intermediate execution result, the IP hard disk can obtain the final execution result only by executing the remaining unexecuted steps of the work task. In particular, if the intermediate execution result is obtained by the IP hard disk executing all execution steps of the work task, the IP hard disk takes the intermediate execution result as the final execution result.

207、将最终执行结果发送给该外部节点。207. Send the final execution result to the external node.

IP硬盘得到了最终执行结果后,将该最终执行结果发送给该外部节点。After obtaining the final execution result, the IP hard disk sends the final execution result to the external node.

本实施例在图1所示的实施例的基础上进一步描述了IP硬盘获取中间执行结果的步骤。其中,IP硬盘执行工作任务的至少一个执行步骤,得到中间执行结果,并保存中间执行结果与工作标识的对应关系。通过这样的方法,IP硬盘在接收了外部节点发送的工作任务与工作标识后,可以根据工作标识获取该工作任务的中间执行结果,使得IP硬盘可以在后续的操作中继续使用该第一中间执行结果。这样就保证了IP硬盘中保存的中间执行结果可以在IP硬盘与可用节点建立连接后继续被使用,使得IP硬盘的中间执行结果可以输出而不会丢失,避免了IP硬盘执行结果数据的浪费。On the basis of the embodiment shown in FIG. 1 , this embodiment further describes the steps for the IP hard disk to obtain intermediate execution results. Wherein, the IP hard disk executes at least one execution step of the work task, obtains an intermediate execution result, and stores the corresponding relationship between the intermediate execution result and the work identifier. Through this method, after receiving the work task and work ID sent by the external node, the IP hard disk can obtain the intermediate execution result of the work task according to the work ID, so that the IP hard disk can continue to use the first intermediate execution in subsequent operations. result. This ensures that the intermediate execution results saved in the IP hard disk can continue to be used after the IP hard disk establishes a connection with an available node, so that the intermediate execution results of the IP hard disk can be output without being lost, and the waste of execution result data on the IP hard disk is avoided.

优选地,工作任务还可以包括关联标识,该关联标识用于标识与该工作任务相关联的其它任务,该关联标识可以由IP硬盘从下发该工作任务的节点处获得,也可以由该IP硬盘指定,此处不做限定。其中,与该工作任务相关联的其它任务包括:执行条件为该工作任务的最终执行结果的任务。在完成了步骤207后,IP硬盘还可以保存该最终执行结果,并保存最终执行结果与所述关联标识之间的对应关系,以便于与该工作任务相关联的其它任务根据该关联标识获得该最终执行结果,并且以该最终执行结果为执行条件,执行与该工作任务相关联的其它任务包含的执行步骤。Preferably, the work task can also include an association identifier, which is used to identify other tasks associated with the work task, and the association identifier can be obtained from the node that issued the work task by the IP hard disk, or can be obtained by the IP Hard disk specified, not limited here. Wherein, other tasks associated with the work task include: tasks whose execution condition is the final execution result of the work task. After step 207 is completed, the IP hard disk can also save the final execution result, and save the corresponding relationship between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the execution result according to the association identifier. The final execution result, and using the final execution result as an execution condition, execute the execution steps included in other tasks associated with the work task.

为了便于理解上述实施例,下面将以上述实施例的一个具体应用场景为例进行说明:In order to facilitate understanding of the above embodiment, a specific application scenario of the above embodiment will be taken as an example for description below:

IP硬盘内预置有多个IP地址,这些IP地址对应的节点为该IP硬盘默认可用的外部节点。There are multiple IP addresses preset in the IP hard disk, and the nodes corresponding to these IP addresses are external nodes available by default for the IP hard disk.

节点A下发给IP硬盘三个工作任务,分别为任务1、任务2与任务3。其中,任务1为对目标文件1进行杀毒,任务2为对目标文件2进行杀毒,任务3为将经过杀毒的目标文件1与经过杀毒的目标文件2压缩到一个压缩文件中并输出给外部节点。Node A issues three tasks to the IP hard disk, namely task 1, task 2 and task 3. Among them, task 1 is to disinfect the target file 1, task 2 is to disinfect the target file 2, and task 3 is to compress the sterilized target file 1 and the sterilized target file 2 into a compressed file and output it to the external node .

IP硬盘接收到任务1、任务2与任务3后,为该3个任务指定工作标识分别为Job1、Job2与Job3。其中,Job1用于标识任务1、Job2用于标识任务2、Job3用于标识任务3。由于该3个任务具有相关性,所以IP硬盘指定这3个任务的关联标识均为JobListOne。After receiving task 1, task 2, and task 3, the IP hard disk specifies job IDs for the three tasks as Job1, Job2, and Job3, respectively. Wherein, Job1 is used to identify task 1, Job2 is used to identify task 2, and Job3 is used to identify task 3. Since the three tasks are related, the IP hard disk specifies that the associated identifiers of the three tasks are all JobListOne.

该硬盘执行任务1与任务2,即分别对目标文件1与目标文件2进行杀毒,并将杀毒后的目标文件1、目标文件1的关联标识JobListOne、目标文件2、目标文件2的关联标识JobListOne保存在硬盘划分出的专用“中间执行结果保存区”中。The hard disk executes task 1 and task 2, that is, respectively disinfects the target file 1 and target file 2, and the target file 1 after disinfection, the associated identifier of the target file 1 JobListOne, the target file 2, and the associated identifier of the target file 2 JobListOne It is stored in the dedicated "intermediate execution result storage area" divided by the hard disk.

此时IP硬盘要执行任务3。由于任务3的关联标识JobListOne与任务1与任务2的关联标识相同,所以IP硬盘从“中间执行结果保存区”中获取Job1与Job2对应的执行结果,即经过杀毒的目标文件1与经过杀毒的目标文件2。At this time, the IP hard disk needs to perform task 3. Since the associated identifier JobListOne of task 3 is the same as the associated identifier of task 1 and task 2, the IP hard disk obtains the execution results corresponding to Job1 and Job2 from the "intermediate execution result storage area", that is, the disinfected target file 1 and the disinfected target file2.

IP硬盘执行任务3,将经过杀毒的目标文件1与经过杀毒的目标文件2压缩为一个压缩文件,将该压缩文件与对应的工作标识Job3保存在“中间执行结果保存区”。此时节点A已经离线,IP硬盘无法输出该压缩文件。The IP hard disk executes task 3, compresses the anti-virus target file 1 and the anti-virus target file 2 into a compressed file, and saves the compressed file and the corresponding job ID Job3 in the "intermediate execution result storage area". At this time, node A is offline, and the IP hard disk cannot output the compressed file.

10分钟后,节点B与IP硬盘建立连接,并向IP硬盘发送任务3以及工作标识Job3。IP硬盘接收任务3与工作标识Job3。After 10 minutes, node B establishes a connection with the IP hard disk, and sends task 3 and job ID Job3 to the IP hard disk. The IP hard disk receives task 3 and job ID Job3.

IP硬盘确定节点B的IP地址在该IP硬盘内预置的IP地址内,于是确定节点B为可用的外部节点。IP硬盘获取保存在“中间执行结果保存区”中的上述压缩文件,将该压缩文件作为Job3的最终执行结果,并将该压缩文件输出给节点B。The IP hard disk determines that the IP address of node B is within the preset IP addresses in the IP hard disk, and thus determines that node B is an available external node. The IP hard disk obtains the above-mentioned compressed file stored in the "intermediate execution result storage area", uses the compressed file as the final execution result of Job3, and outputs the compressed file to node B.

本发明实施例还提供了相关的IP硬盘,其基本结构请参见图3,主要包括:The embodiment of the present invention also provides related IP hard disk, its basic structure sees Fig. 3, mainly comprises:

接收模块301,用于接收外部节点发送的工作任务与工作标识,该工作标识用于标识该工作任务;A receiving module 301, configured to receive a work task and a work identification sent by an external node, where the work identification is used to identify the work task;

判断模块302,用于判断外部节点是否为可用的外部节点;Judging module 302, configured to judge whether the external node is an available external node;

获取模块303,用于当外部节点为可用的外部节点时,获取该工作标识对应的中间执行结果,该中间执行结果为工作任务对应的中间执行结果;An acquisition module 303, configured to acquire an intermediate execution result corresponding to the work identifier when the external node is an available external node, where the intermediate execution result is an intermediate execution result corresponding to the work task;

结果执行模块304,用于根据中间执行结果,完成对工作任务的执行,得到工作任务对应的最终执行结果;The result execution module 304 is configured to complete the execution of the work task according to the intermediate execution result, and obtain the final execution result corresponding to the work task;

输出模块305,用于将最终执行结果发送给所述外部节点。An output module 305, configured to send the final execution result to the external node.

本实施例中,接收模块301接收外部节点发送的工作任务与工作标识;判断模块302判断所述外部节点是否是可用的外部节点;当所述外部节点是可用的外部节点时,获取模块303根据所述工作标识获得中间执行结果;结果执行模块304根据所述中间执行结果,完成对所述工作任务对应的所有执行步骤,得到所述工作任务对应的最终执行结果;输出模块305将最终执行结果发送给所述外部节点。其中,本实施例中IP硬盘在接收了外部节点发送的工作任务与工作标识后,可以根据工作标识获取该工作任务的中间执行结果,使得IP硬盘可以在后续的操作中继续使用该第一中间执行结果。这样就保证了IP硬盘中保存的中间执行结果可以在IP硬盘与可用节点建立连接后继续被使用,使得IP硬盘的中间执行结果可以输出而不会丢失,避免了IP硬盘执行结果数据的浪费。In this embodiment, the receiving module 301 receives the work task and the work identifier sent by the external node; the judging module 302 judges whether the external node is an available external node; when the external node is an available external node, the obtaining module 303 according to The work identification obtains an intermediate execution result; the result execution module 304 completes all execution steps corresponding to the work task according to the intermediate execution result, and obtains the final execution result corresponding to the work task; the output module 305 outputs the final execution result sent to the external node. Wherein, in this embodiment, after the IP hard disk receives the work task and the work identification sent by the external node, it can obtain the intermediate execution result of the work task according to the work identification, so that the IP hard disk can continue to use the first intermediate execution result in subsequent operations. Results of the. This ensures that the intermediate execution results saved in the IP hard disk can continue to be used after the IP hard disk establishes a connection with an available node, so that the intermediate execution results of the IP hard disk can be output without being lost, and the waste of execution result data on the IP hard disk is avoided.

图3所示的实施例给出了本发明提供的IP硬盘的基本结构,下面的实施例将给出IP硬盘的一种更为具体的结构,请参见图4,本发明提供的又一种IP硬盘包括:The embodiment shown in Figure 3 provides the basic structure of the IP hard disk provided by the present invention, and the following embodiments will provide a more specific structure of the IP hard disk, please refer to Figure 4, another kind of IP hard disk provided by the present invention IP hard drives include:

中间执行模块401,用于执行工作任务的多个执行步骤中的至少一个执行步骤,得到中间执行结果;An intermediate execution module 401, configured to execute at least one execution step in a plurality of execution steps of a work task, and obtain an intermediate execution result;

保存模块402,用于保存工作标识与中间执行结果的对应关系;A saving module 402, configured to save the corresponding relationship between the work identifier and the intermediate execution result;

接收模块403,用于接收外部节点发送的工作任务与工作标识,该工作标识用于标识该工作任务;A receiving module 403, configured to receive a work task and a work identification sent by an external node, where the work identification is used to identify the work task;

判断模块404,用于判断外部节点是否为可用的外部节点;Judging module 404, configured to judge whether the external node is an available external node;

优选地,判段模块404可以具体用于:将外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点。Preferably, the judgment module 404 may be specifically configured to: compare the node identifier of the external node with the node identifier of the available external node preset by the IP hard disk, if the node identifier of the external node is the same as that preset by the IP hard disk If the node identifiers of the configured available external nodes are the same, it is determined that the external node is an available external node.

获取模块405,用于当外部节点为可用的外部节点时,获取该工作标识对应的中间执行结果,该中间执行结果为工作任务对应的中间执行结果;An acquisition module 405, configured to acquire an intermediate execution result corresponding to the work identifier when the external node is an available external node, where the intermediate execution result is an intermediate execution result corresponding to the work task;

结果执行模块406,用于根据中间执行结果,完成对工作任务的执行,得到工作任务对应的最终执行结果;The result execution module 406 is configured to complete the execution of the work task according to the intermediate execution result, and obtain the final execution result corresponding to the work task;

输出模块407,用于将最终执行结果发送给该外部节点。An output module 407, configured to send the final execution result to the external node.

本实施例在图3所示的实施例的基础上提出了一种更为细化的IP硬盘,其中,中间执行模块401执行工作任务的至少一个执行步骤,得到中间执行结果,保存模块402保存中间执行结果与工作标识的对应关系。通过这样的方法,IP硬盘在接收了外部节点发送的工作任务与工作标识后,可以根据工作标识获取该工作任务的中间执行结果,使得IP硬盘可以在后续的操作中继续使用该第一中间执行结果。即使IP硬盘在执行工作任务时与其他节点断开,IP硬盘得到的中间执行结果也可以在IP硬盘与可用的外部节点建立连接后继续被使用,使得IP硬盘的中间执行结果可以输出给可用的外部节点而不会丢失,避免了IP硬盘执行结果数据的浪费。This embodiment proposes a more detailed IP hard disk on the basis of the embodiment shown in FIG. Correspondence between intermediate execution results and job identifiers. Through this method, after receiving the work task and work ID sent by the external node, the IP hard disk can obtain the intermediate execution result of the work task according to the work ID, so that the IP hard disk can continue to use the first intermediate execution in subsequent operations. result. Even if the IP hard disk is disconnected from other nodes when performing work tasks, the intermediate execution results obtained by the IP hard disk can continue to be used after the IP hard disk establishes a connection with an available external node, so that the intermediate execution results of the IP hard disk can be output to the available external nodes External nodes will not be lost, avoiding the waste of IP hard disk execution result data.

优选地,工作任务还可以包括关联标识,用于标识与所述工作任务相关联的其它任务,该关联标识可以由IP硬盘从下发该工作任务的节点处获得,也可以由该IP硬盘指定,此处不做限定。其中,与该工作任务相关联的其它任务包括:执行条件为该工作任务的最终执行结果的任务。保存模块402还可以用于:保存最终执行结果与关联标识之间的对应关系,以便于与该工作任务相关联的其它任务根据该关联标识获得所述最终执行结果,并且以该最终执行结果为执行条件,执行与所述工作任务相关联的其它任务包含的执行步骤。Preferably, the work task can also include an association identifier, which is used to identify other tasks associated with the work task, and the association identifier can be obtained by the IP hard disk from the node that issued the work task, or can be specified by the IP hard disk , is not limited here. Wherein, other tasks associated with the work task include: tasks whose execution condition is the final execution result of the work task. The saving module 402 can also be used to: save the corresponding relationship between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the final execution result according to the association identifier, and take the final execution result as The execution condition is to execute the execution steps included in other tasks associated with the work task.

为了便于理解上述实施例,下面将以上述实施例的一个具体应用场景为例进行说明:In order to facilitate understanding of the above embodiment, a specific application scenario of the above embodiment will be taken as an example for description below:

IP硬盘内预置有多个IP地址,这些IP地址对应的节点为该IP硬盘默认可用的外部节点。There are multiple IP addresses preset in the IP hard disk, and the nodes corresponding to these IP addresses are external nodes available by default for the IP hard disk.

节点A下发给IP硬盘三个工作任务,分别为任务1、任务2与任务3。其中,任务1为对目标文件1进行杀毒,任务2为对目标文件2进行杀毒,任务3为将经过杀毒的目标文件1与经过杀毒的目标文件2压缩到一个压缩文件中并输出给外部节点。Node A issues three tasks to the IP hard disk, namely task 1, task 2 and task 3. Among them, task 1 is to disinfect the target file 1, task 2 is to disinfect the target file 2, and task 3 is to compress the sterilized target file 1 and the sterilized target file 2 into a compressed file and output it to the external node .

IP硬盘接收到任务1、任务2与任务3后,为该3个任务指定工作标识分别为Job1、Job2与Job3。其中,Job1用于标识任务1、Job2用于标识任务2、Job3用于标识任务3。由于该3个任务具有相关性,所以IP硬盘指定这3个任务的关联标识均为JobListOne。After receiving task 1, task 2, and task 3, the IP hard disk specifies job IDs for the three tasks as Job1, Job2, and Job3, respectively. Wherein, Job1 is used to identify task 1, Job2 is used to identify task 2, and Job3 is used to identify task 3. Since the three tasks are related, the IP hard disk specifies that the associated identifiers of the three tasks are all JobListOne.

该IP硬盘的中间执行模块401执行任务1与任务2,即分别对目标文件1与目标文件2进行杀毒,并将杀毒后的目标文件1、目标文件1的关联标识JobListOne、目标文件2、目标文件2的关联标识JobListOne保存在硬盘划分出的专用“中间执行结果保存区”中。The middle execution module 401 of this IP hard disk executes task 1 and task 2, promptly carries out antivirus to target file 1 and target file 2 respectively, and the target file 1 after the virus removal, the association mark JobListOne of target file 1, target file 2, target The associated identifier JobListOne of file 2 is stored in the dedicated "intermediate execution result storage area" divided by the hard disk.

此时IP硬盘要执行任务3。由于任务3的关联标识JobListOne与任务1与任务2的关联标识相同,所以IP硬盘从“中间执行结果保存区”中获取Job1与Job2对应的执行结果,即经过杀毒的目标文件1与经过杀毒的目标文件2。At this time, the IP hard disk needs to perform task 3. Since the associated identifier JobListOne of task 3 is the same as the associated identifier of task 1 and task 2, the IP hard disk obtains the execution results corresponding to Job1 and Job2 from the "intermediate execution result storage area", that is, the disinfected target file 1 and the disinfected target file2.

IP硬盘的中间执行模块401执行任务3,将经过杀毒的目标文件1与经过杀毒的目标文件2压缩为一个压缩文件,保存模块402将该压缩文件与对应的工作标识Job3保存在“中间执行结果保存区”。此时节点A已经离线,IP硬盘无法输出该压缩文件。The intermediate execution module 401 of the IP hard disk executes task 3, and compresses the target file 1 and the target file 2 through the antivirus into a compressed file, and the preservation module 402 saves the compressed file and the corresponding job identification Job3 in the "intermediate execution result" storage area". At this time, node A is offline, and the IP hard disk cannot output the compressed file.

10分钟后,节点B与IP硬盘建立连接,并向IP硬盘发送任务3以及工作标识Job3。接收模块403接收任务3与工作标识Job3。After 10 minutes, node B establishes a connection with the IP hard disk, and sends task 3 and job ID Job3 to the IP hard disk. The receiving module 403 receives the task 3 and the job ID Job3.

判断模块404确定节点B的IP地址在该IP硬盘内预置的IP地址内,于是确定节点B为可用的外部节点,获取模块405获取保存在“中间执行结果保存区”中的上述压缩文件,结果执行模块406将该压缩文件作为Job3的最终执行结果,输出模块407将该压缩文件输出给节点B。Judging module 404 determines that the IP address of node B is in the IP address preset in the IP hard disk, and then determines that node B is an available external node, and obtaining module 405 obtains the above-mentioned compressed file stored in the "intermediate execution result storage area", The result execution module 406 takes the compressed file as the final execution result of Job3, and the output module 407 outputs the compressed file to Node B.

上面从单元化功能实体的角度对本发明实施例中的IP硬盘进行了描述,下面从硬件处理的角度对本发明实施例中的IP硬盘进行描述,请参阅图5,本发明实施例中的IP硬盘500另一实施例包括:The IP hard disk in the embodiment of the present invention has been described above from the perspective of unitized functional entities, and the IP hard disk in the embodiment of the present invention is described below from the perspective of hardware processing. Please refer to FIG. 5, the IP hard disk in the embodiment of the present invention Another embodiment of 500 includes:

输入装置501、输出装置502、处理器503和存储器504(其中IP硬盘500中的处理器503的数量可以一个或多个,图5中以一个处理器503为例)。在本发明的一些实施例中,输入装置501、输出装置502、处理器503和存储器504可通过总线或其它方式连接,其中,图5中以通过总线连接为例。An input device 501 , an output device 502 , a processor 503 and a memory 504 (the number of processors 503 in the IP hard disk 500 can be one or more, one processor 503 is taken as an example in FIG. 5 ). In some embodiments of the present invention, the input device 501 , the output device 502 , the processor 503 and the memory 504 may be connected through a bus or in other ways, wherein connection through a bus is taken as an example in FIG. 5 .

其中,通过调用存储器504存储的操作指令,处理器503用于执行如下步骤:接收外部节点发送的工作任务与工作标识;判断所述外部节点是否为可用的外部节点;当所述外部节点为可用的外部节点时,获取所述工作标识对应的中间执行结果;根据所述中间执行结果,完成对所述工作任务的执行,得到所述工作任务对应的最终执行结果;将所述最终执行结果发送给所述外部节点;执行所述多个执行步骤中的至少一个所述执行步骤,得到所述中间执行结果;保存所述工作标识与所述中间执行结果的对应关系;将所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点;保存所述最终执行结果与所述关联标识之间的对应关系,以便于与所述工作任务相关联的其它任务根据所述关联标识获得所述最终执行结果,并且以所述最终执行结果为执行条件,执行与所述工作任务相关联的其它任务包含的执行步骤。Wherein, by calling the operation instruction stored in the memory 504, the processor 503 is used to perform the following steps: receiving the work task and the work identification sent by the external node; judging whether the external node is an available external node; when the external node is available When the external node of the work identifier is used, the intermediate execution result corresponding to the work identifier is obtained; the execution of the work task is completed according to the intermediate execution result, and the final execution result corresponding to the work task is obtained; the final execution result is sent to to the external node; execute at least one of the execution steps in the plurality of execution steps to obtain the intermediate execution result; save the corresponding relationship between the work identifier and the intermediate execution result; The node ID is compared with the node ID of the available external node preset in the IP hard disk, and if the node ID of the external node is the same as the node ID of the available external node preset in the IP hard disk, then it is determined that the external node The node is an available external node; save the correspondence between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the final execution result according to the association identifier, and use The final execution result is an execution condition, and the execution steps included in other tasks associated with the work task are executed.

所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that for the convenience and brevity of the description, the specific working process of the above-described system, device and unit can refer to the corresponding process in the foregoing method embodiment, which will not be repeated here.

在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, device and method can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or May be integrated into another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。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 may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-OnlyMemory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the essence of the technical solution of the present invention 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 several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk, and other media that can store program codes.

以上所述,以上实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围。As mentioned above, the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: it can still understand the foregoing The technical solutions recorded in each embodiment are modified, or some of the technical features are replaced equivalently; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims (6)

1.一种IP硬盘任务执行方法,其特征在于,包括:1. A kind of IP hard disk task execution method, it is characterized in that, comprising: 网络间互连协议IP硬盘接收外部节点发送的工作任务与工作标识,所述工作标识用于标识所述工作任务;The network interconnection protocol IP hard disk receives the work task and the work identification sent by the external node, and the work identification is used to identify the work task; 所述IP硬盘判断所述外部节点是否为可用的外部节点;The IP hard disk determines whether the external node is an available external node; 当所述外部节点为可用的外部节点时,所述IP硬盘获取所述工作标识对应的中间执行结果,所述中间执行结果是所述工作任务对应的中间执行结果;When the external node is an available external node, the IP hard disk acquires an intermediate execution result corresponding to the work identifier, where the intermediate execution result is an intermediate execution result corresponding to the work task; 所述IP硬盘根据所述中间执行结果,完成对所述工作任务的执行,得到所述工作任务对应的最终执行结果;The IP hard disk completes the execution of the work task according to the intermediate execution result, and obtains the final execution result corresponding to the work task; 所述IP硬盘将所述最终执行结果发送给所述外部节点;The IP hard disk sends the final execution result to the external node; 所述工作任务包括多个执行步骤,所述IP硬盘接收外部节点发送的工作任务与工作标识之前还包括:The work task includes a plurality of execution steps, and before the IP hard disk receives the work task and the work identification sent by the external node, it also includes: 所述IP硬盘接收了其他节点下发的所述工作任务,并执行所述多个执行步骤中的至少一个所述执行步骤,得到所述中间执行结果,所述其他节点失效,导致所述中间执行结果不能输出;The IP hard disk receives the work task delivered by other nodes, and executes at least one of the execution steps in the plurality of execution steps to obtain the intermediate execution result, and the failure of the other nodes causes the intermediate The execution result cannot be output; 所述IP硬盘保存所述工作标识与所述中间执行结果的对应关系。The IP hard disk saves the corresponding relationship between the work identifier and the intermediate execution result. 2.根据权利要求1所述的IP硬盘任务执行方法,其特征在于,所述外部节点具有节点标识;2. IP hard disk task execution method according to claim 1, is characterized in that, described external node has node identification; 所述判断所述外部节点是否为可用的外部节点包括:The judging whether the external node is an available external node includes: 将所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点。Comparing the node identifier of the external node with the node identifier of the available external node preset by the IP hard disk, if the node identifier of the external node is the same as the node identifier of the available external node preset by the IP hard disk , it is determined that the external node is an available external node. 3.根据权利要求1至2中任一项所述的IP硬盘任务执行方法,其特征在于,所述工作任务包括关联标识,所述关联标识用于标识与所述工作任务相关联的其它任务;所述方法还包括:3. The IP hard disk task execution method according to any one of claims 1 to 2, wherein the work task includes an association identifier, and the association identifier is used to identify other tasks associated with the work task ; The method also includes: 保存所述最终执行结果与所述关联标识之间的对应关系,以便于与所述工作任务相关联的其它任务根据所述关联标识获得所述最终执行结果,并且以所述最终执行结果为执行条件,执行与所述工作任务相关联的其它任务包含的执行步骤。Save the corresponding relationship between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the final execution result according to the association identifier, and use the final execution result as the execution condition, execute the execution steps included in other tasks associated with the work task. 4.一种IP硬盘,其特征在于,包括:4. A kind of IP hard disk, is characterized in that, comprises: 接收模块,用于接收外部节点发送的工作任务与工作标识,所述工作标识用于标识所述工作任务;A receiving module, configured to receive a work task and a work identification sent by an external node, and the work identification is used to identify the work task; 判断模块,用于判断所述外部节点是否为可用的外部节点;A judging module, configured to judge whether the external node is an available external node; 获取模块,用于当所述外部节点为可用的外部节点时,获取所述工作标识对应的中间执行结果,所述中间执行结果是所述工作任务对应的中间执行结果;An acquisition module, configured to acquire an intermediate execution result corresponding to the work identifier when the external node is an available external node, where the intermediate execution result is an intermediate execution result corresponding to the work task; 结果执行模块,用于根据所述中间执行结果,完成对所述工作任务的执行,得到所述工作任务对应的最终执行结果;A result execution module, configured to complete the execution of the work task according to the intermediate execution result, and obtain a final execution result corresponding to the work task; 输出模块,用于将所述最终执行结果发送给所述外部节点;an output module, configured to send the final execution result to the external node; 所述工作任务包括多个执行步骤,所述IP硬盘还包括:Described working task comprises multiple execution steps, and described IP hard disk also comprises: 中间执行模块,用于接收其他节点下发的所述工作任务,执行所述多个执行步骤中的至少一个所述执行步骤,得到所述中间执行结果,所述其他节点失效,导致所述中间执行结果不能输出;an intermediate execution module, configured to receive the work task issued by other nodes, execute at least one of the execution steps in the plurality of execution steps, and obtain the intermediate execution result, and the failure of the other nodes causes the intermediate The execution result cannot be output; 保存模块,用于保存所述工作标识与所述中间执行结果的对应关系。A saving module, configured to save the corresponding relationship between the job identifier and the intermediate execution result. 5.根据权利要求4所述的IP硬盘,其特征在于,所述外部节点具有节点标识;5. IP hard disk according to claim 4, is characterized in that, described external node has node identification; 所述判断模块具体用于:The judgment module is specifically used for: 将所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识进行比较,若所述外部节点的节点标识与所述IP硬盘预置的可用的外部节点的节点标识相同,则确定所述外部节点为可用的外部节点。Comparing the node identifier of the external node with the node identifier of the available external node preset by the IP hard disk, if the node identifier of the external node is the same as the node identifier of the available external node preset by the IP hard disk , it is determined that the external node is an available external node. 6.根据权利要求4至5中任一项所述的IP硬盘,其特征在于,所述工作任务包括关联标识,所述关联标识用于标识与所述工作任务相关联的其它任务;所述保存模块还用于:6. The IP hard disk according to any one of claims 4 to 5, wherein the work task includes an association identifier, and the association identifier is used to identify other tasks associated with the work task; The save module is also used to: 保存所述最终执行结果与所述关联标识之间的对应关系,以便于与所述工作任务相关联的其它任务根据所述关联标识获得所述最终执行结果,并且以所述最终执行结果为执行条件,执行与所述工作任务相关联的其它任务包含的执行步骤。Save the corresponding relationship between the final execution result and the association identifier, so that other tasks associated with the work task can obtain the final execution result according to the association identifier, and use the final execution result as the execution condition, execute the execution steps included in other tasks associated with the work task.
CN201410219794.0A 2014-05-22 2014-05-22 IP hard disk task execution method and IP hard disk Active CN103995745B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410219794.0A CN103995745B (en) 2014-05-22 2014-05-22 IP hard disk task execution method and IP hard disk

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410219794.0A CN103995745B (en) 2014-05-22 2014-05-22 IP hard disk task execution method and IP hard disk

Publications (2)

Publication Number Publication Date
CN103995745A CN103995745A (en) 2014-08-20
CN103995745B true CN103995745B (en) 2017-09-05

Family

ID=51309919

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410219794.0A Active CN103995745B (en) 2014-05-22 2014-05-22 IP hard disk task execution method and IP hard disk

Country Status (1)

Country Link
CN (1) CN103995745B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104461817B (en) * 2014-11-26 2017-08-11 华为技术有限公司 A kind of method and server for detecting key
CN105407137B (en) * 2015-10-22 2019-07-23 华为技术有限公司 A kind of data migration method, IP hard disk, IP flaking pass and storage system
CN105700823A (en) * 2015-12-23 2016-06-22 华为技术有限公司 Method and apparatus for transmitting data between IP hard disks
CN107491265B (en) * 2016-06-12 2021-05-25 杭州海康威视数字技术股份有限公司 Method and device for distributing internet protocol IP disk
CN108804218B (en) * 2017-04-28 2021-04-06 深圳中电长城信息安全系统有限公司 Hard disk allocation method and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101964807A (en) * 2009-07-23 2011-02-02 林伟波 Use technology of network disk and method thereof
CN102246152A (en) * 2008-12-12 2011-11-16 亚马逊技术有限公司 Saving program execution state
CN103514173A (en) * 2012-06-20 2014-01-15 华为技术有限公司 Data processing method and node equipment
CN103703441A (en) * 2013-05-20 2014-04-02 华为技术有限公司 Hard disk and data processing method

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7366784B2 (en) * 2001-11-27 2008-04-29 Hitachi, Ltd. System and method for providing and using a VLAN-aware storage device
US20080154986A1 (en) * 2006-12-22 2008-06-26 Storage Technology Corporation System and Method for Compression of Data Objects in a Data Storage System

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102246152A (en) * 2008-12-12 2011-11-16 亚马逊技术有限公司 Saving program execution state
CN101964807A (en) * 2009-07-23 2011-02-02 林伟波 Use technology of network disk and method thereof
CN103514173A (en) * 2012-06-20 2014-01-15 华为技术有限公司 Data processing method and node equipment
CN103703441A (en) * 2013-05-20 2014-04-02 华为技术有限公司 Hard disk and data processing method

Also Published As

Publication number Publication date
CN103995745A (en) 2014-08-20

Similar Documents

Publication Publication Date Title
CN103995745B (en) IP hard disk task execution method and IP hard disk
CN107508795B (en) Cross-container cluster access processing device and method
CN110865867B (en) Method, device and system for discovering application topological relation
AU2014235300B2 (en) Multi-layered storage administration for flexible placement of data
CN103491134B (en) A kind of method of monitoring of containers, device and proxy server
WO2015196967A1 (en) Method and apparatus for application to permanently reside in background of operating system
WO2019184164A1 (en) Method for automatically deploying kubernetes worker node, device, terminal apparatus, and readable storage medium
CN113268308B (en) Information processing method, device and storage medium
WO2017092347A1 (en) Method, device and system for updating client configuration in memcached system
CN105512029A (en) Method, server and system for testing intelligent terminal
CN108121543B (en) Method and device for compiling and processing software code
CN111625419A (en) Log acquisition method, system, equipment and computer readable storage medium
CN107203443A (en) A kind of method and apparatus of the virtual machine High Availabitity based on KVM virtualization
CN105516266A (en) Service monitoring methods and system, and related devices
US9448827B1 (en) Stub domain for request servicing
CN103634388B (en) Controller is restarted in treatment storage server method and relevant device and communication system
CN104462488B (en) The High Availabitity of database solves method and apparatus
US9317355B2 (en) Dynamically determining an external systems management application to report system errors
CN102393838B (en) Data processing method and device, PCI-E (peripheral component interface-express) bus system, and server
CN111130828B (en) An intelligent network distribution method, device and terminal equipment
CN109600260A (en) Distributed memory system High Availabitity arrrangement method, system and device
CN103019847A (en) Method and system for migrating data of virtual machine
US20160197849A1 (en) Method and Apparatus for Implementing a Messaging Interface
CN105700823A (en) Method and apparatus for transmitting data between IP hard disks
CN111031123B (en) Spark task submission method, system, client and server

Legal Events

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