CN107665219B - Log management method and device - Google Patents

Log management method and device Download PDF

Info

Publication number
CN107665219B
CN107665219B CN201610617168.6A CN201610617168A CN107665219B CN 107665219 B CN107665219 B CN 107665219B CN 201610617168 A CN201610617168 A CN 201610617168A CN 107665219 B CN107665219 B CN 107665219B
Authority
CN
China
Prior art keywords
sequence
data object
write
data
write operation
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610617168.6A
Other languages
Chinese (zh)
Other versions
CN107665219A (en
Inventor
周烜
李茂增
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201610617168.6A priority Critical patent/CN107665219B/en
Publication of CN107665219A publication Critical patent/CN107665219A/en
Application granted granted Critical
Publication of CN107665219B publication Critical patent/CN107665219B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • G06F16/2358Change logging, detection, and notification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/1734Details of monitoring file system events, e.g. by the use of hooks, filter drivers, logs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/1805Append-only file systems, e.g. using logs or journals to store data
    • G06F16/1815Journaling file systems

Abstract

The application relates to the technical field of databases, and discloses a log management method and device, which are used for improving the performance of a database management system during log recovery. The method comprises the following steps: determining an operation sequence of a first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object; performing the first write operation to the written data object in accordance with data read from the at least one read data object; writing the first write operation and the determined operation sequence into the transaction log, and replacing the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence.

Description

Log management method and device
Technical Field
The present application relates to the field of database technologies, and in particular, to a log management method and apparatus.
Background
In the field of database technology, a transaction is the fundamental unit of data processing performed by a database. When a transaction is executed, if the operation information involved from the beginning to the end of the transaction is recorded in a binary manner as a special data item, this is the transaction log. The transaction log is recorded in transaction units, and each log entry records information of transaction processing in detail to ensure that the system can replay the transaction when necessary, such as database failure recovery.
The pre-written log is a transaction log implementation method usually adopted by a database, the pre-written log ensures that modification of a data file occurs after the transaction log is written into a permanent memory, namely when a transaction is submitted, the transaction log for recording the modification of the data file can be completely written into a disk, a database page modified by the transaction is not required to be written into the disk immediately, and if the database fails, the database can be recovered by using the transaction log which is stored persistently.
When a large database is managed and maintained, problems of slow operation speed, data recovery failure and the like are easy to occur. Under modern multi-core architectures, advances in database performance are suitable for implementation with a higher degree of parallelism. The transaction log management method with high parallelism can greatly improve the data processing speed of the database and improve the performance of the database while ensuring the reliable recovery of data.
Disclosure of Invention
The embodiment of the application provides a log management method and device, which are used for improving the parallelism of data recovery of a database.
The embodiment of the application provides the following specific technical scheme:
in a first aspect, a log management method is provided, where the method is applied to a database, where the database includes a transaction log and a data set, the data set includes at least two data objects, the data objects carry sequence identifiers, the sequence identifiers are used to characterize an operation sequence of a write operation when the data objects are last written, the transaction log is used to record the write operation and the operation sequence of the write operation, and the data objects include at least one written data object and one written data object, where the method includes the following implementation manners: determining an operation sequence of a first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object; performing the first write operation to the written data object in accordance with data read from the at least one read data object; writing the first write operation and the determined operation sequence into the transaction log, and replacing the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence.
The beneficial effect of this embodiment does: by distributing the sequence identification to the data object, determining the operation sequence identification of the write operation according to the sequence identification carried by the data object, and writing the operation sequence identification into the transaction log, the transaction log can be added with a locally ordered operation sequence identification, and when the fault is recovered, the partial order relation of each transaction log can be determined through the operation sequence identification carried by the transaction log, so that the parallelism of recovering data through the transaction log is improved, the validity and the correctness of recovering data through the transaction log are ensured, the processing speed of the database is improved, and the performance of the database is improved.
In one possible design, the determining an operation sequence of a first write operation to be performed according to a sequence identifier carried by the at least one read data object and a sequence identifier carried by the write data object is implemented by: traversing the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, and selecting the last executed operation sequence from the operation sequences represented by the traversed sequence identifier; determining that an operation order next to the last executed operation order is an operation order of the first write operation.
The beneficial effect of this embodiment does: the method can ensure the accuracy of the logic sequence among the transaction logs, and ensure the accuracy of the partial order relationship among the transaction logs when the data is recovered through the transaction logs.
In a possible design, the last executed operation order is N, where N is an arbitrary natural number, and the operation order next to the last executed operation order is determined as the operation order of the first write operation, that is, the operation order of the first write operation is determined to be N + 1.
In one possible design, the transaction log includes at least two sub-transaction logs, and the operation sequences recorded by any two sub-transaction logs are independent of each other; the writing the first write operation and the determined operation sequence into the transaction log is realized by the following steps: writing the first write operation and the determined sequence of operations to the sub-transaction log for recording non-independence from the first write operation.
The beneficial effect of this embodiment does: the critical area of log management is removed, so that the transaction log does not need to be globally ordered, and the realization of improving the processing parallelism of the database is facilitated.
In one possible design, the data object includes an elementary data unit or a set of elementary data units, the set of elementary data units including at least two of the elementary data units; correspondingly, the data object carries a sequence identifier, where the sequence identifier is used to represent an operation sequence of the write operation when the write operation is executed for the last time on the data object, and the method includes: the elementary data unit carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when the elementary data unit was last written, or the elementary data unit set carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when any elementary data unit in the elementary data unit set was last written.
The beneficial effect of this embodiment does: when the data object comprises the basic data unit set, each basic data unit set carries a sequence identifier, and waste of memory can be reduced.
In one possible design, when the data object includes the set of basic data units, the data set is split into the set of basic data units before determining an operation order of a first write operation to be performed according to an order identifier carried by the at least one read data object and an order identifier carried by the write data object.
In one possible design, the data set includes a table or partition of the database, the set of primitives includes a bucket of the database, and the splitting of the data set into the sets of primitives is performed by: performing bucket operations on the primitives in the table or the partition, grouped into at least two of the buckets.
The beneficial effect of this embodiment does: the grouping mechanism of the basic data units is realized based on the table or the partition, so that the universality and convenience of the realization of the partial ordering relation of the transaction log can be ensured.
In a possible design, before determining the operation sequence of the first write operation to be performed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, the read lock is added to the bucket corresponding to the at least one read data object and the write data object.
The beneficial effect of this embodiment does: ensuring that the current transaction can read the accurate data object.
In one possible design, before the first write operation is performed on the written data object, a write lock is applied to the bucket corresponding to the written data object.
The beneficial effect of this embodiment does: the current transaction can be ensured to smoothly and accurately carry out write operation on the bucket corresponding to the written data object.
In one possible design, the log sequence identification is a log sequence number LSN or a timestamp.
In one possible design, the read data object is used for performing the write operation on the write data object, and the transaction performs the read operation on the read data object before performing the write operation on the write data object.
In a possible design, the determining, according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the written data object, the operation sequence identifier corresponding to the write operation performed on the written data object is implemented by: when a first read data object is read after a transaction is generated, recording a sequence identifier carried by the first read data object as a temporary value of the operation sequence identifier, subsequently comparing the temporary value of the operation sequence identifier recorded currently with a sequence identifier carried by the currently read data object when the transaction reads one read data object or one written data object, and replacing the temporary value of the operation sequence identifier recorded currently with the sequence identifier carried by the currently read data object when the sequence identifier carried by the currently read data object is greater than the temporary value of the operation sequence identifier recorded currently; determining a next sequential identification of a temporary value of the operation sequence identification of the final update record as the operation sequence identification.
The beneficial effect of this embodiment does: the partial order relation among the transaction logs can be ensured, and the correct transaction log recovery sequence is ensured when the fault is recovered.
In a second aspect, there is provided a log management apparatus having a function of implementing any one of the above-described first aspect and possible design methods. The functions can be realized by hardware, and the functions can also be realized by executing corresponding software by hardware. The hardware or software includes one or more modules corresponding to the above-described functions. The log management device can attach a local ordered operation sequence identifier to the transaction log, and can determine the partial order relation of each transaction log through the operation sequence identifier carried in the transaction log when fault recovery is carried out, so that the parallelism of data recovery through the transaction log is improved, the effectiveness and the correctness of data recovery through the transaction log are ensured, the processing speed of the database is improved, and the performance of the database is improved.
In a third aspect, there is provided a log management device comprising a memory for storing a set of programs and a processor for calling the programs stored in the memory to perform the method according to any one of the first aspect and possible designs.
In one possible design, the log management apparatus is applied to a database, where the database includes a transaction log and a data set, the data set includes at least two data objects, the data objects carry sequence identifiers, the sequence identifiers are used to characterize an operation sequence of a write operation when the data objects are last written, the transaction log is used to record the write operation and the operation sequence of the write operation, the data objects include at least one read data object and one write data object, and the processor is configured to: determining an operation sequence of a first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object; performing the first write operation to the written data object in accordance with data read from the at least one read data object; writing the first write operation and the determined operation sequence into the transaction log, and replacing the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence.
The beneficial effect of this embodiment does: the transaction log can be added with a local ordered sequence identifier, and when a fault is recovered, the partial order relationship of each transaction log can be determined through the sequence identifier carried in the transaction log, so that the parallelism of data recovery through the transaction log is improved, the validity and correctness of data recovery through the transaction log are ensured, the processing speed of a database is improved, and the performance of the database is improved.
In one possible design, the processor is to: traversing the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, and selecting the last executed operation sequence from the operation sequences represented by the traversed sequence identifier; determining that an operation order next to the last executed operation order is an operation order of the first write operation.
The beneficial effect of this embodiment does: the method can ensure the accuracy of the logic sequence among the transaction logs, and ensure the accuracy of the partial order relationship among the transaction logs when the data is recovered through the transaction logs.
In one possible design, the last executed operation sequence is N, where N is an arbitrary natural number, and the processor is configured to: and determining the operation sequence of the first write operation to be N + 1.
In one possible design, the transaction log includes at least two sub-transaction logs, and the operation sequences recorded by any two sub-transaction logs are independent of each other; the processor is further configured to: writing the first write operation and the determined sequence of operations to the sub-transaction log for recording non-independence from the first write operation.
The beneficial effect of this embodiment does: the critical area of log management is removed, so that the transaction log does not need to be globally ordered, and the realization of improving the processing parallelism of the database is facilitated.
In one possible design, the data object includes an elementary data unit or a set of elementary data units, the set of elementary data units including at least two of the elementary data units; correspondingly, the data object carries a sequence identifier, where the sequence identifier is used to represent an operation sequence of the write operation when the write operation is executed for the last time on the data object, and the method includes: the elementary data unit carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when the elementary data unit was last written, or the elementary data unit set carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when any elementary data unit in the elementary data unit set was last written.
The beneficial effect of this embodiment does: when the data object comprises the basic data unit set, each basic data unit set carries a sequence identifier, and waste of memory can be reduced.
In one possible design, the processor is further configured to: when the data object comprises the basic data unit set, splitting the data set into the basic data unit set before determining the operation sequence of the first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object.
In one possible design, the set of data includes a table or partition of the database, the set of primitives includes a bucket of the database, and the processor is further configured to: performing bucket operations on the primitives in the table or the partition, grouped into at least two of the buckets.
The beneficial effect of this embodiment does: the grouping mechanism of the basic data units is realized based on the table or the partition, so that the universality and convenience of the realization of the partial ordering relation of the transaction log can be ensured.
In one possible design, the processor is further configured to: and adding a read lock to the bucket corresponding to the at least one read data object and the write data object before determining the operation sequence of the first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object.
The beneficial effect of this embodiment does: ensuring that the current transaction can read the accurate data object.
In one possible design, the processor is further configured to: before the first write operation is executed on the written data object and before the write operation is executed on the written data object, a write lock is added to the bucket corresponding to the written data object.
The beneficial effect of this embodiment does: the current transaction can be ensured to smoothly and accurately carry out write operation on the bucket corresponding to the written data object.
In one possible design, the operation sequence identifier or the sequence identifier includes: a Log Sequence Number (LSN) or a timestamp.
According to the log management method and device provided by the embodiment of the application, the sequence identification is added to the data objects in the database, so that the local sequence relation of the transaction log is ensured, the parallelism of fault recovery of the database is improved, and meanwhile, the correctness of the log recovery is ensured.
Drawings
FIG. 1 is a schematic diagram of a database system in an embodiment of the present application;
FIG. 2 is a diagram of a database system architecture in an embodiment of the present application;
FIG. 3 is a flow chart of an exemplary log management method in an embodiment of the present application;
fig. 4 is a schematic diagram of an exemplary data grouping manner in an embodiment of the present application;
FIG. 5 is a flow diagram of another exemplary log management method in an embodiment of the present application;
FIG. 6 is a diagram of an exemplary transaction log management architecture in an embodiment of the present application;
fig. 7 is a diagram illustrating an exemplary structure of a log management apparatus according to an embodiment of the present application;
fig. 8 is a diagram showing another exemplary log management apparatus in the embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application clearer, the present application will be described in further detail with reference to the accompanying drawings, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In view of the problem in the prior art that it is difficult to improve parallelism and thus hinder improvement of database processing speed when database fault recovery is implemented according to a transaction log, an embodiment of the present application provides a log management method and apparatus, which implement a function of ordering a non-full-order relationship of the transaction log by attaching a locally ordered sequence identifier to a data object in a database (the non-full-order relationship may also be referred to as a partial-order relationship). The embodiment of the invention realizes the improvement of the parallelism of the fault recovery of the database based on the partial order relation of the transaction logs, and simultaneously ensures the correctness of the log recovery.
The method provided by the embodiment of the application is suitable for typical database systems, and can comprise a stand-alone database system and a distributed database system.
As shown in fig. 1, one possible database system architecture in the embodiment of the present application includes a client 101, a database 102, and a disk 103. It should be understood that the client 101 may have various forms, such as a desktop computer, a notebook computer, a human-computer interface, etc., and may be accessed in a remote control manner or a local control manner, without limitation. In one implementation, the client 101 and the database 102 are in the same hardware device, in another implementation, the database 102 and the disk 103 are in the same hardware device, and in another implementation, the client 101, the database 102 and the disk 103 are in the same hardware device, which is not limited. Specifically, taking a stand-alone database system as an example, as shown in fig. 2, the database 102 in the embodiment of the present application has functions that can be implemented by a database management system, the database 102 includes an executor 104, a table locking module 105, a data caching module 106, a log caching module 107, and another management module 108, and the disk 103 represents a persistent storage, and includes a data storage area 109 and a log storage area 110.
The client 101 performs data interaction with the database 102, for example, performs operations such as searching, modifying, inserting, or deleting on data in the database 102; the executor 104 is used for executing operations corresponding to the functions of the database 102; the lock table module 105 is used for implementing a locking management mechanism of database pages; the data caching module 106 is used for caching data, and the log caching module 107 is used for caching a transaction log; the data storage area 109 is used for storing the data cached by the data caching module 106, and the log storage area 110 is used for storing the transaction log cached by the log caching module 107.
Based on the system architecture shown in fig. 2, one possible database operation process is: the database 102, during execution, caches data and a transaction log in the data cache module 106 and the log cache module 107, respectively, and writes the transaction log into a log storage area 110 of the disk 103 when an event is committed, and also writes data into a data storage area 109 of the disk periodically. However, to ensure the performance of the database 102, the writing of data is deferred because the continuous concentration of transaction logs writes to disk much faster than the scatter writing of data. If the database 102 is abnormally shut down, and when the database is started next time, in order to maintain the consistency of the data, fault recovery needs to be performed, that is, data which is not written into the disk needs to be recovered according to the log.
In order to ensure the efficiency of recovering data according to the transaction log when the database fails, in the embodiment of the present application, the log recovery is performed in a parallel manner, and the following describes in detail a preferred embodiment of the present application with reference to the accompanying drawings.
The log management method provided by the embodiment of the application is applied to the database 102, and the database 102 includes a transaction log and a data set, which are respectively cached in the data caching module 106 and the log caching module 107.
A data set is data loaded from the data storage area 109 and includes at least two data objects. The at least two data objects include at least one read data object and one write data object, wherein the read data object and the write data object are determined according to the operation attribute of the transaction to the data object, for example, the data object of the transaction performing the read operation is called the read data object, and the data object of the transaction performing the write operation is called the write data object. The read data object is used to write to the write data object, e.g., a transaction reads the read data object before performing a write operation to the write data object, and performs the write operation to the write data object based on the contents of the read data object. It should be understood that a data object referred to by a read data object in any one transaction may become a written data object in another transaction, and a data object referred to by a written data object in any one transaction may also become a read data object in another transaction.
The data object carries a sequence identifier, and the sequence identifier is used for representing the operation sequence of the write operation when the write operation is executed for the last time on the data object.
The transaction log is used for recording write operation performed on the data object and an operation sequence corresponding to the write operation. It should be understood that the operation sequence of each write operation is executed, and the sequence identifier carried by the executed written data object is in a corresponding relationship when the write operation is executed; in the embodiment of the present invention, the operation sequence identifier may be used to represent a sequence identifier corresponding to a write operation performed on a data object. This sequence of operations may be used to determine the relative logical order of all write operations, as will be described in more detail in the method flow below. The sequence identifier includes: a Log Sequence Number (abbreviated LSN) or a timestamp. The LSN identifies the location of a particular transaction log in a transaction log file. Whether LSN or timestamp, the recovery order of the transaction log can be determined when recovering data from the transaction log.
As shown in fig. 3, a flow of the log management method provided in the embodiment of the present application is as follows.
Step 201: determining an operation sequence of a first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object;
step 202: performing the first write operation to the written data object in accordance with data read from the at least one read data object;
step 203: writing the first write operation and the determined operation sequence into the transaction log, and replacing the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence.
In step 201, the sequence identifiers carried by the read data object and the write data object may be traversed, and the operation sequence executed last is selected from the operation sequences represented by the traversed sequence identifiers; the operation order next to the operation order executed last is assigned as the operation order of the first write operation.
For example, if the last executed operation sequence is N, where N is an arbitrary natural number, the operation sequence of the first write operation is N + 1.
Specifically, when a read data object is selected for the first time, determining a sequence identifier carried by the selected read data object and recording the sequence identifier as a temporary value of an operation sequence identifier, subsequently selecting one read data object every time, comparing the sequence identifier carried by the selected read data object with the temporary value of the recorded operation sequence identifier, replacing the temporary value of the recorded operation sequence identifier with the sequence identifier carried by the currently selected read data object if the temporary value of the recorded operation sequence identifier carried by the currently selected read data object is the temporary value of the recorded operation sequence identifier, comparing the temporary value of the recorded operation sequence identifier with the sequence identifier carried by the written data object, and recording the next sequence identifier with a larger value between the temporary value and the sequence identifier as the operation sequence identifier.
For example, it is assumed that a transaction T performs a read operation on several read data objects G2 and G3 … … Gn before performing a write operation on a write data object G1, each data object carrying an order identifier, the order identifiers carried by G1, G2 and G3 … … Gn are respectively represented by Gs1, Gs2 and Gs3 … … Gsn, Gs1 is updated after performing the write operation on G1, the updated Gs1 is the same as the operation order identifier corresponding to the write operation performed on the write data object G1 by the transaction T, the operation order identifier is max { Gs1, Gs2 and Gs3 … … Gsn } + [ delta ] s, max is the operation of taking the maximum value, and [ delta ] s is the increment of the log sequence identifier generated for each transaction corresponding to one updated data combination. For example, when Gs1, Gs2, and Gs3 … … Gsn are natural numbers, Δ s is 1. When the transaction T commits, the transaction log is written with the write operation performed by the transaction T on the written data object G1 and the operation sequence identifier corresponding to the write operation, and according to the operation sequence identifier corresponding to the write operation, the relative logical sequence between the transaction log of the write operation performed by the transaction T on the written data object G1 and other transaction logs can be determined.
Optionally, the data object comprises a primitive or a set of primitives, wherein the set of primitives comprises at least two primitives; correspondingly, the data object carries a sequence identifier, and the sequence identifier is used for representing the operation sequence of the write operation when the write operation is executed for the last time on the data object, and includes: the elementary data units carry a sequence identifier for characterizing an operation sequence of the write operation when the elementary data unit was last written, or the set of elementary data units carry a sequence identifier for characterizing an operation sequence of any elementary data unit in the set of elementary data units when the write operation was last written.
Specifically, the data object may be a basic data unit, such as a data item, and each basic data unit may carry an order identifier, where the order identifier is an order corresponding to the last write operation performed on the basic data unit. However, since a basic data unit carrying a sequence identifier inevitably wastes storage space, in order to save storage space, the data object may also be a basic data unit set, for example, a basic data unit set includes a plurality of data items, a basic data unit set carries a sequence identifier, and any basic data unit in the basic data unit set correspondingly updates the sequence identifier of the basic data unit set when a write operation is performed.
And when the data object is the basic data unit set, splitting the data set into the basic data unit set before determining the operation sequence of the first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object. That is, the data set is split into sets of elementary data units according to certain principles. One possible implementation is to use a table mechanism or a partitioning mechanism in an existing database.
Specifically, the data set includes a table (i.e., table) or a partition (i.e., partition) of the database, the primitive set includes buckets (i.e., bucket) of the database, bucket operations (i.e., hive) are performed on primitives in the table or the partition, the buckets are grouped into at least two buckets, and one bucket represents one primitive set and includes several primitives. The first set of primitives can be referred to as a first bucket and the second set of primitives can be referred to as a second bucket. For example, as shown in FIG. 4, in existing database management systems, table 301 has grouped data, and each bucket 302 represents a set of primitives.
Optionally, in this case, in step 201, before determining the operation sequence of the first write operation to be performed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, adding a read lock to the buckets corresponding to the at least one read data object and the write data object, that is, adding a read lock to the first bucket and the second bucket, so that the transaction reads data in the first bucket and the second bucket;
optionally, in this case, in step 202, before performing the first write operation on the data object to be written according to the data read from the at least one data object to be read, a write lock is applied to a bucket corresponding to the data object to be written, that is, a write lock is applied to a second bucket, so that the transaction performs the write operation on the data in the second bucket.
The log management method provided by the embodiment of the present application is further described in detail below with reference to a specific application scenario in which the data set includes a table of the database and the primitive data unit set includes a bucket of the database.
Referring to fig. 5, the flow of the log management method is as follows.
Step 401: judging whether the transaction is submitted, if so, executing step 408; otherwise, step 402 is performed.
Step 402: it is determined whether the transaction reads data in the first bucket, if yes, step 403 is performed, otherwise, step 406 is performed.
Step 403: and recording the sequence identification carried by the read first bucket.
Step 404: comparing whether the sequence identifier carried by the first bucket is larger than the temporary value of the operation sequence identifier recorded aiming at the current transaction, if so, executing the step 405; otherwise, return to execute step 402.
Step 405: and replacing the temporary value of the operation sequence identifier recorded by the current transaction with the sequence identifier carried by the first bucket.
Step 406: and judging whether the transaction executes the write operation on the second bucket, if so, executing step 407, and otherwise, returning to step 401.
The write operation herein includes operations of change, deletion, and the like.
Step 407: and comparing the temporary value of the operation sequence identifier recorded by the current transaction with the sequence identifier carried by the second bucket, replacing the next sequence identifier of the larger one of the temporary value and the sequence identifier with the operation sequence identifier recorded by the current transaction, and continuing to return to the execution step 401.
Step 408: and writing the transaction into a transaction log according to the operation sequence identifier recorded by the transaction and the write operation executed on the second bucket, and writing the transaction log into a log storage area corresponding to the disk when the transaction is submitted. Wherein, the recorded operation sequence identification is added at the head of the transaction log.
Optionally, the transaction log in step 202 includes at least two sub-transaction logs, and the operation sequence identifiers recorded in any two sub-transaction logs are independent from each other; when the write operation is carried out on the written data object, the write operation and the operation sequence identification corresponding to the write operation are written into the corresponding sub-transaction log. It should be appreciated that the corresponding sub-transaction log only records other write operations that are dependent on, i.e., not independent of, the write operation. The critical area of log management is removed, so that the transaction log does not need to be globally ordered, and the realization of improving the processing parallelism of the database is facilitated.
Referring to fig. 6, three different users perform data interaction with the database 102 through different clients 101, and assume that the clients 1, 2 and 3 are respectively represented to generate transactions 1, 2 and 3, each transaction has an independent log recording space in the log storage area 110, and assume that the transactions are respectively represented by the log storage area 1, the log storage area 2 and the log storage area 3, and each transaction writes processed transaction logs into the corresponding log storage area 110, so that the transaction logs do not conflict with each other, complete parallelization of log operations can be achieved, and the concurrence and expansion capability of log cache is ensured to the maximum extent. When data are recovered according to the transaction logs, the transaction logs read from different log storage areas determine the sequence of log replay according to the operation sequence identification carried in the transaction logs.
Based on the same inventive concept, the embodiment of the present application further provides a log management device, where the log management device has a function of implementing the log management method, and the function may be implemented by hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the functions described above.
Referring to fig. 7, in one possible implementation manner, the log management apparatus 600 includes: a writing unit 601 and an identification assignment unit 602.
A writing unit 601, configured to perform a first write operation on a data object to be written according to data read from at least one data object to be read;
an identifier allocating unit 602, configured to determine an operation sequence of a first write operation to be performed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object;
a writing unit 601, further configured to write the first write operation and the determined operation sequence into a transaction log;
the identifier allocating unit 602 is further configured to replace the sequence identifier carried by the written data object with a sequence identifier corresponding to the determined operation sequence.
Optionally, the identifier assigning unit 602 is configured to:
traversing the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, and selecting the last executed operation sequence from the operation sequences represented by the traversed sequence identifiers;
and determining that the operation sequence next to the last executed operation sequence is the operation sequence of the first write operation.
Optionally, if the last executed operation sequence is N, where N is any natural number, the identifier allocating unit 602 is configured to: the operation order of the first write operation is determined to be N + 1.
Optionally, the transaction log includes at least two sub-transaction logs, and the operation sequences recorded by any two sub-transaction logs are independent from each other; the writing unit 601 is configured to: the first write operation and the determined operation order are written to a sub-transaction log for recording that is not independent of the first write operation.
Optionally, the data object comprises a primitive or a set of primitives, wherein the set of primitives comprises at least two primitives;
correspondingly, the data object carries a sequence identifier, and the sequence identifier is used for representing the operation sequence of the write operation when the write operation is executed for the last time on the data object, and includes: the elementary data units carry a sequence identifier for characterizing an operation sequence of the write operation when the elementary data unit was last written, or the set of elementary data units carry a sequence identifier for characterizing an operation sequence of any elementary data unit in the set of elementary data units when the write operation was last written.
Optionally, when the data object comprises a set of elementary data units, the apparatus 600 further comprises a grouping unit 603;
a grouping unit 603, configured to split the data set into a basic data unit set before the identifier allocating unit 602 determines, according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, an operation sequence of a first write operation to be performed.
Optionally, the data set includes a table or a partition of the database, the set of primitives includes a bucket of the database, and the grouping unit 603 is configured to: bucket operations are performed on primitives in the table or partition, grouped into at least two buckets.
Optionally, the apparatus 600 further comprises a locking unit 604;
a locking unit 604, configured to add a read lock to a bucket corresponding to the at least one read data object and the written data object before the identifier allocating unit 602 determines, according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the written data object, an operation sequence of a first write operation to be performed.
Optionally, the locking unit 604 is further configured to add a write lock to a bucket corresponding to the data object to be written before the writing unit 601 performs the first write operation on the data object to be written.
Optionally, the operation sequence identifier or the sequence identifier includes: a log sequence number or a timestamp.
Based on the same inventive concept, referring to fig. 8, an embodiment of the present application further provides a log management apparatus 700, where the log management apparatus 700 is applied to a database, the database includes a transaction log and a data set, the data set includes at least two data objects, the data objects carry sequence identifiers, the sequence identifiers are used for characterizing an operation sequence of a write operation when the data object is last written, the transaction log is used for recording the write operation and the operation sequence of the write operation, the data objects include at least one read data object and one written data object, the log management apparatus 700 includes a memory 701 and a processor 702, where the memory 701 is used for storing a group of programs, and the processor 702 is used for calling the programs stored in the memory 701 to perform the log management method described above. The processor 702 is configured to: determining an operation sequence of a first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object; performing a first write operation to a written data object based on data read from at least one read data object; and writing the first write operation and the determined operation sequence into a transaction log, and replacing the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence. Therefore, the transaction log can be added with a local ordered operation sequence identifier, and when a fault is recovered, the partial order relation of each transaction log can be determined through the operation sequence identifier carried in the transaction log, so that the parallelism of data recovery through the transaction log is improved, the effectiveness and the correctness of data recovery through the transaction log are ensured, the processing speed of the database is improved, and the performance of the database is improved.
Optionally, the processor 702 is configured to: traversing the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, and selecting the last executed operation sequence from the operation sequences represented by the traversed sequence identifiers; determining that the operation sequence next to the operation sequence executed last is the operation sequence of the first write operation. Therefore, the accuracy of the logic sequence among the transaction logs can be ensured, and the correctness of the partial order relation among the transaction logs is ensured when the data is recovered through the transaction logs.
Optionally, the last executed operation sequence is N, where N is any natural number, and the processor 702 is configured to: the operation order of the first write operation is determined to be N + 1.
Optionally, the transaction log includes at least two sub-transaction logs, and the operation sequences recorded by any two sub-transaction logs are independent from each other; the processor 702 is further configured to: the first write operation and the determined operation order are written to a sub-transaction log for recording that is not independent of the first write operation. Therefore, a critical area of log management is removed, the transaction log does not need to be globally ordered, and the realization of improving the processing parallelism of the database is facilitated.
Optionally, the data object comprises an elementary data unit or a set of elementary data units, the set of elementary data units comprising at least two elementary data units; correspondingly, the data object carries a sequence identifier, and the sequence identifier is used for representing the operation sequence of the write operation when the write operation is executed for the last time on the data object, and includes: the elementary data units carry a sequence identifier for characterizing an operation sequence of the write operation when the elementary data unit was last written, or the set of elementary data units carry a sequence identifier for characterizing an operation sequence of any elementary data unit in the set of elementary data units when the write operation was last written. When the data object comprises the basic data unit set, each basic data unit set carries a sequence identifier, and waste of memory can be reduced.
Optionally, the processor 702 is further configured to: when the data object comprises a basic data unit set, according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the written data object, before determining the operation sequence of the first write operation to be executed, splitting the data set into the basic data unit set.
Optionally, the data set includes a table or partition of the database, the set of primitives includes a bucket of the database, and the processor 702 is further configured to: bucket operations are performed on primitives in the table or partition, grouped into at least two buckets. Therefore, the grouping mechanism of the basic data unit is realized based on the table or the partition, and the universality and the convenience of the realization of the partial ordering relation of the transaction log can be ensured.
Optionally, the processor 702 is further configured to: and adding a reading lock to the bucket corresponding to the at least one read data object and the write data object before determining the operation sequence of the first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object. The data object can be successfully and accurately read by the current transaction.
Optionally, the processor 702 is further configured to: and before the first write operation is executed on the written data object, adding a write lock to a bucket corresponding to the written data object. The current transaction can be ensured to smoothly and accurately carry out write operation on the bucket corresponding to the written data object.
Optionally, the operation sequence identifier or the sequence identifier includes: a Log Sequence Number (LSN) or a timestamp.
The processor 702 may be a Central Processing Unit (CPU), a Network Processor (NP), or a combination of a CPU and an NP.
The processor 702 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit (ASIC), a Programmable Logic Device (PLD), or a combination thereof. The PLD may be a Complex Programmable Logic Device (CPLD), a field-programmable gate array (FPGA), a General Array Logic (GAL), or any combination thereof.
The memory 701 may include a volatile memory (RAM), such as a random-access memory (RAM); the memory 701 may also include a non-volatile memory (english: non-volatile memory), such as a flash memory (english: flash memory), a hard disk (english: hard disk drive, abbreviated: HDD) or a solid-state drive (english: SSD); the memory 701 may also comprise a combination of memories of the kind described above.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all alterations and modifications as fall within the scope of the application.
It will be apparent to those skilled in the art that various changes and modifications may be made in the embodiments of the present application without departing from the spirit and scope of the embodiments of the present application. Thus, if such modifications and variations of the embodiments of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to encompass such modifications and variations.

Claims (21)

1. A log management method is applied to a database, and is characterized in that the database comprises a transaction log and a data set, the data set comprises at least two data objects, the data objects carry sequence identifiers, the sequence identifiers are used for characterizing operation sequences of write operations when the data objects are subjected to write operations last time, the transaction log is used for recording the write operations and the operation sequences of the write operations, the data objects comprise at least one read data object and one write data object, and the method comprises the following steps:
determining an operation sequence of a first write operation to be executed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object;
performing the first write operation to the written data object in accordance with data read from the at least one read data object;
writing the first write operation and the determined operation sequence into the transaction log, and replacing the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence.
2. The method of claim 1, wherein determining an operation order of a first write operation to be performed according to the order identifier carried by the at least one read data object and the order identifier carried by the write data object comprises:
traversing the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, and selecting the last executed operation sequence from the operation sequences represented by the traversed sequence identifier;
determining that an operation order next to the last executed operation order is an operation order of the first write operation.
3. The method of claim 2, wherein the last executed operation order is N, where N is an arbitrary natural number, and wherein determining that the next operation order of the last executed operation order is the operation order of the first write operation comprises:
and determining the operation sequence of the first write operation to be N + 1.
4. The method according to any one of claims 1 to 3, wherein the transaction log comprises at least two sub-transaction logs, and the operation sequences of any two sub-transaction logs are independent of each other;
the writing the first write operation and the determined sequence of operations to the transaction log includes:
writing the first write operation and the determined sequence of operations to the sub-transaction log for recording non-independence from the first write operation.
5. The method of any of claims 1 to 3, wherein the data object comprises a primitive or a set of primitives, the set of primitives comprising at least two of the primitives;
correspondingly, the data object carries a sequence identifier, where the sequence identifier is used to represent an operation sequence of the write operation when the write operation is executed for the last time on the data object, and the method includes: the elementary data unit carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when the elementary data unit was last written, or the elementary data unit set carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when any elementary data unit in the elementary data unit set was last written.
6. The method of claim 5, wherein when the data object comprises the set of elementary data units, the method further comprises, before determining the operation order of the first write operation to be performed based on the sequential identification carried by the at least one read data object and the sequential identification carried by the write data object:
splitting the set of data into the set of primitives.
7. The method of claim 6, wherein the set of data comprises a table or partition of the database, wherein the set of primitives comprises buckets of the database, and wherein splitting the set of data into the set of primitives comprises:
performing bucket operations on the primitives in the table or the partition, grouped into at least two of the buckets.
8. The method of claim 7, wherein before determining the operation order of the first write operation to be performed according to the order identifier carried by the at least one read data object and the order identifier carried by the write data object, the method further comprises:
and adding a read lock to the bucket corresponding to the at least one read data object and the write data object.
9. The method of claim 7 or 8, wherein prior to performing the first write operation on the written data object, the method further comprises:
and adding a write lock to the bucket corresponding to the written data object.
10. The method according to any of claims 1 to 3, wherein the sequential identification comprises: a log sequence number or a timestamp.
11. A log management device applied to a database, wherein the database includes a transaction log and a data set, the data set includes at least two data objects, the data objects carry sequence identifiers, the sequence identifiers are used to characterize an operation sequence of a write operation when the write operation is performed last time on the data objects, the transaction log is used to record the write operation and the operation sequence of the write operation, the data objects include at least one read data object and one write data object, and the device includes:
the identification distribution unit is used for determining the operation sequence of the first write operation to be executed according to the sequence identification carried by the at least one read data object and the sequence identification carried by the write data object;
a write unit configured to perform the first write operation on the written data object according to data read from the at least one read data object;
the writing unit is further configured to write the first write operation and the determined operation sequence into the transaction log;
the identifier allocating unit is further configured to replace the sequence identifier carried by the written data object with the sequence identifier corresponding to the determined operation sequence.
12. The apparatus according to claim 11, wherein the identifier assigning unit is specifically configured to:
traversing the sequence identifier carried by the at least one read data object and the sequence identifier carried by the write data object, and selecting the last executed operation sequence from the operation sequences represented by the traversed sequence identifier;
determining that an operation order next to the last executed operation order is an operation order of the first write operation.
13. The apparatus according to claim 12, wherein the last executed operation sequence is N, where N is any natural number, and the identifier assigning unit is specifically configured to:
and determining the operation sequence of the first write operation to be N + 1.
14. The apparatus according to any one of claims 11 to 13, wherein the transaction log comprises at least two sub-transaction logs, and the operation sequences of any two sub-transaction logs are independent of each other;
the write unit is specifically configured to:
writing the first write operation and the determined sequence of operations to the sub-transaction log for recording non-independence from the first write operation.
15. The apparatus of any of claims 11 to 13, wherein the data object comprises a primitive or a set of primitives, the set of primitives comprising at least two of the primitives;
correspondingly, the data object carries a sequence identifier, where the sequence identifier is used to represent an operation sequence of the write operation when the write operation is executed for the last time on the data object, and the method includes: the elementary data unit carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when the elementary data unit was last written, or the elementary data unit set carries the sequence identifier, where the sequence identifier is used to characterize an operation sequence of the write operation when any elementary data unit in the elementary data unit set was last written.
16. The apparatus of claim 15, wherein when the data object comprises the set of elementary data units, the apparatus further comprises a grouping unit;
the grouping unit is configured to split the data set into the basic data unit set before the identifier allocating unit determines an operation order of a first write operation to be performed according to the order identifier carried by the at least one read data object and the order identifier carried by the write data object.
17. The apparatus of claim 16, wherein the set of data comprises a table or partition of the database, wherein the set of primitives comprises buckets of the database, and wherein the grouping unit is specifically configured to:
performing bucket operations on the primitives in the table or the partition, grouped into at least two of the buckets.
18. The apparatus of claim 17, further comprising a locking unit;
the locking unit is configured to add a read lock to the bucket corresponding to the at least one read data object and the written data object before the identifier allocating unit determines an operation sequence of a first write operation to be performed according to the sequence identifier carried by the at least one read data object and the sequence identifier carried by the written data object.
19. The apparatus of claim 18, wherein the locking unit is further configured to lock the bucket corresponding to the written data object before the writing unit performs the first write operation on the written data object.
20. The apparatus according to any of claims 11 to 13, wherein the operation sequence identifier or the sequence identifier comprises: a log sequence number or a timestamp.
21. A computer usable storage medium having a computer program stored thereon, wherein the computer program when executed by a processor implements the steps of the method of any one of claims 1 to 10.
CN201610617168.6A 2016-07-28 2016-07-28 Log management method and device Active CN107665219B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610617168.6A CN107665219B (en) 2016-07-28 2016-07-28 Log management method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610617168.6A CN107665219B (en) 2016-07-28 2016-07-28 Log management method and device

Publications (2)

Publication Number Publication Date
CN107665219A CN107665219A (en) 2018-02-06
CN107665219B true CN107665219B (en) 2021-01-29

Family

ID=61121978

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610617168.6A Active CN107665219B (en) 2016-07-28 2016-07-28 Log management method and device

Country Status (1)

Country Link
CN (1) CN107665219B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110795318B (en) * 2018-08-01 2023-05-02 阿里云计算有限公司 Data processing method and device and electronic equipment
CN110377612B (en) * 2019-07-17 2020-12-22 武汉达梦数据库股份有限公司 Method for sequencing and recombining data updating operation and corresponding device
CN110457898B (en) * 2019-07-29 2020-10-30 创新先进技术有限公司 Operation record storage method, device and equipment based on trusted execution environment
US10783054B2 (en) 2019-07-29 2020-09-22 Alibaba Group Holding Limited Method, apparatus, and device for storing operation record based on trusted execution environment
CN112347065B (en) * 2019-08-07 2023-08-18 中国船舶工业系统工程研究院 Recording and replay method and system for police plan making process
CN112527759B (en) * 2021-02-09 2021-06-11 腾讯科技(深圳)有限公司 Log execution method and device, computer equipment and storage medium
CN113254460B (en) * 2021-07-07 2022-01-11 阿里云计算有限公司 Data processing method, system, electronic device and storage medium

Family Cites Families (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8768890B2 (en) * 2007-03-14 2014-07-01 Microsoft Corporation Delaying database writes for database consistency
CN101089857B (en) * 2007-07-24 2011-05-11 中兴通讯股份有限公司 Internal store data base transaction method and system
CN100562858C (en) * 2007-09-12 2009-11-25 华为技术有限公司 The methods, devices and systems of EMS memory data-base remote disaster tolerance
CN101119414A (en) * 2007-09-19 2008-02-06 华为技术有限公司 Method and system to access database
CN100498796C (en) * 2007-09-30 2009-06-10 华为技术有限公司 Logic log generation method, database backup/ restoration method and system
CN101183377B (en) * 2007-12-10 2010-09-08 华中科技大学 High availability data-base cluster based on message middleware
CN100555289C (en) * 2007-12-20 2009-10-28 中国科学院计算技术研究所 A kind of continuous data protection system and its implementation
CN101262493B (en) * 2008-01-14 2011-10-05 深圳市深信服电子科技有限公司 Method for accelerating inter-network data transmission via stream buffer
CN101286127B (en) * 2008-05-08 2010-06-02 华中科技大学 Multi-fork diary memory continuous data protecting and restoration method
CN100583050C (en) * 2008-06-11 2010-01-20 华中科技大学 Method for protecting and recovering continuous data based on time stamp diary memory
CN101488012A (en) * 2009-02-13 2009-07-22 国网电力科学研究院 Method for implementing sequential control by flow diagram
CN101699439B (en) * 2009-11-16 2011-12-28 中兴通讯股份有限公司 Database transaction submitting method and device
CN102222071B (en) * 2010-04-16 2014-04-02 华为技术有限公司 Method, device and system for data synchronous processing
US9092475B2 (en) * 2011-11-07 2015-07-28 Sap Se Database log parallelization
CN102611924B (en) * 2012-03-02 2014-09-03 何震宇 Flow control method and system of video cloud platform
CN103729442B (en) * 2013-12-30 2017-11-24 华为技术有限公司 Record the method and database engine of transaction journal

Also Published As

Publication number Publication date
CN107665219A (en) 2018-02-06

Similar Documents

Publication Publication Date Title
CN107665219B (en) Log management method and device
US10372559B2 (en) Managing a redundant computerized database using a replicated database cache
US9189487B2 (en) Method for recording transaction log, and database engine
CN102541757B (en) Write cache method, cache synchronization method and device
CN1179281C (en) Method and arrangement for performing atomic updates using logical flash memory device
US9558077B1 (en) Relational database recovery
JP2001142751A (en) Method and device for data base management and storage medium with recorded database managing program
US10176049B2 (en) Logging process in a data storage system
CN109213432B (en) Storage device for writing data using log structured merge tree and method thereof
US20170212902A1 (en) Partially sorted log archive
CN109726264B (en) Method, apparatus, device and medium for index information update
CN113515501B (en) Nonvolatile memory database management system recovery method and device and electronic equipment
CN110597663A (en) Transaction processing method and device
CN111125040A (en) Method, apparatus and storage medium for managing redo log
CN104899117A (en) Memory database parallel logging method for nonvolatile memory
CN111930716A (en) Database capacity expansion method, device and system
CN113076220A (en) Data processing method and device, electronic equipment and computer readable medium
CN104035822A (en) Low-cost efficient internal storage redundancy removing method and system
CN113253932B (en) Read-write control method and system for distributed storage system
CN112965939A (en) File merging method, device and equipment
KR100725415B1 (en) Log compaction method and apparatus of database
US10877881B2 (en) In-place garbage collection of a sharded, replicated distributed state machine based on mergeable operations
US10452496B2 (en) System and method for managing storage transaction requests
CN105659214B (en) The checkpointing of data cell set
WO2016117007A1 (en) Database system and database management method

Legal Events

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