Disclosure of Invention
In view of this, the embodiments of the present invention provide a method and apparatus for processing object storage metadata, which can solve the problem of unstable performance of a stand-alone database when the number of objects is large, and is easy to expand, and can easily expand to support objects of trillion levels.
In order to achieve the above object, according to one aspect of the embodiment of the present invention, there is provided a method for processing object storage metadata, including storing current object storage metadata into a write-in library, degrading the write-in library to a read-only library when the write-in library is full or fails, merging object storage metadata in the read-only library into a stable library at a set time interval, emptying the read-only library, taking the emptied read-only library as a standby library, and taking the standby library as a new write-in library when the write-in library is full or fails.
The method comprises the steps of selecting a set number of object storage metadata from a current stable base randomly according to a set time interval, calculating a splitting point according to the object storage metadata, generating a metadata table and a metadata range record table according to the splitting point, wherein the metadata range record table records the storage range of the metadata table, and merging the object storage metadata in the read-only base into the stable base based on the metadata table and the metadata range record table.
Optionally, merging the object storage metadata in the read-only library into a stable library based on the metadata table and the metadata range record table, wherein the method comprises the steps of sequentially traversing and reading the object storage metadata of the current stable library and the object storage metadata of the read-only library, and writing the object storage metadata into the metadata table; the metadata table and the metadata range record table form a new stable base, the object storage metadata in the current stable base and the read-only base and the object storage metadata in the new stable base are subjected to offline comparison and verification, after verification is passed, the configuration pointed to the current stable base in the cluster configuration is modified to be pointed to the new stable base, and the current stable base is deleted.
Optionally, the method further comprises the steps of inquiring object storage metadata corresponding to N object names based on the object names, wherein N is a positive integer, and returning an inquiring result set according to the object storage metadata corresponding to the object names.
The method comprises the steps of selecting N object storage metadata corresponding to N object names, randomly reading the N object storage metadata from a write-in library, a read-only library and a stable library to obtain three read result sets, merging and traversing the three read result sets sequentially according to the object names, and after merging and traversing are completed, if the data volume in the query result set does not reach a set threshold value, starting the process of merging and traversing the three read result sets again by the last object name until the data volume in the query result set reaches the set threshold value.
The method comprises the steps of selecting object names, merging and traversing three read result sets according to the object names, wherein the three read result sets comprise setting priorities, sequentially reducing the priorities of the read result sets of a write-in library, a read-only library and a stable library, merging and traversing the three read result sets according to the priorities sequentially according to the object names, judging whether object storage metadata corresponding to the object names carry a deletion mark or not if one object name appears in the three read result sets in total, jumping out if the object names carry the deletion mark, starting merging and traversing by the next object name, returning the object storage metadata corresponding to the object names to the query result set if the object names do not carry the deletion mark, and returning the object storage metadata corresponding to the object names to the query result set if one object name appears in the three read result sets in total for a plurality of times, and returning the object storage metadata corresponding to the object names read from the read result set with the highest priority to the query result set.
According to one aspect of the embodiment of the invention, a device for processing object storage metadata is provided, which comprises a degradation processing module, a merging processing module and a standby processing module, wherein the degradation processing module is used for storing the current object storage metadata into a write-in library, degrading the write-in library into a read-only library when the write-in library is full or fails, merging the object storage metadata in the read-only library into a stable library according to a set time interval, and the standby processing module is used for emptying the read-only library, taking the emptied read-only library as a standby library, and taking the standby library as a new write-in library when the write-in library is full or fails.
The merging processing module is further used for randomly selecting a set number of object storage metadata from a current stable base according to a set time interval, calculating a splitting point according to the object storage metadata, generating a metadata table and a metadata range record table according to the splitting point, recording the storage range of the metadata table in the metadata range record table, and merging the object storage metadata in the read-only base to the stable base based on the metadata table and the metadata range record table.
The merging processing module is further used for sequentially traversing and reading the object storage metadata of the current stable library and the object storage metadata of the read-only library, writing the object storage metadata into the metadata table, forming a new stable library by the metadata table and the metadata range record table, carrying out offline comparison and verification on the object storage metadata in the current stable library and the read-only library and the object storage metadata in the new stable library, modifying the configuration pointed to the current stable library in cluster configuration to be pointed to the new stable library after verification is passed, and deleting the current stable library.
Optionally, the device further comprises a list query module, wherein the list query module is used for querying object storage metadata corresponding to N object names based on the object names, N is a positive integer, and a query result set is returned according to the object storage metadata corresponding to the object names.
The list query module is further used for randomly reading N pieces of object storage metadata from a write-in library, a read-only library and a stable library to obtain three read result sets, merging and traversing the three read result sets sequentially according to the object names, and after the merging and traversing are completed, if the data quantity in the query result set does not reach a set threshold value, starting the process of merging and traversing the three read result sets again by the last object name until the data quantity in the query result set reaches the set threshold value.
The list query module is further used for randomly reading N pieces of object storage metadata from the write-in library, the read-only library and the stable library to obtain three read result sets, setting priority, sequentially reducing the priority of the read result sets of the write-in library, the read-only library and the stable library, merging and traversing the three read result sets according to the priority sequentially according to the object names, judging whether the object storage metadata corresponding to the object names carries a deletion mark if one object name appears in the three read result sets in total, jumping out if the object storage metadata corresponding to the object names carries the object storage metadata, merging and traversing the object storage metadata corresponding to the object names if the object storage metadata carries the object storage metadata, returning the object storage metadata corresponding to the object names to the query result sets if the object names do not appear in the three read result sets in total, and returning the object storage metadata corresponding to the object names read from the read result set with the highest priority to the query result set if the object names appear in total for a plurality of times.
According to an aspect of an embodiment of the present invention, there is provided an electronic device including one or more processors, and a storage device for storing one or more programs, which when executed by the one or more processors, cause the one or more processors to implement a method of storing metadata for a processing object as provided in the foregoing embodiment.
According to an aspect of an embodiment of the present invention, there is provided a computer-readable medium having stored thereon a computer program which, when executed by a processor, implements a method of processing object storage metadata as provided by the foregoing embodiment.
The embodiment of the invention has the advantages that the technical means of mutually matching a plurality of database clusters is adopted, so that the technical problem that the performance of a single database is unstable when the number of objects is large is solved, the service capability of the single database is not limited, the technical effect of stably processing metadata under the condition that the number of objects is extremely large is achieved, and the aim of easily expanding the metadata to support billions of objects is also achieved.
Further effects of the above-described non-conventional alternatives are described below in connection with the embodiments.
Detailed Description
Exemplary embodiments of the present invention will now be described with reference to the accompanying drawings, in which various details of the embodiments of the present invention are included to facilitate understanding, and are to be considered merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic diagram of a basic flow of a method of processing object storage metadata according to an embodiment of the present invention. As shown in fig. 1, an embodiment of the present invention provides a method for processing object storage metadata, including:
And S101, storing the current object storage metadata into a write-in warehouse, degrading the write-in warehouse to a read-only warehouse when the write-in warehouse is full or fails, and storing the current object storage metadata into the write-in warehouse, wherein the object storage metadata are incremental data (readable and writable). When the write-in warehouse is full or fails, the incremental data is converted into stock data, the stock data is set to be read-only, and the stock data is data which cannot be modified at the moment.
S102, merging object storage metadata in the read-only library into a stable library according to a set time interval;
and S103, emptying the read-only library, taking the emptied read-only library as a standby library, and taking the standby library as a new write library when the write library is full or fails.
The embodiment of the invention solves the technical problem that the performance of the single database is unstable when the number of the objects is large because the plurality of database clusters are mutually matched, thereby achieving the technical effect of stably processing the metadata under the condition of extremely large number of the objects.
In step S102 of the embodiment of the invention, merging the object storage metadata in the read-only library into the stable library according to a set time interval, wherein the method comprises the steps of randomly selecting a set number of object storage metadata from the current stable library according to the set time interval, calculating a split point according to the object storage metadata, generating a metadata table and a metadata range record table according to the split point, wherein the metadata range record table records the storage range of the metadata table, and merging the object storage metadata in the read-only library into the stable library based on the metadata table and the metadata range record table.
In the embodiment of the invention, the data in the read-only library is periodically combined into the stable library to reduce the reading consumption, and the combination process is performed on two read-only data sets (namely, the data can only be read from the read-only library and the stable library and cannot be written into the read-only library and the stable library), so that the operation difficulty in the practical application process is reduced.
Based on step S102 of the foregoing embodiment, in the embodiment of the present invention, based on the metadata table and the metadata range record table, merging the object storage metadata in the read-only library into the stable library includes sequentially traversing and reading the object storage metadata of the current stable library and the object storage metadata of the read-only library, writing into the metadata table, forming a new stable library by the metadata table and the metadata range record table, performing offline comparison verification on the object storage metadata in the current stable library and the read-only library and the object storage metadata in the new stable library, modifying the configuration pointed to the current stable library in the cluster configuration to be pointed to the new stable library after verification is passed, and deleting the current stable library.
In the embodiment of the invention, the data in the read-only library is periodically combined into the stable library to reduce the reading consumption, and the combination process is carried out on two read-only data sets, so that the operation difficulty in the actual application process is reduced.
The method further comprises the steps of inquiring object storage metadata corresponding to N object names based on the object names, wherein N is a positive integer, and returning an inquiring result set according to the object storage metadata corresponding to the object names. The embodiment of the invention has the function of list query, such as querying metadata corresponding to 1000 keys starting from a certain object name (Key).
The method comprises the steps of randomly reading N pieces of object storage metadata from a write-in library, a read-only library and a stable library to obtain three read result sets, merging and traversing the three read result sets sequentially according to the object names, and executing the process of merging and traversing the three read result sets again by the last object name until the data amount in the query result set reaches a set threshold value if the data amount in the query result set does not reach the set threshold value after merging and traversing.
For example, a query starts with 1000 keys, which 1000 keys may appear in a write library, a read-only library, and a stable library, 1000 metadata are fetched from each of the three databases, and then returned data is determined according to the business rule, which may be 500, so there is a loop to process until 1000 results are fetched. The embodiment of the invention can solve the problem that the query becomes complex due to the adoption of the database and the table, and has high efficiency and accurate return result in the query process.
Based on the embodiment, the method comprises the steps of sequentially traversing three read result sets according to the object names in a merging mode, wherein the priority of the read result sets of a write-in library, a read-only library and a stable library is sequentially reduced, sequentially traversing the three read result sets according to the priority in a merging mode according to the object names, judging whether object storage metadata corresponding to one object name carries a deletion mark or not if one object name appears in the three read result sets in total, jumping out if the object name does not appear in total, starting merging and traversing by the next object name, returning the object storage metadata corresponding to the object name to the query result set if the object name does not appear in the three read result sets in total, and returning the object storage metadata corresponding to the object name to the query result set from the read result set with the highest priority if the object name appears in the three read result sets in total. The embodiment of the invention adopts a mode of setting priority to inquire and screen in three libraries, can solve the problem that the inquiry becomes complex due to the adoption of the library division and the table division, has high efficiency in the inquiry process and accurate return result.
Fig. 2 is a schematic diagram of basic modules of an apparatus for processing an object storage metadata according to an embodiment of the present invention. As shown in fig. 2, an embodiment of the present invention provides a processing apparatus 200 for storing metadata by an object, including:
the degradation processing module 201 is configured to store the current object storage metadata into a write-in library, and degrade the write-in library into a read-only library when the write-in library is full or fails;
A merging processing module 202, configured to merge object storage metadata in the read-only library into a stable library according to a set time interval;
And the standby processing module 203 is configured to empty the read-only library, take the emptied read-only library as a standby library, and take the standby library as a new write library when the write library is full or fails.
The embodiment of the invention adopts the technical means of mutually matching a plurality of database clusters, so that the technical problem that the performance of a single database is unstable when the number of objects is large is solved, the technical effect of stably processing metadata under the condition of extremely large number of objects is achieved, and the aim of easily expanding to support billions of objects is also achieved.
In the embodiment of the present invention, the merging processing module 202 is further configured to randomly select a set number of object storage metadata from a current stable library according to a set time interval, calculate a split point according to the object storage metadata, generate a metadata table and a metadata range record table according to the split point, wherein a storage range of the metadata table is recorded in the metadata range record table, and merge the object storage metadata in the read-only library into the stable library based on the metadata table and the metadata range record table.
In the embodiment of the invention, the data in the read-only library is periodically combined into the stable library to reduce the reading consumption, and the combination process is performed on two read-only data sets (namely, the data can only be read from the read-only library and the stable library and cannot be written into the read-only library and the stable library), so that the operation difficulty in the practical application process is reduced.
The merging processing module is further used for sequentially traversing and reading the object storage metadata of the current stable base and the object storage metadata of the read-only base and writing the object storage metadata into the metadata table, forming a new stable base by the metadata table and the metadata range record table, carrying out offline comparison and verification on the object storage metadata of the current stable base and the read-only base and the object storage metadata of the new stable base, modifying configuration pointed to the current stable base in cluster configuration to be pointed to the new stable base after verification is passed, and deleting the current stable base.
In the embodiment of the invention, the data in the read-only library is periodically combined into the stable library to reduce the reading consumption, and the combination process is carried out on two read-only data sets, so that the operation difficulty in the actual application process is reduced.
In the embodiment of the invention, the device further comprises a list query module, wherein the list query module is used for querying object storage metadata corresponding to N object names based on the object names, N is a positive integer, and a query result set is returned according to the object storage metadata corresponding to the object names. The embodiment of the invention has the function of List query (List), for example, the metadata corresponding to 1000 keys starting from a certain object name (Key) is queried.
In the embodiment of the invention, the list query module is further used for randomly reading N pieces of object storage metadata from a write-in library, a read-only library and a stable library to obtain three read result sets, sequentially merging and traversing the three read result sets according to the object names, and after the merging and traversing are completed, if the data quantity in the query result set does not reach a set threshold value, starting the process of merging and traversing the three read result sets again by the last object name until the data quantity in the query result set reaches the set threshold value. The embodiment of the invention can solve the problem that the query becomes complex due to the adoption of the database and the table, and has high efficiency and accurate return result in the query process.
In the embodiment of the invention, the list query module is further used for randomly reading N pieces of object storage metadata from a write-in library, a read-only library and a stable library to obtain three read result sets, setting priority, sequentially reducing the priority of the read result sets of the write-in library, the read-only library and the stable library, sequentially merging and traversing the three read result sets according to the priority according to the object names, judging whether the object storage metadata corresponding to the object names carries a deletion mark if one object name appears in the three read result sets in total, jumping out if the object storage metadata corresponding to the object names carries the deletion mark, merging and traversing the object storage metadata corresponding to the object names if the object storage metadata does not carry the object storage metadata, returning the object storage metadata corresponding to the object names to the query result sets if the object storage metadata does not carry the object storage metadata, and returning the object storage metadata corresponding to the object names read from the read result set with the highest priority if the object names appear in the three read result sets in total. The embodiment of the invention adopts a mode of setting priority to inquire and screen in three libraries, can solve the problem that the inquiry becomes complex due to the adoption of the library division and the table division, has high efficiency in the inquiry process and accurate return result.
FIG. 3 is a system architecture diagram of managing object storage metadata according to an embodiment of the present invention. As shown in fig. 3, the system for managing the object storage metadata comprises a stable base, a read-only base, a write-in base, a standby base, a monitoring service, a merging service and a configuration center, wherein the stable base is composed of a plurality of database tables and is used for storing historical stock data, the stable base only supports reading data, the stable base also comprises metadata tables and metadata range record tables, the write-in base is composed of a plurality of database tables and is used for storing data which are currently being read and written, the data can be read from the write-in base and can be written into the write-in base, the write-in base also comprises the metadata tables and the metadata range record tables, the read-only base is formed by switching from the write-in base when the write-in base fails or is full, the standby base is only used for supporting reading data, the standby base is used for switching into a new write-in base when the write-in base fails or is full, the monitoring service is used for monitoring whether the write-in base fails or is full, the configuration center is used for providing consistent cluster information for the database, and the read-in base is used for merging the read-in base according to the set time interval after the read-in base is complete.
The basic operation of the system for managing objects to store metadata is as follows:
1. write (Put), can be written directly into write library (Writeable Meta).
2. Delete (Delete) and write the data with Delete markers in the write library.
3. Reading (Get), namely sequentially reading data corresponding to the object name from a write library (Writeable Meta), a read-only library (ReadOnly Meta) and a Stable library (Stable Meta), and judging as follows:
when the data without the deletion mark is read, jumping out and cycling back to the data;
reading the data with the deletion mark, and jumping out and cycling back to the absence of the object;
if the data is not read, the returned object does not exist.
4. List inquiry (List)
Taking out N pieces of data from a write library (Writeable Meta), a read-only library (ReadOnly Meta) and a Stable library (Stable Meta);
Setting priority, and sequentially reducing the priority of writing into a warehouse, reading out from a warehouse and stabilizing the warehouse;
traversing the three result sets according to the priority merging, and merging until one result set is taken out:
if one Key only appears once, if the object storage metadata (namely metadata) corresponding to the Key carries a deletion mark, the metadata directly jumps out, and if the metadata does not carry the deletion mark, the metadata is returned;
if a Key appears multiple times, the metadata with the highest priority is subject to.
After the merging is finished, if the number of the results is insufficient, the last key is used as a starting mark, and the merging traversing process is re-executed. Fig. 4 is a schematic diagram of a merge function implementation in a system for processing object storage metadata according to an embodiment of the present invention. As shown in fig. 4, the data of the read-only library is periodically merged into the stable library to reduce the read consumption, and in the present system, the merging process is performed on two read-only data sets, which are as follows:
judging whether the stable base needs to be split (when the number of objects is excessive or the service capability of the current system is insufficient), randomly selecting some data to calculate splitting points if the stable base needs to be split, generating a new metadata Table (MetaN Table) according to the splitting points, generating a metadata range record Table (Table Meta) and the range of the Table Meta record MetaN to integrally form a tree structure, 1 traversing the data of the read stable base and writing the data into a new MetaN, 2 traversing the data of the read ReadOnly Meta and writing the data into MetaN (deleting the data with a deletion mark), comparing the object storage metadata of the current stable base and the read-only base participating in merging with the object storage metadata of the new stable base offline to ensure the merging before and after logic, 3 modifying the cluster configuration, modifying the configuration of the current stable base pointed to the current stable base in the cluster configuration to point to the new stable base, and deleting the current stable base to finish the merging.
In the actual operation process, various new storage systems are continuously appeared, based on the requirement of architecture evolution, new systems are tried to be introduced in the production environment, and in general, double writing is needed in this case, but verification of double writing data and rollback when failure can be a troublesome matter. In the system for processing object storage metadata according to the embodiment of the present invention, as shown in fig. 5, in normal circumstances, a New write dual-write New storage device (New Store) and a database (Mysql) are newly written, the New storage device is used as a main storage device, the write-in is periodically changed into a read-only storage, and the consistency of data in the New Store and Mysql is compared, once any problem occurs, a standby storage is directly started, and the service state of the original database is fully backed.
The system realizes a high-availability large-scale global ordered KV cluster based on a plurality of Mysql clusters, creates a large global ordered KV on a plurality of databases based on the thought of LSM Tree, can randomly migrate multi-cluster write points, solves the problem of Mysql single-point faults, solves the problem of Mysql reading and writing due to the Tree structure of logic inside a logic cluster, and converts dynamic data comparison into static data comparison. In the prior art, the HBase, tikv and other systems realize global ordered KV, the scale can be greatly expanded, and the large-scale global ordered requirement is realized, but when the clusters are used, the problem that the whole metadata management service cannot be written in due to single cluster faults can be encountered, and the writing points of the system can be randomly migrated, so that the problem of single cluster faults is solved. Meanwhile, the system can keep the basic architecture unchanged, and only uses HBase, tikv and other systems to replace Mysql, so as to realize higher availability.
The cluster data scale of the system is not limited by the service capability of a single database, and can reach the object of trillion levels, in particular:
The processing capability can be greatly expanded, namely the stock data is read-only data, the reading capability can be improved by simply increasing the backup of the database, the capability of reconstructing the stock data is provided, only one database is needed to be accessed for each access, the capacity can be improved by infinitely expanding the number of the databases without causing the reduction of the processing performance, the incremental data can be quickly read-only, and only a small cluster of the incremental data is needed to be maintained, so that the access of the incremental data is greatly reduced.
The reliability is improved, the availability of the stock data can be improved by simply increasing the number of the slave libraries, and the incremental data clusters (write-in libraries) can be quickly switched to the backup clusters (read-only libraries or standby libraries) when the incremental data clusters are unavailable, so that the writing of the system is not influenced.
The support of architecture evolution can switch the current database into a new system (or a novel storage device), the method is very simple to import the stock data into the new system and can switch back to the original database (or the system) without risk when the new system has problems due to the read-only of the stock data, the incremental data clusters can be quickly switched, the new system can be used as a writable cluster (write-in library), only a small amount of data is stored in the read-only cluster (read-only library), and the writable cluster can be quickly switched to a backup cluster of an old system when the new system has faults.
Fig. 6 illustrates an exemplary system architecture 600 of a method of processing object storage metadata or an apparatus of processing object storage metadata to which embodiments of the present invention may be applied.
As shown in fig. 6, the system architecture 600 may include terminal devices 601, 602, 603, a network 604, and a server 605. The network 604 is used as a medium to provide communication links between the terminal devices 601, 602, 603 and the server 605. The network 604 may include various connection types, such as wired, wireless communication links, or fiber optic cables, among others.
A user may interact with the server 605 via the network 604 using the terminal devices 601, 602, 603 to receive or send messages, etc. Various communication client applications, such as shopping class applications, web browser applications, search class applications, instant messaging tools, mailbox clients, social platform software, etc., may be installed on the terminal devices 601, 602, 603.
The terminal devices 601, 602, 603 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smartphones, tablets, laptop and desktop computers, and the like.
The server 605 may be a server providing various services, such as a background management server providing support for shopping-type websites browsed by the user using the terminal devices 601, 602, 603. The background management server can analyze and other data of the received product information inquiry request and feed back the processing result to the terminal equipment.
It should be noted that, the method for storing metadata in a processing object according to the embodiment of the present invention is generally executed by the server 605, and accordingly, the device for storing metadata in a processing object is generally disposed in the server 605.
It should be understood that the number of terminal devices, networks and servers in fig. 6 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
According to an embodiment of the present invention, there is also provided an electronic device and a readable storage medium.
The electronic equipment comprises one or more processors and a storage device, wherein the storage device is used for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors are enabled to realize the method for storing metadata by the processing object.
The computer readable medium of the embodiment of the present invention stores thereon a computer program which, when executed by a processor, implements the method for storing metadata for a processing object provided by the present invention.
Referring now to FIG. 7, there is illustrated a schematic diagram of a computer system 700 suitable for use in implementing an embodiment of the present invention. The terminal device shown in fig. 7 is only an example, and should not impose any limitation on the functions and the scope of use of the embodiment of the present invention.
As shown in fig. 7, the computer system 700 includes a Central Processing Unit (CPU) 701, which can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 702 or a program loaded from a storage section 708 into a Random Access Memory (RAM) 703. In the RAM703, various programs and data required for the operation of the system 700 are also stored. The CPU701, ROM702, and RAM703 are connected to each other through a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.
Connected to the I/O interface 705 are an input section 706 including a keyboard, a mouse, and the like, an output section 707 including a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, a speaker, and the like, a storage section 708 including a hard disk, and the like, and a communication section 709 including a network interface card such as a LAN card, a modem, and the like. The communication section 709 performs communication processing via a network such as the internet. The drive 710 is also connected to the I/O interface 705 as needed. A removable medium 711 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 710 as necessary, so that a computer program read therefrom is mounted into the storage section 708 as necessary.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication portion 709, and/or installed from the removable medium 711. The above-described functions defined in the system of the present invention are performed when the computer program is executed by a Central Processing Unit (CPU) 701.
The computer readable medium shown in the present invention may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of a computer-readable storage medium may include, but are not limited to, an electrical connection having one or more wires, a portable computer diskette, 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 disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules involved in the embodiments of the present invention may be implemented in software or in hardware. The described modules may also be provided in a processor, for example, a processor may be described as including a degradation processing module, a merge processing module, and a standby processing module. The names of these modules do not in any way limit the module itself, and for example, the merge processing module may also be described as "a module for merging object storage metadata in the read-only library into a stable library".
As a further aspect, the invention also provides a computer readable medium which may be comprised in the device described in the above embodiments or may be present alone without being fitted into the device. The computer readable medium carries one or more programs, and when the one or more programs are executed by the equipment, the equipment comprises the steps of storing the current object storage metadata into a write-in warehouse, degrading the write-in warehouse into a read-only warehouse when the write-in warehouse is full or fails, merging the object storage metadata in the read-only warehouse into a stable warehouse according to a set time interval, emptying the read-only warehouse, taking the emptied read-only warehouse as a standby warehouse, and taking the standby warehouse as a new write-in warehouse when the write-in warehouse is full or fails.
According to the method for processing the object storage metadata, which is disclosed by the embodiment of the invention, the technical problem that the performance of a single database is unstable when the number of objects is large is solved because the technical means that a plurality of database clusters are matched with each other is adopted, so that the technical effect of stably processing the metadata under the condition that the number of objects is extremely large is achieved, and the aim of easily expanding the metadata to support billions of objects is fulfilled.
The above embodiments do not limit the scope of the present invention. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives can occur depending upon design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the scope of the present invention.