WO2013026287A1 - Data control method and system based on distributed database system - Google Patents

Data control method and system based on distributed database system Download PDF

Info

Publication number
WO2013026287A1
WO2013026287A1 PCT/CN2012/074552 CN2012074552W WO2013026287A1 WO 2013026287 A1 WO2013026287 A1 WO 2013026287A1 CN 2012074552 W CN2012074552 W CN 2012074552W WO 2013026287 A1 WO2013026287 A1 WO 2013026287A1
Authority
WO
WIPO (PCT)
Prior art keywords
master server
server node
function
stored procedure
transaction
Prior art date
Application number
PCT/CN2012/074552
Other languages
French (fr)
Chinese (zh)
Inventor
徐宜良
常二鹏
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2013026287A1 publication Critical patent/WO2013026287A1/en

Links

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/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • G06F16/278Data partitioning, e.g. horizontal or vertical partitioning

Definitions

  • the present invention relates to the field of communications, and in particular, to a data control method and system based on a distributed database system. Background technique
  • multiple server nodes form a server cluster, and data is distributed on multiple server nodes, and data is processed synchronously by using a dedicated central processing unit (CPU) and a hard disk under each node.
  • Each server node has equal status, including: a structured query language (SQL, STRUCTURED QUERY LANGUAGE) parsing module, an execution module, an inter-node communication module, a data storage module, and the like.
  • SQL structured query language
  • the client selects a server node to access the distributed database system through a certain consistency algorithm (such as: HASH algorithm).
  • the main object of the present invention is to provide a data control method and system based on a distributed database system, so as to solve the problem in the prior art that stored procedures and functions cannot be executed on multiple server nodes of a distributed database system, resulting in failure to fully utilize all of them.
  • the server node's CPU, hard disk and other resources reduce the server's execution efficiency.
  • a data control method based on a distributed database system is provided.
  • the data control method based on the distributed database system of the present invention comprises: the main control server node receives the stored procedure and the function execution command, and sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and the function execution command, and receives The non-master server to the transaction start notification creates a new transaction; executes the processing statements in the stored procedure and function at the master server node, and sends the processing statement to any one or more non-master server nodes; the non-master server The node executes the processing statement, and returns the obtained processing result to the master server node; the master server node executes all processing statements of the stored procedure and the function according to the processing result, and sends a transaction commit notification to any one or more The non-master server node, the non-master server node receives the transaction commit notification and submits the created new transaction.
  • the method further includes: the master server receives a create command for creating a stored procedure and a function; and parses the vocabulary and syntax of the stored procedure and the function according to the create command, and Record the contents of each statement in the stored procedure and function.
  • the method further includes: the master server node replaces the variable name in the processing statement with a specific variable value Change.
  • the method further includes: determining whether the master server node sends the transaction start notification successfully, In the case of a failed transmission, the system ends the stored procedure and function execution.
  • the method further The method includes: returning, by the non-master server node, a result of processing the transaction start notification to the master server node; determining whether the time at which the master server node receives the processing transaction start notification result exceeds a predetermined time, wherein, in a case that the predetermined time is exceeded, Execution of the stored procedure and function command fails; if the non-master server node received by the master server node processes the transaction start notification result in the case where the predetermined time is not exceeded, the start transaction operation of any of the nodes fails, and then execution is performed. Stored procedures and functions fail.
  • the method further includes: determining whether the processing node sends the processing statement Failed, in the case of a failed delivery, the execution of the stored procedure and function failed this time.
  • the method further includes: executing a processing statement on all non-master server nodes received by the master server node In the result, if any non-master server node fails to execute the processing statement, the execution of the stored procedure and the function fails; or the time that the master server node waits for any non-master server node to execute the processing statement exceeds the time. After a certain time limit, the stored procedure and function execution failed.
  • a data control system based on a distributed database system comprises: a master control server and one or more non-master control servers, wherein
  • the master server is set to receive the stored procedure and function execution commands issued by the client, send a transaction start notification according to the stored procedure and the function execution command, execute the processing statement in the stored procedure and the function, and execute all processing of the stored procedure and the function. After the statement, send a transaction commit notification;
  • One or more non-master servers set to create a new transaction after receiving a transaction start notification, execute the received processing statement, and submit the created new transaction after receiving the transaction commit notification.
  • the master server further includes: a creating unit, configured to receive a creation command issued by the client to create a stored procedure and a function, and parse the vocabulary and syntax of the stored procedure and the function according to the create command, and record the stored procedure and function in the record Each sentence handles the contents of the statement.
  • a creating unit configured to receive a creation command issued by the client to create a stored procedure and a function, and parse the vocabulary and syntax of the stored procedure and the function according to the create command, and record the stored procedure and function in the record Each sentence handles the contents of the statement.
  • the main control server further includes: a first judging module, configured to determine whether the main control server node sends a transaction start notification is successful, in the case that the sending fails, the system ends the storing process and the function performing the operation; the second determining module, Set to determine whether the time when the master server node receives the result of processing the transaction start notification exceeds a predetermined time, wherein, in the case that the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, if the master If all the non-master server nodes received by the control server node process the transaction start notification result, if the start transaction operation of any node fails, the execution of the stored procedure and the function fails; the third judgment module is set to determine that the master server node sends Whether the processing statement fails or not, in the case of a failed transmission, the execution of the stored procedure and function fails this time.
  • a first judging module configured to determine whether the main control server node sends a transaction start notification is successful, in the
  • the master server node is used to receive the stored procedure and the function execution command; the master server node sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and the function execution command, and receives the transaction start notification.
  • the non-master server creates a new transaction; executes the processing statements in the stored procedure and function at the master server node, and processes The statement is sent to any one or more non-master server nodes; the non-master server node executes the processing statement, and returns the obtained processing result to the master server node; the master server node executes the stored procedure according to the processing result and All processing statements of the function, and send a transaction commit notification to any one or more non-master server nodes.
  • the non-master server node receives the transaction commit notification and submits the created new transaction, which solves the prior art due to stored procedures and functions. Cannot be executed on a distributed database system multi-server node, which can not fully utilize the CPU, hard disk and other resources of all server nodes, which reduces the problem of server execution efficiency, and thus achieves that stored procedures and functions can store data on multiple server node hard disks. Access and operations improve the utilization of resources and the efficiency of system execution.
  • FIG. 1 is a schematic structural diagram of a data control system based on a distributed database system according to an embodiment of the present invention
  • FIG. 2 is a flow chart of a distributed database method according to an embodiment of the present invention
  • FIG. 3 is a flowchart of a stored procedure and function creation process according to an embodiment of the present invention
  • FIG. 4 is a distributed database method according to an embodiment of the present invention
  • the invention provides a data control method and system based on a distributed database system.
  • 1 is a data control system based on a distributed database system according to an embodiment of the present invention. Schematic.
  • the system includes: a client 10, a master server node 30, and a non-master server node 50.
  • the master server node 30 is configured to receive a stored procedure and a function execution command issued by the client 10, and send a transaction start notification according to the stored procedure and the function execution command, and execute the processing statement in the stored procedure and the function at the same time. After all the processing statements of the stored procedure and the function are sent, a transaction commit notification is sent; and one or more non-master server nodes 50 are configured to create a new transaction after receiving the transaction start notification, and simultaneously execute the received processing statement, and Submit the created new transaction after receiving the transaction commit notification.
  • the processing statement in the above embodiment of the present invention is an SQL statement.
  • the foregoing embodiment of the present invention implements a method for implementing a stored procedure and a function execution in a distributed database multi-server cluster.
  • the distributed database system is composed of a plurality of server nodes, and the client 10 adopts a certain consistency algorithm (for example: HASH algorithm).
  • Selecting a server node to access the distributed database system that is, the server node with the TCP link linked to the client 10 is called the master server node, and the server node without the link link is called the non-master server node 50.
  • the above embodiment solves the problem that the stored procedure and the function cannot be executed on the multi-server node of the distributed database system by establishing the communication data feedback mechanism, so that the stored procedure and the function can store the data on the multi-server node hard disk.
  • the stored procedures and functions can be executed concurrently on multiple server nodes of the distributed database, and the CPU, hard disk and other resources of each server node can be fully utilized, thereby greatly improving the execution efficiency.
  • the master server in the foregoing embodiment may further include: a creating unit, configured to receive a create command for creating a stored procedure and a function issued by the client 10, and parse the vocabulary and syntax of the stored procedure and the function according to the create command, and simultaneously save and save the record The contents of each statement in the stored procedure and function.
  • a creating unit configured to receive a create command for creating a stored procedure and a function issued by the client 10, and parse the vocabulary and syntax of the stored procedure and the function according to the create command, and simultaneously save and save the record The contents of each statement in the stored procedure and function.
  • the master control server may further include: a first determining module, configured to determine whether the master server node sends a transaction start notification is successful, and in case the sending fails, the system ends the storing process and the function performing the operation; a module, configured to determine whether the time when the master server node receives the result of processing the transaction start notification exceeds a predetermined time, wherein, in the case that the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, If all of the non-master server nodes 50 received by the master server node process the transaction start notification result, and the start transaction operation of any of the nodes fails, the execution of the stored procedure and the function fails. And a third judging module, configured to determine whether the main control server node fails to send the processing statement, and if the sending fails, executing the stored procedure and the function fails to perform this time.
  • a first determining module configured to determine whether the master server node sends a transaction start notification is successful, and in case the sending fails,
  • FIG. 2 is a flow chart of a distributed database based method in accordance with an embodiment of the present invention. As shown in Figure 2, the method includes the following steps:
  • Step S102 the master server node 30 receives the stored procedure and the function execution command.
  • Step S104 the master server node 30 sends a transaction start notification to any one or more non-master server nodes 50 according to the stored procedure and the function execution command, and the non-master server node that receives the transaction start notification creates a new transaction.
  • Step S106 executing a processing statement in the stored procedure and the function at the master server node, and sending the processing statement to any one or more non-master server nodes 50.
  • Step S108 The non-master server node 50 executes the processing statement, and returns the obtained processing result to the master server node.
  • step S110 the master server node 30 executes all the processing statements of the stored procedure and the function according to the processing result, and sends a transaction commit notification to any one or more non-master server nodes 50, and the non-master server node 50 receives the transaction commit notification. And submit the new transaction created.
  • the foregoing embodiment implements a storage procedure and a function execution implementation method in a server cluster environment composed of multiple server nodes, and the processing statement involved may be a SQL statement, which solves the problem that the stored procedure and the function cannot be in the distributed database system.
  • Problems executed on the server node Enables stored procedures and functions to access and manipulate data stored on multiple server nodes. It allows concurrent execution of stored procedures and functions on multiple server nodes in a distributed database, enabling full utilization of CPU, hard disk, etc. of each server node. Resources have greatly improved the efficiency of execution.
  • the method may further include: the master server receiving the create command for creating the stored procedure and the function; and parsing the vocabulary of the stored procedure and the function according to the create command Grammar, and records the contents of each statement in the stored procedure and function.
  • FIG. 3 is a flow chart of a stored procedure and function creation process, as shown in FIG. 3, in accordance with an embodiment of the present invention.
  • the creation process includes the following steps:
  • Step 201 the client 10 sends a create stored procedure and a function command to the master server node.
  • Step 202 The distributed database system lexically and syntaxally parses the stored procedures and functions, and records and saves each processing statement, such as an SQL statement.
  • the foregoing embodiment may be implemented when a stored procedure and a function are created in a distributed database system, that is, when a lexical and syntax analysis is performed on a stored procedure and a function in a structured query language (STRUCTURED QUERY LANGUAGE, SQL for short). Record the contents of each SQL statement in the stored procedure and function.
  • a structured query language STRUCTURED QUERY LANGUAGE, SQL for short.
  • the method may further include: the master server node 30 replacing the variable name in the processing statement with a specific variable value.
  • the method may further include: determining that the master server node 30 sends The transaction start notification is successful. In the case of a failed transmission, the system ends the stored procedure and function execution.
  • the master server node 30 transmits a transaction start notification to any one or more non-master server nodes 50 according to the stored procedure and the function execution command, and the non-master server node 50 that has received the transaction start notification is created.
  • the method may further include: the non-master server node 50 returns a result of processing the transaction start notification to the master server node; determining whether the time at which the master server node 30 receives the processing transaction start notification result exceeds a predetermined time, wherein In the case where the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, if all the non-master server nodes 50 received by the master server node process the transaction start notification result, If a node's start transaction operation fails, the stored procedure and function fail.
  • the method may further include: determining the master Whether the server node 30 sends a processing statement fails, and if the transmission fails, the execution of the stored procedure and the function fails this time.
  • the method further includes: all non-masterings received at the master server node 30 In the result of executing the processing statement by the server node 50, if any non-master server node 50 fails to execute the processing statement, the execution of the stored procedure and the function fails; or the host server node waits for any non-master server node 50.
  • the execution of the result of the processing statement exceeds a certain time limit, the stored procedure and function execution fails.
  • Step 301 The client 10 sends a stored procedure and a function execution command to the master server node.
  • Step 302 the master server node 30 sends a transaction start notification to other non-master servers. Node 50. Specifically, the step may be implemented.
  • the master server node 30 of the distributed database system executes the stored procedure and function
  • the master server node 30 first sends a stored procedure and a function transaction start notification to the other non-master server node 50, and other non-
  • the master server node 50 creates a new transaction after receiving the transaction start notification, and sends the processing result to the master server node 30.
  • the master server node 30 sends a transaction start notification to any non-master server node 50, it is considered that the stored procedure and function send an error during the execution, and end the stored procedure. And the function performs the operation.
  • the non-master server node 50 After the non-master server node 50 receives the transaction start notification transmitted from the master server node 30, the non-master server node 50 starts creating a new transaction and transmits the processing result to the master server node.
  • the master server node 30 waits for any non-master server node 50 to process the transaction start notification. After the time exceeds a certain time limit, the stored procedure and function execution is considered to have failed, and the stored procedure and function execution operation are ended.
  • All non-master server nodes 50 received by the master server node 30 process the transaction start notification result. If the start transaction operation of any node fails, the stored procedure and the function execution are considered to be failed, and the stored procedure and the function execution operation are ended. .
  • Step 303 The master server node 30 replaces the variable name with a specific variable value before executing each SQL statement.
  • the step can implement the master server of the distributed database system. Before each SQL statement in the stored procedure and function is executed, the variable value in the content of the SQL statement is replaced by the actual value of the variable.
  • the master server node 30 sends the SQL statement to the other non-master server node 50.
  • the step may be that the master server node of the distributed database system executes the SQL statement on the local machine. If the SQL statement needs data stored by the hard disk of the other non-master server node 50, the master server node 30 The SQL statement is sent to the corresponding non-master server node 50 through a network protocol, and the non-master server node 50 receives and executes the SQL statement. And send back the execution result.
  • All the non-master server nodes 50 received by the master server node 30 execute the SQL statement result. If any node fails during the execution of the SQL statement, the stored procedure and the function execution are considered to be invalid, and the stored procedure and the function execution operation are ended. .
  • the master server node 30 waits for any non-master server node 50 to execute the SQL statement result for more than a certain time limit, then considers the stored procedure and function execution to fail, and ends the stored procedure and function execution operation.
  • the master server node 30 when the master server node 30 determines that the storage process and the function execution fail during the execution, the master server node 30 needs to notify the non-master server node 50 to process the transaction rollback before ending the stored procedure and the function execution operation. Specifically, the master server node 30 may send a transaction rollback notification to the other non-master server node 50, and the other non-master server node 50 performs the transaction rollback process after receiving the notification, and sends back the processing result.
  • the SELECT statement, the DELETE statement, and the UPDATE statement in the above process are sent to other non-master server nodes 50.
  • the INSERT statement calculates the specific server node to be sent according to the consistency algorithm of the data distribution.
  • Step 305 the non-master server node 50 receives the SQL statement, and executes the SQL statement, and sends the processing result to the master server node 30;
  • Step 306 after executing all the SQL statements of the stored procedure and the function, the master server node 30 sends a transaction commit notification to the other non-master server node 50, and the non-master server node 50 receives the transaction commit notification and submits the transaction, and sends the processing result. Send to the master server node 30.
  • the foregoing two steps may be implemented after the main control server node of the distributed database system executes the SQL statement in the stored procedure and the function, and sends a commit transaction notification to the other non-master control.
  • the server node 50, the other non-master server node 50 receives the commit transaction notification and submits the transaction, and sends the processing result to the master server node.
  • the master server node 30 sends a transaction commit notification to any of the non-master server nodes 50, it is considered that the stored procedure and function send an error during this execution and ends the stored procedure and function execution.
  • the non-master server node 50 After receiving the transaction commit notification sent by the master server node for more than a certain time limit, the non-master server node 50 considers that the stored procedure and function execution failed, and performs a transaction rollback processing operation.
  • the stored procedure and the function execution method of the present invention solve the problem that the stored procedure and function are executed on the distributed server system multiple server nodes, which may be more
  • the server node hard disk stores data for operation
  • the stored procedure and function execution method of the present invention can enable the stored procedure and function to be executed concurrently on multiple server nodes of the distributed database, thereby greatly improving the execution efficiency.
  • modules or steps of the present invention can be implemented by a general-purpose computing device, which can be concentrated on a single computing device or distributed over a network composed of multiple computing devices.
  • they may be implemented by program code executable by the computing device, such that they may be stored in the storage device by the computing device, or they may be separately fabricated into a plurality of integrated circuit modules, or they may be Multiple modules or steps in the fabrication are implemented as a single integrated circuit module.
  • the invention is not limited to any specific combination of hardware and software.

Abstract

Disclosed are a data control method and system based on a distributed database system. The method comprises: a master server node receiving a storage procedure and function execution command, and sending, according to the storage procedure and function execution command, a transaction start notification to a non-master server node, and the non-master server node creating a new transaction; when executing a processing statement, the master server node sending the processing statement to the non-master server node; the non-master server node executing the processing statement, and returning an obtained processing result to the master server node; the master server node sending a transaction submitting notification to any one or multiple non-master server nodes, and the non-master server node receiving the transaction submitting notification and submitting the created new transaction. By means of the present invention, the storage procedure and function can access and operate data stored in hard disks of multiple server nodes, thereby improving the utilization ratio of resources and execution efficiency of the system.

Description

基于分布式数据库系统的数据控制方法及系统 技术领域  Data control method and system based on distributed database system
本发明涉及通信领域, 具体而言, 尤其涉及一种基于分布式数据库系 统的数据控制方法及系统。 背景技术  The present invention relates to the field of communications, and in particular, to a data control method and system based on a distributed database system. Background technique
随着传统的数据库技术日趋成熟, 互联网应用的高速发展, 数据库应 用已经普遍出现在互联网之上。 而传统的集中式数据库系统也同时表现出 它的不足之处: 集中式管理, 势必造成性能瓶颈, 单一的提高硬件性能已 不能满足目前互联网的大数据量, 高并发查询写入的需求, 同时产生大量 的硬件维护和升级费用。 而数据库的集中管理往往造成多数据库关联, 一 旦一台数据库崩溃将造成整个系统崩溃。 所以分布式数据库将逐步取代传 统集中式数据库系统。  With the maturity of traditional database technologies and the rapid development of Internet applications, database applications have generally appeared on the Internet. The traditional centralized database system also shows its shortcomings: Centralized management, it is bound to cause performance bottlenecks, a single improvement in hardware performance can not meet the current large data volume of the Internet, high concurrent query write requirements, A lot of hardware maintenance and upgrade costs are incurred. The centralized management of the database often results in multiple database associations, and once a database crashes, the entire system will crash. Therefore, distributed databases will gradually replace traditional centralized database systems.
在分布式数据库系统中, 多台服务器节点组成服务器集群, 数据被分 布在多台服务器节点上, 利用各个节点下的本机专属中央处理器(CPU ) 和硬盘同步处理数据。 每个服务器节点地位是平等的, 包括: 对结构化查 询语言( SQL, STRUCTURED QUERY LANGUAGE )解析模块、执行模块、 节点间通信模块、 数据存储模块等。 客户端通过某种一致性算法(比如: HASH算法)选择一台服务器节点接入分布式数据库系统。  In a distributed database system, multiple server nodes form a server cluster, and data is distributed on multiple server nodes, and data is processed synchronously by using a dedicated central processing unit (CPU) and a hard disk under each node. Each server node has equal status, including: a structured query language (SQL, STRUCTURED QUERY LANGUAGE) parsing module, an execution module, an inter-node communication module, a data storage module, and the like. The client selects a server node to access the distributed database system through a certain consistency algorithm (such as: HASH algorithm).
对于传统的集中式数据库系统的存储过程和函数, 因为其集中式管理 的特点, 即存储过程和函数的执行只能使用一台服务器节点的 CPU、 同一 服务器节点下数据库实例中的表或视图。 在分布式数据库系统中, 由于多 服务器集群环境下, 数据表被分布在多台服务器节点上, 基于传统的集中 式数据库系统中存储过程和函数的执行模式无法满足分布式数据要求。 针对上述现有技术的由于存储过程和函数无法在分布式数据库系统多 服务器节点上执行, 导致无法充分利用所有的服务器节点的 CPU、 硬盘等 资源, 降低了服务器执行效率的问题, 目前还没有有效的解决方案。 发明内容 For the traditional centralized database system stored procedures and functions, because of its centralized management features, the execution of stored procedures and functions can only use the CPU of one server node, the table or view in the database instance under the same server node. In a distributed database system, due to the multi-server cluster environment, the data tables are distributed on multiple server nodes. The execution mode of stored procedures and functions in the traditional centralized database system cannot meet the distributed data requirements. In view of the above prior art, since the stored procedures and functions cannot be executed on the distributed database system multiple server nodes, the CPU, the hard disk, and the like of all the server nodes cannot be fully utilized, and the server execution efficiency is reduced. s solution. Summary of the invention
本发明的主要目的在于提供一种基于分布式数据库系统的数据控制方 法及系统, 以解决现有技术的由于存储过程和函数无法在分布式数据库系 统多服务器节点上执行, 导致无法充分利用所有的服务器节点的 CPU、 硬 盘等资源, 降低了服务器执行效率的问题。  The main object of the present invention is to provide a data control method and system based on a distributed database system, so as to solve the problem in the prior art that stored procedures and functions cannot be executed on multiple server nodes of a distributed database system, resulting in failure to fully utilize all of them. The server node's CPU, hard disk and other resources reduce the server's execution efficiency.
为了实现上述目的, 根据本发明的一方面, 提供了一种基于分布式数 据库系统的数据控制方法。  In order to achieve the above object, according to an aspect of the present invention, a data control method based on a distributed database system is provided.
本发明的基于分布式数据库系统的数据控制方法包括: 主控服务器节 点接收存储过程和函数执行命令, 根据存储过程和函数执行命令发送事务 开始通知至任意一个或多个非主控服务器节点, 接收到事务开始通知的非 主控服务器创建一个新事务; 在主控服务器节点执行存储过程和函数中的 处理语句, 并将处理语句发送至任意一个或多个非主控服务器节点; 非主 控服务器节点执行所述处理语句, 并将获取到的处理结果返回至主控服务 器节点; 主控服务器节点根据处理结果执行完存储过程和函数的所有处理 语句, 并发送事务提交通知给任意一个或多个非主控服务器节点, 非主控 服务器节点接收事务提交通知并提交创建的新事务。  The data control method based on the distributed database system of the present invention comprises: the main control server node receives the stored procedure and the function execution command, and sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and the function execution command, and receives The non-master server to the transaction start notification creates a new transaction; executes the processing statements in the stored procedure and function at the master server node, and sends the processing statement to any one or more non-master server nodes; the non-master server The node executes the processing statement, and returns the obtained processing result to the master server node; the master server node executes all processing statements of the stored procedure and the function according to the processing result, and sends a transaction commit notification to any one or more The non-master server node, the non-master server node receives the transaction commit notification and submits the created new transaction.
进一步地, 在主控服务器节点接收存储过程和函数执行命令之前, 该 方法还包括: 主控服务器接收创建存储过程和函数的创建命令; 根据创建 命令解析存储过程和函数的作词法和语法, 并记录保存存储过程和函数中 的每一句处理语句的内容。  Further, before the master server node receives the stored procedure and the function execution command, the method further includes: the master server receives a create command for creating a stored procedure and a function; and parses the vocabulary and syntax of the stored procedure and the function according to the create command, and Record the contents of each statement in the stored procedure and function.
进一步地, 在主控服务器节点执行存储过程和函数中的处理语句之前, 该方法还包括: 主控服务器节点将处理语句中的变量名称用具体变量值替 换。 Further, before the master server node executes the processing statement in the stored procedure and the function, the method further includes: the master server node replaces the variable name in the processing statement with a specific variable value Change.
进一步地, 在主控服务器节点根据存储过程和函数执行命令发送事务 开始通知至任意一个或多个非主控服务器节点之后, 该方法还包括: 判断 主控服务器节点发送事务开始通知是否成功, 在发送失败的情况下, 系统 结束该存储过程和函数执行操作。  Further, after the master server node sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and the function execution command, the method further includes: determining whether the master server node sends the transaction start notification successfully, In the case of a failed transmission, the system ends the stored procedure and function execution.
进一步地, 在主控服务器节点根据存储过程和函数执行命令发送事务 开始通知至任意一个或多个非主控服务器节点, 接收到事务开始通知的非 主控服务器创建一个新事务之后, 该方法还包括: 非主控服务器节点将处 理事务开始通知的结果返回给主控服务器节点; 判断主控服务器节点接收 处理事务开始通知结果的时间是否超过预定时间, 其中, 在超过预定时间 的情况下, 在执行存储过程和函数命令失败; 在未超过预定时间的情况下, 如果主控服务器节点接收的所有非主控服务器节点处理事务开始通知结果 中, 有任一节点的开始事务操作发生失败, 则执行存储过程和函数失败。  Further, after the master server node sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and the function execution command, after the non-master server that receives the transaction start notification creates a new transaction, the method further The method includes: returning, by the non-master server node, a result of processing the transaction start notification to the master server node; determining whether the time at which the master server node receives the processing transaction start notification result exceeds a predetermined time, wherein, in a case that the predetermined time is exceeded, Execution of the stored procedure and function command fails; if the non-master server node received by the master server node processes the transaction start notification result in the case where the predetermined time is not exceeded, the start transaction operation of any of the nodes fails, and then execution is performed. Stored procedures and functions fail.
进一步地, 在主控服务器节点执行存储过程和函数中的处理语句, 并 将处理语句发送至任意一个或多个非主控服务器节点之后, 该方法还包括: 判断主控服务器节点发送处理语句是否失败, 在发送失败的情况下, 执行 该存储过程和函数此次执行失败。  Further, after the master server node executes the processing statement in the stored procedure and the function, and sends the processing statement to any one or more non-master server nodes, the method further includes: determining whether the processing node sends the processing statement Failed, in the case of a failed delivery, the execution of the stored procedure and function failed this time.
进一步地, 在非主控服务器节点执行该处理语句, 并将获取到的处理 结果返回至主控服务器节点之后, 该方法还包括: 在主控服务器节点接收 的所有非主控服务器节点执行处理语句结果中, 如果有任一非主控服务器 节点执行处理语句过程中发生失败, 则执行存储过程和函数失败; 或者在 主控服务器节点等待任一非主控服务器节点执行处理语句结果的时间超过 了某一个时间限制后, 则存储过程和函数执行失败。  Further, after the non-master server node executes the processing statement and returns the obtained processing result to the master server node, the method further includes: executing a processing statement on all non-master server nodes received by the master server node In the result, if any non-master server node fails to execute the processing statement, the execution of the stored procedure and the function fails; or the time that the master server node waits for any non-master server node to execute the processing statement exceeds the time. After a certain time limit, the stored procedure and function execution failed.
为了实现上述目的, 根据本发明的另一个方面, 提供了一种基于分布 式数据库系统的数据控制系统。 本发明的基于分布式数据库系统的数据控制系统包括: 主控服务器和 一个或多个非主控服务器, 其中, In order to achieve the above object, according to another aspect of the present invention, a data control system based on a distributed database system is provided. The data control system based on the distributed database system of the present invention comprises: a master control server and one or more non-master control servers, wherein
主控服务器, 设置为接收客户端发出的存储过程和函数执行命令, 根 据存储过程和函数执行命令发送事务开始通知, 执行存储过程和函数中的 处理语句, 在执行完存储过程和函数的所有处理语句之后, 发送事务提交 通知;  The master server is set to receive the stored procedure and function execution commands issued by the client, send a transaction start notification according to the stored procedure and the function execution command, execute the processing statement in the stored procedure and the function, and execute all processing of the stored procedure and the function. After the statement, send a transaction commit notification;
一个或多个非主控服务器, 设置为在接收到事务开始通知之后创建一 个新事务, 执行接收到的处理语句, 并在接收到事务提交通知之后提交创 建的新事务。  One or more non-master servers, set to create a new transaction after receiving a transaction start notification, execute the received processing statement, and submit the created new transaction after receiving the transaction commit notification.
进一步地, 主控服务器还包括: 创建单元, 设置为接收客户端发出的 创建存储过程和函数的创建命令, 并根据创建命令解析存储过程和函数的 作词法和语法, 记录保存存储过程和函数中的每一句处理语句的内容。  Further, the master server further includes: a creating unit, configured to receive a creation command issued by the client to create a stored procedure and a function, and parse the vocabulary and syntax of the stored procedure and the function according to the create command, and record the stored procedure and function in the record Each sentence handles the contents of the statement.
进一步地, 主控服务器还包括: 第一判断模块, 设置为判断主控服务 器节点发送事务开始通知是否成功, 在发送失败的情况下, 系统结束该存 储过程和函数执行操作; 第二判断模块, 设置为判断主控服务器节点接收 处理事务开始通知结果的时间是否超过预定时间, 其中, 在超过预定时间 的情况下, 在执行存储过程和函数命令失败; 在未超过预定时间的情况下, 如果主控服务器节点接收的所有非主控服务器节点处理事务开始通知结果 中, 有任一节点的开始事务操作发生失败, 则执行存储过程和函数失败; 第三判断模块, 设置为判断主控服务器节点发送处理语句是否失败, 在发 送失败的情况下, 执行该存储过程和函数此次执行失败。  Further, the main control server further includes: a first judging module, configured to determine whether the main control server node sends a transaction start notification is successful, in the case that the sending fails, the system ends the storing process and the function performing the operation; the second determining module, Set to determine whether the time when the master server node receives the result of processing the transaction start notification exceeds a predetermined time, wherein, in the case that the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, if the master If all the non-master server nodes received by the control server node process the transaction start notification result, if the start transaction operation of any node fails, the execution of the stored procedure and the function fails; the third judgment module is set to determine that the master server node sends Whether the processing statement fails or not, in the case of a failed transmission, the execution of the stored procedure and function fails this time.
通过本发明, 采用主控服务器节点接收存储过程和函数执行命令; 主 控服务器节点根据存储过程和函数执行命令发送事务开始通知至任意一个 或多个非主控服务器节点, 接收到事务开始通知的非主控服务器创建一个 新事务; 在主控服务器节点执行存储过程和函数中的处理语句, 并将处理 语句发送至任意一个或多个非主控服务器节点; 非主控服务器节点执行该 处理语句, 并将获取到的处理结果返回至主控服务器节点; 主控服务器节 点根据处理结果执行完存储过程和函数的所有处理语句, 并发送事务提交 通知给任意一个或多个非主控服务器节点, 非主控服务器节点接收事务提 交通知并提交创建的新事务, 解决了现有技术的由于存储过程和函数无法 在分布式数据库系统多服务器节点上执行, 导致无法充分利用所有的服务 器节点的 CPU、 硬盘等资源, 降低了服务器执行效率的问题, 进而达到了 存储过程和函数可以对多服务器节点硬盘存储数据进行访问和操作, 提高 了资源的利用率以及系统的执行效率的效果。 附图说明 Through the invention, the master server node is used to receive the stored procedure and the function execution command; the master server node sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and the function execution command, and receives the transaction start notification. The non-master server creates a new transaction; executes the processing statements in the stored procedure and function at the master server node, and processes The statement is sent to any one or more non-master server nodes; the non-master server node executes the processing statement, and returns the obtained processing result to the master server node; the master server node executes the stored procedure according to the processing result and All processing statements of the function, and send a transaction commit notification to any one or more non-master server nodes. The non-master server node receives the transaction commit notification and submits the created new transaction, which solves the prior art due to stored procedures and functions. Cannot be executed on a distributed database system multi-server node, which can not fully utilize the CPU, hard disk and other resources of all server nodes, which reduces the problem of server execution efficiency, and thus achieves that stored procedures and functions can store data on multiple server node hard disks. Access and operations improve the utilization of resources and the efficiency of system execution. DRAWINGS
此处所说明的附图用来提供对本发明的进一步理解, 构成本发明的一 部分, 本发明的示意性实施例及其说明用于解释本发明, 并不构成对本发 明的不当限定。 在附图中:  The drawings are intended to provide a further understanding of the present invention, and are intended to be a part of the invention. In the drawing:
图 1是根据本发明实施例的基于分布式数据库系统的数据控制系统的 结构示意图;  1 is a schematic structural diagram of a data control system based on a distributed database system according to an embodiment of the present invention;
图 2是根据本发明实施例的基于分布式数据库方法的流程示意图; 图 3是根据本发明实施例的存储过程和函数创建处理流程图; 图 4是根据本发明实施例的基于分布式数据库方法的详细流程示意图。 具体实施方式  2 is a flow chart of a distributed database method according to an embodiment of the present invention; FIG. 3 is a flowchart of a stored procedure and function creation process according to an embodiment of the present invention; FIG. 4 is a distributed database method according to an embodiment of the present invention; Detailed process diagram. detailed description
为了使本发明所要解决的技术问题、 技术方案及有益效果更加清楚、 明白, 以下结合附图和实施例, 对本发明进行进一步详细说明。 应当理解, 此处所描述的具体实施例仅仅用以解释本发明, 并不用于限定本发明。  The present invention will be further described in detail below with reference to the accompanying drawings and embodiments in order to make the present invention. It is understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
本发明提供了一种基于分布式数据库系统的数据控制方法及系统。 图 1是根据本发明实施例的基于分布式数据库系统的数据控制系统的 结构示意图。 The invention provides a data control method and system based on a distributed database system. 1 is a data control system based on a distributed database system according to an embodiment of the present invention. Schematic.
如图 1所示, 该系统包括: 客户端 10, 主控服务器节点 30以及非主控 服务器节点 50。  As shown in FIG. 1, the system includes: a client 10, a master server node 30, and a non-master server node 50.
其中, 主控服务器节点 30, 用于接收客户端 10发出的存储过程和函数 执行命令, 并根据存储过程和函数执行命令发送事务开始通知, 同时执行 存储过程和函数中的处理语句, 在执行完存储过程和函数的所有处理语句 之后, 发送事务提交通知; 以及一个或多个非主控服务器节点 50, 用于在 接收到事务开始通知之后创建一个新事务, 同时执行接收到的处理语句, 并在接收到事务提交通知之后提交创建的新事务。 优选地, 本发明上述实 施例中的处理语句为 SQL语句。  The master server node 30 is configured to receive a stored procedure and a function execution command issued by the client 10, and send a transaction start notification according to the stored procedure and the function execution command, and execute the processing statement in the stored procedure and the function at the same time. After all the processing statements of the stored procedure and the function are sent, a transaction commit notification is sent; and one or more non-master server nodes 50 are configured to create a new transaction after receiving the transaction start notification, and simultaneously execute the received processing statement, and Submit the created new transaction after receiving the transaction commit notification. Preferably, the processing statement in the above embodiment of the present invention is an SQL statement.
本发明上述实施例实现了在分布式数据库多服务器集群下存储过程和 函数执行的实现方法, 该分布式数据库系统有多个服务器节点组成, 客户 端 10通过某种一致性算法(比如: HASH算法 )选择一台服务器节点接入 分布式数据库系统,也就是与客户端 10存在 TCP链路链接的服务器节点称 为主控服务器节点, 不存在链路链接的服务器节点称为非主控服务器节点 50。 上述实施例通过建立通信数据反馈机制解决了存储过程和函数执行方 法解决了存储过程和函数无法在分布式数据库系统多服务器节点上执行的 问题, 使存储过程和函数可以对多服务器节点硬盘存储数据进行访问和操 作, 即可以使存储过程和函数在分布式数据库的多个服务器节点上并发执 行, 可以充分利用每个服务器节点的 CPU、 硬盘等资源, 大大提高了执行 效率。  The foregoing embodiment of the present invention implements a method for implementing a stored procedure and a function execution in a distributed database multi-server cluster. The distributed database system is composed of a plurality of server nodes, and the client 10 adopts a certain consistency algorithm (for example: HASH algorithm). Selecting a server node to access the distributed database system, that is, the server node with the TCP link linked to the client 10 is called the master server node, and the server node without the link link is called the non-master server node 50. . The above embodiment solves the problem that the stored procedure and the function cannot be executed on the multi-server node of the distributed database system by establishing the communication data feedback mechanism, so that the stored procedure and the function can store the data on the multi-server node hard disk. By performing access and operations, the stored procedures and functions can be executed concurrently on multiple server nodes of the distributed database, and the CPU, hard disk and other resources of each server node can be fully utilized, thereby greatly improving the execution efficiency.
上述实施例中的主控服务器还可以包括: 创建单元, 用于接收客户端 10发出的创建存储过程和函数的创建命令, 并根据创建命令解析存储过程 和函数的作词法和语法, 同时记录保存存储过程和函数中的每一句处理语 句的内容。 优选地, 该主控服务器还可以包括: 第一判断模块, 用于判断主控服 务器节点发送事务开始通知是否成功, 在发送失败的情况下, 系统结束该 存储过程和函数执行操作; 第二判断模块, 用于判断主控服务器节点接收 处理事务开始通知结果的时间是否超过预定时间, 其中, 在超过预定时间 的情况下, 在执行存储过程和函数命令失败; 在未超过预定时间的情况下, 如果主控服务器节点接收的所有非主控服务器节点 50处理事务开始通知结 果中, 有任一节点的开始事务操作发生失败, 则执行存储过程和函数失败。 以及第三判断模块, 用于判断主控服务器节点发送处理语句是否失败, 在 发送失败的情况下, 执行该存储过程和函数此次执行失败。 The master server in the foregoing embodiment may further include: a creating unit, configured to receive a create command for creating a stored procedure and a function issued by the client 10, and parse the vocabulary and syntax of the stored procedure and the function according to the create command, and simultaneously save and save the record The contents of each statement in the stored procedure and function. Preferably, the master control server may further include: a first determining module, configured to determine whether the master server node sends a transaction start notification is successful, and in case the sending fails, the system ends the storing process and the function performing the operation; a module, configured to determine whether the time when the master server node receives the result of processing the transaction start notification exceeds a predetermined time, wherein, in the case that the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, If all of the non-master server nodes 50 received by the master server node process the transaction start notification result, and the start transaction operation of any of the nodes fails, the execution of the stored procedure and the function fails. And a third judging module, configured to determine whether the main control server node fails to send the processing statement, and if the sending fails, executing the stored procedure and the function fails to perform this time.
图 2是根据本发明实施例的基于分布式数据库方法的流程示意图。 如 图 2所示, 该方法包括如下步驟:  2 is a flow chart of a distributed database based method in accordance with an embodiment of the present invention. As shown in Figure 2, the method includes the following steps:
步驟 S102, 主控服务器节点 30接收存储过程和函数执行命令。  Step S102, the master server node 30 receives the stored procedure and the function execution command.
步驟 S104,主控服务器节点 30根据存储过程和函数执行命令发送事务 开始通知至任意一个或多个非主控服务器节点 50, 接收到事务开始通知的 非主控服务器节点创建一个新事务。  Step S104, the master server node 30 sends a transaction start notification to any one or more non-master server nodes 50 according to the stored procedure and the function execution command, and the non-master server node that receives the transaction start notification creates a new transaction.
步驟 S106, 在主控服务器节点执行存储过程和函数中的处理语句, 并 将处理语句发送至任意一个或多个非主控服务器节点 50。  Step S106, executing a processing statement in the stored procedure and the function at the master server node, and sending the processing statement to any one or more non-master server nodes 50.
步驟 S108 , 非主控服务器节点 50执行该处理语句, 并将获取到的处理 结果返回至主控服务器节点。  Step S108: The non-master server node 50 executes the processing statement, and returns the obtained processing result to the master server node.
步驟 S110,主控服务器节点 30根据处理结果执行完存储过程和函数的 所有处理语句, 并发送事务提交通知给任意一个或多个非主控服务器节点 50, 非主控服务器节点 50接收事务提交通知并提交创建的新事务。  In step S110, the master server node 30 executes all the processing statements of the stored procedure and the function according to the processing result, and sends a transaction commit notification to any one or more non-master server nodes 50, and the non-master server node 50 receives the transaction commit notification. And submit the new transaction created.
上述实施例实现了在多台服务器节点组成服务器集群环境下的一种存 储过程和函数执行实现方法, 且涉及到的处理语句可以为 SQL语句, 解决 了存储过程和函数无法在分布式数据库系统多服务器节点上执行的问题, 使存储过程和函数可以对多服务器节点硬盘存储数据进行访问和操作, 可 以使存储过程和函数在分布式数据库的多个服务器节点上并发执行, 实现 了充分利用每个服务器节点的 CPU、 硬盘等资源, 大大提高了执行效率的 效果。 The foregoing embodiment implements a storage procedure and a function execution implementation method in a server cluster environment composed of multiple server nodes, and the processing statement involved may be a SQL statement, which solves the problem that the stored procedure and the function cannot be in the distributed database system. Problems executed on the server node, Enables stored procedures and functions to access and manipulate data stored on multiple server nodes. It allows concurrent execution of stored procedures and functions on multiple server nodes in a distributed database, enabling full utilization of CPU, hard disk, etc. of each server node. Resources have greatly improved the efficiency of execution.
在上述实施例中, 在主控服务器节点接收存储过程和函数执行命令之 前, 方法还可以包括: 主控服务器接收创建存储过程和函数的创建命令; 根据创建命令解析存储过程和函数的作词法和语法, 并记录保存存储过程 和函数中的每一句处理语句的内容。  In the above embodiment, before the master server node receives the stored procedure and the function execution command, the method may further include: the master server receiving the create command for creating the stored procedure and the function; and parsing the vocabulary of the stored procedure and the function according to the create command Grammar, and records the contents of each statement in the stored procedure and function.
图 3是根据本发明实施例的存储过程和函数创建处理流程图, 如图 3 所示。 该创建处理流程包括如下步驟:  3 is a flow chart of a stored procedure and function creation process, as shown in FIG. 3, in accordance with an embodiment of the present invention. The creation process includes the following steps:
步驟 201 , 客户端 10发送创建存储过程和函数命令给主控服务器节点 Step 201, the client 10 sends a create stored procedure and a function command to the master server node.
30。 30.
步驟 202, 分布式数据库系统对存储过程和函数作词法和语法解析, 并 记录保存每一句处理语句, 例如 SQL语句。  Step 202: The distributed database system lexically and syntaxally parses the stored procedures and functions, and records and saves each processing statement, such as an SQL statement.
具体的, 上述实施例可以实现在分布式数据库系统中创建存储过程和 函数时, 即在结构化查询语言 (STRUCTURED QUERY LANGUAGE, 简 称 SQL )解析层中对存储过程和函数作词法和语法解析时, 记录保存存储 过程和函数中的每一句 SQL语句内容。  Specifically, the foregoing embodiment may be implemented when a stored procedure and a function are created in a distributed database system, that is, when a lexical and syntax analysis is performed on a stored procedure and a function in a structured query language (STRUCTURED QUERY LANGUAGE, SQL for short). Record the contents of each SQL statement in the stored procedure and function.
优选地,在主控服务器节点 30执行存储过程和函数中的处理语句之前, 方法还可以包括: 主控服务器节点 30将处理语句中的变量名称用具体变量 值替换。  Preferably, before the master server node 30 executes the processing statements in the stored procedure and the function, the method may further include: the master server node 30 replacing the variable name in the processing statement with a specific variable value.
本发明上述实施例中, 在主控服务器节点 30根据存储过程和函数执行 命令发送事务开始通知至任意一个或多个非主控服务器节点 50之后, 方法 还可以包括: 判断主控服务器节点 30发送事务开始通知是否成功, 在发送 失败的情况下, 系统结束该存储过程和函数执行操作。 本发明上述实施例中, 在主控服务器节点 30根据存储过程和函数执行 命令发送事务开始通知至任意一个或多个非主控服务器节点 50, 接收到事 务开始通知的非主控服务器节点 50创建一个新事务之后,方法还可以包括: 非主控服务器节点 50将处理事务开始通知的结果返回给主控服务器节点; 判断主控服务器节点 30接收处理事务开始通知结果的时间是否超过预定时 间, 其中, 在超过预定时间的情况下, 在执行存储过程和函数命令失败; 在未超过预定时间的情况下, 如果主控服务器节点接收的所有非主控服务 器节点 50处理事务开始通知结果中,有任一节点的开始事务操作发生失败, 则执行存储过程和函数失败。 In the foregoing embodiment of the present invention, after the master server node 30 sends a transaction start notification to any one or more non-master server nodes 50 according to the stored procedure and the function execution command, the method may further include: determining that the master server node 30 sends The transaction start notification is successful. In the case of a failed transmission, the system ends the stored procedure and function execution. In the above embodiment of the present invention, the master server node 30 transmits a transaction start notification to any one or more non-master server nodes 50 according to the stored procedure and the function execution command, and the non-master server node 50 that has received the transaction start notification is created. After a new transaction, the method may further include: the non-master server node 50 returns a result of processing the transaction start notification to the master server node; determining whether the time at which the master server node 30 receives the processing transaction start notification result exceeds a predetermined time, wherein In the case where the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, if all the non-master server nodes 50 received by the master server node process the transaction start notification result, If a node's start transaction operation fails, the stored procedure and function fail.
本发明上述实施例中, 在主控服务器节点 30执行存储过程和函数中的 处理语句 ,并将处理语句发送至任意一个或多个非主控服务器节点 50之后, 方法还可以包括: 判断主控服务器节点 30发送处理语句是否失败, 在发送 失败的情况下, 执行该存储过程和函数此次执行失败。  In the above embodiment of the present invention, after the master server node 30 executes the processing statement in the stored procedure and the function, and sends the processing statement to any one or more non-master server nodes 50, the method may further include: determining the master Whether the server node 30 sends a processing statement fails, and if the transmission fails, the execution of the stored procedure and the function fails this time.
本发明上述实施例中, 在非主控服务器节点 50执行该处理语句, 并将 获取到的处理结果返回至主控服务器节点之后, 方法还包括: 在主控服务 器节点 30接收的所有非主控服务器节点 50执行处理语句结果中, 如果有 任一非主控服务器节点 50执行处理语句过程中发生失败, 则执行存储过程 和函数失败; 或者在主控服务器节点等待任一非主控服务器节点 50执行处 理语句结果的时间超过了某一个时间限制后, 则存储过程和函数执行失败。  In the above embodiment of the present invention, after the non-master server node 50 executes the processing statement and returns the obtained processing result to the master server node, the method further includes: all non-masterings received at the master server node 30 In the result of executing the processing statement by the server node 50, if any non-master server node 50 fails to execute the processing statement, the execution of the stored procedure and the function fails; or the host server node waits for any non-master server node 50. When the execution of the result of the processing statement exceeds a certain time limit, the stored procedure and function execution fails.
图 4是根据本发明实施例的基于分布式数据库方法的详细流程示意图, 如图 4所示, 用于存储过程和函数在分布式数据库系统多服务器节点上执 行, 执行时可以对多服务器节点硬盘存储数据进行操作, 包括如下步驟: 步驟 301 , 客户端 10发送存储过程和函数执行命令给主控服务器节点 4 is a detailed flow diagram of a method based on a distributed database according to an embodiment of the present invention. As shown in FIG. 4, a stored procedure and a function are executed on a multi-server node of a distributed database system, and a multi-server node hard disk can be executed during execution. The operation of storing data includes the following steps: Step 301: The client 10 sends a stored procedure and a function execution command to the master server node.
30; 30;
步驟 302, 主控服务器节点 30发送事务开始通知给其他非主控服务器 节点 50。 具体的, 该步驟可以实现在分布式数据库系统的主控服务器节点 30执行存储过程和函数时,主控服务器节点 30先发送存储过程和函数事务 开始通知给其他非主控服务器节点 50,其他非主控服务器节点 50接到事务 开始通知后创建一个新事务, 并发送处理结果给主控服务器节点 30。 Step 302, the master server node 30 sends a transaction start notification to other non-master servers. Node 50. Specifically, the step may be implemented. When the master server node 30 of the distributed database system executes the stored procedure and function, the master server node 30 first sends a stored procedure and a function transaction start notification to the other non-master server node 50, and other non- The master server node 50 creates a new transaction after receiving the transaction start notification, and sends the processing result to the master server node 30.
优选地, 在该步驟执行过程中, 如果主控服务器节点 30给任一非主控 服务器节点 50发送事务开始通知发生失败, 则认为该存储过程和函数此次 执行时发送错误, 并结束存储过程和函数执行操作。  Preferably, during the execution of the step, if the master server node 30 sends a transaction start notification to any non-master server node 50, it is considered that the stored procedure and function send an error during the execution, and end the stored procedure. And the function performs the operation.
同时, 在非主控服务器节点 50接收从主控服务器节点 30发送的事务 开始通知之后, 非主控服务器节点 50开始创建一个新的事务, 并把处理结 果发送给主控服务器节点。  Meanwhile, after the non-master server node 50 receives the transaction start notification transmitted from the master server node 30, the non-master server node 50 starts creating a new transaction and transmits the processing result to the master server node.
主控服务器节点 30等待任一非主控服务器节点 50处理事务开始通知 结果的时间超过了某一个时间限制后, 则认为存储过程和函数执行失败, 并结束存储过程和函数执行操作。  The master server node 30 waits for any non-master server node 50 to process the transaction start notification. After the time exceeds a certain time limit, the stored procedure and function execution is considered to have failed, and the stored procedure and function execution operation are ended.
主控服务器节点 30接收的所有非主控服务器节点 50处理事务开始通 知结果中, 如果有任一节点的开始事务操作发生失败, 则认为存储过程和 函数执行失败, 并结束存储过程和函数执行操作。  All non-master server nodes 50 received by the master server node 30 process the transaction start notification result. If the start transaction operation of any node fails, the stored procedure and the function execution are considered to be failed, and the stored procedure and the function execution operation are ended. .
步驟 303 , 主控服务器节点 30执行每个 SQL语句前, 使用具体变量值 替换变量名称。 具体的, 该步驟可以实现分布式数据库系统的主控服务器 节点在存储过程和函数中的每一个 SQL语句执行前, 使用变量的实际值替 换 SQL语句内容中变量名  Step 303: The master server node 30 replaces the variable name with a specific variable value before executing each SQL statement. Specifically, the step can implement the master server of the distributed database system. Before each SQL statement in the stored procedure and function is executed, the variable value in the content of the SQL statement is replaced by the actual value of the variable.
步驟 304,主控服务器节点 30发送 SQL语句给其他非主控服务器节点 50。 具体的, 该步驟可以实现分布式数据库系统的主控服务器节点在本机 上执行 SQL语句, 如果该条 SQL语句需要其他非主控服务器节点 50硬盘 存储的数据,则主控服务器节点 30把该 SQL语句通过网络协议发送给对应 的非主控服务器节点 50, 非主控服务器节点 50收到并执行该 SQL语句, 并发送回执行结果。 In step 304, the master server node 30 sends the SQL statement to the other non-master server node 50. Specifically, the step may be that the master server node of the distributed database system executes the SQL statement on the local machine. If the SQL statement needs data stored by the hard disk of the other non-master server node 50, the master server node 30 The SQL statement is sent to the corresponding non-master server node 50 through a network protocol, and the non-master server node 50 receives and executes the SQL statement. And send back the execution result.
在该步驟执行的过程中, 如果主控服务器节点 30给任一非主控服务器 节点 50发送 SQL语句发生失败,则认为该存储过程和函数此次执行时发送 错误, 并结束存储过程和函数执行操作。  During the execution of this step, if the master server node 30 fails to send a SQL statement to any of the non-master server nodes 50, it is considered that the stored procedure and function send an error during the execution, and end the stored procedure and function execution. operating.
主控服务器节点 30接收的所有非主控服务器节点 50执行 SQL语句结 果中, 如果有任一节点执行 SQL语句过程中发生失败, 则认为存储过程和 函数执行失败, 并结束存储过程和函数执行操作。  All the non-master server nodes 50 received by the master server node 30 execute the SQL statement result. If any node fails during the execution of the SQL statement, the stored procedure and the function execution are considered to be invalid, and the stored procedure and the function execution operation are ended. .
主控服务器节点 30等待任一非主控服务器节点 50执行 SQL语句结果 的时间超过了某一个时间限制后, 则认为存储过程和函数执行失败, 并结 束存储过程和函数执行操作。  The master server node 30 waits for any non-master server node 50 to execute the SQL statement result for more than a certain time limit, then considers the stored procedure and function execution to fail, and ends the stored procedure and function execution operation.
上述实施例中, 当主控服务器节点 30判断存储过程和函数执行过程中 发送失败, 在结束存储过程和函数执行操作前, 主控服务器节点 30需要通 知非主控服务器节点 50对事务回滚处理, 具体的, 主控服务器节点 30可 以发送事务回滚通知给其他非主控服务器节点 50, 其他非主控服务器节点 50收到通知后执行事务回滚处理, 并发送回处理结果。  In the above embodiment, when the master server node 30 determines that the storage process and the function execution fail during the execution, the master server node 30 needs to notify the non-master server node 50 to process the transaction rollback before ending the stored procedure and the function execution operation. Specifically, the master server node 30 may send a transaction rollback notification to the other non-master server node 50, and the other non-master server node 50 performs the transaction rollback process after receiving the notification, and sends back the processing result.
同时 , 上述过程中的 SELECT语句、 DELETE语句、 UPDATE语句采 用群发到其他非主控服务器节点 50方式, INSERT语句根据数据分布的一 致性算法计算出发送的具体服务器节点。  At the same time, the SELECT statement, the DELETE statement, and the UPDATE statement in the above process are sent to other non-master server nodes 50. The INSERT statement calculates the specific server node to be sent according to the consistency algorithm of the data distribution.
步驟 305, 非主控服务器节点 50接收 SQL语句, 并执行 SQL语句, 发送处理结果给主控服务器节点 30;  Step 305, the non-master server node 50 receives the SQL statement, and executes the SQL statement, and sends the processing result to the master server node 30;
步驟 306,主控服务器节点 30执行完存储过程和函数的所有 SQL语句 后, 发送事务提交通知给其他非主控服务器节点 50, 非主控服务器节点 50 接收事务提交通知并提交事务, 发处理结果发送给主控服务器节点 30。  Step 306, after executing all the SQL statements of the stored procedure and the function, the master server node 30 sends a transaction commit notification to the other non-master server node 50, and the non-master server node 50 receives the transaction commit notification and submits the transaction, and sends the processing result. Send to the master server node 30.
具体的, 上述两个步驟可以实现分布式数据库系统的主控服务器节点 执行完存储过程和函数中的 SQL语句后, 发送提交事务通知给其他非主控 服务器节点 50, 其他非主控服务器节点 50收到提交事务通知并提交事务, 并发送处理结果给主控服务器节点。 Specifically, the foregoing two steps may be implemented after the main control server node of the distributed database system executes the SQL statement in the stored procedure and the function, and sends a commit transaction notification to the other non-master control. The server node 50, the other non-master server node 50 receives the commit transaction notification and submits the transaction, and sends the processing result to the master server node.
如果主控服务器节点 30给任一非主控服务器节点 50发送事务提交通 知发生失败, 则认为该存储过程和函数此次执行时发送错误, 并结束存储 过程和函数执行操作。  If the master server node 30 sends a transaction commit notification to any of the non-master server nodes 50, it is considered that the stored procedure and function send an error during this execution and ends the stored procedure and function execution.
非主控服务器节点 50接收主控服务器节点发送的事务提交通知等待时 间超过了某一个时间限制后, 则认为存储过程和函数执行失败, 执行事务 回滚处理操作。  After receiving the transaction commit notification sent by the master server node for more than a certain time limit, the non-master server node 50 considers that the stored procedure and function execution failed, and performs a transaction rollback processing operation.
需要说明的是, 本发明实施例在附图的流程图示出的步驟可以在诸如 一组计算机可执行指令的计算机系统中执行, 并且, 虽然在流程图中示出 了逻辑顺序, 但是在某些情况下, 可以以不同于此处的顺序执行所示出或 描述的步驟。  It should be noted that the steps shown in the flowchart of the accompanying drawings of the embodiments of the present invention may be executed in a computer system such as a set of computer executable instructions, and although a logical sequence is shown in the flowchart, In some cases, the steps shown or described may be performed in an order different than that described herein.
从以上的实施例描述中, 可以看出, 本发明实现了如下技术效果: 本 发明的存储过程和函数执行方法解决了存储过程和函数在分布式数据库系 统多服务器节点上执行问题, 可以对多服务器节点硬盘存储数据进行操作; 本发明的存储过程和函数执行方法可以使存储过程和函数在分布式数据库 的多个服务器节点上并发执行, 大大提高了执行效率。  From the description of the above embodiments, it can be seen that the present invention achieves the following technical effects: The stored procedure and the function execution method of the present invention solve the problem that the stored procedure and function are executed on the distributed server system multiple server nodes, which may be more The server node hard disk stores data for operation; the stored procedure and function execution method of the present invention can enable the stored procedure and function to be executed concurrently on multiple server nodes of the distributed database, thereby greatly improving the execution efficiency.
显然, 本领域的技术人员应该明白, 上述的本发明的各模块或各步驟 可以用通用的计算装置来实现, 它们可以集中在单个的计算装置上, 或者 分布在多个计算装置所组成的网络上, 可选地, 它们可以用计算装置可执 行的程序代码来实现, 从而, 可以将它们存储在存储装置中由计算装置来 执行, 或者将它们分别制作成多个集成电路模块, 或者将它们中的多个模 块或步驟制作成单个集成电路模块来实现。 这样, 本发明不限制于任何特 定的硬件和软件结合。  Obviously, those skilled in the art should understand that the above modules or steps of the present invention can be implemented by a general-purpose computing device, which can be concentrated on a single computing device or distributed over a network composed of multiple computing devices. Alternatively, they may be implemented by program code executable by the computing device, such that they may be stored in the storage device by the computing device, or they may be separately fabricated into a plurality of integrated circuit modules, or they may be Multiple modules or steps in the fabrication are implemented as a single integrated circuit module. Thus, the invention is not limited to any specific combination of hardware and software.
上述说明示出并描述了本发明的一个优选实施例, 但如前所述, 应当 理解本发明并非局限于本文所披露的形式, 不应看作是对其他实施例的排 除, 而可用于各种其他组合、 修改和环境, 并能够在本文所述发明构想范 围内, 通过上述教导或相关领域的技术或知识进行改动。 而本领域人员所 进行的改动和变化不脱离本发明的精神和范围, 则都应在本发明所附权利 要求的保护范围内。 The above description shows and describes a preferred embodiment of the invention, but as mentioned above, It is to be understood that the invention is not to be construed as being limited to the details of the embodiments disclosed herein. Or changes in the technology or knowledge of the relevant field. All changes and modifications made by those skilled in the art are intended to be within the scope of the appended claims.

Claims

权利要求书 Claim
1、 一种基于分布式数据库系统的数据控制方法, 其中, 该方法包括: 主控服务器节点接收存储过程和函数执行命令, 根据所述存储过程和 函数执行命令发送事务开始通知至任意一个或多个非主控服务器节点, 接 收到所述事务开始通知的非主控服务器节点创建一个新事务;  A data control method based on a distributed database system, wherein the method comprises: a master server node receiving a stored procedure and a function execution command, and transmitting a transaction start notification to any one or more according to the stored procedure and a function execution command a non-master server node, the non-master server node receiving the transaction start notification creates a new transaction;
在所述主控服务器节点执行所述存储过程和函数中的处理语句, 并将 所述处理语句发送至任意一个或多个所述非主控服务器节点;  Performing, in the master server node, the processing statement in the stored procedure and the function, and sending the processing statement to any one or more of the non-master server nodes;
所述非主控服务器节点执行所述处理语句, 并将获取到的处理结果返 回至所述主控服务器节点;  The non-master server node executes the processing statement, and returns the obtained processing result to the main control server node;
所述主控服务器节点根据所述处理结果执行完存储过程和函数的所有 处理语句, 并发送事务提交通知给任意一个或多个所述非主控服务器节点, 所述非主控服务器节点接收所述事务提交通知并提交创建的所述新事务。  The master server node executes all processing statements of the stored procedure and the function according to the processing result, and sends a transaction commit notification to any one or more of the non-master server nodes, and the non-master server node receives the The transaction commits the notification and submits the new transaction created.
2、 根据权利要求 1所述的数据控制方法, 其中, 在主控服务器节点接 收存储过程和函数执行命令之前, 所述方法还包括:  2. The data control method according to claim 1, wherein before the master server node receives the stored procedure and the function execution command, the method further includes:
所述主控服务器节点接收创建所述存储过程和函数的创建命令; 根据所述创建命令解析所述存储过程和函数的作词法和语法, 并记录 保存所述存储过程和函数中的每一句处理语句的内容。  The master server node receives a create command to create the stored procedure and function; parses the vocabulary and syntax of the stored procedure and function according to the create command, and records and saves each sentence in the stored procedure and function The content of the statement.
3、 根据权利要求 2所述的数据控制方法, 其中, 在所述主控服务器节 点执行所述存储过程和函数中的处理语句之前, 所述方法还包括:  The data control method according to claim 2, wherein before the execution of the processing statement in the stored procedure and the function, the method further includes:
所述主控服务器节点将处理语句中的变量名称用具体变量值替换。 The master server node replaces the variable name in the processing statement with a specific variable value.
4、 根据权利要求 1至 3中任一项所述的数据控制方法, 其中, 在所述 主控服务器节点根据所述存储过程和函数执行命令发送事务开始通知至任 意一个或多个非主控服务器节点之后, 所述方法还包括: The data control method according to any one of claims 1 to 3, wherein, at the master server node, a transaction start notification is sent to any one or more non-masters according to the stored procedure and a function execution command. After the server node, the method further includes:
判断所述主控服务器节点发送所述事务开始通知是否成功, 在发送失 败的情况下, 系统结束该存储过程和函数执行操作。 Determining whether the master server node sends the transaction start notification is successful, and in case the transmission fails, the system ends the stored procedure and the function execution operation.
5、 根据权利要求 4所述的数据控制方法, 其中, 在所述主控服务器节 点根据所述存储过程和函数执行命令发送事务开始通知至任意一个或多个 非主控服务器节点, 接收到所述事务开始通知的非主控服务器节点创建一 个新事务之后, 所述方法还包括: The data control method according to claim 4, wherein the master server node sends a transaction start notification to any one or more non-master server nodes according to the stored procedure and a function execution command, and receives the After the non-master server node that the transaction start notification creates a new transaction, the method further includes:
所述非主控服务器节点将处理事务开始通知的结果返回给所述主控服 务器节点;  The non-master server node returns a result of processing a transaction start notification to the master server node;
判断所述主控服务器节点接收所述处理事务开始通知结果的时间是否 超过预定时间, 其中,  Determining whether the time when the master server node receives the processing transaction start notification result exceeds a predetermined time, where
在超过所述预定时间的情况下, 在执行所述存储过程和函数命令失败; 在未超过所述预定时间的情况下, 如果所述主控服务器节点接收的所 有非主控服务器节点处理事务开始通知结果中, 有任一节点的开始事务操 作发生失败, 则执行所述存储过程和函数失败。  In the case that the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded, if all the non-master server nodes received by the master server node process the transaction start In the result of the notification, if the start transaction operation of any of the nodes fails, the execution of the stored procedure and the function fails.
6、 根据权利要求 1-3中任一项所述的数据控制方法, 其中, 在所述主 控服务器节点执行所述存储过程和函数中的处理语句, 并将所述处理语句 发送至任意一个或多个所述非主控服务器节点之后, 所述方法还包括: 判断所述主控服务器节点发送所述处理语句是否失败, 在发送失败的 情况下, 执行该存储过程和函数此次执行失败。  The data control method according to any one of claims 1 to 3, wherein a processing statement in the stored procedure and function is executed at the master server node, and the processing statement is sent to any one of After the plurality of non-master server nodes, the method further includes: determining whether the master server node sends the processing statement fails, and if the sending fails, performing the storing process and the function fails to perform this time .
7、 根据权利要求 6所述的方法, 其中, 在所述非主控服务器节点执行 该处理语句, 并将获取到的处理结果返回至所述主控服务器节点之后, 所 述方法还包括:  The method of claim 6, wherein after the non-master server node executes the processing statement and returns the obtained processing result to the master server node, the method further includes:
在所述主控服务器节点接收的所有非主控服务器节点执行处理语句结 果中, 如果有任一非主控服务器节点执行处理语句过程中发生失败, 则执 行所述存储过程和函数失败; 或者  In the execution statement result of all non-master server nodes received by the master server node, if any non-master server node fails to execute the processing statement, the execution of the stored procedure and function fails;
在所述主控服务器节点等待任一非主控服务器节点执行处理语句结果 的时间超过了某一个时间限制后, 则所述存储过程和函数执行失败。 The stored procedure and function execution fails after the master server node waits for any non-master server node to execute the processing statement result for more than a certain time limit.
8、 一种基于分布式数据库系统的数据控制系统, 其中, 该系统包括: 主控服务器和一个或多个非主控服务器, 其中, 8. A data control system based on a distributed database system, wherein the system comprises: a master server and one or more non-master servers, wherein
主控服务器, 设置为接收存储过程和函数执行命令, 根据所述存储过 程和函数执行命令发送事务开始通知, 执行所述存储过程和函数中的处理 语句, 在执行完存储过程和函数的所有处理语句之后, 发送事务提交通知; 一个或多个非主控服务器, 设置为在接收到所述事务开始通知之后创 建一个新事务, 执行接收到的所述处理语句, 并在接收到所述事务提交通 知之后提交创建的新事务。  a master server, configured to receive a stored procedure and a function execution command, send a transaction start notification according to the stored procedure and a function execution command, execute a processing statement in the stored procedure and the function, and execute all processing of the stored procedure and the function After the statement, a transaction commit notification is sent; one or more non-master servers are set to create a new transaction after receiving the transaction start notification, execute the received processing statement, and receive the transaction commit Submit the new transaction created after the notification.
9、 根据权利要求 8所述的数据控制系统, 其中, 所述主控服务器还包 括:  9. The data control system according to claim 8, wherein the master server further comprises:
创建单元, 设置为接收客户端发出的创建所述存储过程和函数的创建 命令, 并根据所述创建命令解析所述存储过程和函数的作词法和语法, 记 录保存所述存储过程和函数中的每一句处理语句的内容。  a creating unit, configured to receive a create command issued by the client to create the stored procedure and function, and parse the vocabulary and syntax of the stored procedure and function according to the create command, and record the save in the stored procedure and function The content of each sentence is processed.
10、 根据权利要求 8所述的数据控制系统, 其中, 所述主控服务器还 包括:  The data control system according to claim 8, wherein the master server further comprises:
第一判断模块, 设置为判断所述主控服务器节点发送所述事务开始通 知是否成功, 在发送失败的情况下, 系统结束该存储过程和函数执行操作; 第二判断模块, 设置为判断所述主控服务器节点接收所述处理事务开 始通知结果的时间是否超过预定时间, 其中, 在超过所述预定时间的情况 下, 在执行所述存储过程和函数命令失败; 在未超过所述预定时间的情况 下, 如果所述主控服务器节点接收的所有非主控服务器节点处理事务开始 通知结果中, 有任一节点的开始事务操作发生失败, 则执行所述存储过程 和函数失败;  a first determining module, configured to determine whether the master server node sends the transaction start notification is successful, in the case that the sending fails, the system ends the storing process and the function performing the operation; the second determining module is configured to determine the Whether the time when the master server node receives the processing transaction start notification result exceeds a predetermined time, wherein, in the case that the predetermined time is exceeded, the execution of the stored procedure and the function command fails; if the predetermined time is not exceeded In the case that if all the non-master server nodes received by the master server node process the transaction start notification result, if any node's start transaction operation fails, executing the stored procedure and function fails;
第三判断模块, 设置为判断所述主控服务器节点发送所述处理语句是 否失败, 在发送失败的情况下, 执行该存储过程和函数此次执行失败。  The third judging module is configured to determine whether the processing of the processing statement by the main control server node fails. If the sending fails, the execution of the stored procedure and the function fails.
PCT/CN2012/074552 2011-08-25 2012-04-23 Data control method and system based on distributed database system WO2013026287A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201110246791.2A CN102955801B (en) 2011-08-25 2011-08-25 Data control method and system based on distributed data base system
CN201110246791.2 2011-08-25

Publications (1)

Publication Number Publication Date
WO2013026287A1 true WO2013026287A1 (en) 2013-02-28

Family

ID=47745884

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2012/074552 WO2013026287A1 (en) 2011-08-25 2012-04-23 Data control method and system based on distributed database system

Country Status (2)

Country Link
CN (1) CN102955801B (en)
WO (1) WO2013026287A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107229628A (en) * 2016-03-23 2017-10-03 中兴通讯股份有限公司 The method and device of distributed data base pretreatment

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017156673A1 (en) * 2016-03-14 2017-09-21 华为技术有限公司 Processing method and device for stored procedure
CN107729421B (en) * 2017-09-27 2019-11-15 华为技术有限公司 The execution method, apparatus and storage medium of storing process
CN109992259B (en) * 2019-04-15 2020-10-30 成都四方伟业软件股份有限公司 Function dynamic creating method and device and electronic equipment
CN112685497B (en) * 2020-12-25 2024-02-13 北京浪潮数据技术有限公司 Data operation execution method, device and equipment of mysql database cluster

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101252603A (en) * 2008-04-11 2008-08-27 清华大学 Cluster distributed type lock management method based on storage area network SAN
CN101950297A (en) * 2010-09-10 2011-01-19 北京大学 Method and device for storing and inquiring mass semantic data
CN102063486A (en) * 2010-12-28 2011-05-18 东北大学 Multi-dimensional data management-oriented cloud computing query processing method
CN102099792A (en) * 2008-06-06 2011-06-15 枢轴3公司 Method and system for distributed raid implementation

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8126848B2 (en) * 2006-12-07 2012-02-28 Robert Edward Wagner Automated method for identifying and repairing logical data discrepancies between database replicas in a database cluster
CN101089857B (en) * 2007-07-24 2011-05-11 中兴通讯股份有限公司 Internal store data base transaction method and system
CN101567006B (en) * 2009-05-25 2012-07-04 中兴通讯股份有限公司 Database system and distributed SQL statement execution plan reuse method
CN101901222B (en) * 2009-05-27 2012-07-18 北京启明星辰信息技术股份有限公司 Method and system for analyzing and matching SQLs (Structured Query Languages)
CN101576915B (en) * 2009-06-18 2011-06-08 北京大学 Distributed B+ tree index system and building method
CN101699439B (en) * 2009-11-16 2011-12-28 中兴通讯股份有限公司 Database transaction submitting method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101252603A (en) * 2008-04-11 2008-08-27 清华大学 Cluster distributed type lock management method based on storage area network SAN
CN102099792A (en) * 2008-06-06 2011-06-15 枢轴3公司 Method and system for distributed raid implementation
CN101950297A (en) * 2010-09-10 2011-01-19 北京大学 Method and device for storing and inquiring mass semantic data
CN102063486A (en) * 2010-12-28 2011-05-18 东北大学 Multi-dimensional data management-oriented cloud computing query processing method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107229628A (en) * 2016-03-23 2017-10-03 中兴通讯股份有限公司 The method and device of distributed data base pretreatment
CN107229628B (en) * 2016-03-23 2022-02-01 金篆信科有限责任公司 Distributed database preprocessing method and device

Also Published As

Publication number Publication date
CN102955801A (en) 2013-03-06
CN102955801B (en) 2017-06-16

Similar Documents

Publication Publication Date Title
US11468060B2 (en) Automatic query offloading to a standby database
CN108431804B (en) Ability to group multiple container databases into a single container database cluster
EP3234780B1 (en) Detecting lost writes
US9589041B2 (en) Client and server integration for replicating data
US20120284228A1 (en) User-Defined Parallelization in Transactional Replication of In-Memory Database
US20060007944A1 (en) Managing network device configuration using versioning and partitioning
US20170116321A1 (en) Ability to group multiple container databases as a single container database cluster
US20130275452A1 (en) Distributing and processing streams over one or more networks
WO2014074957A1 (en) Systems and methods involving resource description framework distributed data base managenent systems and/or related aspects
US11210277B2 (en) Distributing and processing streams over one or more networks for on-the-fly schema evolution
WO2013026287A1 (en) Data control method and system based on distributed database system
EP2947582A1 (en) Computing device and method for executing database operation command
CN102981857A (en) Method for loading parallel compressed mass data of database cluster
CN108090056B (en) Data query method, device and system
US20220156163A1 (en) Fault tolerance in scale-out distributed query processing appliance
US11455219B2 (en) High availability and automated recovery in scale-out distributed database system
US20240134879A1 (en) Keeping stable leadership in raft-based protocol with fast automatic failover
US20240126781A1 (en) Consensus protocol for asynchronous database transaction replication with fast, automatic failover, zero data loss, strong consistency, full sql support and horizontal scalability
Lu et al. Software-Defined, Fast and Strongly-Consistent Data Replication for RDMA-Based PM Datastores
Chandramouli et al. The Quill Distributed Analytics Library and Platform
US20230025059A1 (en) Systems and methods for failure recovery in at-most-once and exactly-once streaming data processing
WO2024081140A1 (en) Configuration and management of replication units for asynchronous database transaction replication
WO2024081139A1 (en) Consensus protocol for asynchronous database transaction replication with fast, automatic failover, zero data loss, strong consistency, full sql support and horizontal scalability
CN116541444A (en) Heterogeneous database integration system and database access method
WO2024076405A1 (en) Framework and method for consistent cross-tier data validation

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 12826061

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 12826061

Country of ref document: EP

Kind code of ref document: A1