Script file monitoring method and apparatus

By monitoring and saving script function attribute information during stack pop operations in Lua scripts, the problems of wasted computing resources and missed reads in Lua script monitoring programs are solved, achieving efficient monitoring results.

CN114579414BActive Publication Date: 2026-02-17ZHUHAI KINGSOFT ONLINE GAME TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210197675.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-01
Publication Date
2026-02-17
Estimated Expiration
2042-03-01

AI Technical Summary

Technical Problem

In existing technologies, Lua script performance monitoring programs have high computational resource consumption, slow running speed, and problems such as missed reads and strong intrusion.

Method used

By monitoring the attribute information of the target script function during the pop operation of Lua script, and saving it to the monitoring data file, the waste of computing resources and missed readings are reduced. The stack pop detection method is used to monitor Lua script functions.

Benefits of technology

It reduces the waste of computing resources and missed readings in the Lua language script monitoring process, and improves monitoring efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114579414B_ABST
    Figure CN114579414B_ABST
Patent Text Reader

Abstract

The application provides a script file monitoring method and device, wherein the script file monitoring method comprises the following steps: receiving a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file comprises at least one script function; in the case that it is monitored that there is a stack-out operation on a stack corresponding to the to-be-monitored script file, determining a target script function of the stack-out operation; acquiring target script function attribute information of the target script function; and saving the target script function attribute information to a monitoring data file. This script file monitoring method can reduce the missed reading of the called script function in the monitoring process of the to-be-monitored script file, reduce the waste of computing resources in the monitoring process, and improve the monitoring efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computers, in particular to a script file monitoring method. The present application also relates to a script file monitoring device, a computing device, and a computer readable storage medium. BACKGROUND

[0002] With the development of Internet technology, various application programs are becoming more and more common, and the update iteration speed of application program functions is accelerating, which leads to people's increasing emphasis on providing flexible expansion and customized functions for application programs. Lua language is developed in this case and quickly shows its simple and fast characteristics, and is widely used. In the prior art, the lua language has a debug package, which can realize the viewing of running information in the running process of the lua language script. Therefore, developers make a performance monitoring program of the lua language script based on the debug package. However, the computing resource overhead required for executing the performance monitoring program is too large, and the running speed is too slow. In order to monitor the lua language script without exceeding the computing resources provided by the computing device, the prior art extracts part of the function for reading when the function is pushed or popped in the running process of the script, but this will cause the situation of missing reading. More cannot be ignored is that this performance monitoring program will have too strong invasiveness to lua code, which is inconvenient for actual use. SUMMARY

[0003] Therefore, the embodiments of the present application provide a script file monitoring method to solve the technical defects in the prior art. The embodiments of the present application also provide a script file monitoring device, a computing device, and a computer readable storage medium.

[0004] According to a first aspect of the embodiments of the present application, a script file monitoring method is provided, which includes:

[0005] receiving a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file includes at least one script function;

[0006] in a case where it is monitored that the stack corresponding to the to-be-monitored script file has a pop operation, determining a target script function of the pop operation;

[0007] obtaining target script function attribute information of the target script function;

[0008] saving the target script function attribute information to a monitoring data file.

[0009] Optionally, before the determination of the target script function of the pop operation, the method further includes:

[0010] According to the to-be-monitored script file information carried in the monitoring instruction, a to-be-monitored script file corresponding to the monitoring instruction is determined;

[0011] File attribute information of the to-be-monitored script file is determined;

[0012] A monitoring script function is constructed based on the file attribute information;

[0013] The to-be-monitored script file is monitored through the monitoring script function.

[0014] Optionally, the constructing of the monitoring script function based on the file attribute information comprises:

[0015] The file attribute information is parsed to obtain running environment information;

[0016] A monitoring programming language is determined according to the running environment information;

[0017] The monitoring script function is constructed based on the monitoring programming language.

[0018] Optionally, the obtaining of the target script function attribute information of the target script function comprises:

[0019] Function identification information, function address information, and function duration information of the target script function are obtained;

[0020] A target script function hash value is constructed based on the function identification information and the function address information;

[0021] The target script function attribute information is generated according to the function identification information, the function address information, the function duration information, and the target script function hash value.

[0022] Optionally, the obtaining of the function duration information of the target script function comprises:

[0023] Out-of-stack time and in-of-stack time corresponding to the target script function are determined;

[0024] A difference between the out-of-stack time and the in-of-stack time is calculated;

[0025] The function duration information is determined based on the calculation result.

[0026] Optionally, the saving of the target script function attribute information to a monitoring data file comprises:

[0027] In a case where the function duration information is greater than or equal to a preset duration threshold, the target script function attribute information is saved to a monitoring data file;

[0028] In a case where the function duration information is less than a preset duration threshold, the step of determining the target script function of the out-stack operation is performed in a case where the stack corresponding to the to-be-monitored script file is monitored to have the out-stack operation.

[0029] Optionally, the saving of the target script attribute information to the monitoring data file comprises:

[0030] converting the target script function attribute information into a to-be-stored string, wherein the to-be-stored string comprises numerical characters;

[0031] compressing the numerical characters in the to-be-stored string to obtain a target string corresponding to the to-be-stored string;

[0032] saving the target string to the monitoring data file.

[0033] Optionally, the compression of the numerical characters in the to-be-stored string to obtain a target string corresponding to the to-be-stored string comprises:

[0034] determining a target numerical character in the to-be-stored string;

[0035] determining target data based on the target numerical character and a preset numerical compression parameter;

[0036] generating an identification code corresponding to each target data, and generating and storing a storage identification code corresponding to the to-be-stored data according to the identification code corresponding to each target data;

[0037] converting the numerical characters in the to-be-stored string into corresponding storage identification codes to obtain a target string corresponding to the to-be-stored string.

[0038] Optionally, the determination of target data based on the target numerical character and a preset numerical compression parameter comprises:

[0039] dividing a value corresponding to the target numerical character by the numerical compression parameter;

[0040] determining whether an i-th quotient value is less than the numerical compression parameter, wherein i is a positive integer;

[0041] if yes, constructing target data based on each remainder value obtained and the i-th quotient value;

[0042] if no, dividing the i-th quotient value by the numerical compression parameter, and increasing i by 1, and performing the step of determining whether the obtained quotient value is less than the numerical compression parameter.

[0043] Optionally, the saving of the target script function attribute information to the monitoring data file comprises:

[0044] determining whether the target script function hash value exists in the monitoring data file;

[0045] If yes, deleting the function address information in the target script function attribute information, and saving the deleted target script function attribute information to the monitoring data file;

[0046] If no, saving the target script function attribute information to the monitoring data file.

[0047] Optionally, the saving the target script function attribute information to the monitoring data file further comprises:

[0048] receiving a display instruction for the monitoring data file;

[0049] in response to the display instruction, performing visual processing on the monitoring data file, generating and displaying a visual result.

[0050] According to a second aspect of the embodiments of the present application, a script file monitoring device is provided, comprising:

[0051] a receiving module configured to receive a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file comprises at least one script function;

[0052] a monitoring module configured to, in a case where it is monitored that there is a stack out operation corresponding to the to-be-monitored script file, determine a target script function of the stack out operation;

[0053] an obtaining module configured to obtain target script function attribute information of the target script function;

[0054] a saving module configured to save the target script function attribute information to a monitoring data file.

[0055] According to a third aspect of the embodiments of the present application, a computing device is provided, comprising:

[0056] a memory and a processor;

[0057] the memory is configured to store computer executable instructions, and the processor is configured to execute the computer executable instructions to implement the steps of the script file monitoring method.

[0058] According to a fourth aspect of the embodiments of the present application, a computer readable storage medium is provided, which stores computer executable instructions, and the instructions are executed by a processor to implement the steps of the script file monitoring method.

[0059] According to a fifth aspect of the embodiments of the present application, a chip is provided, which stores a computer program, and the computer program is executed by the chip to implement the steps of the script file monitoring method.

[0060] The script file monitoring method provided in the application, by responding to the monitoring instruction for the to-be-monitored script file, in the case where the stack corresponding to the to-be-monitored script file is monitored to appear the out-stack operation, the target script function corresponding to the out-stack operation is determined; the target script function attribute information of the target script function is acquired and saved to the monitoring data file, the missing reading of the called script function in the monitoring process of the to-be-monitored script file is reduced, the waste of computing resources in the monitoring process is reduced, and the monitoring efficiency is improved. BRIEF DESCRIPTION OF DRAWINGS

[0061] Figure 1 is a flowchart of a script file monitoring method provided by an embodiment of the application;

[0062] Figure 2 is a processing flowchart of a script file monitoring method applied to C language provided by an embodiment of the application;

[0063] Figure 3 is a structural schematic diagram of a script file monitoring device provided by an embodiment of the application;

[0064] Figure 4 is a structural block diagram of a computing device provided by an embodiment of the application. DETAILED DESCRIPTION

[0065] In the following description, numerous specific details are set forth in order to provide a thorough understanding of the application. However, the application can be practiced without the specific details. In other instances, well-known methods, procedures, components, and circuits have not been described in detail since such can be readily understood.

[0066] The terminology used in this disclosure of the embodiments of the application is for the purpose of describing particular embodiments only and is not intended to be limiting of the embodiments of the application. As used in this disclosure and the appended claims, the singular forms "a," "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will also be understood that the term "and / or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.

[0067] It will be understood that, although the terms first, second, etc. can be used herein to describe various information, these terms are not intended to denote a temporal or chronological order. Rather, these terms are used solely to distinguish one from another only. For example, without departing from the scope of the embodiments of the application, first can be termed second, and similarly, second can be termed first.

[0068] First, the terms of the invention one or more embodiments are explained.

[0069] Lua language: a flexible scripting language written in standard C, which can be compiled on almost all operating systems and platforms; it can be easily called by C / C++ code, and vice versa, which makes Lua widely used in application programs.

[0070] Bytes: a byte stores 8-bit unsigned numbers, used to store binary digit sequences in the range of 0-255, which are used as a digital unit in a computer, usually 8-bit binary numbers.

[0071] Flame chart: each column represents a call stack, and each cell represents a function. The vertical axis shows the depth of the stack, arranged from bottom to top according to the call relationship, and the top cell represents the function that is occupying the CPU at the time of sampling; the horizontal axis means that the flame chart aggregates the collected multiple call stack information by alphabetically sorting horizontally, and it should be noted that it does not represent time; the width of the horizontal axis cell represents its frequency in sampling, so the wider the cell, the more likely it is a bottleneck.

[0072] In this application, a script file monitoring method is provided. This application also relates to a script file monitoring device, a computing device, and a computer readable storage medium, which are described in detail in the following embodiments.

[0073] In practical applications, for monitoring the script file to be monitored, the method used is stack detection, that is, when the script function in the script to be monitored is called, the script function is put into the corresponding stack; at the moment when the script function is put into the corresponding stack, the calling of the script function is monitored, but since the calling process of the script function has not ended, if the calling of the script function needs to be recorded, the script function in the stack needs to be monitored in real time to ensure that the whole calling process of the script function is recorded. However, this method of real-time monitoring of the whole process of script function calling will consume a large amount of computing resources. In order to make the consumed computing resources within the range that the computing device can bear, a technical means similar to "random inspection" is adopted, but this method will cause the monitoring process to miss reading.

[0074] In this application, the method of stack detection is adopted, that is, at the moment when the script function in the script to be monitored is out of the stack, the script function is monitored. Since the script function has completed the whole calling process at this time, only the historical information of the script function calling needs to be collected at this time, and the real-time monitoring method is not needed, which saves computing resources and does not cause the missing reading.

[0075] Figure 1 A flow chart of a script file monitoring method according to an embodiment of the present application is shown, and specifically includes the following steps:

[0076] Step 102: receiving a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file includes at least one script function.

[0077] The to-be-monitored script file can be understood as a program with performance monitoring requirements, and the programming language is provided by a browser, a multimedia authoring tool, and the like. In addition, the to-be-monitored script file can also be provided by a macro of an application program and a batch processing language of an authoring system. The monitoring instruction can be understood as an instruction sent by a user based on the monitoring requirements of the to-be-monitored script file, and is used to instruct to perform a monitoring operation on the to-be-monitored script file. The script function can be understood as a function included in the to-be-monitored script file.

[0078] Based on this, the monitoring instruction is received, and a monitoring operation is performed on the to-be-monitored script file based on the indication of the received monitoring instruction.

[0079] Step 104: in a case where it is monitored that the stack corresponding to the to-be-monitored script file has a pop operation, determining a target script function of the pop operation.

[0080] Specifically, after receiving the monitoring instruction, a monitoring operation is performed on the to-be-monitored script file based on the indication of the monitoring instruction. It should be noted that the monitoring process can be understood as monitoring the calling process of the script function in the to-be-monitored script file. It should be noted that the present application adopts a pop detection (also referred to as a stack monitoring) method.

[0081] The target script function can be understood as a script function corresponding to the pop operation in a case where the stack corresponding to the to-be-monitored script file has a pop operation, that is, the script function that is completed in the calling process of the to-be-monitored script file.

[0082] Based on this, the execution process of the to-be-monitored script file is monitored. The to-be-monitored script file continuously calls the script function included therein in the execution process. In a case where a pop operation occurs in the corresponding stack, that is, at the moment when the calling of the script function ends, the script function that is completed at this moment is determined as the target script function.

[0083] Further, when monitoring the execution process of the to-be-monitored script file, a script file for monitoring needs to monitor the entire execution process. The construction process of the script file for monitoring depends on the to-be-monitored script file itself. Different to-be-monitored script files need to be monitored by different script files. In the present embodiment, the specific implementation manner is as follows:

[0084] According to the script file information carried in the monitoring instruction, a script file to be monitored corresponding to the monitoring instruction is determined; file attribute information of the script file to be monitored is determined; based on the file attribute information, a monitoring script function is constructed; and the script file to be monitored is monitored through the monitoring script function.

[0085] The script file information to be monitored can be understood as indicating a script file to be monitored; the file attribute information can be understood as recording attribute information such as a running environment and a programming language of the script file to be monitored; and the monitoring script function can be understood as a function for monitoring an execution process of the script file to be monitored.

[0086] Based on this, the monitoring instruction is parsed to obtain script file information to be monitored carried in the monitoring instruction; then the script file to be monitored is determined according to the script file information to be monitored; after the script file to be monitored is determined, file attribute information of the script file to be monitored is determined; a monitoring script function most suitable for monitoring an execution process of the script file to be monitored is constructed through the attribute description of the script file to be monitored by the file attribute information; and finally the script file to be monitored is monitored through the constructed monitoring script function.

[0087] For example, a monitoring instruction B1 is received, through parsing of the monitoring instruction B1, script file information C1 is obtained, then it is determined that a script file A1 written based on a Lua language is a script file to be monitored according to the script file information C1 to be monitored; file attribute information C2 of the script file to be monitored is determined, and a monitoring script function D1 most suitable for monitoring the script file A1 to be monitored is constructed based on the file attribute information C2; and finally an execution process of the script file A1 to be monitored is monitored according to the monitoring script function D1.

[0088] In summary, through determination of attribute information of the script file to be monitored, a monitoring script function most suitable for monitoring an execution process of the script file to be monitored is constructed, and monitoring performance and monitoring efficiency are improved.

[0089] Further, to monitor an execution process of the script file to be monitored, a programming language of the script file to be monitored and a running environment of the script file to be monitored need to be determined, which is crucial for construction of the monitoring script function, and in this embodiment, the specific implementation is as follows:

[0090] The file attribute information is parsed to obtain running environment information; a monitoring programming language is determined according to the running environment information; and the monitoring script function is constructed based on the monitoring programming language.

[0091] The running environment information can be understood as information about the running environment of the to-be-monitored script file and information about the programming language used by the to-be-monitored script file; and the monitoring programming language can be understood as the programming language used by the monitoring script function.

[0092] Based on this, according to the running environment information contained in the file attribute information, the running environment of the to-be-monitored script file and the programming language used by the to-be-monitored script file can be determined, and then the programming language used by the monitoring script function is determined, and the monitoring script function is constructed using the determined programming language.

[0093] In the above example, according to the file attribute information C2 of the to-be-monitored script file A1, it is determined that the running environment of the to-be-monitored script file is based on a virtual machine, and the programming language used is Lua language. Since the monitoring script function written in Lua language has low running efficiency and high invasiveness, a C language is used to construct the monitoring script function D1.

[0094] In summary, through the running environment of the to-be-monitored script file and the programming language used, the programming language with the best effect in the corresponding scene can be determined, and the monitoring script function is constructed in this way to increase the efficiency of the monitoring process and achieve the best effect.

[0095] Step 106: Obtain target script function attribute information of the target script function.

[0096] Specifically, after the target script function is determined, the attribute information of the target script function needs to be determined to record the execution of the target script function. Since the target script function is a script function called in the execution process of the to-be-monitored script file, after recording and processing the execution information of all script functions in the execution process of the to-be-monitored script file, the monitoring of the entire execution process of the to-be-monitored script file can be realized.

[0097] The target script function attribute information can be understood as some execution parameters of the target script function when the to-be-monitored script file calls the target script function in the execution process. Since the execution process of the to-be-monitored script file is a process of continuously calling its own script functions, recording the parameters of the calling process of each script function can realize the monitoring of the execution process of the to-be-monitored script function.

[0098] Based on this, after the target script function is determined, the parameters of the target script function in the calling process are obtained to obtain the target script function attribute information.

[0099] Further, in the process of monitoring the execution process of the script file to be monitored and recording the monitoring result, the name, address, and occupied computing resource amount of the target script function called by the script file to be monitored need to be recorded. In this embodiment, the specific implementation manner is as follows:

[0100] obtain function identification information, function address information, and function duration information of the target script function; construct a target script function hash value based on the function identification information and the function address information; and generate target script function attribute information according to the function identification information, the function address information, the function duration information, and the target script function hash value.

[0101] The function identification information can be understood as information containing the function name, function code, and function ID of the target script function. The function address information can be understood as information containing the function address and function path of the target script function. The function duration information can be understood as information containing the duration of the target script function being called by the script file to be monitored and the CPU resource consumed in the calling. It should be noted that the CPU resource consumed can be the CPU processing space occupied in the process of the CPU executing the target script function, or can be the occupancy rate in the process of the CPU executing the target script function. The specific selection is determined according to the actual use scene, and the present application does not limit this. The target script hash value can be understood as a hash value obtained by performing hash operation on the function identification information and the function address information.

[0102] Based on this, the function identification, function address, and function calling duration information of the target script function are obtained one by one. Then, the function identification information and the function address information are subjected to hash calculation to obtain a target script function hash value. Finally, the function identification information, the function address information, the function duration information, and the target script function hash value are collected to obtain target script function attribute information, which is used to record the calling process of the target script function.

[0103] Continuing with the above example, the monitoring script function D1 monitors the script file A1 to be monitored. When there is a stack out operation corresponding to the script file A1 to be monitored, the function D2 of the stack out operation is determined as the target script function, the function identification information a1, the function address information a2, and the function duration information t of the target script function are determined. The function identification information a1 and the function address information a2 are subjected to hash operation to obtain a target script function hash value H. The function identification information a1, the function address information a2, the function duration information t, and the target script function hash value H are collected to obtain target script function attribute information C3.

[0104] In summary, by collecting information about the calling and processing of the target script function during the execution of the script file to be monitored, the execution of the target script function in the script file to be monitored is monitored.

[0105] Further, the function duration information is a direct reflection of the calling process of the target script function. The longer the function duration information, the more processing and operation the calling process of the target script function performs, and vice versa. In the embodiment, the function duration information is determined as follows:

[0106] The pop time and the push time corresponding to the target script function are determined, the difference between the pop time and the push time is calculated, and the function duration information is determined based on the calculation result.

[0107] The push time can be understood as the start time of the calling of the target script function, and the pop time can be understood as the end time of the calling of the target script function.

[0108] Therefore, when the script function is called, the push time is recorded when it is pushed, and the pop time is recorded when it is popped. When the pop operation is performed, the script function popped at this time is determined as the target script function, and the function duration information is obtained by subtracting the push time from the pop time of the target script function.

[0109] In the above example, after the target script function is determined, the pop time t2 of the recorded target function is subtracted from the push time t1 to obtain the function duration information t.

[0110] In summary, by recording the push time and the pop time of the target script function, the function duration information can be directly obtained.

[0111] Step 108: Save the target script function attribute information to the monitoring data file.

[0112] Specifically, after obtaining the target script function attribute information, it needs to be saved to ensure that the user can view the monitoring result of the execution process of the script file to be monitored.

[0113] The monitoring data file can be understood as a database, a storage queue, etc. specially used for saving the monitoring result. It should be noted that the purpose of the monitoring data file is to store the monitoring result of the script file to be monitored, and the specific form and type of the monitoring data file are not limited by the present application.

[0114] Therefore, after obtaining the target script function attribute information, i.e. the monitoring result of the execution process of the script file to be monitored, the monitoring result is stored in the monitoring data file, which facilitates the subsequent user to view or process the monitoring result.

[0115] Further, the function duration information intuitively represents the processing condition of the target script function after being called, and the target script function does not perform processing in the calling process. In this case, the monitoring result of the target script function calling process is not recorded, and in the embodiment, the specific implementation manner is as follows:

[0116] In the case where the function duration information is greater than or equal to the preset duration threshold, the target script function attribute information is saved to the monitoring data file; in the case where the function duration information is less than the preset duration threshold, the step of determining the target script function of the out-stack operation in the case where the stack corresponding to the to-be-monitored script file is monitored to have the out-stack operation is executed.

[0117] The preset duration threshold can be understood as a parameter value set according to actual use, and in the case where the function duration information is less than the preset duration threshold, it is indicated that the target script function does not perform data processing in the calling process.

[0118] Based on this, the function duration information of the obtained target script function is compared with the preset duration threshold, and in the case where the comparison result is less than, the target script function is not recorded, and in other cases, the parameters of the calling process of the target script function are recorded and saved to the monitoring data file.

[0119] In the above example, after comparison, it is obtained that the function duration information t of the target script function D2 is greater than the preset duration threshold T, and in this case, the target script function attribute information C3 is saved to the monitoring data file A2.

[0120] In summary, by using the function duration information of the target script function, the related information of the script function that does not perform processing in the execution process of the to-be-monitored script file is not stored, the storage space is saved, the hardware pressure is reduced, and the processing speed is improved on the premise of ensuring the integrity of the monitoring result.

[0121] Further, the script file monitoring method adopted in the present application stores the related information of the target script function meeting the condition when monitoring the execution process of the to-be-monitored file in real time, which may cause relatively large storage space occupation and relatively large hardware pressure, and the requirements on the equipment and system become relatively high. To solve these problems, in the embodiment, the specific implementation manner is as follows:

[0122] The target script function attribute information is converted into a to-be-stored string, wherein the to-be-stored string includes numerical characters; the numerical characters in the to-be-stored string are compressed to obtain a target string corresponding to the to-be-stored string; and the target string is saved to the monitoring data file.

[0123] The to-be-stored string can be understood as converting the target script attribute information into a string form; the to-be-stored string is compressed to obtain the target string. It should be noted that the compression manner can be selected according to actual use scenarios, and the embodiment is not limited.

[0124] Based on this, the target script function attribute information is converted into a to-be-stored string. It should be noted that the conversion manner can be selected according to actual use scenarios, and the embodiment is not limited. The obtained to-be-stored string is compressed to obtain a target string, and the target string is saved in the monitoring data file.

[0125] In the above example, the obtained target script function attribute information C3 is converted into a string form to obtain a to-be-stored string c1. The to-be-stored string is compressed to obtain a target string c2. The target string c2 is saved to the monitoring data file A2.

[0126] In summary, by compressing the target script function attribute information and compressing the string stored in the monitoring data file, the storage space pressure is reduced.

[0127] Further, in the process of compressing the to-be-stored string, the focus of compression is on the numerical characters in the to-be-stored string. In this embodiment, the specific implementation manner is as follows:

[0128] Determining a target numerical character in the to-be-stored string; determining a target data based on the target numerical character and a preset numerical compression parameter; generating an identification code corresponding to each target data, generating and storing a storage identification code corresponding to the to-be-stored data according to the identification code corresponding to each target data; converting the numerical character in the to-be-stored string into a corresponding storage identification code to obtain a target string corresponding to the to-be-stored string.

[0129] The target numerical character can be understood as a numerical character in the to-be-stored string that needs to be compressed; the numerical compression parameter can be understood as a parameter set in advance and applied to the compression process of the target numerical character; the target data can be understood as a sequence composed of at least one element obtained by processing the target numerical character based on the numerical compression parameter; the identification code can be understood as a one-to-one corresponding byte set constructed based on each element in the target data; and the storage identification code can be understood as a combination of each byte in the identification code to form an unsigned numerical string for storage of a computing device.

[0130] Based on this, the digital character of one of the to-be-stored strings is determined as a target digital character, the target digital character is processed based on a preset digital compression parameter to obtain target data, an identification code is constructed for each element in the target data, each obtained identification code is arranged to form a storage identification code in the form of a string of unsigned numbers, and all digital characters in the to-be-stored string are processed in the above manner to obtain a target string.

[0131] In summary, the digital characters in the to-be-stored string are compressed based on the digital compression parameter, which greatly reduces the storage space occupied by the monitoring data file and relieves the hardware pressure.

[0132] Further, the process of compressing the digital characters in the to-be-stored string based on the digital compression parameter is implemented in the embodiment as follows:

[0133] The corresponding value of the target digital character is divided by the digital compression parameter, it is determined whether the i-th quotient is less than the digital compression parameter, where i is a positive integer, if yes, the target data is constructed based on each obtained remainder value and the i-th quotient, and if no, the i-th quotient is divided by the digital compression parameter, i is increased by 1, and the step of determining whether the obtained quotient is less than the digital compression parameter is executed.

[0134] The corresponding value of the target digital character is divided by the digital compression parameter, it is determined whether the i-th quotient is less than the digital compression parameter, where i is a positive integer, if yes, the target data is constructed based on each obtained remainder value and the i-th quotient, and if no, the i-th quotient is divided by the digital compression parameter, i is increased by 1, and the step of determining whether the obtained quotient is less than the digital compression parameter is executed.

[0135] Based on this, the corresponding value of the target digital character is divided by the digital compression parameter to obtain a quotient and a remainder, it is determined whether the quotient is less than the digital compression parameter, if not, the quotient is continuously divided by the digital compression parameter to obtain a new quotient and a remainder, in the case where the new quotient is greater than the digital compression parameter, the current quotient is continuously divided by the digital compression parameter until the obtained quotient is less than the digital compression parameter, and the target data is constructed based on all the remainders and the last obtained quotient.

[0136] Continuing with the above example, if the obtained digital string to be stored is 100000; sell; 123456, traverse from left to right to determine that the first target digital character is 100000, since the current storage environment stores 8-bit unsigned numbers in one byte, which are used to store binary digital sequences in the range of 0-255, which means that the maximum number that can be stored in one byte is 255, and one byte cannot store a number greater than 255, so the number compression parameter is set to 255, and the target digital character 100000 is divided by the number compression parameter 255 to obtain a first quotient value of 392 and a first remainder of 40, it is determined that the first quotient value 392 is greater than the number compression parameter 255, and the first quotient value 392 is divided by the number compression parameter 255 to obtain a second quotient value of 1 and a second remainder of 137, it is determined that the second quotient value 1 is less than the number compression parameter 255, and based on the second quotient value 1 and the two remainders 40 and 137, the target data is determined to be (1, 137, 40).

[0137] Based on the target data (1, 137, 40), the corresponding identification code is determined to be (00000001, 10001001, 00101000), and the identification code corresponding to each target data is generated to store the identification code (000000011000100100101000), and the second target digital character 123456 in the digital string to be stored is determined, and the storage identification code of the second target digital character is obtained by using the above method (000000011110010100100100), and the ASCII codes of “;”, “s”, “e”, and “l” are “00111011”, “01110011”, “01100101”, and “01101100”, respectively, so at this time all the storage identification codes and the ASCII codes of other elements in the digital string to be stored form a target string (000000011000100100101000001110110111001101100101011011000110110000111011000000011110010100100100), and based on this string, to prevent confusion between the ASCII codes and the storage identification codes during parsing, a decoding identifier is constructed, the position corresponding to the storage identification code is represented by 1, and the ASCII code is represented by 0, then the decoding identifier is constructed as “111000000111”, and based on the target string and the decoding identifier, the reverse conversion of the target string to the digital string to be stored can be realized.

[0138] From the above, it can be seen that the compression effect of the number compression parameter on the target digital character is based on division, at this time the larger the number compression parameter is set, the better the compression effect is, and the number compression parameter cannot be greater than 256, otherwise it will not be able to be represented in one byte, so 255 is preferably selected.

[0139] In summary, by dividing the numerical value corresponding to the target digital string by the digital compression parameter, the quotient and the remainder are obtained. If the quotient at this time is still greater than the digital compression parameter, the quotient is divided by the digital compression parameter again to obtain a new quotient and a remainder. Through such continuous calculation, the target digital string will finally be compressed to a target data that is one bit more than the number of division operations, realizing the compression of the target digital string and saving storage space.

[0140] Further, during the execution of the to-be-monitored script file, repeated calls of the same script function often occur. In this case, storing the repeatedly called script function is relatively large in terms of waste of storage space. In order to solve this problem, in the embodiment, the specific implementation is as follows:

[0141] determining whether the target script function hash value exists in the monitoring data file; if yes, deleting the function address information in the target script function attribute information, and saving the deleted target script function attribute information to the monitoring data file; if no, saving the target script function attribute information to the monitoring data file.

[0142] Based on this, due to the one-to-one correspondence between the target script function hash value and the target script function, by comparing the target script function hash value of the current target script function with the data in the monitoring data file, it can be determined whether the target script function has been called by the to-be-monitored script file before. In the case of having been called before, the function address information of the target script function is deleted, and the target script function attribute information after deletion is saved to the monitoring data file, realizing the saving of storage space. In the case of not having been called before, the target script function attribute information corresponding to the target script function is saved to the monitoring data file.

[0143] In the above example, it is determined whether there is a hash value identical to the target script function hash value H in the monitoring data file A2. If yes, the function address information a2 in the target script function attribute information C3 is deleted, and the deleted target script function attribute information C3 is saved to the monitoring data file A2. If no, the target script function attribute information C3 is saved to the monitoring data file A2.

[0144] In summary, by comparing the target script function hash value with the monitoring data file, it is determined whether the repeatedly called script function is called repeatedly, the function address information of the repeatedly called script function is deleted, the target script function attribute information corresponding to the repeatedly called script function is reduced, only the function identification information is retained as the identification of the target script function, the repeated information in the monitoring data file is reduced, and the storage space is saved.

[0145] Further, after the process of monitoring the to-be-monitored script file, when the user needs to view the monitoring result, in the embodiment, the implementation is as follows:

[0146] receiving a display instruction for the monitoring data file; in response to the display instruction, visualizing the monitoring data file to generate and display a visualized result.

[0147] The display instruction can be understood as an instruction sent by the user for viewing the monitoring result of the to-be-monitored script file.

[0148] Specifically, the display instruction sent by the user for viewing the monitoring result of the to-be-monitored script file is received, and the monitoring data file corresponding to the to-be-monitored script file is visualized according to the indication of the display instruction to generate a visualized display result and display it to the user.

[0149] In the above example, the display instruction B2 sent by the user is received, and the flame chart corresponding to the monitoring data file A2 indicated by the display instruction B2 is constructed to generate the flame chart and display it to the user.

[0150] In summary, the monitoring result of the to-be-monitored script file is visualized, the display effect is more intuitive, and the user can view it conveniently.

[0151] The script file monitoring method provided in the application reduces the missed reading of the called script function in the monitoring process of the to-be-monitored script file, reduces the waste of computing resources in the monitoring process, and improves the monitoring efficiency.

[0152] The following describes the script file monitoring method provided in the application with reference to the accompanying Figure 2 The script file monitoring method provided in the application is applied to the monitoring of a C language script file, and the script file monitoring method is further described. Wherein, Figure 2 FIG. 1 shows a processing flowchart of a script file monitoring method applied to a C language according to an embodiment of the application, and specifically includes the following steps:

[0153] Step 202: receiving a monitoring instruction for a to-be-monitored script file.

[0154] Specifically, the monitoring instruction j1 for the C language script file cj is received.

[0155] Step 204: determining the to-be-monitored script file corresponding to the monitoring instruction according to the to-be-monitored script file information carried in the monitoring instruction.

[0156] Specifically, based on the to-be-monitored script file information X1 carried in the detection instruction j1, it is determined that the to-be-monitored script file is a C language script file cj.

[0157] Step 206: Determine the file attribute information of the to-be-monitored script file.

[0158] Specifically, the file attribute information X2 of the C language script file cj is determined.

[0159] Step 208: Based on the file attribute information, a monitoring script function is constructed.

[0160] Specifically, according to the file attribute information X2, it is determined that the running environment of the C language script file cj is a terminal and the programming language is C language, thereby determining that the monitoring programming language Y corresponding to the monitoring script function is C language, and constructing the monitoring script function H1 based on the monitoring programming language Y.

[0161] Step 210: In the case where it is monitored that the stack corresponding to the to-be-monitored script file has a stack-out operation, determine the target script function of the stack-out operation.

[0162] Specifically, the monitoring script function H1 monitors the C language script file cj, and in the case where the stack corresponding to the C language script file cj has a stack-out operation, the corresponding target script function H2 is determined.

[0163] Step 212: Obtain the target script function attribute information of the target script function.

[0164] Specifically, the stack-out time T1 and the stack-in time T2 of the C language script file cj are obtained, the function duration information TX is obtained by T1-T2, the function identification information h1 and the function address information h2 of the C language script file cj are obtained.

[0165] The function identification information h1 and the function address information h2 are subjected to a hash operation to obtain a target script function hash value MH, and the function identification information h1, the function address information h2, the function duration information TX and the target script function hash value MH are collected to obtain the target script function attribute information MS.

[0166] Step 214: Determine whether the function duration information is greater than or equal to a preset duration threshold;

[0167] If yes, step 216 is executed;

[0168] If not, step 210 is executed.

[0169] Step 216: Convert the target script function attribute information into a to-be-stored string.

[0170] Specifically, the target script function attribute information MS is converted into a to-be-stored string as 10000:me. It is determined that the target digital character is 10000, the target digital character 10000 is divided by the digital compression parameter 255, a first quotient value is 39, and a first remainder is 55. Since the first quotient value is less than the digital compression parameter 255, it is determined that the target data is (39, 55), an identification code corresponding to each target data is generated (00100111, 00110111), and the target string is determined (0010011100110111001110110110110101100101) by combining the ASCII codes of the characters ";","m" and "e".

[0171] Step 218: saving the target string to a monitoring data file.

[0172] Step 220: receiving a display instruction for the monitoring data file.

[0173] Step 222: in response to the display instruction, visualizing the monitoring data file to generate and display a visualization result.

[0174] The script file monitoring method provided in the application reduces the missed reading of the called script function in the monitoring process of the to-be-monitored script file, reduces the waste of computing resources in the monitoring process, and improves the monitoring efficiency.

[0175] Corresponding to the method embodiments, the application further provides script file monitoring device embodiments, Figure 3 A structure diagram of a script file monitoring device is shown. Figure 3 As shown in the figure, the device includes:

[0176] The receiving module 302 is configured to receive a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file includes at least one script function;

[0177] The monitoring module 304 is configured to determine a target script function of a pop operation of a stack corresponding to the to-be-monitored script file when the pop operation is monitored;

[0178] The obtaining module 306 is configured to obtain target script function attribute information of the target script function;

[0179] The saving module 308 is configured to save the target script function attribute information to a monitoring data file.

[0180] In an optional embodiment, the script file monitoring apparatus further comprises:

[0181] The constructing module is configured to determine a to-be-monitored script file corresponding to the monitoring instruction according to to-be-monitored script file information carried in the monitoring instruction, determine file attribute information of the to-be-monitored script file, construct a monitoring script function based on the file attribute information, and monitor the to-be-monitored script file through the monitoring script function.

[0182] In an optional embodiment, the constructing module is further configured to:

[0183] analyze the file attribute information to obtain running environment information, determine a monitoring programming language according to the running environment information, and construct the monitoring script function based on the monitoring programming language.

[0184] In an optional embodiment, the obtaining module 306 is further configured to:

[0185] obtain function identification information, function address information, and function duration information of the target script function, construct a target script function hash value based on the function identification information and the function address information, and generate target script function attribute information according to the function identification information, the function address information, the function duration information, and the target script function hash value.

[0186] In an optional embodiment, the obtaining module 306 is further configured to:

[0187] determine a pop time and a push time corresponding to the target script function, calculate a difference between the pop time and the push time, and determine the function duration information based on the calculation result.

[0188] In an optional embodiment, the saving module 308 is further configured to:

[0189] in a case where the function duration information is greater than or equal to a preset duration threshold, save the target script function attribute information to a monitoring data file, and in a case where the function duration information is less than the preset duration threshold, perform the step of determining a target script function of a pop operation on a stack corresponding to the to-be-monitored script file in a case where the monitoring apparatus monitors that the stack has the pop operation.

[0190] In an optional embodiment, the saving module 308 is further configured to:

[0191] The target script function attribute information is converted into a to-be-stored string, wherein the to-be-stored string includes numerical characters; the numerical characters in the to-be-stored string are compressed to obtain a target string corresponding to the to-be-stored string; and the target string is saved to the monitoring data file.

[0192] In an optional embodiment, the saving module 308 is further configured to:

[0193] A target numerical character is determined in the to-be-stored string; target data is determined based on the target numerical character and a preset numerical compression parameter; an identification code corresponding to each target data is generated, and a storage identification code corresponding to the to-be-stored data is generated and stored according to the identification code corresponding to each target data; and the numerical characters in the to-be-stored string are converted into corresponding storage identification codes to obtain a target string corresponding to the to-be-stored string.

[0194] In an optional embodiment, the saving module 308 is further configured to:

[0195] The numerical value corresponding to the target numerical character is divided by the numerical compression parameter; it is determined whether the i-th quotient is less than the numerical compression parameter, wherein i is a positive integer; if yes, target data is constructed based on the obtained each remainder value and the i-th quotient; and if no, the i-th quotient is divided by the numerical compression parameter, i is increased by 1, and the step of determining whether the obtained quotient is less than the numerical compression parameter is performed.

[0196] In an optional embodiment, the saving module 308 is further configured to:

[0197] It is determined whether the target script function hash value exists in the monitoring data file; if yes, the function address information in the target script function attribute information is deleted, and the target script function attribute information after the deletion is saved to the monitoring data file; and if no, the target script function attribute information is saved to the monitoring data file.

[0198] In an optional embodiment, the script file monitoring apparatus further includes:

[0199] The display module is configured to receive a display instruction for the monitoring data file; in response to the display instruction, the monitoring data file is visually processed to generate and display a visual result.

[0200] The script file monitoring method provided in the application, by responding to a monitoring instruction for a to-be-monitored script file, in a case where it is monitored that a stack corresponding to the to-be-monitored script file appears a stack-out operation, a target script function corresponding to the stack-out operation is determined; target script function attribute information of the target script function is acquired and saved to a monitoring data file, missing reading of a called script function in a monitoring process of the to-be-monitored script file is reduced, waste of computing resources in the monitoring process is reduced, and monitoring efficiency is improved.

[0201] The above is a schematic scheme of the script file monitoring device of the embodiment. It should be noted that the technical scheme of the script file monitoring device belongs to the same concept as the technical scheme of the script file monitoring method described above, and the details of the technical scheme of the script file monitoring device that are not described in detail can be referred to the description of the technical scheme of the script file monitoring method. In addition, each component in the device embodiment should be understood as a function module that must be established to implement each step of the program flow or each step of the method. Each function module is not limited by actual functional division or separation. The device claim defined by such a group of function modules should be understood as a function module architecture of the computer program for realizing the solution mainly by the description of the specification, and should not be understood as an entity device for realizing the solution mainly by hardware.

[0202] Figure 4 A structural block diagram of a computing device 400 according to an embodiment of the application is shown. The components of the computing device 400 include, but are not limited to, a memory 410 and a processor 420. The processor 420 is connected to the memory 410 through a bus 430, and a database 450 is used to save data.

[0203] The computing device 400 also includes an access device 440, which enables the computing device 400 to communicate via one or more networks 460. Examples of these networks include a public switched telephone network (PSTN), a local area network (LAN), a wide area network (WAN), a personal area network (PAN), or a combination of communication networks such as the Internet. The access device 440 can include one or more of any type of network interface (e.g., network interface card (NIC)) such as an IEEE 802.11 wireless local area network (WLAN) wireless interface, a Worldwide Interoperability for Microwave Access (Wi-MAX) interface, an Ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a Bluetooth interface, a near field communication (NFC) interface, and the like, wired or wireless.

[0204] In an embodiment of the application, the above-mentioned components of the computing device 400 and other components not shown in the Figure 4 It should be understood that the above-mentioned components of the computing device 400 and other components not shown in the Figure 4The illustrated computing device structural block diagram is merely for the purpose of example, and is not a limitation on the scope of the present application. Other components can be added or replaced as needed by those skilled in the art.

[0205] The computing device 400 can be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., a tablet computer, a personal digital assistant, a laptop computer, a notebook computer, a netbook, etc.), a mobile phone (e.g., a smartphone), a wearable computing device (e.g., a smart watch, smart glasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. The computing device 400 can also be a mobile or stationary server.

[0206] The processor 420 is configured to execute computer-executable instructions, including:

[0207] receiving a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file includes at least one script function;

[0208] In a case where it is monitored that the stack corresponding to the to-be-monitored script file has a stack-out operation, determining a target script function of the stack-out operation;

[0209] obtaining target script function attribute information of the target script function;

[0210] saving the target script function attribute information to a monitoring data file.

[0211] The above is a schematic scheme of the computing device of the embodiment. It should be noted that the technical scheme of the computing device belongs to the same concept as the technical scheme of the script file monitoring method described above, and the details of the technical scheme of the computing device that are not described in detail can be referred to the description of the technical scheme of the script file monitoring method.

[0212] An embodiment of the present application also provides a computer readable storage medium storing computer instructions, which are executed by a processor to:

[0213] receiving a monitoring instruction for a to-be-monitored script file, wherein the to-be-monitored script file includes at least one script function;

[0214] In a case where it is monitored that the stack corresponding to the to-be-monitored script file has a stack-out operation, determining a target script function of the stack-out operation;

[0215] obtaining target script function attribute information of the target script function;

[0216] saving the target script function attribute information to a monitoring data file.

[0217] The above is a schematic solution of the computer readable storage medium of the embodiment. It should be noted that the technical solution of the storage medium and the technical solution of the script file monitoring method described above belong to the same concept, and the details of the technical solution of the storage medium that are not described in detail can be seen from the description of the technical solution of the script file monitoring method.

[0218] An embodiment of the present application also provides a chip which stores the computer program, and the computer program is executed by the chip to realize the steps of the script file monitoring method.

[0219] The above describes specific embodiments of the present application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims can be performed in a different order than the order described in the embodiments and still achieve the desired result. In addition, the processes depicted in the figures do not necessarily require the particular order shown or sequential order to achieve the desired results. In certain implementations, multitasking and parallel processing can be advantageous or possible.

[0220] The computer instructions include computer program codes which can be in the form of source code, object code, executable files or some intermediate forms. The computer readable medium can include any entity or device capable of carrying the computer program codes, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the contents of the computer readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction, for example, in some jurisdictions, according to legislation and patent practice, the computer readable medium does not include electrical carrier signals and telecommunication signals.

[0221] It should be noted that for the foregoing method embodiments, in order to facilitate description, they are all expressed as a combination of a series of actions, but those skilled in the art should know that the present application is not limited to the order of the actions described, because according to the present application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should know that the embodiments described in the specification all belong to preferred embodiments, and the actions and modules involved are not necessarily essential to the present application.

[0222] In the above embodiments, the description of each embodiment has its own focus, and the parts not described in detail in a certain embodiment can be seen from the related description of other embodiments.

[0223] The preferred embodiments of the application disclosed above are only to facilitate the explanation of the application. Alternative embodiments do not describe all the details and do not limit the application to the specific embodiments described. Obviously, many modifications and changes can be made according to the content of the application. The application selects and describes these embodiments in order to better explain the principles and practical applications of the application, so that those skilled in the art can well understand and utilize the application. The application is limited by the claims and their full scope and equivalents.

Claims

1. A method for monitoring script files, characterized in that, include: Receive monitoring instructions for a script file to be monitored, wherein the script file to be monitored includes at least one script function; If a pop operation is detected in the stack corresponding to the script file to be monitored, the target script function of the pop operation is determined. Obtain the target script function attribute information of the target script function; obtaining the target script function attribute information includes: obtaining the function identifier information, function address information, and function duration information of the target script function; constructing a target script function hash value based on the function identifier information and the function address information; generating target script function attribute information according to the function identifier information, the function address information, the function duration information, and the target script function hash value; The target script function attribute information is saved to the monitoring data file; the step of saving the target script function attribute information to the monitoring data file includes: when the function duration information is greater than or equal to a preset duration threshold, the target script function attribute information is saved to the monitoring data file.

2. The method according to claim 1, characterized in that, Before determining the target script function for the pop operation, the method further includes: Based on the information of the script file to be monitored carried in the monitoring instruction, determine the script file to be monitored corresponding to the monitoring instruction; Determine the file attribute information of the script file to be monitored; Based on the file attribute information, a monitoring script function is constructed; The monitoring script function is used to monitor the script file to be monitored.

3. The method according to claim 2, characterized in that, The step of constructing a monitoring script function based on the file attribute information includes: Parse the file attribute information to obtain the runtime environment information; The monitoring programming language is determined based on the aforementioned operating environment information; The monitoring script function is constructed based on the monitoring programming language.

4. The method according to claim 1, characterized in that, The step of obtaining the function duration information of the target script function includes: Determine the pop and push times corresponding to the target script function; Calculate the difference between the pop time and the push time; The duration information of the function is determined based on the calculation results.

5. The method according to claim 1, characterized in that, Saving the target script function attribute information to the monitoring data file includes: If the function duration information is less than a preset duration threshold, the step of determining the target script function of the pop operation is executed when a pop operation is detected on the stack corresponding to the script file to be monitored.

6. The method according to claim 1 or 5, characterized in that, Saving the target script attribute information to the monitoring data file includes: The target script function attribute information is converted into a string to be stored, wherein the string to be stored includes numeric characters; Compress the numeric characters in the string to be stored to obtain the target string corresponding to the string to be stored. Save the target string to the monitoring data file.

7. The method according to claim 6, characterized in that, The step of compressing the numeric characters in the string to be stored to obtain the target string corresponding to the string to be stored includes: The target numeric character is determined in the string to be stored; The target data is determined based on the target numeric characters and preset numeric compression parameters; Generate an identifier code corresponding to each target data, and generate and store a storage identifier code corresponding to the data to be stored based on the identifier code corresponding to each target data. The numeric characters in the string to be stored are converted into corresponding storage identifiers to obtain the target string corresponding to the string to be stored.

8. The method according to claim 1, characterized in that, The target script function attribute information is saved to the monitoring data file, including: Determine whether the target script function hash value exists in the monitoring data file; If so, delete the function address information in the target script function attribute information, and save the deleted target script function attribute information to the monitoring data file; If not, save the target script function attribute information to the monitoring data file.

9. The method according to claim 1, characterized in that, After saving the target script function attribute information to the monitoring data file, the method further includes: Receive a display command for the monitoring data file; In response to the display command, the monitoring data file is visualized to generate and display the visualization results.

10. A script file monitoring device, characterized in that, include: The receiving module is configured to receive monitoring instructions for a script file to be monitored, wherein the script file to be monitored includes at least one script function; The monitoring module is configured to determine the target script function of the pop operation when a pop operation is detected in the stack corresponding to the script file to be monitored. The acquisition module is configured to acquire target script function attribute information of the target script function; the acquisition module is also configured to acquire function identifier information, function address information, and function duration information of the target script function; construct a target script function hash value based on the function identifier information and the function address information; and generate target script function attribute information according to the function identifier information, the function address information, the function duration information, and the target script function hash value. The save module is configured to save the target script function attribute information to the monitoring data file; The saving module is also configured to save the target script function attribute information to the monitoring data file when the function duration information is greater than or equal to a preset duration threshold.

11. A computing device, characterized in that, include: Memory and processor; The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to implement the steps of the script file monitoring method according to any one of claims 1 to 9.

12. A computer-readable storage medium storing computer instructions, characterized in that, When executed by the processor, this instruction implements the steps of the script file monitoring method according to any one of claims 1 to 9.

13. A computer program product, characterized in that, It includes computer instructions that, when executed by a processor, implement the steps of the script file monitoring method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Game creation method and device

    CN112206531A

  • Application program monitoring method, electronic equipment and storage medium

    CN113672458A