CN105183874A - Self-maintenance distributed database agent method - Google Patents

Self-maintenance distributed database agent method Download PDF

Info

Publication number
CN105183874A
CN105183874A CN201510601592.7A CN201510601592A CN105183874A CN 105183874 A CN105183874 A CN 105183874A CN 201510601592 A CN201510601592 A CN 201510601592A CN 105183874 A CN105183874 A CN 105183874A
Authority
CN
China
Prior art keywords
database instance
database
instance
data base
distributed data
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
Application number
CN201510601592.7A
Other languages
Chinese (zh)
Inventor
廖旻可
毕先春
卢述奇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
BEIJING BAOFENG TECHNOLOGY Co Ltd
Original Assignee
BEIJING BAOFENG TECHNOLOGY Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by BEIJING BAOFENG TECHNOLOGY Co Ltd filed Critical BEIJING BAOFENG TECHNOLOGY Co Ltd
Priority to CN201510601592.7A priority Critical patent/CN105183874A/en
Publication of CN105183874A publication Critical patent/CN105183874A/en
Pending legal-status Critical Current

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/25Integrating or interfacing systems involving database management systems
    • G06F16/254Extract, transform and load [ETL] procedures, e.g. ETL data flows in data warehouses
    • 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/25Integrating or interfacing systems involving database management systems
    • G06F16/252Integrating or interfacing systems involving database management systems between a Database Management System and a front-end application

Abstract

The invention discloses a self-maintenance distributed database agent method. The method includes the steps that a database instance resource pool receives a query link; a database instance is extracted from the resource pool; whether the database instance is connected based on a TCP/IP layer is judged; if not, the database instance is put into a blacklist, and if yes, service data are sampled from the database instance and whether the service data are complete and available is judged; if not, the database instance is put into the blacklist, and if yes, the query is linked to the database instance. According to the scheme, a high-availability distributed database agent can be achieved; through failing database instance management based on a blacklist technology, failing database instances can be automatically recovered; besides, due to introduced delay time between recovery operations, deadlocking caused by frequent recovery of database instances is avoided.

Description

A kind of distributed data base Proxy Method from safeguarding
Technical field
The application relates to database broker technology, specifically, relates to a kind of distributed data base Proxy Method from safeguarding.
Background technology
Current, in the process of distributed data base Proxy Method, existing way majority acts on behalf of the existing database instance pond that connects, but do not relate to the error listing maintenance and management to database instance.
Such as, publication No. be CN103729373A patent document discloses a kind of database broker method and apparatus, wherein database broker method comprises: be each Database connection pool in multiple database; Receive the request that database application end sends; By the request received, the DataBase combining transferred in connection pool carries out database manipulation; Execution result is returned to database application end; Wherein, the DataBase combining transferred described in connection pool carries out database manipulation and comprises: the information acquisition database manipulation order in analysis request; Determine the database as operand according to database manipulation order and configuration information, wherein said configuration information comprises described multiple wide area information server type; From the connection pool corresponding to determined database, called data storehouse connects, apply this DataBase combining and database manipulation order is sent to determined database, and receive execution result from this database, just do not relate to the error listing maintenance and management to database instance in the method.
Summary of the invention
In view of this, technical problems to be solved in this application there is provided a kind of distributed data base Proxy Method from safeguarding, to solve in prior art and only the existing database instance pond that connects is acted on behalf of, and do not relate to the problem of the error listing maintenance and management to database instance.
In order to solve the problems of the technologies described above, the application has following technical scheme:
From the distributed data base Proxy Method safeguarded, it is characterized in that, comprising: database instance resource pool receives an inquiry and connects; A database instance is extracted from described resource pool; Judge that described database instance is based on tcp/ip layer whether UNICOM, if not UNICOM, then described database instance is put into blacklist, if UNICOM, then business datum of sampling from described database instance, and judge that whether complete described business datum is available, if unavailable, then described database instance is put into described blacklist, if available, then described inquiry is connected to described database instance.
Compared with prior art, the method described in the application and, reach following effect:
The first, the scheme of this patent can realize the distributed data base agency of a High Availabitity;
The second, this patent is based on the miss data storehouse instance management of black list techniques, can carry out automatic recovery operation to the database instance of failure;
Three, the time delay between the recovery introduced of this patent, deadlock that frequent restore database example causes (start and restore database example also needs certain hour) is avoided.
Accompanying drawing explanation
Accompanying drawing described herein is used to provide further understanding of the present application, and form a application's part, the schematic description and description of the application, for explaining the application, does not form the improper restriction to the application.In the accompanying drawings:
Fig. 1 is the process flow diagram of described a kind of distributed data base Proxy Method from safeguarding of the present invention;
Fig. 2 is another process flow diagram of described a kind of distributed data base Proxy Method from safeguarding of the present invention;
Embodiment
As employed some vocabulary to censure specific components in the middle of instructions and claim.Those skilled in the art should understand, and hardware manufacturer may call same assembly with different noun.This specification and claims are not used as with the difference of title the mode distinguishing assembly, but are used as the criterion of differentiation with assembly difference functionally." comprising " as mentioned in the middle of instructions and claim is in the whole text an open language, therefore should be construed to " comprise but be not limited to "." roughly " refer to that in receivable error range, those skilled in the art can solve the technical problem within the scope of certain error, reach described technique effect substantially.In addition, " couple " word and comprise directly any and indirectly electric property coupling means at this.Therefore, if describe a first device in literary composition to be coupled to one second device, then represent described first device and directly can be electrically coupled to described second device, or be indirectly electrically coupled to described second device by other devices or the means that couple.Instructions subsequent descriptions is implement the better embodiment of the application, and right described description is for the purpose of the rule that the application is described, and is not used to the scope limiting the application.The protection domain of the application is when being as the criterion depending on the claims person of defining.
Embodiment 1
The specific embodiment of the distributed data base Proxy Method for certainly safeguarding described in the application shown in Figure 1, described in the present embodiment, method comprises the following steps:
Step 101: database instance resource pool receives an inquiry and connects;
Step 102: extract a database instance from described resource pool;
Step 103: judge that described database instance is based on tcp/ip layer whether UNICOM, if not UNICOM, then proceeds to step 106, if UNICOM, proceeds to step 104;
Step 104: business datum of sampling from described database instance, and judge that whether complete described business datum is available, if unavailable, then proceed to step 106, if available, then proceed to step 105;
Step 105: described inquiry is connected to described database instance;
Step 106: described database instance is put into blacklist;
Step 107: database instance blacklist is processed.
Wherein, after described database instance is put into described blacklist, from described resource pool, again choose a database instance, repeat to judge that described database instance is based on tcp/ip layer whether UNICOM and judge that whether complete described business datum is available.
Wherein, multiple database instance is comprised in described resource pool.
Wherein, described resource pool provides unique interface, for receiving the request that inquiry connects.
Embodiment 2
For being described in more detail the present invention, another specific embodiment of the distributed data base Proxy Method for certainly safeguarding described in the application shown in Figure 2, described in the present embodiment, method comprises the following steps:
In order to do more detailed explanation to the present invention, existing for carrying out process to database instance blacklist and be explained as follows in embodiment 1.
Step 201: after described database instance is put into described blacklist, extracts a database instance from described blacklist;
Step 202: judge that this database instance is based on tcp/ip layer whether UNICOM, if not UNICOM, proceeds to step 205, if UNICOM, then proceeds to step 203;
Step 203: business datum of sampling from described database instance, and judge that whether complete described business datum is available, if unavailable, then proceed to step 206, if available, then proceed to step 204;
Step 204: this database instance is removed from described blacklist, and put into can database instance resource pool;
Step 205: notify that maintainer carries out hardware maintenance;
Step 206: managing process restore database example operation in notice instance server;
Step 207: to notify in described instance server, after managing process restore database example operation, again to judge that whether complete described business datum is available, if unavailable, then proceed to step 206; If available, proceed to step 204;
Wherein, if managing process restore database example operation reaches pre-determined number and described business datum is still unavailable in described instance server, then proceed to step 205, notify that maintainer carries out hardware maintenance.
Wherein, from described blacklist, extract a database instance is that intermittent is extracted, and such as, interval time is 60-180 second, and user can set as required.
Known by above each embodiment, the beneficial effect that the application exists is:
The first, the scheme of this patent can realize the distributed data base agency of a High Availabitity;
The second, this patent is based on the miss data storehouse instance management of black list techniques, can carry out automatic recovery operation to the database instance of failure;
Three, the time delay between the recovery introduced of this patent, deadlock that frequent restore database example causes (start and restore database example also needs certain hour) is avoided.
Those skilled in the art should understand, the embodiment of the application can be provided as method, device or computer program.Therefore, the application can adopt the form of complete hardware embodiment, completely software implementation or the embodiment in conjunction with software and hardware aspect.And the application can adopt in one or more form wherein including the upper computer program implemented of computer-usable storage medium (including but not limited to magnetic disk memory, CD-ROM, optical memory etc.) of computer usable program code.
Above-mentioned explanation illustrate and describes some preferred embodiments of the application, but as previously mentioned, be to be understood that the application is not limited to the form disclosed by this paper, should not regard the eliminating to other embodiments as, and can be used for other combinations various, amendment and environment, and can in invention contemplated scope described herein, changed by the technology of above-mentioned instruction or association area or knowledge.And the change that those skilled in the art carry out and change do not depart from the spirit and scope of the application, then all should in the protection domain of the application's claims.

Claims (10)

1., from the distributed data base Proxy Method safeguarded, it is characterized in that, comprising:
Database instance resource pool receives an inquiry and connects;
A database instance is extracted from described resource pool;
Judge that described database instance is based on tcp/ip layer whether UNICOM, if not UNICOM, then described database instance is put into blacklist, if UNICOM, then
To sample from described database instance business datum, and judge that whether complete described business datum is available, if unavailable, then described database instance is put into described blacklist, if available, then described inquiry is connected to described database instance.
2. according to claim 1 from the distributed data base Proxy Method safeguarded, it is characterized in that, after described database instance is put into described blacklist, from described resource pool, again choose a database instance, repeat to judge that described database instance is based on tcp/ip layer whether UNICOM and judge that whether complete described business datum is available.
3. according to claim 1 from the distributed data base Proxy Method safeguarded, it is characterized in that, described resource pool provides unique interface, for receiving the request that inquiry connects.
4. according to claim 1 from the distributed data base Proxy Method safeguarded, it is characterized in that, after described database instance is put into described blacklist, a database instance is extracted from described blacklist, judge that this database instance is based on tcp/ip layer whether UNICOM, if not UNICOM, then notify that maintainer carries out hardware maintenance.
5. according to claim 4 from the distributed data base Proxy Method safeguarded, it is characterized in that, if judge, this database instance is UNICOM based on tcp/ip layer, then to sample from this database instance business datum, and judge that whether complete described business datum is available, if unavailable, then notify managing process restore database example operation in instance server.
6. according to claim 5 from the distributed data base Proxy Method safeguarded, it is characterized in that, to notify in described instance server after managing process restore database example operation, again judge that whether complete described business datum is available, if unavailable, then again notify managing process restore database example operation in described instance server.
7. the distributed data base Proxy Method certainly safeguarded according to claim 5 or 6, it is characterized in that, if judge, described business datum is complete available, then removed from described blacklist by this database instance, and put into can database instance resource pool.
8. according to claim 6 from the distributed data base Proxy Method safeguarded, it is characterized in that, if managing process restore database example operation reaches pre-determined number and described business datum is still unavailable in described instance server, then notify that maintainer carries out hardware maintenance.
9. according to claim 4 from the distributed data base Proxy Method safeguarded, it is characterized in that, from described blacklist, extract a database instance is that intermittent is extracted.
10. according to claim 9 from the distributed data base Proxy Method safeguarded, it is characterized in that, the interval time that described intermittent is extracted is 60-180 second.
CN201510601592.7A 2015-09-19 2015-09-19 Self-maintenance distributed database agent method Pending CN105183874A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510601592.7A CN105183874A (en) 2015-09-19 2015-09-19 Self-maintenance distributed database agent method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510601592.7A CN105183874A (en) 2015-09-19 2015-09-19 Self-maintenance distributed database agent method

Publications (1)

Publication Number Publication Date
CN105183874A true CN105183874A (en) 2015-12-23

Family

ID=54905955

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510601592.7A Pending CN105183874A (en) 2015-09-19 2015-09-19 Self-maintenance distributed database agent method

Country Status (1)

Country Link
CN (1) CN105183874A (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110099146A1 (en) * 2009-10-26 2011-04-28 Mcalister Grant Alexander Macdonald Monitoring of replicated data instances
CN102497435A (en) * 2011-12-16 2012-06-13 海南杰福瑞网络科技有限公司 Data distributing method and device of data service
CN102955851A (en) * 2012-10-30 2013-03-06 北京奇虎科技有限公司 Database switching method and device
CN104252500A (en) * 2013-06-29 2014-12-31 北京新媒传信科技有限公司 Method and device for carrying out fault repairing on database management platform

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110099146A1 (en) * 2009-10-26 2011-04-28 Mcalister Grant Alexander Macdonald Monitoring of replicated data instances
CN102497435A (en) * 2011-12-16 2012-06-13 海南杰福瑞网络科技有限公司 Data distributing method and device of data service
CN102955851A (en) * 2012-10-30 2013-03-06 北京奇虎科技有限公司 Database switching method and device
CN104252500A (en) * 2013-06-29 2014-12-31 北京新媒传信科技有限公司 Method and device for carrying out fault repairing on database management platform

Similar Documents

Publication Publication Date Title
CN103744802B (en) Method and device for identifying SQL injection attacks
CN102402596B (en) A kind of reading/writing method of master slave separation database and system
CN102736939B (en) Software installation method, device and system
US9240933B2 (en) Transaction middleware based application level transaction instance tracking across a composite application
CN102799468B (en) The method and apparatus opening unknown file
US20170147469A1 (en) Correlation of source code with system dump information
CN105760159A (en) Website developing method and system
CN102567485B (en) The special parsing of provider for content retrieval
US9442822B2 (en) Providing a visual representation of a sub-set of a visual program
EP3544331A1 (en) System for simultaneous viewing and editing of multiple network device configurations
CN101821993A (en) Method and system for handling failover in distributed environment that uses session affinity
CN101814077A (en) OCI 9-based database access middleware
US20170187578A1 (en) System and method for acquiring, processing and updating global information
CN106529281B (en) A kind of executable file processing method and processing device
CN105183874A (en) Self-maintenance distributed database agent method
CN105589940A (en) Safety management operation and maintenance service platform based on unstructured real-time database
CN103546500A (en) Method and system for switching servers
CN113672233B (en) Server out-of-band management method, device and equipment based on Redfish
CN106708541A (en) Version upgrading processing method and apparatus
CN103793516A (en) Method and device for obtaining URL icon
EP3716584A1 (en) Data enrichment systems and methods for abbreviated domain name classification
CN113835786A (en) Data docking system, method and computer-readable storage medium
CN109144489B (en) State data processing method based on Yang language model
EP2600271B1 (en) Device for right managing web data, recording medium for performing method for right managing web data on computer, and device and method for providing right management information
JP2008210214A (en) Information processor, communication control processing function addition method and communication control processing function addition program

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information

Address after: 100191 Beijing, Xueyuan Road No. 51, the first to enjoy the science and technology building, floor 6,

Applicant after: Storm group Limited by Share Ltd

Address before: 100191 Beijing, Xueyuan Road No. 51, the first to enjoy the science and technology building, floor 6,

Applicant before: Beijing Baofeng Technology Co., Ltd.

COR Change of bibliographic data
RJ01 Rejection of invention patent application after publication

Application publication date: 20151223

RJ01 Rejection of invention patent application after publication