A database script execution prediction method and apparatus
Patent Information
- Application Number
- CN202310656180.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-05
- Publication Date
- 2026-09-25
- Estimated Expiration
- 2043-06-05
AI Technical Summary
[0002]目前,金融系统经常需要针对数据的异常进行修复,需要执行对应的SQL数据库脚本,但金融行业数据库数据量很大,且时时刻刻都有大流量的请求访问,而且场景错综复杂,如果SQL执行的时间点评估不充分,及有可能对数据库性能造成影响,从而影响到外部请求流量,造成生产事故
Smart Images

Figure CN117009197B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and more specifically, to a database script execution prediction method and apparatus. Background Technology
[0002] Currently, financial systems frequently require the repair of data anomalies, necessitating the execution of corresponding SQL database scripts. However, financial industry databases handle massive amounts of data and experience constant high-volume requests, with complex scenarios. Insufficient assessment of the timing of SQL execution can impact database performance, affecting external request traffic and potentially causing production incidents. Examples include table deadlocks and update conflicts. Clearly, existing methods cannot predict the timing of SQL script execution, thus failing to anticipate its impact on the system and prevent timely prevention of production incidents. Summary of the Invention
[0003] The purpose of this application is to provide a database script execution prediction method and apparatus, which can predict the timing of SQL script execution, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0004] The first aspect of this application provides a database script execution prediction method, including:
[0005] Retrieve the target SQL script to be executed;
[0006] When the target SQL script passes the review, the target SQL script is subjected to data volume detection based on the execution time point to obtain the data volume detection result.
[0007] Calculate the database pressure ratio based on the data volume detection results;
[0008] Based on the database pressure ratio, the target SQL script is pre-executed to predict its impact during execution, thus obtaining an impact profile.
[0009] Based on the impact profile, estimate the executable time of the target SQL script;
[0010] Output the impact profile and the executable time point.
[0011] In the above implementation process, this method can first obtain the target SQL script to be executed; when the target SQL script passes the review, it performs data volume detection on the target SQL script based on the execution time point to obtain the data volume detection result; then, it calculates the database pressure ratio based on the data volume detection result; and performs pre-execution prediction on the target SQL script based on the database pressure ratio to obtain the impact profile at the time of execution; then, it estimates the executable time point of the target SQL script based on the impact profile; finally, it outputs the impact profile and the executable time point. It can be seen that this method can predict the executable time point of the SQL script, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0012] Further, the step of performing data volume detection on the target SQL script based on the execution time point to obtain data volume detection results includes:
[0013] The target SQL script is parsed to obtain script information;
[0014] Based on the script information, obtain the DB information, table information, and script execution time point;
[0015] Extract keywords based on the DB information and the table information;
[0016] Based on the script execution time point and the keyword, the request data volume is detected based on the execution time point to obtain the data volume detection result.
[0017] Further, the step of calculating the database pressure ratio based on the data volume detection results includes:
[0018] Based on the data volume detection results, determine the batch processing job to run at the script execution time point;
[0019] Monitor database performance based on the batch processing jobs described above;
[0020] Calculate the database stress ratio based on the database performance.
[0021] Furthermore, the step of performing pre-execution prediction on the target SQL script based on the database pressure ratio to obtain an impact profile during execution includes:
[0022] Based on the database pressure ratio, predict the execution time of the target SQL script and the range of performance fluctuations it will affect;
[0023] An impact profile is generated based on the execution time and the range of performance fluctuations.
[0024] Furthermore, the method also includes:
[0025] Based on the impact profile, determine whether the target SQL script is suitable for execution at the script execution time point;
[0026] If not, then the execution time point of the target SQL script is estimated based on the impact profile.
[0027] A second aspect of this application provides a database script execution prediction apparatus, the database script execution prediction apparatus comprising:
[0028] The retrieval unit is used to retrieve the target SQL script to be executed.
[0029] The detection unit is used to perform data volume detection on the target SQL script based on the execution time point when the target SQL script passes the review, and obtain the data volume detection result.
[0030] The calculation unit is used to calculate the database pressure ratio based on the data volume detection results;
[0031] The prediction unit is used to perform pre-execution prediction on the target SQL script based on the database pressure ratio to obtain an impact profile during execution;
[0032] The estimation unit is used to estimate the executable time point of the target SQL script based on the impact profile.
[0033] The output unit is used to output the impact profile and the executable time point.
[0034] In the above implementation process, the device can acquire the target SQL script to be executed through the acquisition unit; when the target SQL script passes the review, the detection unit performs data volume detection on the target SQL script based on the execution time point to obtain the data volume detection result; the calculation unit calculates the database pressure ratio based on the data volume detection result; the prediction unit performs pre-execution prediction on the target SQL script based on the database pressure ratio to obtain the impact profile at the time of execution; the estimation unit estimates the executable time point of the target SQL script based on the impact profile; and the output unit outputs the impact profile and the executable time point. It can be seen that this method can estimate the executable time point of the SQL script, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0035] Furthermore, the detection unit includes:
[0036] The parsing subunit is used to parse the target SQL script to obtain script information;
[0037] The acquisition subunit is used to acquire DB information, table information, and script execution time points based on the script information.
[0038] An extraction subunit is used to extract keywords based on the DB information and the table information;
[0039] The detection subunit is used to perform request data volume detection based on the script execution time point and the keyword, and obtain the data volume detection result.
[0040] Furthermore, the computing unit includes:
[0041] A subunit is defined to determine the batch processing job to be executed at the script execution time point based on the data volume detection result.
[0042] The monitoring subunit is used to monitor database performance based on the batch processing job.
[0043] The calculation subunit is used to calculate the database pressure ratio based on the database performance.
[0044] Furthermore, the prediction unit includes:
[0045] The prediction subunit is used to predict the execution time of the target SQL script and the range of performance fluctuations based on the database pressure ratio.
[0046] A generation subunit is used to generate an impact profile based on the execution time and the range of performance fluctuations.
[0047] Furthermore, the database script execution prediction device also includes:
[0048] The judgment unit is used to determine, based on the impact profile, whether the target SQL script is suitable for execution at the script execution time point;
[0049] The estimation unit is specifically used to estimate the executable time of the target SQL script based on the impact profile when the target SQL script is not suitable for execution at the script execution time.
[0050] A third aspect of this application provides an electronic device, including a memory and a processor. The memory stores a computer program, and the processor runs the computer program to cause the electronic device to perform the database script execution prediction method described in any one of the first aspects of this application.
[0051] A fourth aspect of this application provides a computer-readable storage medium storing computer program instructions, which, when read and executed by a processor, perform the database script execution prediction method described in any one of the first aspects of this application. Attached Figure Description
[0052] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0053] Figure 1 A schematic flowchart illustrating a database script execution prediction method provided in an embodiment of this application;
[0054] Figure 2 A flowchart illustrating another database script execution prediction method provided in this application embodiment;
[0055] Figure 3 A schematic diagram of the structure of a database script execution prediction device provided in this application embodiment;
[0056] Figure 4 This is a schematic diagram of another database script execution prediction device provided in an embodiment of this application. Detailed Implementation
[0057] The technical solutions in the embodiments of this application will now be described with reference to the accompanying drawings.
[0058] It should be noted that similar reference numerals and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. Furthermore, in the description of this application, terms such as "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0059] Example 1
[0060] Please refer to Figure 1 , Figure 1 This embodiment provides a flowchart illustrating a database script execution prediction method. The database script execution prediction method includes:
[0061] S101. Obtain the target SQL script to be executed.
[0062] S102. When the target SQL script passes the review, perform a data volume check on the target SQL script based on the execution time point to obtain the data volume check result.
[0063] S103. Calculate the database pressure ratio based on the data volume detection results.
[0064] S104. Based on the database pressure comparison, perform pre-execution prediction on the target SQL script to obtain an impact profile during execution.
[0065] S105. Estimate the executable time of the target SQL script based on the impact profile.
[0066] S106, Output impact profile and executable time point.
[0067] In this embodiment, the method can be implemented by probing and checking middleware such as JARs before a DB script is executed.
[0068] In the financial sector, it is frequently necessary to perform data checks on the systems in order to repair any abnormal data. Currently, a common repair method is to execute the corresponding SQL database scripts to perform the necessary repairs.
[0069] However, in practice, it has been found that the databases used by financial systems often contain a large amount of data and receive high-volume requests constantly. Furthermore, the application scenarios for this data are complex and varied. Therefore, determining the optimal timing for executing the corresponding SQL statement becomes crucial. Insufficient evaluation of the SQL execution timing can unnecessarily impact database performance, affecting external request traffic and potentially causing production incidents (such as table deadlocks or update conflicts).
[0070] Based on the aforementioned technical issues, this paper proposes a method for predicting the execution of database SQL scripts. This method can estimate the timing when SQL scripts can be executed, thereby accurately determining the corresponding executable time node. This allows developers to better assess the impact of the repair process on the system, and effectively avoid production accidents.
[0071] In this embodiment, the subject executing the method can be a computing device such as a computer or server, and no limitation is made in this embodiment.
[0072] In this embodiment, the subject executing the method can also be a smart device such as a smartphone or tablet, and no limitation is made in this embodiment.
[0073] As can be seen, the database script execution prediction method described in this embodiment can predict the timing of SQL script execution, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0074] Example 2
[0075] Please refer to Figure 2 , Figure 2 This embodiment provides a flowchart illustrating a database script execution prediction method. The database script execution prediction method includes:
[0076] S201. Obtain the target SQL script to be executed.
[0077] S202. When the target SQL script passes the review, the target SQL script is parsed to obtain script information.
[0078] In this embodiment, the method requires the DBA to review the target SQL script to determine whether it can be used.
[0079] In this embodiment, Database Administrator (DBA) is a general term for staff who manage and maintain Database Management System (DBMS). It is a branch of operations engineers and is mainly responsible for the full lifecycle management of business databases from design and testing to deployment and delivery.
[0080] In this embodiment, after the DBA reviews the SQL script to be executed, the method can parse and calculate the required DB information, table information, and execution time points based on the script information, thereby facilitating the subsequent steps.
[0081] S203. Obtain DB information, table information, and script execution time based on script information.
[0082] S204. Extract keywords based on DB and table information.
[0083] In this embodiment, the method can identify keywords such as insert and update, and based on the keywords and tables, it can detect the access requests to the DB database at that time point, collect whether there are a large number of requests at that time point, distinguish between updates and queries, and extract the corresponding table name during updates and compare it with the existing script SQL table name to assess the impact if the same table is involved.
[0084] In this embodiment, the method can intelligently calculate the amount of requested data based on the above steps, determine the average size of DB access, and then combine system scanning to determine whether there is a corresponding batch processing job.
[0085] For example, when the number of database accesses per second exceeds one thousand, and all involve insert or update operations, this method can automatically determine that the system is in the process of running batch jobs, thus identifying this time as unsuitable for executing SQL scripts (due to the high probability of conflicts). However, if the majority of accesses are query operations, this method can determine that their impact is relatively small.
[0086] S205. Based on the script execution time point and keywords, perform request data volume detection based on the execution time point to obtain the data volume detection result.
[0087] S206. Determine the batch processing job to run at the script execution time point based on the data volume detection results.
[0088] In this embodiment, the method can intelligently judge and calculate the impact of DB based on a point in time.
[0089] S207. Monitor database performance based on batch processing jobs.
[0090] S208. Calculate the database pressure ratio based on database performance.
[0091] S209. Based on the database pressure ratio, predict the execution time of the target SQL script and the range of performance fluctuations it will affect.
[0092] In this embodiment, the method can use performance monitoring commands (such as the SHOW command) to view the number of connections (max_connections), the number of users (max_used_connections), and the number of running threads (PROCESSLIST). This allows for monitoring the performance consumption ratio of the database. Therefore, this method can monitor database performance and intelligently determine its impact ratio in real time.
[0093] In this embodiment, the method can also track the bin_log status of the database.
[0094] For example, this method can intelligently calculate the pressure ratio of write operations at the current point in time based on the database disk space. When the pressure ratio is much lower than a preset ratio, it is considered that the write pressure is not very high, and therefore it can automatically determine that this point in time is suitable for executing the script. Specifically, this method can automatically estimate the execution time based on the pressure ratio and the number of database entries.
[0095] S210. Generate an impact profile based on the execution time and the range of performance fluctuations.
[0096] S211. Based on the impact profile, determine whether the target SQL script is suitable for execution at the script execution time. If so, end this process; otherwise, proceed to steps S212 to S213.
[0097] S212. Estimate the executable time of the target SQL script based on the impact profile.
[0098] In this embodiment, the method can probe the database to be accessed based on SQL scripts. Simultaneously, it performs a comprehensive evaluation by combining existing table data statistics and database virtual machine resources.
[0099] For example, this method can assess how long SQL execution takes, the range of performance fluctuations, the number of affected rows, whether there will be rollbacks or anomalies in the middle, and whether the timing of the execution is appropriate.
[0100] S213, Output impact profile and executable time point.
[0101] In this embodiment, the method can combine the impact assessed by the above steps to generate corresponding profiles or pop-up prompts to the relevant personnel.
[0102] For example, an update script might be executed at 6 AM on a certain day, but a request might arrive at that exact moment, causing a table locking conflict. By the time the entire database is restored, production has been affected for nearly half an hour. However, this method can proactively assess the actual production traffic to determine if the script's execution point is unsuitable at that time, how long it should be postponed, and what the expected consequences would be if it were executed.
[0103] Therefore, by implementing this method, DBAs and developers can gain a general understanding and make it easier for them to predict whether the script is suitable for execution.
[0104] By implementing this method, the timing of SQL script execution can be estimated, thereby accurately determining the corresponding execution time point. This allows developers to better assess the impact on the system, avoid production accidents, and improve system reliability.
[0105] In this embodiment, the subject executing the method can be a computing device such as a computer or server, and no limitation is made in this embodiment.
[0106] In this embodiment, the subject executing the method can also be a smart device such as a smartphone or tablet, and no limitation is made in this embodiment.
[0107] As can be seen, the database script execution prediction method described in this embodiment can predict the timing of SQL script execution, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0108] Example 3
[0109] Please refer to Figure 3 , Figure 3 This is a schematic diagram of the structure of a database script execution prediction device provided in this embodiment. Figure 3 As shown, the database script execution prediction device includes:
[0110] Acquisition unit 310 is used to acquire the target SQL script to be executed;
[0111] The detection unit 320 is used to perform data volume detection on the target SQL script based on the execution time point when the target SQL script passes the review, and obtain the data volume detection result;
[0112] Calculation unit 330 is used to calculate the database pressure ratio based on the data volume detection results;
[0113] Prediction unit 340 is used to perform pre-execution prediction on the target SQL script based on the database pressure ratio to obtain an impact profile during execution.
[0114] Prediction unit 350 is used to predict the executable time point of the target SQL script based on the impact profile;
[0115] Output unit 360 is used to output impact profiles and executable time points.
[0116] In this embodiment, the explanation of the database script execution prediction device can be referred to the description in Embodiment 1 or Embodiment 2, and will not be repeated here.
[0117] As can be seen, by implementing the database script execution prediction device described in this embodiment, the timing of SQL script execution can be estimated, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0118] Example 4
[0119] Please refer to Figure 4 , Figure 4 This is a schematic diagram of the structure of a database script execution prediction device provided in this embodiment. Figure 4 As shown, the database script execution prediction device includes:
[0120] Acquisition unit 310 is used to acquire the target SQL script to be executed;
[0121] The detection unit 320 is used to perform data volume detection on the target SQL script based on the execution time point when the target SQL script passes the review, and obtain the data volume detection result;
[0122] Calculation unit 330 is used to calculate the database pressure ratio based on the data volume detection results;
[0123] Prediction unit 340 is used to perform pre-execution prediction on the target SQL script based on the database pressure ratio to obtain an impact profile during execution.
[0124] Prediction unit 350 is used to predict the executable time point of the target SQL script based on the impact profile;
[0125] Output unit 360 is used to output impact profiles and executable time points.
[0126] As an optional implementation, the detection unit 320 includes:
[0127] Parsing subunit 321 is used to parse the target SQL script and obtain script information;
[0128] Get subunit 322, which is used to obtain DB information, table information and script execution time point based on script information;
[0129] Extraction subunit 323 is used to extract keywords based on DB information and table information;
[0130] The detection subunit 324 is used to detect the amount of request data based on the execution time point and keywords, and obtain the data volume detection result.
[0131] As an optional implementation, the computing unit 330 includes:
[0132] Determine subunit 331, which is used to determine the batch processing job to run at the script execution time point based on the data volume detection result;
[0133] Monitoring subunit 332 is used to monitor database performance based on batch processing jobs.
[0134] The calculation subunit 333 is used to calculate the database pressure ratio based on database performance.
[0135] As an optional implementation, the prediction unit 340 includes:
[0136] Prediction subunit 341 is used to predict the execution time of the target SQL script and the range of performance fluctuations based on the database pressure ratio.
[0137] Generating subunit 342 is used to generate an impact profile based on the execution time and the range of performance fluctuations.
[0138] As an optional implementation, the database script execution prediction apparatus further includes:
[0139] Judgment unit 370 is used to determine whether the target SQL script is suitable for execution at the script execution time point based on the impact profile;
[0140] Prediction unit 350 is specifically used to predict the executable time of the target SQL script based on the impact profile when the target SQL script is not suitable for execution at the script execution time.
[0141] In this embodiment, the explanation of the database script execution prediction device can be referred to the description in Embodiment 1 or Embodiment 2, and will not be repeated here.
[0142] As can be seen, by implementing the database script execution prediction device described in this embodiment, the timing of SQL script execution can be estimated, thereby predicting the impact of script execution on the system, thus avoiding production accidents in a timely manner and improving system reliability.
[0143] This application provides an electronic device, including a memory and a processor. The memory stores a computer program, and the processor runs the computer program to enable the electronic device to execute the database script execution prediction method in embodiment 1 or embodiment 2 of this application.
[0144] This application provides a computer-readable storage medium storing computer program instructions. When these computer program instructions are read and executed by a processor, they perform the database script execution prediction method described in embodiment 1 or embodiment 2 of this application.
[0145] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram and / or flowchart, and combinations of blocks in block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0146] In addition, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0147] If the aforementioned functions are implemented as software functional modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0148] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application. It should be noted that similar reference numerals and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0149] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0150] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
Claims
1. A database script execution prediction method, characterized in that, include: Retrieve the target SQL script to be executed; When the target SQL script passes the review, a data volume detection is performed on the target SQL script based on the execution time point to obtain the data volume detection result; Calculate the database pressure ratio based on the data volume detection results; Based on the database pressure ratio, the target SQL script is pre-executed to predict its impact during execution, thus obtaining an impact profile. Based on the impact profile, estimate the executable time of the target SQL script; Output the impact profile and the executable time point; The step of calculating the database pressure ratio based on the data volume detection results includes: Based on the data volume detection results, determine the batch processing job to run at the script execution time point; Monitor database performance based on the batch processing jobs described above; Calculate the database stress ratio based on the database performance; The step of performing pre-execution prediction on the target SQL script based on the database pressure ratio to obtain an impact profile during execution includes: Based on the database pressure ratio, predict the execution time of the target SQL script and the range of performance fluctuations it will affect; An impact profile is generated based on the execution time and the range of performance fluctuations.
2. The database script execution prediction method according to claim 1, characterized in that, The step of performing data volume detection on the target SQL script based on the execution time point to obtain data volume detection results includes: The target SQL script is parsed to obtain script information; Based on the script information, obtain the DB information, table information, and script execution time point; Extract keywords based on the DB information and the table information; Based on the script execution time point and the keyword, the request data volume is detected based on the execution time point to obtain the data volume detection result.
3. The database script execution prediction method according to claim 2, characterized in that, The method further includes: Based on the impact profile, determine whether the target SQL script is suitable for execution at the script execution time point; If not, then the execution time point of the target SQL script is estimated based on the impact profile.
4. A database script execution prediction device, characterized in that, The database script execution prediction device includes: The retrieval unit is used to retrieve the target SQL script to be executed. The detection unit is used to perform data volume detection on the target SQL script based on the execution time point when the target SQL script passes the review, and obtain the data volume detection result. The calculation unit is used to calculate the database pressure ratio based on the data volume detection results; The prediction unit is used to perform pre-execution prediction on the target SQL script based on the database pressure ratio to obtain an impact profile during execution; The estimation unit is used to estimate the executable time point of the target SQL script based on the impact profile. The output unit is used to output the impact profile and the executable time point; The computing unit includes: A subunit is defined to determine the batch processing job to be executed at the script execution time point based on the data volume detection result. The monitoring subunit is used to monitor database performance based on the batch processing job. A calculation subunit is used to calculate the database pressure ratio based on the database performance. The prediction unit includes: The prediction subunit is used to predict the execution time of the target SQL script and the range of performance fluctuations based on the database pressure ratio. A generation subunit is used to generate an impact profile based on the execution time and the range of performance fluctuations.
5. The database script execution prediction device according to claim 4, characterized in that, The detection unit includes: The parsing subunit is used to parse the target SQL script to obtain script information; The acquisition subunit is used to acquire DB information, table information, and script execution time points based on the script information. An extraction subunit is used to extract keywords based on the DB information and the table information; The detection subunit is used to perform request data volume detection based on the script execution time point and the keyword, and obtain the data volume detection result.
6. An electronic device, characterized in that, The electronic device includes a memory and a processor, the memory storing a computer program, and the processor running the computer program to cause the electronic device to execute the database script prediction method according to any one of claims 1 to 3.
7. A readable storage medium, characterized in that, The readable storage medium stores computer program instructions, which, when read and executed by a processor, perform the database script execution prediction method according to any one of claims 1 to 3.
Citation Information
Patent Citations
Database script execution processing method and device
CN115080542A
Resource assignment method to database server
JP2009037369A