Eureka AIR delivers breakthrough ideas for toughest innovation challenges, trusted by R&D personnel around the world.

Method and database engine for recording transaction log

A database and log technology, applied in the database field, can solve the problems of reduced database system availability, slow writing of transaction logs to disk, poor user experience, etc., to improve user experience, reduce lock granularity, and improve performance.

Active Publication Date: 2017-11-24
HUAWEI CLOUD COMPUTING TECH CO LTD
View PDF4 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

However, the serial method makes the transaction log writing to the disk very slow, and a single cache queue will cause the resource to be locked when responding to a request, and other requests must wait for unlocking, so the lock granularity is large, resulting in reduced availability of the database system , poor user experience

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and database engine for recording transaction log
  • Method and database engine for recording transaction log
  • Method and database engine for recording transaction log

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0069] In order to make the object, technical solution and advantages of the present invention clearer, the implementation manner of the present invention will be further described in detail below in conjunction with the accompanying drawings.

[0070] The embodiments of the present invention relate to a method for recording transaction logs and a database engine for recording transaction logs. The method for recording transaction logs and the database engine can be applied to database systems such as stand-alone, cluster or dual-machine backup. FIG. 1 is a schematic diagram of an application scenario of the above method and database engine. in, Figure 1a It is a schematic diagram of a stand-alone database system, which provides services such as query and modification of the database through the database engine, and stores them in the disk accordingly. Figure 1b It is a schematic diagram of a cluster database system, including multiple database engines, which provide users...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a method for recording transaction logs and a database engine, belonging to the technical field of databases. The method includes: receiving an SQL request; modifying a data page corresponding to the SQL request according to the SQL request; generating a corresponding transaction log for the modification; partitioning the transaction log to obtain multiple log fragments, and The log fragments are written into multiple cache queues, and the log fragments in the multiple cache queues are written into log files in parallel. The database engine includes: receiving module, modifying module, generating module and writing module. The present invention realizes parallel record transaction log, because there are multiple cache queues, and writing log files is a parallel processing mode, therefore, not only reduces the lock granularity of transaction log cache queue, but also greatly improves the log file write disk Speed, improve the performance of the database system, and enhance the user experience.

Description

technical field [0001] The invention relates to the technical field of databases, in particular to a method for recording transaction logs and a database engine. Background technique [0002] The transaction log of the database is a file used to record every modification activity of the database. The transaction log is the basis for undoing transactions and recovering them in case of failure. Different from ordinary system logs, database transaction logs need to ensure sequence consistency when recording changes in the database system. When recovering from a fault, it is also required to recover completely in the order in which transactions occurred. Usually, in order to reduce input and output, the database system adopts the WAL (Write-Ahead Logging, write-ahead log) mechanism to record the transaction log. WAL means that modifications to data files must occur after these modifications have been recorded in the transaction log, that is, after the log records describing th...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): G06F17/30
CPCG06F16/2358G06F11/1471G06F16/27G06F11/1469G06F2201/80G06F16/137G06F16/00G06F16/152G06F16/2365
Inventor 于巍刘辉军聂愿愿
Owner HUAWEI CLOUD COMPUTING TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Eureka Blog
Learn More
PatSnap group products