Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

High-performance database read-write separation method

A read-write separation and database technology, which is applied in the field of high-performance database read-write separation, can solve problems such as unbalanced load, increased network delay of middleware nodes, and increased processing difficulty, achieving the effect of low performance overhead and avoiding high cost

Pending Publication Date: 2021-03-16
中软国际科技服务南京有限公司
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0011] 2) The read / write operation is not only manifested in a single SQL statement itself, but also needs to consider whether there is a write operation in the entire transaction, which increases the complexity of application development, and if it is not handled properly, it will lead to processing errors
[0012] 3) The application needs to perform fault management for each data source, and perform correct read / write switching when a fault occurs, and isolate the faulty data source, which increases the difficulty of processing
[0016] 1) The read / write operation is not only manifested in a single SQL statement itself, but in a transaction. It is more difficult for the middleware to identify whether there is a write operation in the transaction, and it may also be the wrong transaction setting of the Application, so there is a problem location Increased difficulty
[0017] 2) The middleware is the proxy for the application to access the database. All requests must pass through the middleware, and the middleware may become a performance bottleneck
[0018] 3) Because all requests pass through the middleware, the CPU processing delay of the middleware is increased; if the middleware is deployed independently, it will also increase the network delay of the middleware node
[0022] 1) The application only points to the main library (writing library) or the standby library (reading library). Once the main library fails, it is impossible to find a switchable standby library
[0023] 2) For applications that only have read operations, if only one read library is configured, the above-mentioned problem of writing libraries will also exist, and other read libraries cannot be found after the failure
[0029] 1) The cost of the Oracle database license and magnetic array is very high. The O in the IOE movement refers to ORACLE, and the E refers to the EMC magnetic array used.
[0030] 2) The listener does not distinguish between read and write operations. The read / write operations of the same data from different applications will be distributed to multiple instances in parallel for simultaneous processing. In order to obtain consistent processing results, data modification operations need to be performed in the memory of the relevant instance Synchronize between, so it is easy to cause lock waiting during concurrent processing, and transaction deadlock occurs in severe cases
[0031] 3) The listener does not distinguish between read and write operations, and cannot independently expand the read library, and the capacity for expansion is limited
[0032] 4) If the loadbalance policy is configured, the allocated connection instance may be in a fault state, resulting in the need for a reconnection request; if the failover policy is configured, the connection instance needs to be allocated in order. Except for the faulty instance that needs failover, the instance load registered in front will be Higher than other instances, resulting in load imbalance

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
  • High-performance database read-write separation method
  • High-performance database read-write separation method
  • High-performance database read-write separation method

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0077] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

[0078] The present invention uses the combination of floating IP and database reading and writing instance scheduling to realize database cluster management, and the application program accesses the database cluster just like accessing a single database, and does not need to care about the internal networking of the cluster, which realizes the "middleware solution" It also overcomes the problem of extra processing delay and network node delay caused by the introduct...

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 high-performance database read-write separation method which is characterized by comprising the following steps: S1, Application initiates a database connection request through a database driving program, wherein the IP of the connection request is a floating IP, and Port is a scheduler Port; s2, the main scheduler acquires a connection request of Applications, and allocates a write library or read library database instance node according to a read-write rule and a load balancing rule configured by a user in advance after acquiring related parameters; s3, the main scheduler returns the allocated database instance IP and Port to the Application; s4, the database drive program initiates connection to the distributed database instance IP and Port again, and real database connection is obtained; and S5, the Application initiates an SQL request through real database connection, thus obtaining an SQL processing result, and realizing database cluster management by using a mode of combining a floating IP and database read-write instance scheduling.

Description

technical field [0001] The invention relates to the technical field of databases and their applications, in particular to a high-performance database reading and writing separation method. Background technique [0002] Whether it is an open source database or a commercial database, the service capability of a single database is limited, and the reliability cannot meet the 7*24 hours service. In order to improve the reliability of the database system and enhance the service capability of the database system, the industry generally uses the cluster scheme of "separation of reading and writing" of the database - the main database is used as the "write" database, and the standby database is used as the "read" database, and the read load is transferred from the main database Stripped out, and when the main library fails, one of the standby databases will be switched to the main library. Such as figure 1 , because the main database and the standby database are different database...

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
IPC IPC(8): G06F16/2455G06F16/27
CPCG06F16/27G06F16/24561
Inventor 李臻峰
Owner 中软国际科技服务南京有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products