Capacity detection method and related equipment based on full-link online stress testing
Through the full-link online pressure measurement method, the probe is used for identification and processing, and the pressure measurement flow and formal flow are separated and stored, solving the problems of inaccurate capacity detection results and the risks brought about by system code transformation in the prior art, and achieving accurate and safe capacity detection.
Patent Information
- Application Number
- CN202210316706.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-28
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2042-03-28
AI Technical Summary
In the prior art, the capacity detection method has problems with inaccurate results and the risks brought about by system code transformation. The stand-alone pressure measurement method lacks the same flow background as the production environment. The theoretical estimation method depends on estimation. The online pressure measurement method requires the system code transformation.
The capacity detection method based on full-link online pressure measurement is adopted, and the pressure measurement request is received through the full-link pressure measurement platform, the business application system is subject to pressure testing, and the pressure measurement flow and formal flow are separated and stored to avoid major adjustments to the source system code.
It realizes non-invasive capacity detection, avoids the risk of source system, ensures the accuracy of test results, avoids contamination of formal data, and solves the problem of inaccurate capacity data.
Smart Images

Figure CN114942873B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a capacity detection method and related equipment based on full-link online stress testing. Background Art
[0002] Capacity refers to the maximum processing ability of the system for requests when the system is at maximum load or a certain indicator reaches the maximum acceptable threshold. Capacity data can be used to identify shortcomings, such as finding systems that need to be expanded or adding some hardware configurations to prevent excessive traffic during production that exceeds the traffic supported by the system as a whole. Through capacity estimation and capacity stress testing, relevant data can be obtained to help operations and maintenance support business development at a reasonable Internet technology cost.
[0003] Based on the above situation, in the prior art, capacity detection is performed through single-machine stress testing method, theoretical estimation method or online stress testing method. However, the single-machine stress testing method lacks the same traffic background as the production environment, which leads to inaccurate test results. The theoretical estimation method obtains the results through estimation, so the results are still inaccurate. In addition, the online stress testing method requires modification of the system code, such as adding corresponding logic to the test traffic, adding baffle programs, etc., which will bring risks to the original system. Summary of the invention
[0004] In view of this, the purpose of this application is to propose a capacity detection method and related equipment based on full-link online stress testing to solve the above technical problems.
[0005] Based on the above purpose, the first aspect of the present application provides a capacity detection method based on full-link online stress testing, which is applied to a full-link stress testing system, wherein the full-link stress testing system includes a business scenario system and a full-link stress testing platform, wherein the business scenario system includes a business application system in which a probe is deployed, and the business application system includes at least a first business application system and a second business application system;
[0006] The method comprises:
[0007] Performing a stress test on the first business application system according to the stress test request received by the full-link stress test platform, obtaining a stress test flow with a set stress test target, and performing identification and processing through a probe deployed by the first business application, and separating and storing the stress test flow and the official flow obtained by running the business scenario system;
[0008] Calling the stress test request through the second business application system to obtain a transmission message of the stress test traffic and a transmission message of the formal traffic, and storing the transmission message of the stress test traffic and the transmission message of the formal traffic separately;
[0009] In response to determining that the stress test mark is transmitted to the second business application system, business key information and logs of the stress test traffic and business key information and logs of the formal traffic are obtained, and identification processing is performed through the probe deployed by the second business application system, and the business key information of the stress test traffic and the business key information of the formal traffic are separated and stored, and the logs of the stress test traffic and the logs of the formal traffic are separated and stored;
[0010] The probe deployed based on the second business application system retrieves and analyzes the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform to obtain capacity data.
[0011] A second aspect of the present application provides a full-link stress testing system, the full-link stress testing system comprising a business scenario system and a full-link stress testing platform, wherein the business scenario system comprises a business application system in which a probe is deployed, and the business application system comprises at least a first business application system and a second business application system;
[0012] A stress testing module is configured to perform a stress test on the first business application system according to the stress testing request received by the full-link stress testing platform, obtain a stress testing flow with a set stress testing target, perform identification processing through a probe deployed by the first business application, and separate and store the stress testing flow from a formal flow obtained by running the business scenario system;
[0013] a transmission module configured to call the stress test request through the second business application system, obtain a transmission message of the stress test traffic and a transmission message of the formal traffic, and store the transmission message of the stress test traffic and the transmission message of the formal traffic separately;
[0014] Calling a stress test module, configured to obtain the business key information and log of the stress test traffic and the business key information and log of the formal traffic in response to determining that the stress test mark is transmitted to the second business application system, and performing identification processing through a probe deployed by the second business application system, separating the business key information of the stress test traffic from the business key information of the formal traffic for storage, and separating the log of the stress test traffic from the log of the formal traffic for storage;
[0015] The parsing and processing module is configured to retrieve and parse the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform based on the probe deployed by the second business application system to obtain capacity data.
[0016] A third aspect of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method described in the first aspect when executing the program.
[0017] A fourth aspect of the present application provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the method described in the first aspect.
[0018] From the above, it can be seen that the capacity detection method and related equipment based on full-link online stress testing provided by the present application perform stress testing on the first business application system according to the stress testing request received by the full-link stress testing platform, obtain the stress testing traffic for setting the stress testing target, and identify and process it through the probe deployed by the first business application. A non-invasive method is implemented through the deployed probe, and there is no need to make major adjustments to the code, architecture, etc. of the source system, which has little impact on it, avoiding problems such as system risks caused by more modifications to the source system, and storing the stress testing traffic and the formal traffic obtained from the operation of the business scenario system separately. Then, the stress test request is called through the second business application system to obtain the transmission message of the stress test traffic and the transmission message of the formal traffic, and the transmission message of the stress test traffic and the transmission message of the formal traffic are separated and stored. When the stress test mark is passed to the second business application system, the business key information and log of the stress test traffic and the business key information and log of the formal traffic are obtained, and the probe deployed by the second business application system is used for identification and processing, and the business key information of the stress test traffic and the business key information of the formal traffic are separated and stored. At the same time, the log of the stress test traffic and the log of the formal traffic are separated and stored. Through the probe, stress test mark and the transmission of stress test mark, the stress test traffic and the formal traffic, the transmission message of the stress test traffic and the transmission message of the formal traffic, the business key information of the stress test traffic and the business key information of the formal traffic, the log of the stress test traffic and the log of the formal traffic are logically isolated respectively, so that they do not affect each other and avoid contaminating the formal data. Finally, based on the probe deployed by the second business application system, the log of the stress test traffic and the log of the formal traffic are retrieved and analyzed through the full-link stress test platform to obtain capacity data, thereby solving the problem of inaccurate capacity data. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the technical solutions in the present application or related technologies, the drawings required for use in the embodiments or related technical descriptions are briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0020] Figure 1 This is a flow chart of a capacity detection method based on full-link online stress testing according to an embodiment of the present application;
[0021] Figure 2 A schematic diagram of a structural frame of a pressure test according to an embodiment of the present application;
[0022] Figure 3 A schematic diagram of a structural block diagram of generating capacity data according to an embodiment of the present application;
[0023] Figure 4 This is a schematic diagram of the structure of the full-link stress testing system of an embodiment of the present application;
[0024] Figure 5 A schematic diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0025] In order to make the objectives, technical solutions and advantages of the present application more clearly understood, the present application is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.
[0026] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present application should be the usual meanings understood by people with ordinary skills in the field to which the present application belongs. The "first", "second" and similar words used in the embodiments of the present application do not represent any order, quantity or importance, but are only used to distinguish different components. "Including" or "comprising" and similar words mean that the elements or objects appearing in front of the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.
[0027] In the related technology, a single-machine stress testing method is used to build a verification environment consistent with the production environment, to verify the single-machine capacity of each system, until the TPS (Transactions Per Second) and the corresponding time when the waterline is reached, as well as CPU (Central Processing Unit), memory, I / O (Input / Output), bandwidth and other information. However, the single-machine stress testing method lacks the same traffic background as the production environment, resulting in inaccurate test results.
[0028] Theoretical estimation is used to calculate the peak TPS and estimate the average response time based on the empirical data of the production environment. For example, if the data under 100 concurrent users is known, the TPS and response time under 1000 concurrent users can be estimated. Since the theoretical estimation method is used for estimation, the estimation result is still inaccurate.
[0029] In addition, there is also an online stress test method in related technologies. For systems that can be stress tested in the production environment, stress tests are performed directly in production. The production capacity of each system is verified until the TPS and corresponding time when the waterline is reached, as well as information such as CPU, memory, I / O, and bandwidth. The system code needs to be modified, such as adding corresponding logic to the test traffic, adding baffle programs, etc., which will bring risks to the original system.
[0030] The embodiment of the present application provides a capacity detection method based on full-link online stress testing. A non-invasive method is implemented through the deployed probes. There is no need to make major adjustments to the code, architecture, etc. of the source system, and the impact on it is minimal, avoiding problems such as system risks caused by more modifications to the source system. Through probes, stress testing labels, and the transmission of stress testing labels, the stress testing traffic and the official traffic, the transmission messages of the stress testing traffic and the transmission messages of the official traffic, the business key information of the stress testing traffic and the business key information of the official traffic, and the logs of the stress testing traffic and the logs of the official traffic are logically isolated respectively, so that they do not affect each other, avoid contamination of the official data, and solve the problem of inaccurate capacity data.
[0031] like Figure 1 As shown, the method of this embodiment is applied to a full-link stress testing system, wherein the full-link stress testing system includes a business scenario system and a full-link stress testing platform, wherein the business scenario system includes a business application system in which the probe is deployed, and the business application system includes at least a first business application system and a second business application system;
[0032] The method comprises:
[0033] Step 101: Perform a stress test on the first business application system according to the stress test request received by the full-link stress test platform, obtain the stress test traffic for setting the stress test target, and identify and process it through the probe deployed by the first business application, and separate and store the stress test traffic and the formal traffic obtained by running the business scenario system.
[0034] In this step, the full-link stress testing platform sets the address information of the first business application system, sends a stress testing request through the first business application system, performs stress testing on the first business application system through the full-link stress testing platform based on the stress testing request and according to the address information of the first business application system, obtains the stress testing traffic with the stress testing target set, and identifies and processes it through the probe deployed by the first business application, separates and stores the stress testing traffic from the formal traffic obtained by the operation of the business scenario system, and uses the deployed probe to identify and process the stress testing traffic with the stress testing target set (for example, adding a Header normal traffic tag to the request), so that it can be accurately located when searching for the call link, and in this way, it is achieved that the source program is not modified, thereby avoiding problems such as system risks. Among them, the probe refers to an independent process installed on the operating system, which is used to collect architecture information.
[0035] The stress test traffic can be correctly identified at any link. The stress test mark is set at the traffic entry layer. The middleware identifies and continues to pass the stress test mark downward to ensure that the stress test mark is not lost on the entire link. In this way, downstream applications and storage can also receive the stress test mark.
[0036] In addition, the first business application system and the second business application system represent different systems in the same business scenario. For example, for a shopping platform on Double Eleven, a product system and a payment system will be involved. The first business application system and the second business application system are not specifically limited here.
[0037] Step 102: Call the stress test request through the second business application system to obtain the transmission message of the stress test traffic and the transmission message of the formal traffic, and store the transmission message of the stress test traffic and the transmission message of the formal traffic separately.
[0038] In this step, the stress testing request is called through the second business application system to obtain the transmission message of the stress testing traffic and the transmission message of the formal traffic, and the transmission message of the stress testing traffic and the transmission message of the formal traffic are stored separately to isolate them logically. The isolation is relatively thorough and safe, so that they do not affect each other and avoid contaminating the formal data.
[0039] Step 103, in response to determining that the stress test mark is passed to the second business application system, the business key information and log of the stress test traffic, the business key information and log of the formal traffic are obtained, and the probes deployed by the second business application system are used for identification and processing, and the business key information of the stress test traffic and the business key information of the formal traffic are separated and stored, and the log of the stress test traffic and the log of the formal traffic are separated and stored.
[0040] In this step, the second business application system calls the stress test request, passes the stress test label to the second business application system, and obtains the business key information and log of the stress test traffic, and the business key information and log of the formal traffic, wherein the business key information and log of the stress test traffic are respectively set to the stress test label transmitted to the second business application system, and are identified and processed by the probe deployed by the second business application system. The business key information of the stress test traffic and the business key information of the formal traffic, the log of the stress test traffic and the log of the formal traffic are identified and processed by the deployed probe (for example, adding a Header normal traffic tag to the request). In this way, the call link can be accurately located when searching, and can be logically isolated. The isolation is relatively thorough and safe, so that they do not affect each other and avoid contaminating the formal data.
[0041] Step 104: The probe deployed based on the second business application system retrieves and analyzes the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform to obtain capacity data.
[0042] In this step, the full-link stress testing platform sets the address information of the second business application system, accesses the full-link stress testing platform through the address information of the second business application system, and parses and processes the data extracted from the logs of the stress testing traffic and the logs of the formal traffic based on the probes deployed by the second business application system to obtain capacity data, thereby solving the problem of inaccurate capacity data.
[0043] In addition, the shortcomings of the business scenario system can be identified based on capacity data, so that optimization can be carried out to prevent the traffic from being too large during production and exceeding the traffic supported by the system as a whole.
[0044] Through the above scheme, the first business application system is stress tested according to the stress test request received by the full-link stress test platform, and the stress test traffic with the stress test target set is obtained. The stress test traffic and the formal traffic obtained by the operation of the business scenario system are separated and stored, and the deployment probe is used to identify and process the stress test traffic with the stress test target set (for example, adding a Header (header) normal traffic mark in the request), so that it can be accurately located when searching for the call link. In this way, it is achieved that the source program is not modified, thereby avoiding problems such as system risks. Then, the stress test request is called by the second business application system to obtain the transmission message of the stress test traffic and the transmission message of the formal traffic, and the transmission message of the stress test traffic and the transmission message of the formal traffic are separated and stored, so that they are logically isolated. The isolation is relatively thorough and safe, so that they do not affect each other and avoid contaminating the formal data. When the stress testing mark is passed to the second business application system, the business key information and logs of the stress testing traffic and the business key information and logs of the formal traffic are obtained, and the probes deployed by the second business application system are used to identify and process them, and the business key information of the stress testing traffic and the business key information of the formal traffic are separated and stored. At the same time, the logs of the stress testing traffic and the logs of the formal traffic are separated and stored. Through the probes, stress testing marks and the transmission of stress testing marks, the stress testing traffic and the formal traffic, the transmission messages of the stress testing traffic and the transmission messages of the formal traffic, the business key information of the stress testing traffic and the business key information of the formal traffic, the logs of the stress testing traffic and the logs of the formal traffic are logically isolated respectively, so that they do not affect each other and avoid contaminating the formal data. Finally, based on the probes deployed by the second business application system, the logs of the stress testing traffic and the logs of the formal traffic are retrieved and analyzed through the full-link stress testing platform to obtain capacity data, thereby solving the problem of inaccurate capacity data.
[0045] In some embodiments, the business scenario system includes at least one of the following:
[0046] Formal storage database, shadow storage database, formal message queue database, shadow message queue database, formal cache database, shadow cache database, formal log database and shadow log database.
[0047] In the above scheme, the shadow storage database is a mirror database of the formal storage database, the shadow message queue database is a mirror database of the formal message queue database, the shadow cache database is a mirror database of the formal cache database, and similarly, the shadow log database is a mirror database of the formal log database.
[0048] Because online write operations cannot pollute official data, it is necessary to transfer stress testing traffic and stress testing traffic data to the mirror database through the mirror database, and transfer official traffic to the official database, logically isolating the two types of traffic so that they do not affect each other.
[0049] In some embodiments, step 101, the identification processing performed by the probe deployed by the first business application, and the separation and storage of the stress test traffic and the formal traffic obtained by the operation of the business scenario system, includes:
[0050] The stress test target is identified by the probe deployed by the first business application, and the stress test traffic of the set stress test target is stored in the shadow storage database. At the same time, the formal traffic obtained by running the business scenario system is stored in the formal storage database.
[0051] In the above solution, the shadow storage database is configured in the same way as the formal storage database. The shadow storage database name is usually added with a fixed prefix and suffix based on the formal storage database name, and the table name remains unchanged. Database-level isolation is the isolation of the data source, which is relatively thorough and safe, thus ensuring that the formal data will not be polluted.
[0052] In some embodiments, in step 102, the separate storage of the transmission message of the stress testing traffic and the transmission message of the formal traffic includes:
[0053] The transmission message of the stress testing traffic is stored in the shadow message queue database, and the transmission message of the formal traffic is stored in the formal message queue database.
[0054] In the above solution, the transmission messages of the stress testing traffic are stored in the shadow message queue database, and the transmission messages of the formal traffic are stored in the formal message queue database, so that the data in the transmission process are isolated and do not affect each other, further avoiding pollution of the formal data.
[0055] In some embodiments, step 103, the identification processing performed by the probe deployed by the second business application system, the business key information of the stress test traffic and the business key information of the formal traffic are separated and stored, and the log of the stress test traffic and the log of the formal traffic are separated and stored, including:
[0056] The stress test target is identified by the probe deployed by the second business application system, and the business key information of the stress test traffic with the stress test target is stored in the shadow cache database, and the business key information of the formal traffic is stored in the formal cache database. At the same time, the log of the stress test traffic with the stress test target is stored in the shadow log database, and the log of the formal traffic is stored in the formal log database.
[0057] In the above scheme, the business key information of the stress testing traffic and the log of the stress testing traffic are set with a stress testing mark, and the stress testing mark is identified by the probe deployed by the second business application system. The deployed probe is used to identify and process the business key information of the stress testing traffic and the log of the stress testing traffic that are set with the stress testing mark (for example, adding a Header normal traffic mark in the request), so that the business key information of the stress testing traffic and the business key information of the formal traffic, and the log of the stress testing traffic and the log of the formal traffic are isolated, so that they do not affect each other and avoid contaminating the formal data. At the same time, it allows accurate positioning when searching for the call link. In this way, it is achieved that the source program is not modified, thereby avoiding problems such as system risks.
[0058] The isolation of the business key information of stress test traffic and formal traffic is generally used in KV cache (Key-Value cache module) and storage components (such as Redis (Remote Dictionary Server)). The probe will intercept all operations on KV cache and storage components, and automatically modify the Key (business key information) and expiration time according to the stress test mark to achieve the purpose of isolating and cleaning data.
[0059] In some embodiments, step 104 includes:
[0060] The probe deployed based on the second business application system retrieves and analyzes the logs of the stress test traffic and the logs of the formal traffic through the full-link stress test platform to obtain probe data information, stress test data information and link data information;
[0061] The capacity data is obtained by calculating and processing the probe data information, the stress test data information and the link data information.
[0062] In the above scheme, the probe deployed based on the second business application system retrieves and analyzes the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform to obtain probe data information, stress testing data information and link data information.
[0063] Among them, the probe data information includes call chain data such as points and edges of business activities;
[0064] Stress testing data information includes the export and import data of each application, stress testing data, etc.
[0065] The link data information includes the call chain data and the detailed data of each probe;
[0066] By calculating and processing the probe data information, stress test data information and link data information, we can obtain the performance baseline data and capacity data of each business application system, thereby obtaining the flow limiting threshold, and find out the shortcomings of the business scenario system based on the capacity data, so as to optimize it to prevent the traffic from being too large during production and exceeding the traffic supported by the system as a whole.
[0067] In some embodiments, the probe data information, the stress testing data information and the link data information are stored separately through the full-link stress testing platform.
[0068] In the above solution, the probe data information, stress testing data information and link data information are separated and stored through the full-link stress testing platform. The probe data information is stored in the clickhouse (open source column database) database of the full-link stress testing platform, the stress testing data information is stored in the influxdb (time series database) database, and the link data information is stored in the mysql (relational database management system) database to meet query calls.
[0069] In some embodiments, for example, Figure 2 and Figure 3 As shown, according to the stress test request received by the full-link stress test platform, the stress test is performed on the business application A (i.e., the first business application) through the stress machine of the full-link stress test platform, and the probe deployed by the business application A is used for identification and processing, and the stress test traffic and the formal traffic are stored separately, and the stress test traffic is written to the shadow library (i.e., the shadow storage database), and the formal traffic is written to the formal library (i.e., the formal storage database). The stress test request is called through business application B (i.e., the second business application), and the transmission message of the stress test traffic and the transmission message of the formal traffic are obtained, and the transmission message of the stress test traffic and the transmission message of the formal traffic are stored separately, and the transmission message of the stress test traffic is written to the shadow library. c (i.e., shadow message queue database), writes the transmission message of the formal traffic into the formal topic (i.e., formal message queue database). When the stress test mark is passed to business application B, the business key information and log of the stress test traffic, the business key information and log of the formal traffic are obtained, and the probes deployed by the second business application system are used for identification and processing. The business key information of the stress test traffic is written into the shadow key (i.e., shadow cache database), and the business key information of the formal traffic is written into the formal key (i.e., shadow cache database). At the same time, the log of the stress test traffic is written into the shadow log (i.e., shadow log database), and the log of the formal traffic is separated and written into the formal log (i.e., formal log database).
[0070] The surge task (network debugging task) is executed through the storm cluster system (distributed real-time big data processing framework) in the full-link stress testing platform to parse and process the probe log data (i.e., the data retrieved by the probe deployed by the second business application system from the log of the stress testing traffic and the log of the formal traffic) to obtain probe data (i.e., probe data information), stress testing data (i.e., stress testing data information) and link data (i.e., link data information), and the probe data information is stored in the clickhouse (open source column database) database of the full-link stress testing platform, the stress testing data information is stored in the influxdb (time series database) database, and the link data information is stored in the mysql (relational database management system) database. The probe data information, stress testing data information and link data information are calculated and processed through the storm cluster system to obtain capacity data, and data can be queried through the amdb database (Advanced MassDatabase, distributed storage database) of the control center of the full-link stress testing platform, wherein the address information of business application A and the address information of business application B are set through the zookeeper cluster system (distributed application coordination service) in the configuration center of the full-link stress testing platform.
[0071] It should be noted that the method of the embodiment of the present application can be performed by a single device, such as a computer or server. The method of this embodiment can also be applied to a distributed scenario and completed by multiple devices cooperating with each other. In the case of such a distributed scenario, one of the multiple devices can only perform one or more steps in the method of the embodiment of the present application, and the multiple devices will interact with each other to complete the described method.
[0072] It should be noted that the above describes some embodiments of the present application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the above embodiments and still achieve the desired results. In addition, the processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0073] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides a full-link stress testing system.
[0074] refer to Figure 4 , the full-link stress testing system includes a business scenario system and a full-link stress testing platform, wherein the business scenario system includes a business application system in which the probe is deployed, and the business application system includes at least a first business application system and a second business application system;
[0075] The stress testing module 401 is configured to perform a stress test on the first business application system according to the stress testing request received by the full-link stress testing platform, obtain the stress testing traffic for setting the stress testing target, identify and process the stress testing traffic through the probe deployed by the first business application, and separate and store the stress testing traffic from the formal traffic obtained by running the business scenario system;
[0076] The transmission module 402 is configured to call the stress test request through the second business application system, obtain the transmission message of the stress test traffic and the transmission message of the formal traffic, and store the transmission message of the stress test traffic and the transmission message of the formal traffic separately;
[0077] The stress test module 403 is called, and is configured to obtain the business key information and log of the stress test traffic and the business key information and log of the formal traffic in response to determining that the stress test mark is transmitted to the second business application system, and perform identification processing through the probe deployed by the second business application system, separate the business key information of the stress test traffic from the business key information of the formal traffic for storage, and separate the log of the stress test traffic from the log of the formal traffic for storage;
[0078] The parsing and processing module 404 is configured to retrieve and parse the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform based on the probe deployed by the second business application system to obtain capacity data.
[0079] In some embodiments, the business scenario system includes at least one of the following:
[0080] Formal storage database, shadow storage database, formal message queue database, shadow message queue database, formal cache database, shadow cache database, formal log database and shadow log database.
[0081] In some embodiments, the stress testing module 401 is specifically configured to:
[0082] The stress test target is identified by the probe deployed by the first business application, and the stress test traffic of the set stress test target is stored in the shadow storage database. At the same time, the formal traffic obtained by running the business scenario system is stored in the formal storage database.
[0083] In some embodiments, the transmission module 402 is specifically configured to:
[0084] The transmission message of the stress testing traffic is stored in the shadow message queue database, and the transmission message of the formal traffic is stored in the formal message queue database.
[0085] In some embodiments, the stress test module 403 is called and is specifically configured to:
[0086] The stress test target is identified by the probe deployed by the second business application system, and the business key information of the stress test traffic with the stress test target is stored in the shadow cache database, and the business key information of the formal traffic is stored in the formal cache database. At the same time, the log of the stress test traffic with the stress test target is stored in the shadow log database, and the log of the formal traffic is stored in the formal log database.
[0087] In some embodiments, the parsing processing module 404 is specifically configured to:
[0088] The probe deployed based on the second business application system retrieves and analyzes the logs of the stress test traffic and the logs of the formal traffic through the full-link stress test platform to obtain probe data information, stress test data information and link data information;
[0089] The capacity data is obtained by calculating and processing the probe data information, the stress test data information and the link data information.
[0090] In some embodiments, the probe data information, the stress testing data information and the link data information are stored separately through the full-link stress testing platform.
[0091] For the convenience of description, the above device is described in terms of functions divided into various modules. Of course, when implementing the present application, the functions of each module can be implemented in the same or multiple software and / or hardware.
[0092] The device of the above embodiment is used to implement the corresponding capacity detection method based on full-link online stress testing in any of the above embodiments, and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.
[0093] Based on the same inventive concept, corresponding to any of the above-mentioned embodiments and methods, the present application also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the capacity detection method based on full-link online stress testing described in any of the above embodiments is implemented.
[0094] Figure 5 A more specific schematic diagram of the hardware structure of an electronic device provided in this embodiment is shown, and the device may include: a processor 501, a memory 502, an input / output interface 503, a communication interface 504, and a bus 505. The processor 501, the memory 502, the input / output interface 503, and the communication interface 504 are connected to each other through the bus 505 in the device.
[0095] The processor 501 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.
[0096] The memory 502 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 502 can store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 502 and called and executed by the processor 501.
[0097] The input / output interface 503 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.
[0098] The communication interface 504 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through wired mode (such as USB, network cable, etc.) or wireless mode (such as mobile network, WIFI, Bluetooth, etc.).
[0099] The bus 505 includes a path for transmitting information between various components of the device (eg, the processor 501 , the memory 502 , the input / output interface 503 , and the communication interface 504 ).
[0100] It should be noted that, although the above device only shows a processor 501, a memory 502, an input / output interface 503, a communication interface 504, and a bus 505, in a specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include components necessary for implementing the embodiments of the present specification, and does not necessarily include all the components shown in the figure.
[0101] The electronic device in the above embodiment is used to implement the corresponding capacity detection method based on full-link online stress testing in any of the above embodiments, and has the beneficial effects of the corresponding method embodiment, which will not be repeated here.
[0102] Based on the same inventive concept, corresponding to any of the above-mentioned embodiment methods, the present application also provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the capacity detection method based on full-link online stress testing as described in any of the above embodiments.
[0103] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.
[0104] The computer instructions stored in the storage medium of the above embodiment are used to enable the computer to execute the capacity detection method based on full-link online stress testing as described in any of the above embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.
[0105] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present application (including the claims) is limited to these examples. In line with the concept of the present application, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the embodiments of the present application as described above, which are not provided in detail for the sake of simplicity.
[0106] In addition, to simplify the description and discussion, and in order not to make the embodiments of the present application difficult to understand, the known power supply / ground connection with the integrated circuit (IC) chip and other components may or may not be shown in the provided drawings. In addition, the device can be shown in the form of a block diagram to avoid making the embodiments of the present application difficult to understand, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform to be implemented in the embodiments of the present application (that is, these details should be fully within the scope of understanding of those skilled in the art). In the case of elaborating specific details (e.g., circuits) to describe exemplary embodiments of the present application, it is obvious to those skilled in the art that the embodiments of the present application can be implemented without these specific details or when these specific details are changed. Therefore, these descriptions should be considered to be illustrative rather than restrictive.
[0107] Although the present application has been described in conjunction with specific embodiments of the present application, many replacements, modifications and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.
[0108] The embodiments of the present application are intended to cover all such substitutions, modifications and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of the present application should be included in the scope of protection of the present application.
Claims
1. A capacity detection method based on full-link online stress testing, characterized in that: Applied to a full-link stress testing system, the full-link stress testing system includes a business scenario system and a full-link stress testing platform, wherein the business scenario system includes a business application system in which the probe is deployed, and the business application system includes at least a first business application system and a second business application system; The method comprises: Performing a stress test on the first business application system according to the stress test request received by the full-link stress test platform, obtaining a stress test flow with a set stress test target, and performing identification and processing through a probe deployed by the first business application, and separating and storing the stress test flow and the official flow obtained by running the business scenario system; Calling the stress test request through the second business application system to obtain a transmission message of the stress test traffic and a transmission message of the formal traffic, and storing the transmission message of the stress test traffic and the transmission message of the formal traffic separately; In response to determining that the stress test mark is transmitted to the second business application system, business key information and logs of the stress test traffic and business key information and logs of the formal traffic are obtained, and identification processing is performed through the probe deployed by the second business application system, and the business key information of the stress test traffic and the business key information of the formal traffic are separated and stored, and the logs of the stress test traffic and the logs of the formal traffic are separated and stored; The probe deployed based on the second business application system retrieves and analyzes the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform to obtain capacity data.
2. The method according to claim 1, characterized in that The business scenario system includes at least one of the following: Formal storage database, shadow storage database, formal message queue database, shadow message queue database, formal cache database, shadow cache database, formal log database and shadow log database.
3. The method according to claim 2, characterized in that The identification processing is performed by the probe deployed by the first business application, and the stress test traffic and the formal traffic obtained by the operation of the business scenario system are separated and stored, including: The stress test target is identified by the probe deployed by the first business application, and the stress test traffic of the set stress test target is stored in the shadow storage database. At the same time, the formal traffic obtained by running the business scenario system is stored in the formal storage database.
4. The method according to claim 2, characterized in that: The separate storage of the transmission message of the stress testing traffic and the transmission message of the formal traffic includes: The transmission message of the stress testing traffic is stored in the shadow message queue database, and the transmission message of the formal traffic is stored in the formal message queue database.
5. The method according to claim 2, characterized in that: The identification processing is performed by the probe deployed by the second business application system, the business key information of the stress test traffic and the business key information of the formal traffic are separated and stored, and the log of the stress test traffic and the log of the formal traffic are separated and stored, including: The stress testing target is identified by the probe deployed by the second business application system, and the business key information of the stress testing traffic with the stress testing target is stored in the shadow cache database, and the business key information of the formal traffic is stored in the formal cache database. At the same time, the log of the stress testing traffic with the stress testing target is stored in the shadow log database, and the log of the formal traffic is stored in the formal log database.
6. The method according to claim 1, characterized in that The probe deployed based on the second business application system retrieves and analyzes the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform to obtain capacity data, including: The probe deployed based on the second business application system retrieves and analyzes the logs of the stress test traffic and the logs of the formal traffic through the full-link stress test platform to obtain probe data information, stress test data information and link data information; The capacity data is obtained by calculating and processing the probe data information, the stress test data information and the link data information.
7. The method according to claim 6, characterized in that The probe data information, the stress testing data information and the link data information are separated and stored through the full-link stress testing platform.
8. A full-link stress testing system, characterized in that: The full-link stress testing system includes a business scenario system and a full-link stress testing platform, wherein the business scenario system includes a business application system in which the probe is deployed, and the business application system includes at least a first business application system and a second business application system; A stress testing module is configured to perform a stress test on the first business application system according to the stress testing request received by the full-link stress testing platform, obtain a stress testing flow with a set stress testing target, perform identification processing through a probe deployed by the first business application, and separate and store the stress testing flow from a formal flow obtained by running the business scenario system; a transmission module configured to call the stress test request through the second business application system, obtain a transmission message of the stress test traffic and a transmission message of the formal traffic, and store the transmission message of the stress test traffic and the transmission message of the formal traffic separately; The stress test module is called, and is configured to obtain the business key information and log of the stress test traffic and the business key information and log of the formal traffic in response to determining that the stress test mark is transmitted to the second business application system, and perform identification processing through the probe deployed by the second business application system, separate the business key information of the stress test traffic from the business key information of the formal traffic for storage, and separate the log of the stress test traffic from the log of the formal traffic for storage; The parsing and processing module is configured to retrieve and parse the logs of the stress testing traffic and the logs of the formal traffic through the full-link stress testing platform based on the probe deployed by the second business application system to obtain capacity data.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method according to any one of claims 1 to 7 is implemented.
10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Pressure measurement data storage isolation method and device, computer equipment and storage medium
CN112287410A
Online full-link pressure measurement method and device and computer equipment
CN113254323A