CN108549691A - A kind of tracking of database session and analysis method and its device - Google Patents

A kind of tracking of database session and analysis method and its device Download PDF

Info

Publication number
CN108549691A
CN108549691A CN201810330655.3A CN201810330655A CN108549691A CN 108549691 A CN108549691 A CN 108549691A CN 201810330655 A CN201810330655 A CN 201810330655A CN 108549691 A CN108549691 A CN 108549691A
Authority
CN
China
Prior art keywords
function
session
information
failure
tracking
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.)
Granted
Application number
CN201810330655.3A
Other languages
Chinese (zh)
Other versions
CN108549691B (en
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.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information 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 Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201810330655.3A priority Critical patent/CN108549691B/en
Publication of CN108549691A publication Critical patent/CN108549691A/en
Application granted granted Critical
Publication of CN108549691B publication Critical patent/CN108549691B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

The invention discloses a kind of tracking of database session and analysis methods, including obtain the identity coding and serial line interface coding of failure session;Preset first function is called, first function encodes the session information that real-time returning tracking captures according to identity coding real-time tracking failure session, and by serial line interface;Preset second function, the session information that second function Analysis and Screening first function returns is called to obtain useful information and be stored in presupposed information library;Wherein, after failure conversation end, first function is out of service;Whole session information Analysis and Screening that second function receives itself finish and first function it is out of service after, second function is out of service.The present invention can be automatically to failure session into line trace and Analysis and Screening, and working efficiency and accuracy are high, and continuity is good;The invention also discloses a kind of device, equipment and computer readable storage medium based on the above method.

Description

A kind of tracking of database session and analysis method and its device
Technical field
The present invention relates to database monitoring technical fields, more particularly to a kind of tracking of database session and analysis method. The invention further relates to a kind of tracking of database session and analytical equipment, equipment and computer readable storage mediums.
Background technology
After database session refers to connection of the user by consumer process and Database, generate in the database Process, the performance evaluation of database session and tuning are always a hot issue.
It is only capable of to session into line trace in current all relevant databases, but a kind of no molding method Or device automatically analyzes database session, and usually after tracking, manual analysis is carried out to the information of tracking Screening and manual analysis, it is relatively low to the efficiency of performance evaluation, and there may be artificial erroneous judgement, accuracy is low, and meeting The continuity of words tracking and analysis is poor.
Therefore, how the good database session tracking of a kind of efficient and continuity and analysis method, device, equipment are provided And computer readable storage medium is the current problem to be solved of those skilled in the art.
Invention content
The object of the present invention is to provide a kind of tracking of database session and analysis methods, can be carried out automatically to failure session Tracking and Analysis and Screening, working efficiency and accuracy are high, and continuity is good;It is a further object of the present invention to provide one kind based on upper State device, equipment and the computer readable storage medium of method.
In order to solve the above technical problems, the present invention provides a kind of tracking of database session and analysis methods, including:
Obtain the identity coding and serial line interface coding of failure session;
Call preset first function, the first function according to failure session described in the identity coding real-time tracking, And the session information of real-time returning tracking capture is encoded by the serial line interface;
Call preset second function, the session information that first function returns described in the second function Analysis and Screening obtains To useful information and it is stored in presupposed information library;
Wherein, after the failure conversation end, the first function is out of service;The second function receives itself Whole session information Analysis and Screening finish and the first function it is out of service after, the second function is out of service.
Preferably, the condition of the second function is called to be specially:
The session information that the first function returns is received, that is, calls the second function.
Preferably, the condition of the second function is called to be specially:
The first function is out of service and after receiving whole session informations that the first function returns, described in calling Second function.
Preferably, further include:
After the second function is stopped, third function is called, the third function is according to the presupposed information library In useful information and default tuning rule, determine tuning scheme, and according to failure session described in the tuning project setting.
Preferably, further include before the identity coding for obtaining failure session and serial line interface coding:
The state of currently running each session is detected, and the state detected is compared with arm's length standard, is analyzed Comparison result obtains the identity coding and serial line interface coding of the failure session, and described in input if finding failure session In storing process where first function.
Preferably, the useful information includes SQL executive plans, waits for event and statistical information.
In order to solve the above technical problems, the present invention also provides a kind of tracking of database session and analytical equipments, including:
Trigger module, the identity coding for obtaining failure session and serial line interface coding;Trigger tracking module;
The tracking module, for calling preset first function, the first function real-time according to the identity coding The failure session is tracked, and encodes the session information of real-time returning tracking capture by the serial line interface;Wherein, the event After hindering conversation end, the first function is out of service;Trigger Analysis and Screening module;
The Analysis and Screening module, for calling preset second function, first described in the second function Analysis and Screening The session information that function returns, obtains useful information and is stored in presupposed information library;What the second function received itself Whole session information Analysis and Screening finish and the first function it is out of service after, the second function is out of service.
Preferably, further include:
Tuning module, for after the second function is stopped, calling third function, the third function is according to institute The useful information and default tuning rule in presupposed information library are stated, determines tuning scheme, and according to the tuning project setting The failure session.
In order to solve the above technical problems, the present invention also provides a kind of tracking of database session and analytical equipments, including:
Memory, for storing computer program;
Processor, realized when for executing the computer program database session as described in any of the above item track and The step of analysis method.
In order to solve the above technical problems, the present invention also provides a kind of computer readable storage medium, the computer can It reads to be stored with computer program on storage medium, be realized as described in any of the above item when the computer program is executed by processor Database session tracking and the step of analysis method.
The present invention provides a kind of tracking of database session and analysis methods, after finding failure session, obtain characterization event Hinder the identity coding of session and be used for transmission the serial line interface coding of the session information of failure session, calls first function later, That failure session is obtained session information, then call second function into line trace, Analysis and Screening carried out to session information, Obtain useful information.As it can be seen that the present invention can be to failure session automatically into line trace and Analysis and Screening, work efficiency is high, and accidentally The case where judgement, is few, and accuracy is high;Also, the sequential consistency of the work of session tracking and screening analysis is good.The present invention also carries A kind of device, equipment and computer readable storage medium based on the above method are supplied.
Description of the drawings
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to institute in the prior art and embodiment Attached drawing to be used is needed to be briefly described, it should be apparent that, the accompanying drawings in the following description is only some implementations of the present invention Example, for those of ordinary skill in the art, without creative efforts, can also obtain according to these attached drawings Obtain other attached drawings.
Fig. 1 is the flow chart of the process of a kind of database session tracking provided by the invention and analysis method;
Fig. 2 is the structural schematic diagram of a kind of database session tracking provided by the invention and analytical equipment.
Specific implementation mode
Core of the invention is to provide a kind of tracking of database session and analysis method, can be carried out automatically to failure session Tracking and Analysis and Screening, working efficiency and accuracy are high, and continuity is good;Another core of the present invention is to provide a kind of based on upper State device, equipment and the computer readable storage medium of method.
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with the embodiment of the present invention In attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is A part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art The every other embodiment obtained without making creative work, shall fall within the protection scope of the present invention.
The present invention provides a kind of tracking of database session and analysis methods, and shown in Figure 1, Fig. 1 provides for the present invention A kind of database session tracking and analysis method process flow chart;This method includes:
Step s1:The identity coding SID and serial line interface for obtaining failure session encode SERIAL;
Step s2:Preset first function, first function is called to pass through according to identity coding real-time tracking failure session Serial line interface encodes the session information of real-time returning tracking capture;
Step s3:Preset second function, the session information that second function Analysis and Screening first function returns is called to obtain Useful information is simultaneously stored in presupposed information library;
Wherein, after failure conversation end, first function is out of service;Whole sessions letter that second function receives itself Breath Analysis and Screening finish and first function it is out of service after, second function is out of service.
It is understood that the purpose of first function and second function is analyzed into line trace and screening failure session, Therefore, (i.e. session becomes inactive from activity) after failure conversation end, first function and second function need not rerun, no It crosses and is finished since second function may there remains partial session information and not yet analyze, it is therefore desirable to after waiting for all analyses, Second function is out of service again.
In an advantageous embodiment, the condition of second function is called to be specially:
The session information for receiving first function return, that is, call second function.
It is understood that in the present embodiment, once receiving the session information of first function return, then calling immediately Second function is screened, so when first function run simultaneously with second function.This mode can utmostly reduce meeting The total time of words tracking and screening, improve working efficiency.
In another preferred embodiment, the condition of second function is called to be specially:
First function it is out of service and receive first function return whole session informations after, call second function.
It is understood that in the present embodiment, second function needs to start to transport again after waiting for first function end of run It goes, under this mode, second function can carry out the session information of entire session unified screen and analyze, compared to one side reception meeting The mode that words information is screened on one side, the globality of the present embodiment is more preferable, and the condition integrally screened can be arranged in second function.
Preferably, this method further includes:
Step s4:After second function is stopped, third function is called, third function is according to useful in presupposed information library Information and default tuning rule, determine tuning scheme, and according to tuning project setting failure session.
It is understood that the useful information in presupposed information library can manually be analyzed by staff, and then determine Tuning scheme, the scheme that can also be used in above example are realized.For above-described embodiment, after second function is stopped, It calls third function to carry out tuning, session tracking-screening analysis-tuning sequence can be made to carry out, improve continuity, and reduce The process of artificial tuning, further reduces workload, improves work efficiency.
Preferably, it obtains the identity coding of failure session and serial line interface encodes and further includes before:
The state of currently running each session is detected, and the state detected is compared with arm's length standard, is analyzed Comparison result obtains the identity coding and serial line interface coding of the failure session if finding failure session, and input first In storing process where function.
It is understood that determining that the mode of failure session is generally artificial at present, therefore it is easy to miss failure session, And by the above method, even if can find the session to go wrong, and automatically obtain SID and SERIAL after, triggering session with Track and follow-up process, reliability is high, and promptness is good.
Specifically, useful information includes SQL executive plans, waits for event and statistical information.
Certainly, useful information also may include other content, it includes content can be decided according to the actual requirements, the present invention is not Make specific limit.
It should be noted that the method for the present invention be based on a preset storing process (storing process be one group in order to Complete the SQL statement collection of specific function) carry out, first function, second function and third function are provided in the storing process (may not include third function for section Example) after storing process receives SID and SERIAL, calls first function, After calling second function, second function to be stopped after the session information that storing process reception first function returns, storing process Call third function.
The present invention provides a kind of tracking of database session and analysis methods, after finding failure session, obtain characterization event Hinder the identity coding of session and be used for transmission the serial line interface coding of the session information of failure session, calls first function later, That failure session is obtained session information, then call second function into line trace, Analysis and Screening carried out to session information, Obtain useful information.As it can be seen that the present invention can be to failure session automatically into line trace and Analysis and Screening, work efficiency is high, and accidentally The case where judgement, is few, and accuracy is high;Also, the sequential consistency of the work of session tracking and screening analysis is good.
The present invention also provides a kind of tracking of database session and analytical equipments, and shown in Figure 2, Fig. 2 carries for the present invention The structural schematic diagram of a kind of tracking of database session and analytical equipment that supply.The device includes:
Trigger module 1, the identity coding for obtaining failure session and serial line interface coding;Trigger tracking module 2;
Tracking module 2, for calling preset first function, first function is according to identity coding real-time tracking failure meeting Words, and the session information that real-time returning tracking captures is encoded by serial line interface;Wherein, after failure conversation end, first function It is out of service;Trigger Analysis and Screening module 3;
Analysis and Screening module 3, for calling preset second function, the meeting that second function Analysis and Screening first function returns Information is talked about, useful information is obtained and is stored in presupposed information library;Whole session informations analysis that second function receives itself Screening finish and first function it is out of service after, second function is out of service.
Preferably, which further includes:
Tuning module 4, for after second function is stopped, calling third function, the third function is according to default Useful information in information bank and default tuning rule, determine tuning scheme, and according to tuning project setting failure session.
The present invention provides a kind of tracking of database session and analytical equipments, after finding failure session, obtain characterization event Hinder the identity coding of session and be used for transmission the serial line interface coding of the session information of failure session, calls first function later, That failure session is obtained session information, then call second function into line trace, Analysis and Screening carried out to session information, Obtain useful information.As it can be seen that the present invention can be to failure session automatically into line trace and Analysis and Screening, work efficiency is high, and accidentally The case where judgement, is few, and accuracy is high;Also, the sequential consistency of the work of session tracking and screening analysis is good.
The present invention also provides a kind of tracking of database session and analytical equipments, including:
Memory, for storing computer program;
Processor realizes the database session tracking such as any of the above item and analysis method when for executing computer program The step of.
The present invention also provides a kind of computer readable storage medium, computer is stored on computer readable storage medium Program is realized when computer program is executed by processor such as the database session tracking of any of the above item and the step of analysis method Suddenly.
Above several specific implementation modes are only the preferred embodiment of the present invention, and above several specific embodiments can be with Arbitrary combination, the embodiment obtained after combination is also within protection scope of the present invention.It should be pointed out that for the art For those of ordinary skill, relevant speciality technical staff deduced out in the case where not departing from spirit of that invention and concept thereof other change Into and variation, should all be included in the protection scope of the present invention.
Each embodiment is described by the way of progressive in this specification, the highlights of each of the examples are with other The difference of embodiment, just to refer each other for identical similar portion between each embodiment.For device disclosed in embodiment For, since it is corresponded to the methods disclosed in the examples, so description is fairly simple, related place is said referring to method part It is bright.
It should also be noted that, in the present specification, relational terms such as first and second and the like be used merely to by One entity or operation are distinguished with another entity or operation, without necessarily requiring or implying these entities or operation Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant meaning Covering non-exclusive inclusion, so that the process, method, article or equipment including a series of elements includes not only that A little elements, but also include other elements that are not explicitly listed, or further include for this process, method, article or The intrinsic element of equipment.In the absence of more restrictions, the element limited by sentence "including a ...", is not arranged Except there is also other identical elements in the process, method, article or apparatus that includes the element.
The foregoing description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, as defined herein General Principle can be realized in other embodiments without departing from the spirit or scope of the present invention.Therefore, of the invention It is not intended to be limited to the embodiments shown herein, and is to fit to and the principles and novel features disclosed herein phase one The widest range caused.

Claims (10)

1. a kind of database session tracking and analysis method, which is characterized in that including:
Obtain the identity coding and serial line interface coding of failure session;
Preset first function, the first function is called to lead to according to failure session described in the identity coding real-time tracking Cross the session information that the serial line interface encodes real-time returning tracking capture;
Call preset second function, the session information that first function returns described in the second function Analysis and Screening is had With information and it is stored in presupposed information library;
Wherein, after the failure conversation end, the first function is out of service;The second function receives itself complete Portion's session information Analysis and Screening finish and the first function it is out of service after, the second function is out of service.
2. according to the method described in claim 1, it is characterized in that, calling the condition of the second function to be specially:
The session information that the first function returns is received, that is, calls the second function.
3. according to the method described in claim 1, it is characterized in that, calling the condition of the second function to be specially:
The first function is out of service and after receiving whole session informations that the first function returns, and calls described second Function.
4. according to claim 1-3 any one of them methods, which is characterized in that further include:
After the second function is stopped, third function is called, the third function is according in the presupposed information library Useful information and default tuning rule, determine tuning scheme, and according to failure session described in the tuning project setting.
5. according to the method described in claim 4, it is characterized in that, the identity coding and serial interface for obtaining failure session Further include before mouth coding:
The state of currently running each session is detected, and the state detected is compared with arm's length standard, analysis is compared If as a result, finding failure session, that is, the identity coding and serial line interface coding of the failure session are obtained, and inputs described first In storing process where function.
6. according to the method described in claim 5, it is characterized in that, the useful information includes SQL executive plans, waits for event And statistical information.
7. a kind of database session tracking and analytical equipment, which is characterized in that including:
Trigger module, the identity coding for obtaining failure session and serial line interface coding;Trigger tracking module;
The tracking module, for calling preset first function, the first function is according to the identity coding real-time tracking The failure session, and the session information that real-time returning tracking captures is encoded by the serial line interface;Wherein, the failure meeting After words, the first function is out of service;Trigger Analysis and Screening module;
The Analysis and Screening module, for calling preset second function, first function described in the second function Analysis and Screening The session information of return obtains useful information and is stored in presupposed information library;The whole that the second function receives itself Session information Analysis and Screening finish and the first function it is out of service after, the second function is out of service.
8. device according to claim 7, which is characterized in that further include:
Tuning module, for after the second function is stopped, calling third function, the third function is according to described pre- If the useful information in information bank and default tuning rule, determine tuning scheme, and according to described in the tuning project setting Failure session.
9. a kind of database session tracking and analytical equipment, which is characterized in that including:
Memory, for storing computer program;
Processor, when for executing the computer program realize as claim 1 to 6 any one of them database session with The step of track and analysis method.
10. a kind of computer readable storage medium, which is characterized in that be stored with computer on the computer readable storage medium Program realizes that claim 1 to 6 any one of them database session such as tracks when the computer program is executed by processor And the step of analysis method.
CN201810330655.3A 2018-04-13 2018-04-13 Database session tracking and analyzing method and device Active CN108549691B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810330655.3A CN108549691B (en) 2018-04-13 2018-04-13 Database session tracking and analyzing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810330655.3A CN108549691B (en) 2018-04-13 2018-04-13 Database session tracking and analyzing method and device

Publications (2)

Publication Number Publication Date
CN108549691A true CN108549691A (en) 2018-09-18
CN108549691B CN108549691B (en) 2021-09-17

Family

ID=63515090

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810330655.3A Active CN108549691B (en) 2018-04-13 2018-04-13 Database session tracking and analyzing method and device

Country Status (1)

Country Link
CN (1) CN108549691B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6223215B1 (en) * 1998-09-22 2001-04-24 Sony Corporation Tracking a user's purchases on the internet by associating the user with an inbound source and a session identifier
US20080098359A1 (en) * 2006-09-29 2008-04-24 Ventsislav Ivanov Manipulation of trace sessions based on address parameters
CN101989283A (en) * 2009-08-04 2011-03-23 中兴通讯股份有限公司 Monitoring method and device of performance of database
CN101997925A (en) * 2010-11-22 2011-03-30 北京亮点时间科技有限公司 Server monitoring method with early warning function and system thereof
US7953756B1 (en) * 2002-08-09 2011-05-31 Cisco Technology, Inc. Unified high-performance database connectivity system and method
CN104360939A (en) * 2014-10-29 2015-02-18 中国建设银行股份有限公司 Method, equipment and system for positioning fault
CN105446855A (en) * 2015-11-10 2016-03-30 广州西麦科技股份有限公司 APA application tracking and analyzing system
CN106126403A (en) * 2016-06-16 2016-11-16 北京中亦安图科技股份有限公司 Oracle database failure analysis methods and device
CN107895011A (en) * 2017-11-03 2018-04-10 携程旅游网络技术(上海)有限公司 Processing method, system, storage medium and the electronic equipment of session information

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6223215B1 (en) * 1998-09-22 2001-04-24 Sony Corporation Tracking a user's purchases on the internet by associating the user with an inbound source and a session identifier
US7953756B1 (en) * 2002-08-09 2011-05-31 Cisco Technology, Inc. Unified high-performance database connectivity system and method
US20080098359A1 (en) * 2006-09-29 2008-04-24 Ventsislav Ivanov Manipulation of trace sessions based on address parameters
CN101989283A (en) * 2009-08-04 2011-03-23 中兴通讯股份有限公司 Monitoring method and device of performance of database
CN101997925A (en) * 2010-11-22 2011-03-30 北京亮点时间科技有限公司 Server monitoring method with early warning function and system thereof
CN104360939A (en) * 2014-10-29 2015-02-18 中国建设银行股份有限公司 Method, equipment and system for positioning fault
CN105446855A (en) * 2015-11-10 2016-03-30 广州西麦科技股份有限公司 APA application tracking and analyzing system
CN106126403A (en) * 2016-06-16 2016-11-16 北京中亦安图科技股份有限公司 Oracle database failure analysis methods and device
CN107895011A (en) * 2017-11-03 2018-04-10 携程旅游网络技术(上海)有限公司 Processing method, system, storage medium and the electronic equipment of session information

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
GRITZALIS D: "Formal analysis for robust anti-SPIT protection using model checking", 《INTERNATIONAL JOURNAL OF INFORMATION SECURITY》 *
金鑫: "面向企业级数据库的故障分析及运维研究:以Oracle数据库为例", 《软件》 *

Also Published As

Publication number Publication date
CN108549691B (en) 2021-09-17

Similar Documents

Publication Publication Date Title
CN107341098B (en) Software performance testing method, platform, equipment and storage medium
CN107273280B (en) Log processing method and device, electronic equipment and storage medium
US9590880B2 (en) Dynamic collection analysis and reporting of telemetry data
CN106371984B (en) A kind of data monitoring method, equipment and system
CN108845910A (en) Monitoring method, device and the storage medium of extensive micro services system
CN107909330B (en) Workflow data processing method and device, storage medium and computer equipment
CN109633351B (en) Intelligent IT operation and maintenance fault positioning method, device, equipment and readable storage medium
CN109885496B (en) Test log management method and system
US20070083564A1 (en) Automatic performance statistical comparison between two periods
WO2016188100A1 (en) Information system fault scenario information collection method and system
CN111666563B (en) Method and device for verifying application running state
CN109819098A (en) Menu option display methods, server, system and computer readable storage medium
CN118069119B (en) Rule editing system for low-code platform
CN112491617A (en) Link tracking method, device, electronic equipment and medium
CN107958024B (en) Session merging method and device and computer equipment
CN103248511B (en) A kind of analysis methods, devices and systems of single-point service feature
CN111240981A (en) Interface testing method, system and platform
CN109522100A (en) Real-time calculating task method of adjustment and device
CN108960384A (en) A kind of coding/decoding method and client of graphic code
CN108549691A (en) A kind of tracking of database session and analysis method and its device
CN111726402B (en) User behavior data processing method and device, electronic equipment and storage medium
CN108804267A (en) Database polling method, device, computer equipment and storage medium
US20140208288A1 (en) Apparatus and Method for Managing a Software Development and Maintenance System
KR101888131B1 (en) Method for Performing Real-Time Changed Data Publish Service of DDS-DBMS Integration Tool
CN112527620A (en) Database performance analysis method and device, electronic equipment, medium and product

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
GR01 Patent grant
GR01 Patent grant