CN109101403A - A kind of pair of mobile terminal generates the method and system that SQL is monitored in real time - Google Patents
A kind of pair of mobile terminal generates the method and system that SQL is monitored in real time Download PDFInfo
- Publication number
- CN109101403A CN109101403A CN201810972939.2A CN201810972939A CN109101403A CN 109101403 A CN109101403 A CN 109101403A CN 201810972939 A CN201810972939 A CN 201810972939A CN 109101403 A CN109101403 A CN 109101403A
- Authority
- CN
- China
- Prior art keywords
- sql
- mobile terminal
- monitored
- real time
- background server
- 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
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/30—Monitoring
- G06F11/3003—Monitoring arrangements specially adapted to the computing system or computing system component being monitored
- G06F11/302—Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a software system
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/30—Monitoring
- G06F11/34—Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
- G06F11/3466—Performance evaluation by tracing or monitoring
Abstract
The invention discloses a kind of pair of mobile terminals to generate the method and system that SQL is monitored in real time, belongs to computer software technical field.Of the invention generates the method that SQL is monitored in real time to mobile terminal, it is initiated in HTTP request to background server mobile terminal, the mobile unique session identification of end equipment is carried, background server records the SQL of this request generation of mobile terminal according to unique session identification and recorded.The method of the invention monitored in real time to mobile terminal generation SQL facilitates field conduct and backstage exploitation and tester to business understanding and system problem analysis, improves working efficiency, has good application value.
Description
Technical field
The present invention relates to computer software technical fields, specifically provide a kind of couple of mobile terminal generation SQL and monitor in real time
Method and system.
Background technique
By taking tobacco business customer manager's mobile oa platform app as an example, since tobacco business business operation logic is more multiple
It is miscellaneous, it is relatively large to the logic understanding cost of business realizing for test or development and implementation personnel, generally require program of leafing through
Or study analysis is carried out by log recording.Simultaneously with the generation of performance issue, it is difficult to carry out under complications real-time
Analysis and monitoring, generally require client and finish to analyze the record in log after key business, lack real-time, and
And it is difficult to restore corresponding problem.
Summary of the invention
Technical assignment of the invention be in view of the above problems, provide it is a kind of facilitate field conduct and backstage exploitation with
And tester understands business and system problem is analyzed, and improves monitoring in real time to mobile terminal generation SQL for working efficiency
Method.
The further technical assignment of the present invention is to provide a kind of pair of mobile terminal and generates the system that SQL is monitored in real time.
To achieve the above object, the present invention provides the following technical scheme that
A kind of pair of mobile terminal generates the method that SQL is monitored in real time, and in the method, mobile terminal is initiated to background server
In HTTP request, the mobile unique session identification of end equipment is carried, background server records mobile terminal sheet according to unique session identification
The SQL of secondary request generation is simultaneously recorded.
The SQL, Structured Query Language, that is, structured query language,
Preferably, this method specifically includes the following steps:
S1: exploitation configuration mobile terminal overall situation HTTP request blocker is added mobile terminal session in all HTTP requests and uniquely marks
Know parameter;
S2: the global SQL blocker of customization is developed in background server, the SQL blocker is parsed the SQL of execution simultaneously
Parameter duplication is carried out, executable SQL is converted to, and records and executes the time, only according to mobile terminal by corresponding SQL log
One mark carries out storage record.
In step S2, for the ORM frame that background server is selected, such as MyBatis, Hibernate, Srping
JdbcTemplate etc., exploitation customization overall situation SQL blocker.
Preferably, the method also includes following steps:
S3: developing corresponding SQL monitoring plug-in unit or the monitoring page, opens monitoring plug-in unit or the monitoring page runs shape to SQL in real time
Condition is monitored, and facilitates the real time inspection of SQL.
Preferably, the mode of the SQL log includes in deposit memory or persistent layer in step S2.
SQL within such as 30 is defined according to specific threshold values to be stored in memory, it is asynchronous more than 30 to be transferred to persistent layer
I.e. in database, the SQL record for being transferred to persistent layer can be used for performance or the analysis of other data uses.
Whether uniquely marked with legal mobile terminal preferably, the background server is examined in received HTTP request
Know parameter, the normal processing if having, if not being considered as invalidation request and miscue being returned to mobile terminal.
Preferably, inputting the unique session identification in mobile terminal in step S3 in monitoring plug-in unit or the monitoring page, passing through length
The mode of poll obtains SQL from background server and executes record.
A kind of pair of mobile terminal generates the system that SQL is monitored in real time, including mobile terminal and background server end, the shifting
HTTP request is initiated to background server in moved end, carries the mobile unique session identification of end equipment, background server is according to unique meeting
The SQL of this request generation of words identification record mobile terminal is simultaneously recorded.
Preferably, the mobile terminal exploitation configuration mobile terminal overall situation HTTP request blocker, in all HTTP requests
Mobile terminal session unique id parameter, the global SQL blocker of the background server exploitation customization is added, the SQL is intercepted
The SQL of execution is parsed and is carried out parameter duplication by device, is converted to executable SQL, and is recorded and executed the time, will be corresponding
SQL log carries out storage record according to mobile terminal unique identification.
Preferably, further including monitoring module, corresponding SQL monitoring plug-in unit or monitoring page are developed in the monitoring module
Face, opens monitoring plug-in unit or the monitoring page is in real time monitored SQL operation conditions.
Preferably, the background server is for examining in received HTTP request whether have legal mobile terminal only
One identification parameter, the normal processing if having, if not being considered as invalidation request and miscue being returned to mobile terminal.
Compared with prior art, the method for the invention monitored in real time to mobile terminal generation SQL has following prominent
The utility model has the advantages that
(1) method monitored in real time to mobile terminal generation SQL utilizes long poll technological development monitoring plug-in unit or prison
The page is controlled, the real time inspection of SQL is facilitated;
(2) SQL log carries out storage record according to mobile terminal unique identification, according to specific threshold values define such as 30 with
Interior SQL is stored in memory, asynchronous more than 30 to be transferred in persistent layer i.e. database, and the SQL record for being transferred to persistent layer can
To be used for performance or the analysis of other data;
(3) this method facilitates field conduct and backstage exploitation and tester to analyze business understanding and system problem, improves
Working efficiency has good application value.
Detailed description of the invention
Fig. 1 is the flow chart of the present invention that the method that SQL is monitored in real time is generated to mobile terminal.
Specific embodiment
Below in conjunction with drawings and examples, to it is of the invention to mobile terminal generate method that SQL is monitored in real time and
System is described in further detail.
Embodiment
As shown in Figure 1, of the invention generate the method that is monitored in real time of SQL to mobile terminal, mobile terminal is to background service
End is initiated in HTTP request, and the mobile unique session identification of end equipment is carried, and background server is recorded according to unique session identification and moved
The SQL of this request generation of moved end is simultaneously recorded.Specifically includes the following steps:
S1: exploitation configuration mobile terminal overall situation HTTP request blocker is added mobile terminal session in all HTTP requests and uniquely marks
Know parameter.
S2: the global SQL blocker of customization is developed in background server, the SQL blocker solves the SQL of execution
Parameter duplication is analysed and carried out, executable SQL is converted to, and records and executes the time, by corresponding SQL log according to movement
End unique identification carries out storage record.
For the ORM frame that background server is selected, such as MyBatis, Hibernate, Srping JdbcTemplate
Deng exploitation customization overall situation SQL blocker.
The mode of SQL log includes in deposit memory or persistent layer.It is defined within such as 30 according to specific threshold values
SQL is stored in memory, asynchronous more than 30 to be transferred in persistent layer i.e. database, and the SQL record for being transferred to persistent layer can be with
It is used for performance or the analysis of other data.
Whether background server is examined with legal mobile terminal unique id parameter in received HTTP request, if having
Normal processing, is considered as invalidation request if not and miscue is returned to mobile terminal.
S3: developing corresponding SQL monitoring plug-in unit or the monitoring page, opens monitoring plug-in unit or the monitoring page in real time transports SQL
Row situation is monitored.
The unique session identification in mobile terminal is inputted in monitoring plug-in unit or the monitoring page, is taken by way of long poll from backstage
Business end obtains SQL and executes record.
Of the invention generates the system that SQL is monitored in real time, including mobile terminal, background server end and prison to mobile terminal
Control module.HTTP request is initiated to background server in mobile terminal, carries the mobile unique session identification of end equipment, background server root
According to unique session identification record mobile terminal, this is requested the SQL generated and is recorded.
Mobile terminal exploitation configuration mobile terminal overall situation HTTP request blocker, is added mobile terminal session in all HTTP requests
Unique id parameter, the global SQL blocker of background server exploitation customization, the SQL blocker by the SQL of execution into
Row parse simultaneously carry out parameter duplication, be converted to executable SQL, and record execute the time, by corresponding SQL log according to
Mobile terminal unique identification carries out storage record.Whether background server is for examining in received HTTP request with legal shifting
Moved end unique id parameter, the normal processing if having, if not being considered as invalidation request and miscue being returned to mobile terminal.
Corresponding SQL monitoring plug-in unit or the monitoring page are developed in monitoring module, open monitoring plug-in unit or the monitoring page is real-time
SQL operation conditions is monitored.
Embodiment described above, the only present invention more preferably specific embodiment, those skilled in the art is at this
The usual variations and alternatives carried out within the scope of inventive technique scheme should be all included within the scope of the present invention.
Claims (10)
1. a kind of pair of mobile terminal generates the method that SQL is monitored in real time, it is characterised in that: in the method, mobile terminal is backward
Platform server-side is initiated in HTTP request, carries the mobile unique session identification of end equipment, background server is according to unique session identification
The SQL of this request generation of record mobile terminal is simultaneously recorded.
2. according to claim 1 generate the method that SQL is monitored in real time to mobile terminal, it is characterised in that: this method
Specifically includes the following steps:
S1: exploitation configuration mobile terminal overall situation HTTP request blocker is added mobile terminal session in all HTTP requests and uniquely marks
Know parameter;
S2: the global SQL blocker of customization is developed in background server, the SQL blocker is parsed the SQL of execution simultaneously
Parameter duplication is carried out, executable SQL is converted to, and records and executes the time, only according to mobile terminal by corresponding SQL log
One mark carries out storage record.
3. according to claim 2 generate the method that SQL is monitored in real time to mobile terminal, it is characterised in that: the side
Method is further comprising the steps of:
S3: developing corresponding SQL monitoring plug-in unit or the monitoring page, opens monitoring plug-in unit or the monitoring page runs shape to SQL in real time
Condition is monitored.
4. according to claim 3 generate the method that SQL is monitored in real time to mobile terminal, it is characterised in that: step S2
In, the mode of the SQL log includes in deposit memory or persistent layer.
5. according to claim 4 generate the method that SQL is monitored in real time to mobile terminal, it is characterised in that: after described
Platform server-side examines the normal processing if having whether with legal mobile terminal unique id parameter in received HTTP request,
It is considered as invalidation request if not and miscue is returned into mobile terminal.
6. according to claim 5 generate the method that SQL is monitored in real time to mobile terminal, it is characterised in that: step S3
In, the unique session identification in mobile terminal is inputted in monitoring plug-in unit or the monitoring page, from background server by way of long poll
It obtains SQL and executes record.
7. a kind of pair of mobile terminal generates the system that SQL is monitored in real time, it is characterised in that: including mobile terminal and background server
HTTP request is initiated to background server in end, the mobile terminal, carries the mobile unique session identification of end equipment, background server root
According to unique session identification record mobile terminal, this is requested the SQL generated and is recorded.
8. according to claim 7 generate the system that SQL is monitored in real time to mobile terminal, it is characterised in that: the shifting
Moved end exploitation configuration mobile terminal overall situation HTTP request blocker, is added mobile terminal session unique identification ginseng in all HTTP requests
The SQL of execution is carried out parsing and gone forward side by side by number, the global SQL blocker of the background server exploitation customization, the SQL blocker
The duplication of row parameter, is converted to executable SQL, and records and execute the time, and corresponding SQL log is unique according to mobile terminal
Mark carries out storage record.
9. according to claim 7 or 8 generate the system that SQL is monitored in real time to mobile terminal, it is characterised in that: also wrap
Monitoring module is included, corresponding SQL monitoring plug-in unit or the monitoring page are developed in the monitoring module, opens monitoring plug-in unit or monitoring page
Face is in real time monitored SQL operation conditions.
10. according to claim 9 generate the system that SQL is monitored in real time to mobile terminal, it is characterised in that: after described
Whether platform server-side is for examining with legal mobile terminal unique id parameter in received HTTP request, the normal place if having
Reason, is considered as invalidation request if not and miscue is returned to mobile terminal.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810972939.2A CN109101403A (en) | 2018-08-24 | 2018-08-24 | A kind of pair of mobile terminal generates the method and system that SQL is monitored in real time |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810972939.2A CN109101403A (en) | 2018-08-24 | 2018-08-24 | A kind of pair of mobile terminal generates the method and system that SQL is monitored in real time |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109101403A true CN109101403A (en) | 2018-12-28 |
Family
ID=64851396
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810972939.2A Pending CN109101403A (en) | 2018-08-24 | 2018-08-24 | A kind of pair of mobile terminal generates the method and system that SQL is monitored in real time |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109101403A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109947630A (en) * | 2019-03-14 | 2019-06-28 | 腾讯科技(深圳)有限公司 | A kind of failure bulletin method, apparatus and storage medium |
CN112882893A (en) * | 2021-02-07 | 2021-06-01 | 浪潮软件股份有限公司 | Method for real-time monitoring application service log generated by mobile terminal |
CN114827065A (en) * | 2022-04-28 | 2022-07-29 | 抖动科技(深圳)有限公司 | Real-time communication method based on unified communication channel and related equipment |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103559444A (en) * | 2013-11-05 | 2014-02-05 | 星云融创(北京)信息技术有限公司 | Sql (Structured query language) injection detection method and device |
CN105704146A (en) * | 2016-03-18 | 2016-06-22 | 四川长虹电器股份有限公司 | System and method for SQL injection prevention |
CN106294075A (en) * | 2016-08-17 | 2017-01-04 | 浪潮软件股份有限公司 | A kind of SQL is monitored method, Apparatus and system |
-
2018
- 2018-08-24 CN CN201810972939.2A patent/CN109101403A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103559444A (en) * | 2013-11-05 | 2014-02-05 | 星云融创(北京)信息技术有限公司 | Sql (Structured query language) injection detection method and device |
CN105704146A (en) * | 2016-03-18 | 2016-06-22 | 四川长虹电器股份有限公司 | System and method for SQL injection prevention |
CN106294075A (en) * | 2016-08-17 | 2017-01-04 | 浪潮软件股份有限公司 | A kind of SQL is monitored method, Apparatus and system |
Non-Patent Citations (1)
Title |
---|
吴志祥等: "《Java EE应用开发教程》", 31 December 2016 * |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109947630A (en) * | 2019-03-14 | 2019-06-28 | 腾讯科技(深圳)有限公司 | A kind of failure bulletin method, apparatus and storage medium |
CN112882893A (en) * | 2021-02-07 | 2021-06-01 | 浪潮软件股份有限公司 | Method for real-time monitoring application service log generated by mobile terminal |
CN114827065A (en) * | 2022-04-28 | 2022-07-29 | 抖动科技(深圳)有限公司 | Real-time communication method based on unified communication channel and related equipment |
CN114827065B (en) * | 2022-04-28 | 2024-02-23 | 抖动科技(深圳)有限公司 | Real-time communication method based on unified communication channel and related equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107341098B (en) | Software performance testing method, platform, equipment and storage medium | |
US10621064B2 (en) | Proactive impact measurement of database changes on production systems | |
US7640459B2 (en) | Performing computer application trace with other operations | |
WO2018059402A1 (en) | Method and apparatus for determining fault type | |
EP2572294B1 (en) | System and method for sql performance assurance services | |
CN109861844A (en) | A kind of cloud service problem fine granularity intelligence source tracing method based on log | |
CN109101403A (en) | A kind of pair of mobile terminal generates the method and system that SQL is monitored in real time | |
CN107247811B (en) | SQL statement performance optimization method and device based on Oracle database | |
CN106021079A (en) | A Web application performance testing method based on a user frequent access sequence model | |
US10528456B2 (en) | Determining idle testing periods | |
CN109560996B (en) | Automatic testing system and method for terminal of Internet of things | |
CN111459698A (en) | Database cluster fault self-healing method and device | |
CN111259073A (en) | Intelligent business system running state studying and judging system based on logs, flow and business access | |
CN111522728A (en) | Method for generating automatic test case, electronic device and readable storage medium | |
CN115562978A (en) | Performance test system and method based on service scene | |
CN107704369A (en) | A kind of recording method of Operation Log, electronic equipment, storage medium, system | |
US7617313B1 (en) | Metric transport and database load | |
CN110427298A (en) | A kind of Automatic Feature Extraction method of distributed information log | |
CN113127356A (en) | Pressure measurement method and device, electronic equipment and storage medium | |
CN112491965A (en) | Monitoring data transmission method based on Kafka and Netty framework | |
CN111970151A (en) | Flow fault positioning method and system for virtual and container network | |
CN114968727B (en) | Database through infrastructure fault positioning method based on artificial intelligence operation and maintenance | |
CN108345541A (en) | A kind of program detecting method and system | |
CN113032341A (en) | Log processing method based on visual configuration | |
CN113568804A (en) | Web application-oriented performance bottleneck accurate positioning system |
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 |
Application publication date: 20181228 |
|
RJ01 | Rejection of invention patent application after publication |