Method, device, server and medium for processing business and metadata in parallel
By pre-configuring metadata synchronization tasks and using metadata synchronization bitmaps, parallel processing of business and metadata synchronization is achieved when the controller leaves or joins the cluster. This solves the business interruption problem caused by metadata synchronization and ensures business continuity and user experience.
Patent Information
- Application Number
- CN202211107045.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-09
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2042-09-09
AI Technical Summary
When a controller leaves or joins a cluster, metadata synchronization causes a temporary interruption in business processing, affecting business continuity and user experience.
Pre-configure metadata synchronization tasks, obtain metadata information from the data source, use the metadata synchronization bitmap to record the synchronization progress, and control the parallel processing of business and metadata synchronization.
Business operations are not interrupted during metadata synchronization, ensuring business continuity and improving user experience.
Smart Images

Figure CN115657934B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of servers, and in particular to a method and device for parallel processing of business and metadata synchronization, a server and a medium. BACKGROUND
[0002] A redundant array of independent disks (RAID) uses multiple independent disks to form a disk system to achieve better storage performance and higher reliability than a single disk. A multi-controller RAID system uses multiple controllers to jointly process user read and write operations, achieving performance and security stacking of multiple controllers and preventing single-point failures. The RAID needs to perform data configuration and recovery tasks, which relies on recorded metadata of a stripe. The metadata is managed according to the address space state in units of stripes. Fixed address metadata is usually managed by two controllers, including a main controller that processes read and write operations and a partner controller that synchronously backs up data. When a controller exits or joins the cluster, the main controller or partner controller of a certain address space needs to be changed, and the metadata needs to be resynchronized according to the new partnership so that the metadata can be redundantly backed up.
[0003] Currently, when a controller exits or joins the cluster, the metadata needs to be synchronized for a period of time before the space can be operated, that is, the metadata synchronization when the controller exits or joins the cluster will cause temporary interruption of business processing, affecting the continuity of the business and the user experience.
[0004] Therefore, how to ensure the continuity of the business during the metadata synchronization process is a technical problem that needs to be solved by those skilled in the art. SUMMARY
[0005] The purpose of the present application is to provide a method and device for parallel processing of business and metadata synchronization, a server and a medium, which can ensure the continuity of the business during the metadata synchronization process.
[0006] To solve the above technical problems, the present application provides a method for parallel processing of business and metadata synchronization, comprising:
[0007] Obtaining a data source for configuration, wherein the data source contains the metadata;
[0008] Configuring a metadata synchronization task according to the metadata in the data source;
[0009] In the case where the metadata synchronization task is completed, controlling the business and the metadata synchronization task to be processed in parallel.
[0010] Preferably, the configuring the metadata synchronization task according to the metadata in the data source comprises:
[0011] acquiring a space size of the metadata from the data source;
[0012] applying a space of the metadata and a metadata synchronization bitmap according to the space size of the metadata; wherein the metadata synchronization bitmap records a progress of the metadata synchronization;
[0013] configuring the metadata synchronization bitmap;
[0014] configuring the metadata synchronization task according to the metadata synchronization bitmap.
[0015] Preferably, the controlling the business and the metadata synchronization task to be processed in parallel comprises:
[0016] in a case that the business is recorded in a task list and there is an address space to be taken over, judging whether the metadata synchronization bitmap is empty;
[0017] if not, reading and storing the metadata from the data source;
[0018] reading the metadata and processing read-write operations according to the metadata.
[0019] Preferably, the reading and storing the metadata from the data source comprises:
[0020] sending information of reading the metadata to the data source;
[0021] receiving the metadata of a preset length returned by the data source; wherein the preset length is less than or equal to a maximum value of data transmissible between a controller and the data source.
[0022] Preferably, the method further comprises:
[0023] in a case that the business is recorded in a task list and there is an address space to be taken over, preferentially executing the metadata synchronization task.
[0024] Preferably, the method further comprises:
[0025] in a case that the business causes metadata update of a RAID task, judging whether the metadata synchronization is completed;
[0026] if not, synchronizing the metadata; and after the metadata synchronization is completed, updating the metadata of the RAID task.
[0027] Preferably, the method further comprises:
[0028] In the metadata synchronization process, a controller exiting from the cluster is detected;
[0029] It is judged whether the controller exiting from the cluster is the data source;
[0030] If yes, the controller exiting from the cluster is waited to recover;
[0031] After the data source recovers, the step of controlling the business and the metadata synchronization task to be processed in parallel is entered.
[0032] To solve the above technical problems, the application further provides a device for processing business and metadata in parallel, comprising:
[0033] An acquisition module is configured to acquire a configured data source; wherein the data source contains the metadata;
[0034] A configuration module is configured to configure a metadata synchronization task according to the metadata in the data source;
[0035] A control module is configured to control the business and the metadata synchronization task to be processed in parallel when the configuration of the metadata synchronization task is completed.
[0036] To solve the above technical problems, the application further provides a server, comprising:
[0037] A memory is configured to store a computer program;
[0038] A processor is configured to execute the computer program to realize the steps of the method for processing business and metadata in parallel.
[0039] To solve the above technical problems, the application further provides a computer readable storage medium, wherein the computer readable storage medium stores a computer program, and the computer program is executed by a processor to realize the steps of the method for processing business and metadata in parallel.
[0040] The method for processing business and metadata in parallel provided by the application comprises the following steps: acquiring a configured data source; wherein the configured data source contains metadata; configuring a metadata synchronization task according to the metadata in the configured data source; and controlling the business and the metadata synchronization task to be processed in parallel when the configuration of the metadata synchronization task is completed. In the previous metadata synchronization process, a business operation needs to be paused to acquire metadata information, which leads to the interruption of the business during the metadata synchronization process. However, in the method of the application, the metadata information is configured in advance before the metadata task, so that the business does not need to be interrupted to acquire the metadata information when the metadata task is performed, and the business can be processed in parallel with the metadata, thereby ensuring the continuity of the business and improving the user experience.
[0041] Further, the application also provides a device for processing business and metadata synchronously in parallel, a server and a computer readable storage medium, which have the same or corresponding technical features and effects as the method for processing business and metadata synchronously in parallel. BRIEF DESCRIPTION OF DRAWINGS
[0042] In order to more clearly illustrate the embodiments of the present application, the drawings needed in the embodiments will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0043] Figure 1 A flow chart of a method for processing business and metadata synchronously in parallel is provided for an embodiment of the present application.
[0044] Figure 2 A structure diagram of a device for processing business and metadata synchronously in parallel is provided for an embodiment of the present application.
[0045] Figure 3 A structure diagram of a server is provided for another embodiment of the present application. DETAILED DESCRIPTION
[0046] The technical solutions in the embodiments of the present application will be described clearly and completely in combination with the drawings in the embodiments of the present application. Obviously, the described embodiments are only some embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the present application.
[0047] The core of the present application is to provide a method, device, server and medium for processing business and metadata synchronously in parallel, which is used to ensure the continuity of business in the process of metadata synchronization.
[0048] RAID uses multiple independent disks to form a disk system to achieve better storage performance and higher reliability than single disk. Multi-controller RAID system uses multiple controllers to process user read and write operations together, to realize performance superposition, security superposition of multiple controllers, and to prevent single point failure. RAID needs to perform data configuration and recovery tasks, which depends on the recorded metadata of the stripe. The metadata manages the address space state according to the stripe. For example, the formatting task needs to record whether the stripe has been formatted, to ensure data consistency while avoiding multiple formatting. A bitmap is used, where 0 in the nth bit describes that the nth stripe has been formatted.
[0049] The plurality of controllers access the address space of the RAID to divide the address space into the plurality of controllers, and isolate the address space to avoid cross-domain information. Therefore, the fixed address metadata has two controllers, including a master controller for processing read and write operations and a partner controller for synchronously backing up the metadata. When a controller exits or joins the cluster, the master controller or the partner controller of a block of address space changes, and the metadata needs to be re-synchronized according to the new partnership. In order to ensure the continuity of the service as much as possible during the metadata synchronization process, in the embodiment, the metadata information is configured in advance before the metadata task is performed, so that the metadata synchronization does not need to be performed under the condition of interrupting the service.
[0050] In order for those skilled in the art to better understand the scheme of the present application, the present application will be further described in detail below in combination with the drawings and specific embodiments. Figure 1 A flowchart of a method for parallel processing of a service and metadata synchronization provided by an embodiment of the present application is shown in Figure 1 The method comprises the following steps.
[0051] S10: Obtain a data source for configuration; wherein the data source contains metadata;
[0052] S11: Configure a metadata synchronization task according to the metadata in the data source;
[0053] S12: Control parallel processing of the service and the metadata synchronization task in the case of completing the configuration of the metadata synchronization task.
[0054] The fixed address metadata is usually managed by two controllers, including a master controller for processing read and write operations and a partner controller for synchronously backing up the metadata. Specifically, a block of address space belongs to a controller, which is referred to as the master controller of the block of address space. The metadata backup node of the master controller of a block of address space takes over the block of address space of the master controller when the master controller exits the cluster. After the controller exits, the metadata exists only in the partner controller of the previous partnership with the controller. When a new controller is added, in order to prevent the metadata in the partner controller from being lost, the metadata in the partner controller needs to be synchronized to the newly added controller. For example, initially, the metadata is managed by controller A and controller C. However, if controller A exits, only controller C has metadata. In order to prevent the loss of metadata due to the failure of controller C, controller B is additionally added, that is, controller B needs to replace the original controller A. After controller B joins the cluster, controller B has no metadata. Therefore, the metadata in controller C needs to be synchronized to controller B. Controller B configures a data source according to the new and old partnership. The data source is the target of metadata reading, and can be a master controller or a partner controller.
[0055] Since the previous metadata synchronization process needs to suspend the business to obtain the information of the metadata, which leads to the interruption of the business, the information of the metadata is configured in advance in the embodiment. That is, after the data source is obtained, the controller B configures the metadata synchronization task according to the metadata. After the configuration of the metadata synchronization task is completed, the business and the metadata synchronization task can be executed in parallel.
[0056] The metadata synchronization of the controller is kept consistent through the inter-controller message. When the controller needs to modify the metadata, the metadata is updated in the controller itself and the target node (partner controller) synchronously. When the controller exits or joins the cluster, the controller synchronization relationship is reorganized, the metadata is re-synchronized according to the new address space attribution, and the controller reads the metadata update to the controller according to the new partner relationship. When the metadata synchronization is completed, the metadata of the controller and the partner node is consistent.
[0057] The method for parallel processing of the business and the metadata synchronization provided by the embodiment comprises: obtaining a configuration data source; wherein the configuration data source contains metadata; configuring a metadata synchronization task according to the metadata in the configuration data source; and controlling the parallel processing of the business and the metadata synchronization task in the case of completing the configuration of the metadata synchronization task. In the previous metadata synchronization process, since the business operation needs to be suspended to obtain the information of the metadata, the business is interrupted in the metadata synchronization process. In the method of the embodiment, the information of the metadata is configured in advance before the metadata task, so that the information of the metadata does not need to be obtained by interrupting the business when the metadata task is performed. Therefore, the business can be performed in parallel with the metadata synchronization, the continuity of the business is ensured, and the user experience is improved.
[0058] In the implementation, in order to understand the synchronization progress of the metadata, the preferred implementation mode is that configuring the metadata synchronization task according to the metadata in the data source comprises:
[0059] Obtaining the space size of the metadata from the data source;
[0060] Applying the space of the metadata and the metadata synchronization bitmap according to the space size of the metadata; wherein the metadata synchronization bitmap records the progress of the metadata synchronization;
[0061] Configuring the metadata synchronization bitmap;
[0062] Configuring the metadata synchronization task according to the metadata synchronization bitmap.
[0063] Since there is metadata in the data source, the spatial size of the metadata is first obtained from the data source in the process of configuring the metadata synchronization task, and after the spatial size of the metadata is obtained, the newly added controller can apply for appropriate metadata space to ensure that the metadata can be accommodated. In addition, in order to understand the synchronization progress of the metadata, a metadata synchronization bitmap is used to record the progress of the metadata synchronization.
[0064] According to the reorganized metadata synchronization relationship, it is assumed that controller B needs to read metadata from other controllers:
[0065] 1. Controller B configures the data source according to the new and old partnership. The data source is the target of metadata reading, and can be a master controller or a partner controller.
[0066] 2. Controller B reads the data source metadata space size, applies for the controller metadata space according to the metadata space size, and applies for the metadata synchronization bitmap according to the metadata space size.
[0067] 3. Controller B configures the metadata synchronization bitmap: detects the task list, wherein the task list records the data configuration and recovery tasks of the current RAID, when the task list is empty, it is described that all the stripes of the current RAID are in consistent normal operation, and any data configuration and recovery is not needed, the task list of the controller is kept consistent through the cluster algorithm, and all the controllers in the cluster stop processing the business when the task list of the controller is changed; when the list change is completed, the controller resumes processing the business. If the task list is empty, the metadata synchronization bitmap is cleared, and the metadata synchronization is completed; otherwise, the task being executed in the task list is read, and the metadata synchronization bitmap without the task being executed is cleared.
[0068] 4. Controller B configures the metadata synchronization task, which reads the metadata of the source controller to the current controller according to the metadata synchronization bitmap, and updates the metadata synchronization bitmap (only configuration is not started).
[0069] 5. Controller B starts processing the read-write operation, and the metadata synchronization task starts.
[0070] In the method for configuring the metadata synchronization task provided by the embodiment, the spatial size of the metadata is first applied according to the size of the metadata in the data source, so that the metadata can be accommodated in the process of metadata synchronization; secondly, the progress of the metadata synchronization can be understood through the metadata synchronization bitmap, and in addition, the metadata synchronization task is configured in advance to prevent the business interruption caused by obtaining the metadata information during the metadata synchronization, and the continuity of the business is improved.
[0071] In practice, there are cases where only business needs to be performed, and there are cases where both business and metadata synchronization need to be performed, therefore, the preferred embodiment is to control the parallel processing of business and metadata synchronization tasks including:
[0072] In the case of recording business in the task list and there is address space to be taken over, it is judged whether the metadata synchronization bitmap is empty or not;
[0073] If not, read and store metadata from the data source;
[0074] Read the metadata and process the read-write operation according to the metadata.
[0075] If the task list is not empty, and controller B needs to take over part of the address space, when controller B starts reading and writing data, B does not have the metadata of the address space it belongs to:
[0076] 1. Controller B reads and writes data, and controller B detects whether the metadata synchronization bitmap is empty or not; the metadata synchronization bitmap is empty, which describes that the metadata is synchronized or there is no task currently being performed without metadata, and the read-write operation is directly performed.
[0077] 2. The metadata synchronization bitmap is not empty, and metadata needs to be read from the data source and stored in the current controller.
[0078] 3. Controller B reads the metadata and processes the read-write operation according to the metadata.
[0079] The embodiment provided according to the metadata synchronization bitmap controls the parallel processing of business and metadata synchronization tasks, in the case that the metadata synchronization bitmap is not empty, only the parallel processing of business and metadata synchronization tasks is controlled, and for the case that the metadata synchronization bitmap is empty, the read-write business is directly executed. As can be seen, whether the parallel processing of business and metadata synchronization tasks needs to be controlled can be analyzed through the metadata synchronization bitmap.
[0080] In implementation, in the process of metadata synchronization, if the metadata is large, if directly copied, it needs to spend a long time, which may cause business interruption, therefore, in the embodiment, the metadata is gradually synchronized according to the preset length. Specifically, reading and storing metadata from the data source includes:
[0081] Sending information of reading metadata to the data source;
[0082] Receiving metadata of a preset length returned by the data source; wherein the preset length is less than or equal to the maximum value of the transmissible data between the controller and the data source.
[0083] The metadata synchronization bitmap describes the synchronization progress of the metadata in a fixed length (i.e. a preset length). The metadata synchronization bitmap follows a common bitmap organization form, and uses bits to describe whether the metadata of the fixed length is synchronized or not. The fixed length is less than the maximum value of the data that can be transmitted by the inter-controller message. The metadata synchronization bitmap of the controller has no backup of the partner node, and the bitmap does not need to be reserved when the controller holding the bitmap exits the cluster, and the bitmap is re-applied when the controller joins the cluster. The controller B reads the target controller; the target controller returns the fixed length metadata according to the metadata synchronization bitmap unit; the data is updated to the metadata bitmap, and the metadata synchronization bitmap is updated.
[0084] The method provided by the embodiment replicates the metadata according to the preset length, and has less impact on the business process compared with the method of directly replicating the entire metadata.
[0085] In implementation, there can be multiple tasks in the task list, and the preferred implementation is that the method of parallel processing of business and metadata synchronization further includes:
[0086] In the case that the business is recorded in the task list and there is address space to be taken over, the metadata synchronization task is preferentially executed.
[0087] If the task list is not empty, and the controller B needs to take over part of the address space, when the controller B starts to perform the task data, the controller B has no metadata of the address space to which it belongs: the priority of the metadata synchronization task of the controller B is higher than the priority of any other RAID task, and the remaining tasks are prohibited from being performed before the metadata synchronization task of the controller B ends.
[0088] The embodiment preferentially executes the metadata synchronization task, and since the purpose of the metadata synchronization task is to still be able to obtain the metadata through the metadata in other controllers in the case of failure of a controller, preferentially executing the metadata synchronization task can make the metadata have a backup.
[0089] In implementation, the controller processes the metadata update of the RAID task caused by read and write operations, and therefore, the method of parallel processing of business and metadata synchronization further includes:
[0090] In the case that the business causes the metadata update of the RAID task, it is judged whether the metadata synchronization is completed;
[0091] If not, the metadata is synchronized; and after the metadata synchronization is completed, the metadata update of the RAID task is performed.
[0092] It should be noted that the controller B needs to process the interaction of read-write operation, RAID task and metadata synchronization only when it is the master controller, and there is no interaction behavior if it is the partner controller, and the metadata is synchronized through the synchronization task. When the controller B processes the metadata update of the RAID task caused by the read-write operation, the metadata synchronization bitmap needs to be processed: when the metadata is not synchronized, the metadata synchronization of the region needs to be performed first, and then the metadata update is performed, that is, the metadata synchronization task is preferentially performed.
[0093] The same as the above embodiment, the priority of the metadata synchronization task provided in the embodiment can make the metadata have a backup.
[0094] In the implementation, the controller may exit the cluster during the metadata synchronization process, therefore, the device and method for processing the business and metadata synchronization in parallel further includes:
[0095] detecting the controller exiting the cluster during the metadata synchronization process;
[0096] judging whether the controller exiting the cluster is the data source;
[0097] if yes, waiting for the controller exiting the cluster to recover;
[0098] after the data source recovers, entering the step of processing the business and metadata synchronization in parallel.
[0099] detecting whether the controller exiting the cluster is the data source of the metadata during the synchronization process, if the exiting controller is the data source, the RAID is offline and waits for the controller to recover, and the controller continues to synchronize the metadata after recovering. In addition, the metadata can be redistributed, and the recovery can be forced through the check and rewriting mode (since there is a probability of data loss).
[0100] In the above embodiment, the method for processing the business and metadata synchronization in parallel is described in detail, and the application further provides an embodiment of a device for processing the business and metadata synchronization in parallel and a server. It should be noted that the embodiment of the device part is described from two angles, one is based on the functional module, and the other is based on the hardware.
[0101] Figure 2 The structural diagram of the device for processing the business and metadata synchronization in parallel provided in an embodiment of the application. The embodiment is based on the functional module and includes:
[0102] The acquisition module 10 is configured to acquire a data source for configuration, wherein the data source contains metadata.
[0103] The configuration module 11 is configured to configure the metadata synchronization task according to the metadata in the data source.
[0104] The control module 12 is configured to control the business and the metadata synchronization task to be processed in parallel when the configuration of the metadata synchronization task is completed.
[0105] Since the embodiments of the device part correspond to the embodiments of the method part, the embodiments of the device part are described in the description of the embodiments of the method part, and will not be described here.
[0106] The device for processing business and metadata in parallel provided in the embodiment obtains a data source for configuration through the obtaining module; wherein the data source contains metadata; the configuration module configures the metadata synchronization task according to the metadata in the data source; and the control module controls the business and the metadata synchronization task to be processed in parallel when the configuration of the metadata synchronization task is completed. In the previous metadata synchronization process, the business needs to be suspended for a period of time to obtain the metadata information, which leads to the interruption of the business in the metadata synchronization process. In the device of the embodiment, the metadata information is configured in advance before the metadata task, so that the metadata information does not need to be obtained by interrupting the business when the metadata task is performed, so that the business can be processed in parallel with the metadata, ensuring the continuity of the business and improving the user experience.
[0107] Figure 3 The structure diagram of the server provided in another embodiment of the application is provided. The embodiment is based on the hardware angle, as shown in Figure 3 The server comprises:
[0108] The memory 20 is configured to store the computer program.
[0109] The processor 21 is configured to execute the computer program to realize the steps of the method for processing business and metadata in parallel mentioned in the above embodiments.
[0110] The server provided in the embodiment can include but is not limited to a smart phone, a tablet computer, a notebook computer or a desktop computer, etc.
[0111] The processor 21 can include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 21 can be implemented in at least one of a hardware form of a digital signal processor (DSP), a field-programmable gate array (FPGA), a programmable logic array (PLA), etc. The processor 21 can also include a main processor and a coprocessor. The main processor is a processor for processing data in a wake-up state, also referred to as a central processing unit (CPU). The coprocessor is a low-power processor for processing data in a standby state. In some embodiments, the processor 21 can be integrated with a graphics processing unit (GPU) for rendering and drawing content to be displayed by the display screen. In some embodiments, the processor 21 can further include an artificial intelligence (AI) processor for processing machine learning-related computing operations.
[0112] The memory 20 can include one or more computer-readable storage media, which can be non-transitory. The memory 20 can further include a high-speed random access memory, and a nonvolatile memory such as one or more disk storage devices, flash storage devices. In this embodiment, the memory 20 is at least used to store a computer program 201, wherein the computer program is loaded and executed by the processor 21, and can implement the related steps of the method for parallel processing of business and metadata synchronization disclosed in any of the preceding embodiments. In addition, the resources stored by the memory 20 can further include an operating system 202 and data 203, etc., and the storage manner can be temporary storage or permanent storage. The operating system 202 can include Windows, Unix, Linux, etc. The data 203 can include but is not limited to the data involved in the method for parallel processing of business and metadata synchronization mentioned above, etc.
[0113] In some embodiments, the server can further include a display screen 22, an input / output interface 23, a communication interface 24, a power supply 25, and a communication bus 26.
[0114] Those skilled in the art can understand that the structure shown in the above embodiments does not constitute a limitation on the server, and can include more or fewer components than those shown in the drawings. Figure 3 The structure shown in the above embodiments does not constitute a limitation on the server, and can include more or fewer components than those shown in the drawings.
[0115] The server provided by the embodiments of the present application comprises a memory and a processor, and the processor can implement the following method when executing the program stored in the memory: a method for processing service and metadata synchronously in parallel, and the effects are the same as above.
[0116] Finally, the present application also provides an embodiment corresponding to a computer readable storage medium. The computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement the steps recorded in the above method embodiments.
[0117] It can be understood that if the method in the above embodiments is implemented 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 such understanding, the technical solutions of the present application essentially or the part that contributes to the prior art or the whole or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and executes all or part of the steps of the methods described in the various embodiments of the present application. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various media that can store program codes.
[0118] The computer readable storage medium provided by the present application comprises the above-mentioned method for processing service and metadata synchronously in parallel, and the effects are the same as above.
[0119] The method, device, server and medium for processing service and metadata synchronously in parallel provided by the present application are described in detail. The embodiments in the specification are described in a progressive manner, and each embodiment mainly describes the differences from other embodiments. The same or similar parts of each embodiment can be referred to. For the device disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple, and the related parts can be referred to the method part. It should be pointed out that, for those skilled in the art, without departing from the principles of the present application, some improvements and modifications can be made to the present application, and these improvements and modifications also fall within the protection scope of the claims of the present application.
[0120] It also needs to be explained that in the present specification, the relational terms such as first and second and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises", "comprising", or any other variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. An element proceeded by "comprises... a" does not, without more constraints, exclude the existence of additional identical elements in the process, method, article, or apparatus that comprises the element.
Claims
1. A method for business and metadata synchronization parallel processing, characterized in that, The method comprises: obtaining a data source for configuration; wherein the data source contains the metadata; configuring a metadata synchronization task according to the metadata in the data source; controlling the business and the metadata synchronization task to be processed in parallel in the case of completing the configuration of the metadata synchronization task; the configuration of the metadata synchronization task according to the metadata in the data source comprises: obtaining the space size of the metadata from the data source; applying the space of the metadata and a metadata synchronization bitmap according to the space size of the metadata; wherein the metadata synchronization bitmap records the progress of the metadata synchronization; configuring the metadata synchronization bitmap; configuring the metadata synchronization task according to the metadata synchronization bitmap.
2. The method for business and metadata synchronization parallel processing according to claim 1, characterized in that, the control of the business and the metadata synchronization task to be processed in parallel comprises: in the case of recording the business in the task list and existing address space to be taken over, judging whether the metadata synchronization bitmap is empty or not; if not, reading and storing the metadata from the data source; reading the metadata and processing read-write operation according to the metadata.
3. The method for business and metadata synchronization parallel processing according to claim 2, characterized in that, the reading and storing of the metadata from the data source comprises: sending information of reading the metadata to the data source; receiving the metadata of a preset length returned by the data source; wherein the preset length is less than or equal to the maximum value of the transmissible data between the controller and the data source.
4. The method for business and metadata synchronization parallel processing of claim 1, wherein, The method further comprises: in the case of recording the business in the task list and existing address space to be taken over, preferentially executing the metadata synchronization task.
5. The method for service and metadata synchronization parallel processing according to claim 4, characterized in that, The method further comprises: in the case of the metadata update of the RAID task caused by the execution of the business, judging whether the metadata synchronization is completed or not; if not, synchronizing the metadata; after the metadata synchronization is completed, updating the metadata of the RAID task.
6. The method for parallel processing of traffic and metadata synchronization according to any one of claims 1 to 5, characterized in that, The method further comprises: in the process of the metadata synchronization, detecting the controller exiting the cluster; judging whether the controller exiting the cluster is the data source or not; if yes, waiting for the recovery of the controller exiting the cluster; after the recovery of the data source, entering the step of controlling the business and the metadata synchronization task to be processed in parallel.
7. An apparatus for synchronous and parallel processing of business and metadata, characterized in that, The method comprises: an obtaining module, configured to obtain a data source for configuration; wherein the data source contains the metadata; a configuration module, configured to configure a metadata synchronization task according to the metadata in the data source; a control module, configured to control the business and the metadata synchronization task to be processed in parallel in the case of completing the configuration of the metadata synchronization task; the configuration module is specifically configured to: obtain the space size of the metadata from the data source; apply the space of the metadata and a metadata synchronization bitmap according to the space size of the metadata; wherein the metadata synchronization bitmap records the progress of the metadata synchronization; configure the metadata synchronization bitmap; configure the metadata synchronization task according to the metadata synchronization bitmap.
8. A server, characterized by The method comprises: a memory, configured to store a computer program; A processor for implementing the steps of the method for parallel processing of service and metadata synchronization according to any one of claims 1 to 6 when executing the computer program.
9. A computer-readable storage medium, characterized in that, A computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the method for parallel processing of service and metadata synchronization according to any one of claims 1 to 6.
Citation Information
Patent Citations
Metadata updating
US10417213B1