Pressure measurement data filtering method and device, storage medium and computer equipment

By using a Bloom filter to identify performance stress test requests and generate unique identifiers, combined with a whitelist and a timed cleanup mechanism, the problem of dirty data caused by performance stress testing is solved, ensuring stable interface performance.

CN114238052BActive Publication Date: 2026-02-10PING AN TECH (SHENZHEN) CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202111534954.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-15
Publication Date
2026-02-10
Estimated Expiration
2041-12-15

AI Technical Summary

Technical Problem

In existing technologies, dirty data generated by performance stress testing leads to excessive data in database tables, low query efficiency, and affects the performance of routine tests.

Method used

Bloom filters are used to identify performance stress test requests, generate unique identifiers and store business data, and dirty data in the business data table is cleaned up periodically. The cleanup process is optimized through whitelist configuration.

Benefits of technology

Automatically and periodically clean up dirty data in business data tables to reduce the impact on routine testing, isolate the impact of performance stress testing, and ensure the normal operation of interfaces.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114238052B_ABST
    Figure CN114238052B_ABST
Patent Text Reader

Abstract

The application discloses a kind of pressure test data filtering method, device, storage medium and computer equipment, the method includes the following steps: receiving current test data request, and judge whether the data identification of current test data request is stored in Bloom filter;If yes, determine that the current test data request is performance stress test request, and generate unique identifier;The current test data request is sent to the communication interface of request, and the service data generated based on the current test data request is obtained by the communication interface;The service data generated and the unique identifier corresponding storage are stored in service data table;According to the unique identifier, the corresponding service data in the service data table is inquired, and the service data inquired is deleted.The application can automatically clean up dirty data caused by performance stress test, to reduce the influence on regular test.At the same time, the application also relates to blockchain technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and in particular to a method, apparatus, storage medium, and computer equipment for filtering stress test data. Background Technology

[0002] With the rapid development of the Internet and the popularity of microservice architecture, more and more companies are designing their systems to be service-oriented. In service-oriented design, services mainly interact with each other through interfaces, which become the channels for communication between systems.

[0003] In today's booming internet era, the number of system users is increasing dramatically, and the pressure on interfaces is also increasing dramatically. Therefore, interface performance testing has become increasingly important. By conducting interface performance testing before deployment, performance bottlenecks of the system and database can be identified in advance.

[0004] To make load testing more realistic, a large number of load test requests are typically made to the interface at a certain point in time to identify performance bottlenecks. This results in a large amount of dirty data being stored in the database. If this dirty data is not cleaned up, it will remain in the database, causing the database tables to grow larger and larger. The larger the database tables, the lower the query efficiency, thus affecting the performance of regular tests. Summary of the Invention

[0005] Based on this, the present invention addresses the problem in the prior art where a large amount of dirty data generated by performance stress testing affects routine testing by providing a stress test data filtering method, device, storage medium, and computer equipment.

[0006] To achieve the above objectives, the present invention provides a method for filtering stress test data, comprising the following steps:

[0007] Receive the current test data request and determine whether the data identifier of the current test data request is stored in the Bloom filter;

[0008] If so, determine that the current test data request is a performance stress test request, and generate a unique identifier;

[0009] Send the current test data request to the requested communication interface and obtain the business data generated by the communication interface based on the current test data request;

[0010] The generated business data and the unique identifier are stored in the business data table;

[0011] Periodically query the corresponding business data in the business data table based on the unique identifier, and delete the queried business data.

[0012] Furthermore, in the above-mentioned stress test data filtering method, the step of generating a unique identifier is preceded by:

[0013] Determine whether the requested communication interface is in the preset whitelist;

[0014] If not, proceed with the steps to generate a unique identifier.

[0015] Furthermore, in the above-described stress test data filtering method, before the step of determining whether the data identifier of the current test data request is stored in the Bloom filter, the method further includes:

[0016] The test process is divided into multiple test time periods based on a preset time frame. The data identifier for the performance test data request within the current test time period is obtained during the test process.

[0017] A Bloom filter is created based on the data identifiers acquired during the current test period.

[0018] Furthermore, in the above-mentioned stress test data filtering method, after the step of generating a unique identifier, the method further includes:

[0019] Store the unique identifier in the load test request data table;

[0020] The step of periodically querying the corresponding business data in the business data table based on the unique identifier includes:

[0021] Periodically query the corresponding business data in the business data table based on each unique identifier in the load test request data table.

[0022] Furthermore, in the above-mentioned stress test data filtering method, after the step of deleting the queried business data, the method further includes:

[0023] Delete the data from the load test request data table.

[0024] Furthermore, the above-mentioned stress test data filtering method further includes, after the step of determining whether the data identifier of the current test data request is stored in the Bloom filter:

[0025] When the data identifier of the current test data request is not stored in the Bloom filter, the current test data request is sent to the requested communication interface;

[0026] Obtain the business data generated by the communication interface based on the current test data request, and store the generated business data in the business data table.

[0027] Preferably, the results of the above-mentioned stress test data filtering method can be uploaded to the blockchain so that the blockchain can encrypt and store the results of the stress test data filtering method.

[0028] To achieve the above objectives, the present invention also discloses a pressure test data filtering device, comprising:

[0029] The first judgment module is used to receive the current test data request and determine whether the data identifier of the current test data request is stored in the Bloom filter;

[0030] The identifier generation module is used to determine that the current test data request is a performance stress test request when the data identifier of the current test data request is stored in the Bloom filter, and to generate a unique identifier.

[0031] The first acquisition module is used to send the current test data request to the requesting communication interface and acquire the business data generated by the communication interface based on the current test data request.

[0032] The first storage module is used to store the generated business data and the unique identifier in the business data table;

[0033] The first deletion module is used to periodically query the corresponding business data in the business data table based on the unique identifier, and delete the queried business data.

[0034] Furthermore, the aforementioned pressure test data filtering device also includes:

[0035] The second judgment module is used to determine whether the requested communication interface is in the preset whitelist. If not, the identifier generation module performs the step of generating a unique identifier.

[0036] Furthermore, the aforementioned pressure test data filtering device also includes:

[0037] The second acquisition module is used to acquire the data identifier of the performance test data request within the current test time period during the test process. The test process is divided into multiple test time periods according to a preset time.

[0038] A module is created to build a Bloom filter based on the data identifiers acquired during the current test period.

[0039] Furthermore, the aforementioned pressure test data filtering device also includes:

[0040] The second storage module is used to store the unique identifier in the stress test request data table;

[0041] The deletion module is specifically used for:

[0042] Periodically query the corresponding business data in the business data table based on each unique identifier in the load test request data table.

[0043] Furthermore, the aforementioned pressure test data filtering device also includes:

[0044] The second deletion module is used to delete data from the load test request data table.

[0045] Furthermore, the aforementioned pressure test data filtering device also includes:

[0046] The sending module is used to send the current test data request to the requested communication interface when the data identifier of the current test data request is not stored in the Bloom filter;

[0047] The third storage module is used to obtain the business data generated by the communication interface based on the current test data request, and store the generated business data in the business data table.

[0048] To achieve the above objectives, the present invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the stress test data filtering method described above.

[0049] To achieve the above objectives, the present invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the stress test data filtering method described above.

[0050] The present invention provides a stress test data filtering method, apparatus, storage medium, and computer equipment that can automatically and periodically clean up dirty data caused by performance stress tests in the business data table, and promptly clean up useless data in the business data table to reduce the impact on regular tests; furthermore, by using a Bloom filter to identify whether a request is a performance stress test request, the impact on non-performance stress test requests is isolated, ensuring that non-performance stress tests of the interface are not affected. Attached Figure Description

[0051] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0052] Figure 1 This is a schematic diagram of an application environment for a pressure test data filtering method according to an embodiment of the present invention;

[0053] Figure 2 This is a flowchart of a pressure test data filtering method in one embodiment of the present invention;

[0054] Figure 3 This is a flowchart of a pressure test data filtering method in another embodiment of the present invention;

[0055] Figure 4 This is a flowchart of a pressure test data filtering method in another embodiment of the present invention;

[0056] Figure 5 This is a schematic diagram of the structure of a pressure test data filtering device in one embodiment of the present invention;

[0057] Figure 6 This is a schematic diagram of a computer device according to an embodiment of the present invention. Detailed Implementation

[0058] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0059] The stress test data filtering method provided in this application can be applied to applications such as... Figure 1 The computer device can communicate with the server via a network. This computer device includes, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server can be a standalone server or a server cluster consisting of multiple servers.

[0060] In one embodiment, such as Figure 2 As shown, a method for filtering load test data is provided, which is then applied to... Figure 1 The following steps, S11 to S16, are used as an example of computer equipment.

[0061] Step S11: Receive the current test data request and determine whether the data identifier of the current test data request is stored in the Bloom filter.

[0062] Communication interfaces serve as communication channels between various systems. Before a system goes live, all communication interfaces need to be tested, including performance stress testing and some routine tests. These routine tests include, for example, testing the correctness of interface parameter passing, the correctness of interface function implementation, the correctness of test output results, and the completeness and rationality of fault tolerance handling for various abnormal situations. During performance stress testing, a large number of performance stress test requests are sent to the server, which then forwards these requests to the corresponding communication ports.

[0063] Understandably, during communication interface testing, in addition to sending stress test requests to the server, regular test requests are also sent. Typically, the business data generated after these stress test requests and regular test requests are sent to the communication port are identical in characteristics and are both stored in the business data table after communication is disconnected. This results in a large business data table, slow operation, and thus affects the performance of regular tests. Therefore, it is necessary to delete the large amount of dirty data generated by the stress test from this business data table to ensure the normal operation of regular tests.

[0064] To distinguish between normal test requests and performance stress test requests received at the moment, this embodiment introduces a Bloom filter. A Bloom filter, similar to a hash set, is an algorithm for quickly determining whether a given element (key) exists in the set. Unlike a typical hash set, this algorithm does not need to store the key's value; for each key, only k bits are needed, each storing a flag to determine if the key is in the set. Bloom filters offer very high insertion and query efficiency and consume very little memory.

[0065] In this embodiment, a Bloom filter is pre-created on the server side, and the data identifiers of all performance stress test requests required for this test are pre-written into the Bloom filter. These data identifiers, such as application numbers, are used to determine whether the current test data request is a performance stress test request based on whether its data identifier exists in the Bloom filter. Throughout the testing phase, all test data requests are filtered through this Bloom filter to identify each performance stress test data request in real time.

[0066] This data identifier can be the application number carried in the test data request. That is, each test data request is assigned a unique application number, which is used to identify whether it is a performance stress test request or a regular test request.

[0067] Step S12: If yes, determine that the current test data request is a performance stress test request.

[0068] Step S13: Generate a unique identifier.

[0069] When the system determines that the currently received test data request is a performance requirement test request, it generates a unique identifier. In practice, this unique identifier can be an automatically generated unique serial number, or it can be generated based on the request content and data identifier corresponding to the current test data request.

[0070] Step S14: Send the current test data request to the requested communication interface, and obtain the business data generated by the communication interface based on the current test data request.

[0071] Step S15: Store the generated business data and the unique identifier in the business data table.

[0072] In practice, this test data request can be used to test one or more communication interfaces. The test data request is sent to the corresponding communication interface to be tested. The communication interface generates corresponding business data based on the test data request, and the business data of each communication interface is stored in the corresponding business data table.

[0073] When a performance stress test request is sent to a specific communication interface, the business data table involved in the actual stress test interface, in addition to storing the business data processed by the business itself, also needs to store the previously generated unique identifier. This associates the record of this stress test request with the business data in the actual business data table. After the performance stress test is completed, all stress test requests can be associated with the business data in the actual business table.

[0074] It should be noted that when the unique identifier and the corresponding business data are stored in the business data table, they can be stored in two different columns of the business data table according to the mapping relationship, or the unique identifier and the business data can be connected with a special symbol to form a new data storage in the business data table.

[0075] Step S16: Periodically query the corresponding business data in the business data table based on the unique identifier, and delete the queried business data.

[0076] During communication interface testing, the generated business data is stored in a business data table in real time. To minimize the impact on the test environment, dirty data related to performance stress testing in the business data table can be cleaned periodically. This means that the business data table should be cleaned at a specific time to ensure the normal operation of communication interface testing. Understandably, the cleanup schedule for the business data table can be set according to the user's actual needs; it can be cleaned daily, every three days, or weekly, depending on the specific testing requirements. For example, a scheduled task can be created to clean the business data table at 00:00 every day.

[0077] When cleaning up dirty data, the system queries the corresponding business data table based on a unique identifier generated by the system. If the corresponding business data is found, it is deleted from the business data table. This process automatically removes business data generated during performance stress testing, reducing the impact on regular tests. Furthermore, since regular test data is not included in the Bloom filter, it isolates the impact on non-performance stress test requests.

[0078] The load test data filtering method provided in this embodiment of the invention can automatically and periodically clean up dirty data caused by performance stress testing in the business data table, and promptly clean up useless data in the business data table to reduce the impact on regular testing; furthermore, by using a Bloom filter to identify whether it is a performance stress test request, the impact on non-performance stress test requests is isolated, ensuring that non-performance stress testing of the interface is not affected.

[0079] Furthermore, in one embodiment of the present invention, the step of generating a unique identifier is followed by the following step:

[0080] Store the unique identifier in the load test request data table;

[0081] The step of periodically querying the corresponding business data in the business data table based on the unique identifier includes:

[0082] The load test request data table is scanned periodically, and the corresponding business data in the business data table is queried based on the currently scanned unique identifier.

[0083] This involves pre-establishing a load testing request data table in the server-side system. Once a unique identifier is generated, it is stored in this table. A pre-defined scheduled task scans the load testing request data table for unique identifiers at regular intervals. After scanning, the task queries the business data table for records based on all unique identifiers found in the load testing request data table. Once a record is found in the business data table, it is deleted.

[0084] Furthermore, after determining whether the data identifier of the current test data request is stored in the Bloom filter, the following steps are also included:

[0085] When the data identifier of the current test data request is not stored in the Bloom filter, the current test data request is sent to the requested communication interface;

[0086] Obtain the business data generated by the communication interface based on the current test data request, and store the generated business data in the business data table.

[0087] When test data requests are sent to a specific communication interface during routine testing, the corresponding business data is also stored in the business data table associated with that communication interface. Unlike performance stress testing, the business data for routine testing does not need to store unique identifiers. Understandably, business data generated during normal operation will also be stored in this business data table.

[0088] Furthermore, the step of deleting the retrieved business data described above also includes the following steps:

[0089] Delete the data from the load test request data table.

[0090] After deleting dirty data from the business data table, the records in the load test request data table become meaningless. All records in the load test request data table need to be cleared to free up memory and facilitate subsequent performance stress testing.

[0091] In this embodiment, when initiating a performance stress test, the data identifier for the performance stress test, such as the order number, is pre-placed in a Bloom filter. When the server receives a test data request, it determines whether it is a performance stress test request based on whether the data identifier is in the Bloom filter. If it is a performance stress test request, a unique identifier is generated and stored in the stress test request data table A. The server pre-establishes a stress test request data table to store the unique identifiers of performance stress test requests. When requesting a specific communication interface for the performance stress test, in addition to storing the business data involved in the actual stress test communication interface, the previously generated unique identifier is also stored. This associates the record of this performance stress test request with the business data in the actual business processing table. After the performance stress test is completed, all performance stress test requests can be associated with the data in the actual business table. A scheduled task is set up to scan the load test request data table at a preset time each day to minimize the impact on the test environment. After scanning, the task queries the business data table for records based on all unique identifiers in the load test request data table. Once a record is found in the business data table, it is deleted, thus achieving the goal of timely cleaning up dirty data. It should be noted that the load test request data table only stores records of performance load test requests and therefore will not affect the business data of the actual load test interface.

[0092] Furthermore, such as Figure 3 As shown, in another embodiment of the present invention, the step of generating a unique identifier is further included before:

[0093] Step S21: Determine whether the requested communication interface is in the preset whitelist. If not, execute the step of generating a unique identifier.

[0094] Cleaning up dirty data in business data tables often disrupts communication port testing, sometimes even requiring interruptions. Furthermore, in practice, not every communication interface's business data table needs dirty data processing. For example, some communication interfaces involve fewer performance stress tests, or some critical interfaces require continuous and normal testing. For these interfaces, dirty data processing is unsuitable, and therefore, generating unique identifiers is unnecessary.

[0095] To address this issue, a whitelist can be pre-established, adding communication interfaces that do not require dirty data processing to the pre-defined list. In practice, the port identifiers of the communication ports need to be stored in this whitelist. When a test data request is determined to be a performance stress test request, the port identifier of the requesting communication port is compared with the port identifiers recorded in the whitelist. If the requested communication port identifier is in the whitelist, the test is performed as a regular test request; otherwise, if the requested communication port identifier is not in the whitelist, the step of generating a unique identifier is executed.

[0096] In this embodiment, not only can dirty data caused by performance stress testing be automatically cleared, reducing the impact on regular testing, but also, if the data of a certain stress testing interface does not need to be cleared, a whitelist can be configured to individually configure interfaces that do not need to have their data cleared.

[0097] The load test data filtering method provided in this embodiment can configure separate load test data that does not need to be cleared by configuring a whitelist. When adding a new interface that does not need to clear load test data, the whitelist setting method is quick, convenient and flexible.

[0098] Furthermore, such as Figure 4 As shown, in another embodiment of the present invention, the step of determining whether the data identifier of the current test data request is stored in the Bloom filter further includes:

[0099] Step S31: Obtain the data identifier of the performance test data request within the current test time period during the test process. The test process is divided into multiple test time periods according to a preset time.

[0100] Step S32: Build a Bloom filter based on the data identifiers obtained during the current test period.

[0101] Bloom filters can effectively determine whether a current test request is a performance stress test request. However, due to the inherent characteristics of Bloom filters, deletion operations are not supported; data identifiers previously placed into the Bloom filter cannot be deleted. Therefore, placing a large number of data identifiers into the Bloom filter reduces its space efficiency and query efficiency.

[0102] To improve the data filtering efficiency of Bloom filters, a new Bloom filter can be created at regular intervals throughout the testing phase, and the Bloom filters can be replaced periodically to ensure their working efficiency.

[0103] Understandably, in this embodiment, after cleaning up the dirty data in the current test period, the next test period begins, the data identifier of the performance test data request for the next test phase is obtained, and the process returns to step S32, that is, a Bloom filter is established based on the data identifier of the performance test data request in the next time period, and dirty data is filtered.

[0104] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.

[0105] In an alternative implementation, the results of the above-described stress test data filtering method can also be uploaded to the blockchain.

[0106] Specifically, based on the results of the stress test data filtering method, corresponding digest information is obtained. More specifically, the digest information is obtained by hashing the results of the stress test data filtering method, for example, using the SHA256s algorithm. Uploading the digest information to the blockchain ensures its security and fairness and transparency to users. Users can download the digest information from the blockchain to verify whether the results of the stress test data filtering method have been tampered with. The blockchain referred to in this example is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. A blockchain is essentially a decentralized database, a chain of data blocks linked using cryptographic methods. Each data block contains information about a batch of network transactions, used to verify the validity of the information (anti-counterfeiting) and generate the next block. A blockchain can include a blockchain underlying platform, a platform product service layer, and an application service layer.

[0107] like Figure 5 As shown, in one embodiment, a pressure test data filtering device is provided, comprising:

[0108] The first judgment module 10 is used to receive the current test data request and determine whether the data identifier of the current test data request is stored in the Bloom filter;

[0109] The identifier generation module 20 is used to determine that the current test data request is a performance stress test request and generate a unique identifier when the data identifier of the current test data request is stored in the Bloom filter;

[0110] The first acquisition module 30 is used to send the current test data request to the requesting communication interface and acquire the business data generated by the communication interface based on the current test data request.

[0111] The first storage module 40 is used to store the generated business data and the unique identifier in the business data table;

[0112] The first deletion module 50 is used to periodically query the corresponding business data in the business data table based on the unique identifier, and delete the queried business data.

[0113] Furthermore, the aforementioned pressure test data filtering device also includes:

[0114] The second judgment module is used to determine whether the requested communication interface is in the preset whitelist. If not, the identifier generation module performs the step of generating a unique identifier.

[0115] Furthermore, the aforementioned pressure test data filtering device also includes:

[0116] The second acquisition module is used to acquire the data identifier of the performance test data request within the current test time period during the test process. The test process is divided into multiple test time periods according to a preset time.

[0117] A module is created to build a Bloom filter based on the data identifiers acquired during the current test period.

[0118] Furthermore, the aforementioned pressure test data filtering device also includes:

[0119] The second storage module is used to store the unique identifier in the stress test request data table;

[0120] The deletion module is specifically used for:

[0121] Periodically query the corresponding business data in the business data table based on each unique identifier in the load test request data table.

[0122] Furthermore, the aforementioned pressure test data filtering device also includes:

[0123] The second deletion module is used to delete data from the load test request data table.

[0124] Furthermore, the aforementioned pressure test data filtering device also includes:

[0125] The sending module is used to send the current test data request to the requested communication interface when the data identifier of the current test data request is not stored in the Bloom filter;

[0126] The third storage module is used to obtain the business data generated by the communication interface based on the current test data request, and store the generated business data in the business data table.

[0127] The pressure test data filtering device provided in this embodiment of the invention has the same implementation principle and technical effect as the aforementioned method embodiment. For the sake of brevity, any parts not mentioned in the device embodiment can be referred to the corresponding content in the aforementioned method embodiment.

[0128] The load test data filtering device provided in this embodiment of the invention can automatically and periodically clean up dirty data caused by performance stress testing in the business data table, and promptly clean up useless data in the business data table to reduce the impact on regular testing; furthermore, by using a Bloom filter to identify whether it is a performance stress test request, it isolates the impact on non-performance stress test requests, ensuring that non-performance stress testing of the interface is not affected.

[0129] The terms "first" and "second" in the above-mentioned modules / units are only used to distinguish different modules / units and are not intended to specify which module / unit has a higher priority or any other limiting meaning. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or modules is not necessarily limited to those steps or modules explicitly listed, but may include other steps or modules not explicitly listed or inherent to these processes, methods, products, or devices. The module divisions appearing in this application are merely logical divisions; in actual applications, different division methods may be used.

[0130] Specific limitations regarding the load test data filtering device can be found in the limitations of the load test data filtering method described above, and will not be repeated here. Each module in the aforementioned load test data filtering device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.

[0131] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 6As shown, the computer device includes a processor, memory, network interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The network interface is used to communicate with an external server via a network connection. When the computer program is executed by the processor, it implements a stress test data filtering method.

[0132] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the stress test data filtering method described in the above embodiments, for example... Figure 2 The steps S11 to S16 shown, as well as other extensions and related steps of the method, are examples. Alternatively, when the processor executes the computer program, it implements the functions of each module / unit of the pressure test data filtering device in the above embodiments, for example... Figure 5 The functions of modules 10 to 50 are shown. To avoid repetition, they will not be described again here.

[0133] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the computer device, connecting various parts of the computer device via various interfaces and lines.

[0134] The memory can be used to store the computer programs and / or modules. The processor implements various functions of the computer device by running or executing the computer programs and / or modules stored in the memory and by calling data stored in the memory. The memory may mainly include a program storage area and a data storage area. The program storage area may store the operating system, applications required for at least one function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created based on the use of the mobile phone (such as audio data, video data, etc.).

[0135] The memory can be integrated into the processor or it can be set up separately from the processor.

[0136] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When executed by a processor, the computer program implements the steps of the stress test data filtering method described in the above embodiments, for example... Figure 2 The steps S11 to S16 shown, as well as other extensions and related steps of the method, are examples. Alternatively, when a computer program is executed by a processor, it implements the functions of each module / unit of the pressure test data filtering device in the above embodiments, for example... Figure 5 The functions of modules 10 to 50 are shown. To avoid repetition, they will not be described again here.

[0137] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0138] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0139] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.

Claims

1. A method for filtering pressure test data, characterized in that, Including the following steps: Receive the current test data request and determine whether the data identifier of the current test data request is stored in the Bloom filter; The Bloom filter is replaced periodically; before the step of determining whether the data identifier of the current test data request is stored in the Bloom filter, the method further includes obtaining the data identifier of the performance test data request within the current test time period during the test process, wherein the test process is divided into multiple test time periods according to a preset time; and establishing a Bloom filter based on the data identifier obtained within the current test time period. If so, determine that the current test data request is a performance stress test request, and generate a unique identifier; The unique identifier is a unique serial number generated based on the request content and data identifier corresponding to the current test data request, which corresponds to the data request. Send the current test data request to the requested communication interface and obtain the business data generated by the communication interface based on the current test data request; The generated business data and the unique identifier are stored in the business data table; Periodically query the corresponding business data in the business data table based on the unique identifier, and delete the queried business data; Obtain the data identifier of the performance test data request for the next test period, and build a Bloom filter based on the data identifier of the performance test data request for the next test period.

2. The pressure test data filtering method as described in claim 1, characterized in that, The step of generating a unique identifier is preceded by: Determine whether the requested communication interface is in the preset whitelist; If not, proceed with the steps to generate a unique identifier.

3. The pressure test data filtering method as described in claim 1, characterized in that, The step of generating a unique identifier is followed by: Store the unique identifier in the load test request data table; The step of periodically querying the corresponding business data in the business data table based on the unique identifier includes: Periodically query the corresponding business data in the business data table based on each unique identifier in the load test request data table.

4. The pressure test data filtering method as described in claim 3, characterized in that, The step of deleting the retrieved business data further includes: Delete the data from the load test request data table.

5. The pressure test data filtering method as described in claim 1, characterized in that, After determining whether the data identifier of the current test data request is stored in the Bloom filter, the method further includes: When the data identifier of the current test data request is not stored in the Bloom filter, the current test data request is sent to the requested communication interface; Obtain the business data generated by the communication interface based on the current test data request, and store the generated business data in the business data table.

6. A pressure test data filtering device, characterized in that, include: The second acquisition module is used to acquire the data identifier of the performance test data request within the current test time period during the test process. The test process is divided into multiple test time periods according to a preset time. A module is created to build a Bloom filter based on the data identifiers acquired during the current test period. The first judgment module is used to receive the current test data request and determine whether the data identifier of the current test data request is stored in the Bloom filter; The Bloom filter is replaced periodically; The identifier generation module is used to determine that the current test data request is a performance stress test request when the data identifier of the current test data request is stored in the Bloom filter, and to generate a unique identifier. The unique identifier is a unique serial number generated based on the request content and data identifier corresponding to the current test data request, which corresponds to the data request. The first acquisition module is used to send the current test data request to the requesting communication interface and acquire the business data generated by the communication interface based on the current test data request. The first storage module is used to store the generated business data and the unique identifier in the business data table; The first deletion module is used to periodically query the corresponding business data in the business data table based on the unique identifier, and delete the queried business data. The second acquisition module is also used to acquire the data identifier of the performance test data request for the next test period; The establishment module is also used to establish a Bloom filter based on the data identifier of the performance test data request in the next test period.

7. The pressure test data filtering device as described in claim 6, characterized in that, Also includes: The second judgment module is used to determine whether the requested communication interface is in the preset whitelist. If not, the identifier generation module performs the step of generating a unique identifier.

8. A computer 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 computer program, it implements the steps of the stress test data filtering method as described in any one of claims 1 to 5.

9. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the stress test data filtering method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Data query method and apparatus

    CN105718455A

  • Data processing method and device, application server and storage medium

    CN109871320A

  • Pressure measurement data storage isolation method and device, computer equipment and storage medium

    CN112287410A