CN110083587A - A kind of databases comparison measures and procedures for the examination and approval based on Git - Google Patents
A kind of databases comparison measures and procedures for the examination and approval based on Git Download PDFInfo
- Publication number
- CN110083587A CN110083587A CN201910305964.XA CN201910305964A CN110083587A CN 110083587 A CN110083587 A CN 110083587A CN 201910305964 A CN201910305964 A CN 201910305964A CN 110083587 A CN110083587 A CN 110083587A
- Authority
- CN
- China
- Prior art keywords
- git
- rule
- script
- examination
- procedures
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/21—Design, administration or maintenance of databases
- G06F16/219—Managing data history or versioning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/28—Databases characterised by their database models, e.g. relational or object models
- G06F16/284—Relational databases
Landscapes
- Engineering & Computer Science (AREA)
- Databases & Information Systems (AREA)
- Theoretical Computer Science (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The present invention provides a kind of databases comparison measures and procedures for the examination and approval based on Git, is write DDL script by setting rule name in the version branch of the script bank of Git by user creation base first in the branch and is submitted to Git server end;After received server-side to submission event, by finger daemon to the DDL script of submission, whether verification SQL statement meets the requirement of change rule, it is unsatisfactory for rule and notifies user, notification data library manager merges the branch with database trunk after meeting rule and requiring, and changing process terminates after merging.The databases comparison measures and procedures for the examination and approval provided by the invention based on Git, can low cost build, low cost training, low cost development, easily promote.
Description
Technical field
The present invention relates to relevant database management methods, examine more particularly, to a kind of databases comparison based on Git
Method.
Background technique
Git (pronunciation be /git/) is the distributed version control system of an open source, can handle effectively, at high speed from
Very little is to very big Item version management.
With the development of information technology, the information system based on relevant database (referred to as: RDBMS) foundation is increasingly
It is more, also become increasingly complex.The core of these systems is RDBMS, it is by structure compositions such as data field, tables of data.Data field
Map physical world material property, with system constantly improve involved in attribute it is more and more, correspond to RDBMS also otherwise
It is disconnected to increase section of altering.
It is risky for adding field on the RDBMS of operation, increasing tables of data, especially in the case of big data quantity easily
Situations such as lock table, system crash occurs.Therefore there are examination & approval to data field change.
Summary of the invention
The databases comparison measures and procedures for the examination and approval based on Git that the present invention provides a kind of, data volume it is larger (such as single table note
Number is recorded at million grades or more), it solves the problems, such as to add field on the RDBMS of operation, increase tables of data, skill
Art scheme is as described below:
A kind of databases comparison measures and procedures for the examination and approval based on Git, including the following steps:
(1) user creation base is in the version branch of the script bank of Git, by setting rule name;
(2) user writes DDL script in the branch and is submitted to Git server end;
(3) after Git received server-side to submission event, the information that is related to that triggering Git hook submits this passes through
Http protocol is sent on the port for calling demons to monitor;
(4) finger daemon from the port that demons are monitored receive this submit be related to information after, obtained and mentioned with this
The DDL script of friendship, and verify the requirement whether SQL statement meets change rule;
(5) if being unsatisfactory for rule, finger daemon sends how circular mail prompt is modified to user, and user is according to mentioning
Show and modified, after submitting again, execute step (3), which is able to carry out repeatedly, requires until meeting rule;
(6) it if meeting rule, sends mail notification database administrator and merges the branch with database trunk;
(7) merged event triggering finger daemon executes change script, and changing process terminates.
Further, in step (3), being related to information includes submitting user, version branch name, version number.
Demons are to change situation for the increasing in library, table, field, and creation meets database performance requirements and structure design rule
The regular expression of model.
Based on the program that any programming language for connecting database and executing SQL script is write, in a manner of finger daemon
Particular port is monitored in operation, is realized the verification of script rule, is executed.
The databases comparison measures and procedures for the examination and approval provided by the invention based on Git, can low cost build, low cost training, it is low
Cost exploitation, is easily promoted.
Detailed description of the invention
Fig. 1 is the flow diagram of the databases comparison measures and procedures for the examination and approval provided by the invention based on Git.
Specific embodiment
The databases comparison measures and procedures for the examination and approval provided by the invention based on Git, are related to databases comparison script bank and data
Library script execution finger daemon.
Wherein, one databases comparison script bank (abbreviation script bank): is created in the server-side for supporting Git agreement specially
Store the script warehouse of change script (SQL statement).
Database script executes finger daemon (abbreviation demons): the increasing for library, table, field changes situation, and creation is full
The regular expression of sufficient database performance requirements and code for structural design.It connects database based on any and executes SQL script
The program write of programming language, run in a manner of finger daemon, monitor particular port, realized the verification of script rule, execute, with
And notify the function of related personnel.
As shown in Figure 1, the changing process of the present invention in embodiment, comprising the following steps:
1, user creation base is named in the script bank branch of Git by ad hoc rules, such as: { date }-{ user }-
{DBName}。
2, user writes DDL (Data Definition Language) script in the branch and submits (Push) content to clothes as submitter
Business device end.
3, triggering Git hook after Git received server-side to submission event, the relevant information that this is submitted (submitter,
Branch name, version number etc.) it is sent on the port for calling demons to monitor by http protocol.
4, after finger daemon receives the relevant information that this is submitted, DDL script (the Git software sheet of submission is obtained with this
Body provides this function), and verify the requirement whether SQL statement meets change rule:
If being unsatisfactory for rule, finger daemon to submitter send circular mail prompt how to modify, submitter according to
Prompt has been modified, and executes step 3 again after submitting again, this process can carry out repeatedly, is required until meeting rule;
If meeting rule, sends mail notification database administrator and merge the branch with trunk branch;
Main verification rule is as follows:
A, data are not backed up when using DELETE operation.
B, not specified major key or major key non-int or bigint, it is desirable that confirmation major key and major key data type.
C, integer data type has used the such definition of INT (3), INT (4).Because they and INT (8) are in magnetic
It is all the memory space for occupying 4bytes on disk, it is not necessary to create the integer in bracket less than 8.
D, ALTER is operated, and is not write the default value of former field, no default value, can not online list of modification when table is larger
Structure.
E, index name is lack of standardization.Common secondary index is using idx_ as prefix, and unique index is using uk_ as prefix.
F, the same character set is not used in column and table, and column individually specify character set.
When initialization data, specified column name is not known in INSERT or REPLACE, easily occurs exceeding expected result.Foundation
As above rule gives SQL marking, starting points 10 points, and one of hit rule subtracts 0.5 point, is considered as rule verification less than 9 points and does not pass through.
Administrator is notified to merge branch by the email of verification.
Merged event triggers finger daemon and executes change script, and changing process terminates.
The present invention has following distinguishing feature:
1. Construction of Low Cost relies only on Git software (Git is free software, without paying copyright fee thus).
2. it is convenient to use, it needs to be the personnel of databases comparison without additional studies, need to only grasp the side using Git software
Method, it is unrelated with the structure of database based on the database of Git.
3. database change operation record can be retained, more become history convenient for checking and tracking database.
4. having preset the inspection rule to change script, it is ensured that satisfactory change can be just performed, and ensure that
The safety and stabilization of Database Systems.
5. this patent is by the general utility functions of Git, but creativeness is to arrange Git file designation, and develops
Rule verification journey increases regular judgement, and meeting rule can just execute.
Claims (4)
1. a kind of databases comparison measures and procedures for the examination and approval based on Git, including the following steps:
(1) user creation base is in the version branch of the script bank of Git, by setting rule name;
(2) user writes DDL script in the branch and is submitted to Git server end;
(3) after Git received server-side to submission event, the information that is related to that triggering Git hook submits this is assisted by HTTP
View is sent on the port for calling demons to monitor;
(4) finger daemon from the port that demons are monitored receive this submit be related to information after, submission is obtained with this
DDL script, and verify the requirement whether SQL statement meets change rule;
(5) if being unsatisfactory for rule, finger daemon sends how circular mail prompt is modified to user, and user repairs according to prompt
It has been changed that, after submitting again, executed step (3), which is able to carry out repeatedly, requires until meeting rule;
(6) it if meeting rule, sends mail notification database administrator and merges the branch with database trunk;
(7) merged event triggering finger daemon executes change script, and changing process terminates.
2. the databases comparison measures and procedures for the examination and approval according to claim 1 based on Git, it is characterised in that: in step (3), relate to
And information includes submitting user, version branch name, version number.
3. the databases comparison measures and procedures for the examination and approval according to claim 1 based on Git, it is characterised in that: demons are needles
Situation is changed to the increasing in library, table, field, creation meets the regular expression of database performance requirements and code for structural design.
4. the databases comparison measures and procedures for the examination and approval according to claim 3 based on Git, it is characterised in that: connected based on any
It connects database and executes the program that the programming language of SQL script is write, run in a manner of finger daemon, monitor particular port, it is real
Existing script rule verification executes.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910305964.XA CN110083587A (en) | 2019-04-16 | 2019-04-16 | A kind of databases comparison measures and procedures for the examination and approval based on Git |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910305964.XA CN110083587A (en) | 2019-04-16 | 2019-04-16 | A kind of databases comparison measures and procedures for the examination and approval based on Git |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110083587A true CN110083587A (en) | 2019-08-02 |
Family
ID=67415386
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910305964.XA Pending CN110083587A (en) | 2019-04-16 | 2019-04-16 | A kind of databases comparison measures and procedures for the examination and approval based on Git |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110083587A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110505088A (en) * | 2019-08-20 | 2019-11-26 | 北京市燃气集团有限责任公司 | Store the method and apparatus that authorize a change |
CN110633284A (en) * | 2019-09-19 | 2019-12-31 | 中国工商银行股份有限公司 | Method and device for changing table in database |
CN110716739A (en) * | 2019-09-19 | 2020-01-21 | 平安科技(深圳)有限公司 | Code change information statistical method, system and readable storage medium |
CN110825508A (en) * | 2019-11-01 | 2020-02-21 | 浪潮云信息技术有限公司 | Task management method based on Git |
CN112256672A (en) * | 2020-10-22 | 2021-01-22 | 中国联合网络通信集团有限公司 | Database change approval method and device |
CN113535687A (en) * | 2021-07-29 | 2021-10-22 | 北京互金新融科技有限公司 | Data variable management method and device, computer readable storage medium and processor |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101222360A (en) * | 2008-01-22 | 2008-07-16 | 中兴通讯股份有限公司 | Regulation engine system and method for establishing alarm regulation association |
CN105094851A (en) * | 2015-09-06 | 2015-11-25 | 浪潮软件股份有限公司 | Method for momentarily issuing codes based on Git |
US20160117303A1 (en) * | 2014-10-22 | 2016-04-28 | Accenture Global Services Limited | Electronic document system |
CN105701010A (en) * | 2015-12-31 | 2016-06-22 | 北京元心科技有限公司 | Method and device for accelerating software testing |
CN105760164A (en) * | 2016-02-15 | 2016-07-13 | 浪潮(北京)电子信息产业有限公司 | Method for achieving ACL permission in user space file system |
CN106484807A (en) * | 2016-09-23 | 2017-03-08 | 北京许继电气有限公司 | Build the method and system of autonomous controlled data storehouse dual-active or many aggregated structures living |
CN106708740A (en) * | 2017-01-10 | 2017-05-24 | 网易(杭州)网络有限公司 | Script testing method and device |
CN109213645A (en) * | 2018-08-23 | 2019-01-15 | 郑州云海信息技术有限公司 | A kind of method and apparatus of distributed memory system performance test |
CN109471634A (en) * | 2018-08-28 | 2019-03-15 | 上海思立微电子科技有限公司 | The inspection method and equipment of source code format |
-
2019
- 2019-04-16 CN CN201910305964.XA patent/CN110083587A/en active Pending
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101222360A (en) * | 2008-01-22 | 2008-07-16 | 中兴通讯股份有限公司 | Regulation engine system and method for establishing alarm regulation association |
US20160117303A1 (en) * | 2014-10-22 | 2016-04-28 | Accenture Global Services Limited | Electronic document system |
CN105094851A (en) * | 2015-09-06 | 2015-11-25 | 浪潮软件股份有限公司 | Method for momentarily issuing codes based on Git |
CN105701010A (en) * | 2015-12-31 | 2016-06-22 | 北京元心科技有限公司 | Method and device for accelerating software testing |
CN105760164A (en) * | 2016-02-15 | 2016-07-13 | 浪潮(北京)电子信息产业有限公司 | Method for achieving ACL permission in user space file system |
CN106484807A (en) * | 2016-09-23 | 2017-03-08 | 北京许继电气有限公司 | Build the method and system of autonomous controlled data storehouse dual-active or many aggregated structures living |
CN106708740A (en) * | 2017-01-10 | 2017-05-24 | 网易(杭州)网络有限公司 | Script testing method and device |
CN109213645A (en) * | 2018-08-23 | 2019-01-15 | 郑州云海信息技术有限公司 | A kind of method and apparatus of distributed memory system performance test |
CN109471634A (en) * | 2018-08-28 | 2019-03-15 | 上海思立微电子科技有限公司 | The inspection method and equipment of source code format |
Non-Patent Citations (1)
Title |
---|
佚名: "Git分支创建于合并", 《HTTP://WWW.UML.ORG.CN/PZGL/201805154.ASP》 * |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110505088A (en) * | 2019-08-20 | 2019-11-26 | 北京市燃气集团有限责任公司 | Store the method and apparatus that authorize a change |
CN110505088B (en) * | 2019-08-20 | 2021-07-27 | 北京市燃气集团有限责任公司 | Storage authorization changing method and device |
CN110633284A (en) * | 2019-09-19 | 2019-12-31 | 中国工商银行股份有限公司 | Method and device for changing table in database |
CN110716739A (en) * | 2019-09-19 | 2020-01-21 | 平安科技(深圳)有限公司 | Code change information statistical method, system and readable storage medium |
CN110633284B (en) * | 2019-09-19 | 2022-04-29 | 中国工商银行股份有限公司 | Method and device for changing table in database |
CN110825508A (en) * | 2019-11-01 | 2020-02-21 | 浪潮云信息技术有限公司 | Task management method based on Git |
CN112256672A (en) * | 2020-10-22 | 2021-01-22 | 中国联合网络通信集团有限公司 | Database change approval method and device |
CN112256672B (en) * | 2020-10-22 | 2023-05-30 | 中国联合网络通信集团有限公司 | Database change approval method and device |
CN113535687A (en) * | 2021-07-29 | 2021-10-22 | 北京互金新融科技有限公司 | Data variable management method and device, computer readable storage medium and processor |
CN113535687B (en) * | 2021-07-29 | 2024-01-26 | 北京互金新融科技有限公司 | Data variable management method, device, computer readable storage medium and processor |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110083587A (en) | A kind of databases comparison measures and procedures for the examination and approval based on Git | |
US10565223B2 (en) | Integrated workflow and database transactions | |
US8209284B1 (en) | Data propagation in a multi-shard database system | |
JP5598017B2 (en) | Judgment program, method and apparatus | |
CN102934114B (en) | For the checkpoint of file system | |
US10204125B2 (en) | Method, apparatus, and application platform for updating application object attribute | |
US8832022B2 (en) | Transaction processing device, transaction processing method and transaction processing program | |
CN109952564A (en) | The formation and manipulation of test data in Database Systems | |
CN107257973A (en) | The data source inquired about on network | |
US9940182B1 (en) | Business rule engine validation systems and related methods | |
Kleppmann et al. | Online event processing | |
WO2019026171A1 (en) | Storage system management system | |
JP5033322B2 (en) | Information management method and apparatus using connection relation information | |
US20090070743A1 (en) | System and method for analyzing software applications | |
Fürber et al. | Data quality | |
AU2017352442B2 (en) | Defining variability schemas in an application programming interface (API) | |
US20080313472A1 (en) | Method and apparatus for changing and adding activation keys for functions of digital content without having to change and recompile the digital content | |
US20210342471A1 (en) | System and method of block chain based protection for customized data integration processes | |
EP2130151A1 (en) | System and method for validating design requirements | |
JP2009517780A (en) | Business transaction representation | |
EP3944170A1 (en) | Asset model configuration and validation | |
CN106934701B (en) | Enterprise tax risk value calculation method | |
Watt | Microsoft SQL Server 2005 for dummies | |
JP2012164177A (en) | Program automatic generation system | |
Kleppmann et al. | The magazine archive includes every article published in Communications of the ACM for over the past 50 years. |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20190802 |