Backup task processing method and device, electronic equipment and storage medium
By interfaced encapsulation and calling the job information interface of backup tasks, the problem of cumbersome management task information of multiple backup management platforms is solved, and the effect of simplifying operations and improving efficiency is achieved.
Patent Information
- Application Number
- CN202411453238.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2025-01-10
AI Technical Summary
In the prior art, staff need to log in to multiple backup management platforms to manage task information of multiple backup tasks, resulting in cumbersome operations, error-prone and poor experience.
By interface encapsulating the backup task, the encapsulated job information interface is obtained, and the job information interface of each backup task is called through the interface call parameters, the task information is obtained, and sent to the preset display tool to display.
It simplifies staff operations, reduces the probability of errors, improves staff experience, and improves task information acquisition efficiency, avoids the process of logging in to multiple backup software.
Smart Images

Figure CN119292832A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a backup task processing method, device, electronic device and storage medium. Background Art
[0002] With the development of the information age, the amount of data in major enterprises and organizations has shown an exponential growth trend. At present, all enterprises and organizations will back up data to ensure the security of data and avoid data loss or damage due to unexpected circumstances.
[0003] In the prior art, after backing up the data, that is, completing the data backup task, it is necessary to manage the task information of the backup task on a backup management platform corresponding to the backup task, such as checking the backup result.
[0004] However, since multiple backup tasks are completed in different backup software, and the backup management platforms for managing multiple different backup software are also different, this results in the staff needing to log in to multiple backup management platforms when managing the task information of multiple backup tasks of the data. This process is cumbersome, prone to errors, and the staff experience is poor. Summary of the invention
[0005] The present application provides a backup task processing method, device, electronic device and storage medium to solve the problem in the prior art that when staff manage the task information of multiple backup tasks of data, they need to log in to multiple backup management platforms, which is cumbersome and error-prone, and the staff experience is poor.
[0006] In a first aspect, the present application provides a backup task processing method, the method comprising:
[0007] Performing interface encapsulation on the backup task to obtain a job information interface corresponding to the encapsulated backup task; wherein the number of the backup tasks is multiple, the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same;
[0008] Calling the job information interface corresponding to each of the backup tasks through the interface calling parameters to obtain the task information of the backup tasks corresponding to each of the job information interfaces; wherein the format of the task information is consistent with the output data format of the job information interface;
[0009] The task information of each backup task is sent to a preset display tool, so that the task information of each backup task is displayed on a page of the preset display tool; wherein the preset display tool is used to display the task information of the backup task on the page of the preset display tool.
[0010] In a second aspect, the present application provides a backup task processing device, the device comprising:
[0011] The encapsulation module is used to perform interface encapsulation on the backup task to obtain the job information interface corresponding to the encapsulated backup task; wherein the number of the backup tasks is multiple, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same;
[0012] A calling module, used to call the job information interface corresponding to each of the backup tasks through the interface calling parameters, and obtain the task information of the backup tasks corresponding to each of the job information interfaces; wherein the format of the task information is consistent with the output data format of the job information interface;
[0013] A display module is used to send the task information of each backup task to a preset display tool so that the task information of each backup task is displayed on the page of the preset display tool; wherein the preset display tool is used to display the task information of the backup task on the page of the preset display tool.
[0014] In a third aspect, the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the backup task processing method as described in any embodiment of the present application is implemented.
[0015] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the backup task processing method as described in any embodiment of the present application.
[0016] In a fifth aspect, the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the backup task processing method as described in any embodiment of the present application.
[0017] The scheme of the present application performs interface encapsulation on the backup task to obtain the job information interface corresponding to the encapsulated backup task; wherein, there are multiple backup tasks, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same; the job information interface corresponding to each backup task is called through the interface call parameters to obtain the task information of the backup task corresponding to each job information interface; wherein, the format of the task information is consistent with the output data format of the job information interface; the task information of each backup task is sent to the preset display tool so that the task information of each backup task is displayed on the page of the preset display tool; wherein, the preset display tool is used to display the task information of the backup task on the page of the preset display tool. That is, the scheme of the present application can encapsulate the job information interface for the backup task that completes the backup process in different backup software, and by calling the job information interface, the task information of the backup task corresponding to the job information interface can be obtained, which avoids the need for staff to obtain and manage the task information of multiple backup tasks through multiple different backup software, simplifies the staff operation, reduces the error probability, and improves the work experience of the staff. At the same time, by calling the job information interface to obtain task information, the process of logging into the backup software to obtain task information of the backup task is avoided, the task information acquisition process is simplified, and the task information acquisition efficiency is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] In order to more clearly illustrate the technical solution of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0019] Figure 1 It is a flowchart of the backup task processing method provided by this application;
[0020] Figure 2 is another flowchart of the backup task processing method provided by the present application;
[0021] Figure 3 It is a structural schematic diagram of the backup task processing device provided by the present application;
[0022] Figure 4 It is a structural schematic diagram of the electronic device provided by this application. DETAILED DESCRIPTION
[0023] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0025] Figure 1 The present invention provides a flowchart of a backup task processing method. The method can be executed by a backup task processing device, which can be implemented in software and / or hardware. In a specific embodiment, the device can be applied to an electronic device, which can be a computer. The following embodiments will be described by taking the application of the device in an electronic device as an example. Figure 1 , the method may specifically include the following steps:
[0026] Step 101, perform interface encapsulation on the backup task to obtain the job information interface corresponding to the encapsulated backup task.
[0027] There are multiple backup tasks, and the multiple backup tasks are backup tasks that complete the backup process in different backup software. The interface call parameters and output data format of the job information interface corresponding to each backup task are the same.
[0028] Specifically, interface encapsulation of the backup task means packaging the specific process and content of the backup task into a unit, so as to hide the specific process of the backup task and protect the backup method, and only expose the public interface for external objects to access. Due to different backup software, the task details of the backup task that completes the backup process and the format of the backup task may be different in different backup software. Therefore, by performing interface encapsulation on each of the multiple backup tasks, the job information interface corresponding to the encapsulated backup task can be obtained, so that external objects can access the backup task corresponding to the job information interface through each job information interface. The interface call parameters of multiple job information interfaces are the same, so that when calling multiple job information interfaces, the call can be implemented using the same interface call parameters. The output data format of multiple job information interfaces is the same, so that the output data of multiple job information interfaces can be in the same format, which is convenient for staff to read information.
[0029] Step 102: Call the job information interface corresponding to each backup task through the interface calling parameters to obtain the task information of the backup task corresponding to each job information interface.
[0030] The format of the task information is consistent with the output data format of the job information interface.
[0031] Specifically, the interface call parameters are parameters for calling the job information interface. For example, the interface call parameters can be the calling time. At this time, the job information interface is called through the interface call parameters of each job information interface to obtain the task information of the backup task corresponding to the job information interface, that is, the job information interface is called at the calling time to obtain the task information of the full backup task within the calling time. The call to the job information interface can be a request to the job information interface to obtain data, such as obtaining data through a GET request. After receiving the information requesting to obtain data, the job information interface returns the task information. The task information includes basic information that can describe the task status of the backup task, such as the task information includes the backup task name, the backup task status, and the backup result of the backup task. The format of the task information is consistent with the output data format of the job information interface, so that the task information of each backup task is in the same format, which is convenient for the staff to understand.
[0032] Optionally, the interface call parameters of the job information interface include the call time, the call execution time range start point and the call execution time range end point. Calling the job information interface corresponding to each backup task through the interface call parameters to obtain the task information of the backup task corresponding to each job information interface can be achieved by step 1021.
[0033] Step 1021: Call the job information interface corresponding to each target backup task at the calling time to obtain the task information of the target backup task corresponding to each job information interface.
[0034] The backup end time of the target backup task is greater than the start time of the call execution time range and less than the end time of the call execution time range.
[0035] Specifically, the interface call parameters of the job information interface include the call time, the call execution time range start point, and the call execution time range end point, and the job information interface is called by the call time, the call execution time range start point, and the call execution time range end point to obtain the task information of the target backup task corresponding to the job information interface at the call time, that is, the task information of the backup task that is backed up between the call execution time range start point and the call execution time range end point.
[0036] Exemplarily, the contents of the interface call parameters are shown in Table 1. In Table 1, the fields are the fields in the program corresponding to different interface call parameters after the interface is called using the Python programming language, so as to call the interface. Type is the format of the data corresponding to each interface call parameter, such as String is a string format. Description is a description of the interface call parameters. Example is an example of a possible value of an interface call parameter. For example, in Table 1, the field corresponding to the call time is applyTime, the type of the call time is a string type, and the example of the call time is 2023063000000. The field corresponding to the starting point of the call execution time range is startTime, the type of the call execution time range starting point is a string type, and the example of the call execution time range starting point is 20230614141101. The field corresponding to the end point of the call execution time range is endTime, the type of the call execution time range end point is a string type, and the example of the call execution time range end point is 20230615141101.
[0037] Table 1
[0038]
[0039]
[0040] Optionally, the data dictionaries of the multiple job information interfaces are the same. The data dictionary includes the correspondence between the coding information and the text information. Obtaining the task information of the backup task corresponding to each job information interface can be achieved through steps 1022 to 1024.
[0041] Step 1022: Obtain first coding information of the backup task corresponding to each job information interface.
[0042] Specifically, the coded information is information that is a part of the computer code or computer coding during the data transmission process, and has a high degree of difficulty in understanding. For example, the coded information of the backup type is log. Text information is text information that is easy for staff to read and understand, and is the interpretation corresponding to the coded information. For example, the text information corresponding to the coded information log is log backup. The data dictionary is definition information that can explain the coded information that is difficult to understand and obtain text information that is easier to understand, that is, it indicates the correspondence between the coded information and the text information. For example, the coded information of the backup type is full, and the corresponding text information in the data dictionary is full backup. The data dictionaries of multiple job information interfaces are the same, that is, the text information obtained according to the coded information is based on the same data dictionary, so that the staff does not need to perform secondary conversion and understanding according to the description of each backup task. After calling the job information interface, the first coded information of the backup task corresponding to each job information interface is obtained.
[0043] Exemplarily, the data dictionary of multiple job information interfaces is shown in Table 2. In Table 2, the field name is the type of part of the content in the task information, and the field is the field in the program corresponding to each field name. The data dictionary includes the correspondence between the coding information and the text information. The type is the format of the data corresponding to each field name, such as the format in Table 2 is String string format. For example, in Table 2, the field name is the backup type, the corresponding field is job_type, the data dictionary includes the coding information full, and the corresponding text information in the data dictionary is full backup. The coding information is incremental, and the corresponding text information in the data dictionary is incremental / differential backup. The coding information is log, and the corresponding text information in the data dictionary is log backup. The coding information is same_city, and the corresponding text information in the data dictionary is same-city disaster recovery. The coding information is different_place, and the corresponding text information in the data dictionary is different-place disaster recovery. The coding information is full, and the corresponding text information in the data dictionary is full backup. The field name is task status, the corresponding field is task_status, the data dictionary includes the coding information success, and the corresponding text information in the data dictionary is success. The coding information is failed, and the corresponding text information in the data dictionary is failure. The field name is execution time, the corresponding field is task_time, the data dictionary includes the coding information YMD h:m:s, and the corresponding text information in the data dictionary is year-month-day hour:minute:second. The field name is end time, the corresponding field is end_time, the data dictionary includes the coding information YM-Dh:m:s, and the corresponding text information in the data dictionary is year-month-day hour:minute:second.
[0044] Table 2
[0045]
[0046] Step 1023: Determine text information corresponding to each first encoding information according to the data dictionary of the job information interface.
[0047] Specifically, in the data dictionary of the job information interface, the text information corresponding to each first coding information is determined.
[0048] Exemplarily, the first coded information is the task status success, and the corresponding text information in the data dictionary is success, so the text information corresponding to the first coded information is the task status success.
[0049] Step 1024: determine the text information corresponding to each first coded information as task information of the backup task corresponding to each job information interface.
[0050] Specifically, after determining the text information corresponding to each first coded information according to the data dictionary of the job information interface, the text information corresponding to each first coded information is determined as the task information of the backup task corresponding to each job information interface, so that the task information is text information that is easy for the staff to read and understand, thereby enhancing the processing efficiency of the staff.
[0051] Optionally, the output data format of the job information interface is used to indicate at least one of the following: a backup task name format of the backup task, a backup type format of the backup task, a start time format of the backup task, a backup duration format of the backup task, a backup set size format of the backup task, a task status format of the backup task, an end time format of the backup task, an original size format of the backup task, and a storage size format of the backup task.
[0052] Specifically, the output data of the job information interface and the output data format of the job information interface correspond to each other, that is, when the output data format of the job information interface includes at least one of the above, the output data of the job information interface includes at least one of the backup task name of the backup task, the backup type of the backup task, the start time of the backup task, the backup duration of the backup task, the backup set size of the backup task, the task status of the backup task, the end time of the backup task, the original size of the backup task and the storage size of the backup task.
[0053] Exemplarily, the output data format of the job information interface is set through the Python language, and the correspondence between the output data and the fields in the program is that the backup job name corresponds to bk_init_name, the backup type corresponds to job_type, the start time corresponds to task_time, the backup duration corresponds to backup_cont_time, the backup set size corresponds to backup_cluster_size, the task status corresponds to task_status, the end time corresponds to end_time, the original size corresponds to orig_size, and the storage size corresponds to store_size. The program output content of Example 1 is {"task_id":123456,"bk_init_name":"XXX1","task_status":"success","job_type":"full","task_time":"2023-07-03 11:11:11","backup_cont_time":"00:11:11","orig_size":"5.0MB,"store_size":"165KB","end_time":""2023-07-03 11:22:22"}, where the content corresponding to the task_id field is the interface call number. That is, the task information output by Example 1 is that the interface call number is 123456, the backup job name is XXX1, the task status is success, the backup type is full backup, the start time is 11:11:11 on July 3, 2023, the backup duration is 00:11:11, the original size is 5.0 MB, the storage size is 165 KB, and the end time is 11:22:22 on July 3, 2023. The output data of Example 2 is {"task_id":1234565,"bk_init_name":"XXX2","task_status":"success","job_type":"log","task_time":"2023-07-03 11:11:11","backup_cont_time":"00:11:11","orig_size":"5.0MB,"store_size":"165KB","end_time":""2023-07-03 11:22:22"}, where the content corresponding to the task_id field is the interface call number.That is, the task information output by Example 2 is that the interface call number is 1234565, the backup job name is XXX2, the task status is success, the backup type is log backup, the start time is 11:11:11 on July 3, 2023, the backup duration is 00:11:11, the original size is 5.0MB, the storage size is 165KB, and the end time is 11:22:22 on July 3, 2023.
[0054] Optionally, calling the job information interface corresponding to each backup task through the interface calling parameters may be implemented through step 1025 .
[0055] Step 1025, calling the job information interface corresponding to each backup task through the interface calling parameters and the security identifier corresponding to each job information interface, so that when the job information interface determines that it is in a secure network environment according to the security identifier, it will feedback the task information of the backup task corresponding to the job information interface.
[0056] Specifically, the security identifier is the identification information corresponding to the job information interface. For example, the security identifier can be an encrypted request header information (Header X-Secret). After the job information interface receives the security identifier, if the security identifier corresponds to the job information interface, it means that the job information interface can be called and the network environment is a secure environment. If the security identifier does not correspond to the job information interface, it means that the job information interface cannot be called and the network environment is an insecure environment. Therefore, by calling the job information interface through the interface call parameters of each job information interface and the security identifier corresponding to each job information interface, the job information interface can be determined whether it is in a secure network environment according to the security identifier, and only when it is determined to be in a secure network environment, the task information of the backup task corresponding to the job information interface is fed back, thereby improving the security level of the interface call.
[0057] Step 103: Send the task information of each backup task to a preset display tool, so that the task information of each backup task is displayed on a page of the preset display tool.
[0058] The preset display tool is used to display task information of multiple backup tasks on a page of the preset display tool.
[0059] Specifically, the preset display tool is a pre-set tool capable of displaying task information. For example, the preset display tool can be a configuration management database (CMDB) tool. After obtaining the task information of the backup task corresponding to each job information interface, the task information of the obtained multiple backup tasks is displayed so that the staff can manage the task information of the multiple backup tasks. For example, a page is established in an electronic device that executes the present method to display the task information so that the staff can manage the task information of the multiple backup tasks in the page. For example, the staff can view the task execution results of the backup tasks in the page. The task information of the multiple backup tasks is sent to the preset display tool, and the preset display tool displays the task information of the multiple backup tasks in the page so that the staff can manage the task information of the multiple backup tasks in the page of the preset display tool. Moreover, displaying the task information of the multiple backup tasks in the preset display tool can improve the display efficiency of the backup tasks. The task information of the multiple backup tasks can also be stored in the preset display tool to avoid the loss of task information and improve the data security of the task information.
[0060] Optionally, after executing step 1021 , sending the task information of each backup task to a preset display tool so that the task information of each backup task is displayed on a page of the preset display tool can be achieved through step 1031 .
[0061] Step 1031 : Send the task information of each target backup task to a preset display tool, so that the task information of each target backup task is displayed on a page of the preset display tool.
[0062] Specifically, after obtaining the task information of the target backup task, the task information of the target backup task is displayed in a preset display tool, that is, only the task information of the backup tasks whose backup end time is greater than the starting point of the call execution time range and less than the end point of the call execution time range is displayed on the page of the preset display tool, which is convenient for the staff to manage the backup tasks within the time range and avoids the redundant work of calling all backup tasks.
[0063] The scheme of the present application, through the interface call parameters of each job information interface, calls the job information interface to obtain the task information of the backup task corresponding to the job information interface; wherein the job information interface is an interface obtained after pre-interface encapsulation of one of the multiple backup tasks, the format of the task information is consistent with the output data format of the job information interface, the interface call parameters of the multiple job information interfaces are the same, and the output data formats of the multiple job information interfaces are the same; the task information of the multiple backup tasks is displayed so that the staff can manage the task information of the multiple backup tasks. That is, the scheme of the present application, through calling the job information interface, obtains and displays the task information of the backup task corresponding to the job information interface, avoids the staff from obtaining and managing the task information of multiple backup tasks through multiple backup management platforms, simplifies the staff operation, reduces the probability of error, and improves the staff's work experience. At the same time, it simplifies the task information acquisition process and improves the efficiency of task information acquisition.
[0064] Figure 2 is another flowchart of the backup task processing method provided by the present application. Figure 1 Based on the illustrated embodiment and various optional implementation schemes, the operation of the backup failed task is described in detail. Figure 2 As shown, the method may include the following steps:
[0065] Step 201 , perform interface encapsulation on the backup task to obtain the job information interface corresponding to the encapsulated backup task.
[0066] Step 202: Call the job information interface corresponding to each backup task through the interface calling parameters to obtain the task information of the backup task corresponding to each job information interface.
[0067] Step 203: Determine the failed backup task according to the task information of the backup task.
[0068] Specifically, the task information of the backup task includes the task status of the backup task, and the task status includes backup success and backup failure, so the backup task includes backup success task and backup failure task. According to the task status in the task information, the backup failure task is determined.
[0069] Step 204: perform interface encapsulation on the backup failure task to obtain a backup failure alarm interface corresponding to the encapsulated backup failure task.
[0070] There are multiple backup failure tasks, and the interface calling method and the pushed data format of the backup failure alarm interface corresponding to each backup failure task are the same.
[0071] Specifically, after performing interface encapsulation on the backup failure task, a backup failure alarm interface is obtained. The interface calling method of the backup failure alarm interface is a method of sending a data request to the backup failure alarm interface, such as sending a post request or a get request. The interface calling methods of multiple backup failure alarm interfaces are the same, so that the backup failure alarm interfaces of multiple backup failure tasks can be called through the same interface calling method. The push data format of multiple backup failure alarm interfaces is the same, and the format of the backup failure alarm information is consistent with the push data format, so that the format of the backup failure alarm information is the same, which is convenient for staff or users to read and understand.
[0072] Step 205: Call the backup failure alarm interface corresponding to each backup failure task through an interface calling method to obtain the device identifier of the user device corresponding to each backup failure task and the backup failure alarm information.
[0073] The format of the backup failure alarm information is consistent with the push data format.
[0074] Specifically, according to the task information of the failed backup task, the user device corresponding to the failed backup task is determined, and the backup failure alarm information is sent to the user device corresponding to the failed backup task. The user device corresponding to the failed backup task can be a staff device corresponding to the failed backup task, which is convenient for the staff to handle the failed backup task. Through the interface calling method of the backup failure alarm interface of each failed backup task, multiple backup failure alarm interfaces are called using the same interface calling method to obtain the device identification of the user device corresponding to each failed backup task and the backup failure alarm information.
[0075] Exemplarily, the backup failure alarm information is information including content related to the backup failure, for example, the backup failure alarm information includes an alarm identifier, a task name of the backup failure task, a task status of the backup failure task, a backup content of the backup failure task, a failure time of the backup failure task, a backup failure reason of the backup failure task, and a device identifier of a user device corresponding to the failed backup task. According to the task information of the backup failure task, it is determined that the user device corresponding to the backup failure task is device A, and the backup failure alarm information is sent to device A.
[0076] Exemplarily, the backup failure alarm information includes the content as shown in Table 3. In Table 3, the backup failure alarm information consists of multiple contents. The field is the field in the program corresponding to the content of each backup failure alarm information after calling the interface using the Python program language, so as to read the corresponding backup failure alarm information. The type is the format of the data corresponding to each information, such as String is a string format, and int is an integer format. The description is a part that describes the content of the backup failure alarm information, which is convenient for understanding the failure alarm information. The example is an output example of a possible backup failure alarm information in this content part. For example, in Table 3, the field in the program corresponding to the part of the content being the alarm identifier is event_id, the type of the alarm identifier is a string type, and the example of the alarm identifier is a randomly generated string of numbers 83b0fa0cbb2aafab0. The field in the program corresponding to the part of the content being the task name is bk_init_name, the type of the task name is a string type, and the example of the task name is 192.168.1.1_file_full backup every Saturday, incremental backup every day. The field in the program corresponding to the part with the content of task status is event_type, the type of task status is string type, and the example of task status is failure. The field in the program corresponding to the part with the content of backup content is event_theme, the type of backup content is string type, and the example of backup content is backup data information. The field in the program corresponding to the part with the content of failure occurrence time YYYY-MM-DD HH:mm:ss is event_time, the type of failure occurrence time is string type, and the example of failure occurrence time is 2024 / 5 / 22 16:15. The field in the program corresponding to the part with the content of failure reason is event_content, the type of failure reason is string type, and the example of failure reason is unable to obtain backup path. The field in the program corresponding to the part with the content of device identification is bk_obj_id, the type of device identification is integer type, and the example of device identification is 192.168.1.1.
[0077] Table 3
[0078]
[0079] Optionally, the push data format of the backup failure alarm interface includes at least one of the following: an alarm identification format, a backup task name format corresponding to the failed backup task, a backup status format corresponding to the failed backup task, a backup content format corresponding to the failed backup task, a failure occurrence time format corresponding to the failed backup task, a failure reason format corresponding to the failed backup task, and a device identification format of the user device corresponding to the failed backup task.
[0080] Specifically, the backup failure alarm information and the push data format of the backup failure alarm interface correspond to each other, that is, when the push data format of the backup failure alarm interface includes at least one of the above, the backup failure alarm information includes the alarm identifier, the backup task name corresponding to the failed backup task, the backup status corresponding to the failed backup task, the backup content corresponding to the failed backup task, the failure occurrence time corresponding to the failed backup task, the failure reason corresponding to the failed backup task and at least one of the device identifier of the user device corresponding to the failed backup task.
[0081] Exemplarily, the alarm identifier format is a string format, and the alarm identifier is 001. The backup task name format corresponding to the failed backup task is a string format, and the backup task name corresponding to the failed backup task is the backup of backup task A. The backup status format corresponding to the failed backup task is a string format, and the backup status corresponding to the failed backup task is backup failure. The backup content format corresponding to the failed backup task is a string format, and the backup content corresponding to the failed backup task is the content of the data in the backup task. The failure occurrence time format corresponding to the failed backup task is a string format, and the failure occurrence time of the failed backup task. The failure reason format corresponding to the failed backup task is a string format, and the failure reason corresponding to the failed backup task is insufficient backup space. The device identifier format of the user device corresponding to the failed backup task is an integer format, and the device identifier of the user device corresponding to the failed backup task is 111.
[0082] Step 206: Send backup failure alarm information to the user equipment corresponding to each backup failed task according to the device identifier of the user equipment corresponding to each backup failed task.
[0083] Specifically, after determining the device identifier of the user equipment corresponding to the failed backup task, the backup failure alarm information is sent to the user equipment corresponding to the failed backup task according to the device identifier of the user equipment corresponding to the failed backup task.
[0084] Step 207: Send the task information of each backup task to the preset display tool, so that the task information of each backup task is displayed on the page of the preset display tool.
[0085] The solution of the present application obtains the user device identifier and backup failure alarm information by calling the backup failure alarm interface, and then sends the backup failure alarm information to the user device corresponding to the backup failure task, so that the user device identifier and failure alarm information can only be obtained through the backup failure alarm interface, further improving the security of access to the backup task, and enabling the user corresponding to the backup failure task to understand the backup failure situation.
[0086] Figure 3Schematic diagram of a backup task processing device provided by the present application, which is suitable for executing the backup task processing method provided by the present application. Figure 3 As shown, the device may specifically include:
[0087] The encapsulation module 301 is used to perform interface encapsulation on the backup task to obtain a job information interface corresponding to the encapsulated backup task; wherein, there are multiple backup tasks, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same.
[0088] The calling module 302 is used to call the job information interface corresponding to each backup task through the interface calling parameters to obtain the task information of the backup task corresponding to each job information interface; wherein the format of the task information is consistent with the output data format of the job information interface.
[0089] The display module 303 is used to send the task information of each backup task to the preset display tool so that the task information of each backup task is displayed on the page of the preset display tool; wherein the preset display tool is used to display the task information of the backup task on the page of the preset display tool.
[0090] In one embodiment, the interface calling parameters of the job information interface of the encapsulation module 301 include the calling time, the starting point of the calling execution time range, and the end point of the calling execution time range; the calling module 302 is specifically used to: call the job information interface corresponding to each target backup task at the calling time, and obtain the task information of the target backup task corresponding to each of the job information interfaces; wherein the backup end time of the target backup task is greater than the starting point of the calling execution time range, and less than the end point of the calling execution time range; the display module 303 is specifically used to: send the task information of each of the target backup tasks to a preset display tool, so that the task information of each of the target backup tasks is displayed on the page of the preset display tool.
[0091] In one embodiment, the data dictionaries of multiple job information interfaces are the same; the data dictionary includes the correspondence between coding information and text information; the calling module 302 is specifically used to obtain the task information of the backup task corresponding to each job information interface, specifically to: obtain the first coding information of the backup task corresponding to each job information interface; determine the text information corresponding to each first coding information according to the data dictionary of the job information interface; determine the text information corresponding to each first coding information as the task information of the backup task corresponding to each job information interface.
[0092] In one embodiment, the output data format of the job information interface of the encapsulation module 301 is used to indicate at least one of the following: the backup task name format of the backup task, the backup type format of the backup task, the start time format of the backup task, the backup duration format of the backup task, the backup set size format of the backup task, the task status format of the backup task, the end time format of the backup task, the original size format of the backup task, and the storage size format of the backup task.
[0093] In one embodiment, the calling module 302, in terms of calling the job information interface corresponding to each of the backup tasks through the interface calling parameters, is specifically used to: call the job information interface corresponding to each of the backup tasks through the interface calling parameters and the security identifier corresponding to each of the job information interfaces, so that when the job information interface determines that it is in a secure network environment based on the security identifier, it feeds back the task information of the backup task corresponding to the job information interface.
[0094] In one embodiment, the device also includes: a backup failure determination module, which is used to determine the backup failure task according to the task information of the backup task after the calling module 301 obtains the task information of the backup task corresponding to each of the job information interfaces; a failure encapsulation module, which is used to perform interface encapsulation on the backup failure task to obtain a backup failure alarm interface corresponding to the encapsulated backup failure task; wherein, the number of the backup failure tasks is multiple, and the interface calling method and the push data format of the backup failure alarm interface corresponding to each of the backup failure tasks are the same; a failure calling module, which is used to call the backup failure alarm interface corresponding to each of the backup failure tasks through the interface calling method to obtain the device identification of the user device corresponding to each of the backup failure tasks and the backup failure alarm information; wherein, the format of the backup failure alarm information is consistent with the push data format; a sending module, which is used to send the backup failure alarm information to the user device corresponding to the backup failure task according to the device identification of the user device corresponding to each of the backup failure tasks.
[0095] In one embodiment, the push data format of the backup failure alarm interface of the failure encapsulation module includes at least one of the following: an alarm identification format, a backup task name format corresponding to the failed backup task, a backup status format corresponding to the failed backup task, a backup content format corresponding to the failed backup task, a failure occurrence time format corresponding to the failed backup task, a failure reason format corresponding to the failed backup task, and a device identification format of the user device corresponding to the failed backup task.
[0096] The device of the present application performs interface encapsulation on the backup task to obtain the job information interface corresponding to the encapsulated backup task; wherein, the number of backup tasks is multiple, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same; the job information interface corresponding to each backup task is called through the interface call parameters to obtain the task information of the backup task corresponding to each job information interface; wherein, the format of the task information is consistent with the output data format of the job information interface; the task information of each backup task is sent to the preset display tool so that the task information of each backup task is displayed on the page of the preset display tool; wherein, the preset display tool is used to display the task information of the backup task on the page of the preset display tool. That is, the scheme of the present application can encapsulate the job information interface for the backup task that completes the backup process in different backup software, and by calling the job information interface, the task information of the backup task corresponding to the job information interface can be obtained, which avoids the need for staff to obtain and manage the task information of multiple backup tasks through multiple different backup software, simplifies the staff operation, reduces the error probability, and improves the work experience of the staff. At the same time, by calling the job information interface to obtain task information, the process of logging into the backup software to obtain task information of the backup task is avoided, the task information acquisition process is simplified, and the task information acquisition efficiency is improved.
[0097] The present application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the backup task processing method provided in any of the above embodiments when executing the program.
[0098] The present application also provides a computer-readable medium on which a computer program is stored. When the program is executed by a processor, the backup task processing method provided in any of the above embodiments is implemented.
[0099] Reference below Figure 4 , which shows a structural schematic diagram of an electronic device 400 suitable for implementing the present application. Figure 4 The electronic device shown is only an example and should not bring any limitation to the function and scope of use of the present application.
[0100] like Figure 4As shown, the electronic device 400 includes a central processing unit (CPU) 401, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 402 or a program loaded from a storage part 408 into a random access memory (RAM) 403. In the RAM 403, various programs and data required for the operation of the electronic device 400 are also stored. The CPU 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.
[0101] The following components are connected to the I / O interface 405: an input section 406 including a keyboard, a mouse, etc.; an output section 407 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 408 including a hard disk, etc.; and a communication section 409 including a network interface card such as a LAN card, a modem, etc. The communication section 409 performs communication processing via a network such as the Internet. A drive 410 is also connected to the I / O interface 405 as needed. A removable medium 411, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 410 as needed, so that a computer program read therefrom is installed into the storage section 408 as needed.
[0102] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 409, and / or installed from the removable medium 411. When the computer program is executed by the central processing unit (CPU) 401, the above-mentioned functions defined in the system of the present application are executed.
[0103] It should be noted that the computer-readable medium shown in the present application may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0104] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the above-mentioned module, program segment or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0105] The modules and / or units described in this application may be implemented in software or hardware. The modules and / or units described may also be set in a processor, for example, it may be described as: a processor includes a packaging module, a calling module and a display module. The names of these modules do not, in some cases, constitute limitations on the modules themselves.
[0106] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device performs the following operations:
[0107] Perform interface encapsulation on the backup task to obtain a job information interface corresponding to the encapsulated backup task; wherein, there are multiple backup tasks, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface calling parameters and output data format of the job information interface corresponding to each backup task are the same; call the job information interface corresponding to each backup task through the interface calling parameters to obtain task information of the backup task corresponding to each job information interface; wherein the format of the task information is consistent with the output data format of the job information interface; send the task information of each backup task to a preset display tool, so that the task information of each backup task is displayed on the page of the preset display tool; wherein the preset display tool is used to display the task information of the backup task on the page of the preset display tool.
[0108] According to the technical solution of the present invention, the backup task is interface encapsulated to obtain the job information interface corresponding to the encapsulated backup task; wherein, the number of backup tasks is multiple, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same; the job information interface corresponding to each backup task is called through the interface call parameters to obtain the task information of the backup task corresponding to each job information interface; wherein, the format of the task information is consistent with the output data format of the job information interface; the task information of each backup task is sent to the preset display tool so that the task information of each backup task is displayed on the page of the preset display tool; wherein, the preset display tool is used to display the task information of the backup task on the page of the preset display tool. That is, the solution of the present application can encapsulate the job information interface for the backup task that completes the backup process in different backup software, and by calling the job information interface, the task information of the backup task corresponding to the job information interface can be obtained, which avoids the need for staff to obtain and manage the task information of multiple backup tasks through multiple different backup software, simplifies the staff operation, reduces the error probability, and improves the work experience of the staff. At the same time, by calling the job information interface to obtain task information, the process of logging into the backup software to obtain task information of the backup task is avoided, the task information acquisition process is simplified, and the task information acquisition efficiency is improved.
[0109] An embodiment of the present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the backup task processing method provided in any embodiment of the present application.
[0110] In the process of implementation, the computer program product can be written in one or more programming languages or a combination thereof to perform the computer program code of the present application, and the programming language includes an object-oriented programming language, such as Java, Smalltalk, C++, and also includes a conventional procedural programming language, such as "C" language or similar programming language. The program code can be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on the remote computer, or completely on the remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, using an Internet service provider to connect through the Internet).
[0111] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.
[0112] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A backup task processing method, characterized in that: The method comprises: Performing interface encapsulation on the backup task to obtain a job information interface corresponding to the encapsulated backup task; wherein the number of the backup tasks is multiple, the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same; Calling the job information interface corresponding to each of the backup tasks through the interface calling parameters to obtain the task information of the backup tasks corresponding to each of the job information interfaces; wherein the format of the task information is consistent with the output data format of the job information interface; The task information of each backup task is sent to a preset display tool, so that the task information of each backup task is displayed on a page of the preset display tool; wherein the preset display tool is used to display the task information of the backup task on the page of the preset display tool.
2. The method according to claim 1, characterized in that: The interface call parameters of the job information interface include the call time, the call execution time range start point and the call execution time range end point; The step of calling the job information interface corresponding to each of the backup tasks through the interface calling parameters to obtain the task information of the backup tasks corresponding to each of the job information interfaces includes: Calling the job information interface corresponding to each target backup task at the calling time to obtain the task information of the target backup task corresponding to each job information interface; wherein the backup end time of the target backup task is greater than the starting point of the calling execution time range and less than the end point of the calling execution time range; The sending the task information of each backup task to a preset display tool so that the task information of each backup task is displayed on a page of the preset display tool includes: The task information of each target backup task is sent to a preset display tool, so that the task information of each target backup task is displayed on a page of the preset display tool.
3. The method according to claim 1, characterized in that The data dictionaries of the plurality of operation information interfaces are all the same; the data dictionary includes the correspondence between the coding information and the text information; The step of obtaining the task information of the backup task corresponding to each of the job information interfaces includes: Acquire first coding information of the backup task corresponding to each of the job information interfaces; Determine text information corresponding to each of the first coding information according to the data dictionary of the job information interface; The text information corresponding to each of the first coding information is determined as the task information of the backup task corresponding to each of the job information interfaces.
4. The method according to claim 1, characterized in that: The output data format of the job information interface is used to indicate at least one of the following: the backup task name format of the backup task, the backup type format of the backup task, the start time format of the backup task, the backup duration format of the backup task, the backup set size format of the backup task, the task status format of the backup task, the end time format of the backup task, the original size format of the backup task, and the storage size format of the backup task.
5. The method according to claim 1, characterized in that The calling of the job information interface corresponding to each backup task through the interface calling parameter includes: The job information interface corresponding to each of the backup tasks is called through the interface calling parameters and the security identifier corresponding to each of the job information interfaces, so that when the job information interface determines that it is in a secure network environment based on the security identifier, it will feedback the task information of the backup task corresponding to the job information interface.
6. The method according to claim 1, characterized in that After obtaining the task information of the backup task corresponding to each of the job information interfaces, the method further includes: Determine the failed backup task according to the task information of the backup task; Performing interface encapsulation on the backup failure task to obtain a backup failure alarm interface corresponding to the encapsulated backup failure task; wherein the number of the backup failure tasks is multiple, and the interface calling method and the push data format of the backup failure alarm interface corresponding to each backup failure task are the same; Calling the backup failure alarm interface corresponding to each of the backup failure tasks through the interface calling method, obtaining the device identifier of the user device corresponding to each of the backup failure tasks and the backup failure alarm information; wherein the format of the backup failure alarm information is consistent with the push data format; The backup failure alarm information is sent to the user equipment corresponding to each of the backup failure tasks according to the device identifier of the user equipment corresponding to the backup failure task.
7. The method according to claim 6, characterized in that The push data format of the backup failure alarm interface includes at least one of the following: an alarm identification format, a backup task name format corresponding to the failed backup task, a backup status format corresponding to the failed backup task, a backup content format corresponding to the failed backup task, a failure occurrence time format corresponding to the failed backup task, a failure reason format corresponding to the failed backup task, and a device identification format of the user device corresponding to the failed backup task.
8. A backup task processing device, characterized in that: The device comprises: The encapsulation module is used to perform interface encapsulation on the backup task to obtain the job information interface corresponding to the encapsulated backup task; wherein the number of the backup tasks is multiple, and the multiple backup tasks are backup tasks that complete the backup process in different backup software, and the interface call parameters and output data format of the job information interface corresponding to each backup task are the same; A calling module, used to call the job information interface corresponding to each of the backup tasks through the interface calling parameters, and obtain the task information of the backup tasks corresponding to each of the job information interfaces; wherein the format of the task information is consistent with the output data format of the job information interface; A display module is used to send the task information of each backup task to a preset display tool so that the task information of each backup task is displayed on the page of the preset display tool; wherein the preset display tool is used to display the task information of the backup task on the page of the preset display tool.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the backup task processing method according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the backup task processing method as described in any one of claims 1 to 7 is implemented.