CN116737576A - System testing method and device - Google Patents

System testing method and device Download PDF

Info

Publication number
CN116737576A
CN116737576A CN202310734485.6A CN202310734485A CN116737576A CN 116737576 A CN116737576 A CN 116737576A CN 202310734485 A CN202310734485 A CN 202310734485A CN 116737576 A CN116737576 A CN 116737576A
Authority
CN
China
Prior art keywords
transaction
test
information
request
processing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310734485.6A
Other languages
Chinese (zh)
Inventor
王川
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Construction Bank Corp
CCB Finetech Co Ltd
Original Assignee
China Construction Bank Corp
CCB Finetech Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Construction Bank Corp, CCB Finetech Co Ltd filed Critical China Construction Bank Corp
Priority to CN202310734485.6A priority Critical patent/CN116737576A/en
Publication of CN116737576A publication Critical patent/CN116737576A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/324Display of status information
    • G06F11/327Alarm or error message display
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3409Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment for performance assessment

Abstract

The invention discloses a system testing method and device, and relates to the technical field of software testing. One embodiment of the method comprises the following steps: generating a plurality of transaction test requests; acquiring transaction initiation information of each transaction test request, and sending the transaction test requests to a tested system; wherein the transaction initiation information includes: request identification and initiation time; acquiring transaction processing information of the tested system for each transaction test request; wherein the transaction processing information includes: request identification, processing start time and processing end time; generating a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining a system test result of the tested system according to the transaction association records. The embodiment can accurately acquire the performance condition of the asynchronous processing system.

Description

System testing method and device
Technical Field
The present invention relates to the field of software testing technologies, and in particular, to a system testing method and apparatus.
Background
In an asynchronous processing system, online transaction is only used as a trigger for data processing, and after the online transaction request is received by the system, the system performs data processing according to a certain scheduling mode, and after the processing is completed, callback is performed or the data state is modified. For the services with low real-time requirements, long time consumption and large resource consumption, such as calling external services, notifying payment results, online processing of audio and video, and the like, the method is suitable for adopting an asynchronous processing mode.
The traditional performance testing tool and method mainly aims at testing a synchronous processing system. The performance testing tools and the performance testing methods simulate multi-user parallel initiation of online transactions, then obtain response information, and further count performance indexes such as response delay, throughput and the like. Conventional performance testing tools and methods are unable to accurately obtain the performance of an asynchronous processing system.
Disclosure of Invention
In view of this, the embodiment of the invention provides a system testing method and device, which can accurately acquire the performance condition of an asynchronous processing system.
In a first aspect, an embodiment of the present invention provides a system testing method, including:
generating a plurality of transaction test requests;
acquiring transaction initiation information of each transaction test request, and sending the transaction test requests to a tested system; wherein the transaction initiation information includes: request identification and initiation time;
acquiring transaction processing information of the tested system for each transaction test request; wherein the transaction processing information includes: request identification, processing start time and processing end time;
generating a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining a system test result of the tested system according to the transaction association records.
Optionally, the acquiring the transaction initiation information of each transaction test request includes:
intercepting each transaction test request by using a pressure generating agent, and acquiring transaction initiation information of each transaction test request;
the acquiring transaction processing information of the tested system for each transaction test request includes:
and acquiring transaction processing information of the tested system for each transaction test request by using a service probe.
Optionally, the generating a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request includes:
receiving transaction initiation information of each transaction test request sent by the pressure generating agent;
receiving transaction processing information of each transaction test request sent by the service probe;
carrying out association processing on the transaction initiating information and the transaction processing information by using the request identification to generate a plurality of transaction association records; wherein, the transaction association record comprises: request identification, initiation time, processing start time, and processing end time.
Optionally, the determining a system test result of the tested system according to the transaction association records includes:
acquiring transaction association records corresponding to all transaction types;
and generating a system test result of the tested system for each transaction type according to the transaction association record corresponding to each transaction type.
Optionally, after generating the system test result of the tested system for each transaction type according to the transaction association record corresponding to each transaction type, the method further includes:
determining display information corresponding to the transaction type;
and loading the system test result of the transaction type according to the display information to generate a test result report of the tested system.
Optionally, after determining the system test result of the tested system according to the transaction association records, the method further includes:
determining whether a system test result of the tested system meets a first test condition;
responding to the system test result of the tested system to meet the first test condition, and acquiring resource condition information of the tested system;
and generating a test result report of the tested system according to the system test result and the resource condition information.
Optionally, after determining the system test result of the tested system according to the transaction association records, the method further includes:
determining whether a system test result of the tested system meets a second test condition;
responding to the system test result of the tested system to meet the second test condition, generating a next batch of test requests, and sending the next batch of test requests to the tested system to be tested;
and generating alarm information that the tested system fails to pass the test and check in response to the system test result of the tested system not meeting the second check condition.
In a second aspect, an embodiment of the present invention provides a system testing apparatus, including:
the request generation module is used for generating a plurality of transaction test requests;
the first acquisition module is used for acquiring transaction initiation information of each transaction test request and sending the transaction test requests to a tested system; wherein the transaction initiation information includes: request identification and initiation time;
the second acquisition module is used for acquiring transaction processing information of the tested system for each transaction test request; wherein the transaction processing information includes: request identification, processing start time and processing end time;
the result generation module is used for generating a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining the system test result of the tested system according to the transaction association records.
Optionally, the first obtaining module is specifically configured to:
intercepting each transaction test request by using a pressure generating agent, and acquiring transaction initiation information of each transaction test request;
the second obtaining module is specifically configured to:
and acquiring transaction processing information of the tested system for each transaction test request by using a service probe.
Optionally, the result generation module is specifically configured to:
receiving transaction initiation information of each transaction test request sent by the pressure generating agent;
receiving transaction processing information of each transaction test request sent by the service probe;
carrying out association processing on the transaction initiating information and the transaction processing information by using the request identification to generate a plurality of transaction association records; wherein, the transaction association record comprises: request identification, initiation time, processing start time, and processing end time.
Optionally, the result generation module is specifically configured to:
acquiring transaction association records corresponding to all transaction types;
and generating a system test result of the tested system for each transaction type according to the transaction association record corresponding to each transaction type.
Optionally, the method further comprises:
the report generation module is used for determining display information corresponding to the transaction type;
and loading the system test result of the transaction type according to the display information to generate a test result report of the tested system.
Optionally, the report generating module is further configured to:
determining whether a system test result of the tested system meets a first test condition;
responding to the system test result of the tested system to meet the first test condition, and acquiring resource condition information of the tested system;
and generating a test result report of the tested system according to the system test result and the resource condition information.
In a third aspect, an embodiment of the present invention provides an electronic device, including:
one or more processors;
storage means for storing one or more programs,
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the methods of any of the embodiments described above.
In a fourth aspect, embodiments of the present invention provide a computer readable medium having stored thereon a computer program which, when executed by a processor, implements a method as described in any of the above embodiments.
In a fifth aspect, embodiments of the present invention provide a computer program product comprising a computer program which, when executed by a processor, implements a method as described in any of the above embodiments.
One embodiment of the above invention has the following advantages or benefits: when the tested system is an asynchronous processing system, in the process of testing the tested system, not only transaction processing information of each transaction test request is obtained, but also transaction initiating information of each transaction test request is obtained. By integrating the transaction processing information and the transaction initiating information of each transaction test request, a plurality of transaction association records are generated, and performance indexes such as the total number of asynchronous processing tasks, average processing delay, processing efficiency and the like of the tested system can be accurately obtained, so that the real performance condition of the tested system is obtained.
Further effects of the above-described non-conventional alternatives are described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a flow chart of a system testing method according to a first embodiment of the present invention;
FIG. 2 is a flow chart of a system testing method according to a second embodiment of the present invention;
FIG. 3 is a flow chart of a system testing method according to a third embodiment of the present invention;
FIG. 4 is a schematic diagram of a system architecture of a test system according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of a system testing device according to an embodiment of the present invention;
fig. 6 is a schematic diagram of a computer system suitable for use in implementing an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention will now be described with reference to the accompanying drawings, in which various details of the embodiments of the present invention are included to facilitate understanding, and are to be considered merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
In the technical scheme of the invention, the aspects of acquisition, analysis, use, transmission, storage and the like of the related user personal information all meet the requirements of related laws and regulations, are used for legal and reasonable purposes, are not shared, leaked or sold outside the aspects of legal use and the like, and are subjected to supervision and management of a supervision department. Necessary measures should be taken for the personal information of the user to prevent illegal access to such personal information data, ensure that personnel having access to the personal information data comply with the regulations of the relevant laws and regulations, and ensure the personal information of the user. Once these user personal information data are no longer needed, the risk should be minimized by limiting or even prohibiting the data collection and/or deletion.
Fig. 1 is a flow chart of a system testing method according to a first embodiment of the present invention, as shown in fig. 1, the method includes:
step 101: a plurality of transaction test requests are generated.
Multiple concurrent transaction test requests may be generated using a test tool, such as Jmeter, loadrunner, to simulate user operations.
Step 102: acquiring transaction initiation information of each transaction test request, and sending the transaction test request to a tested system; wherein the transaction initiation information includes: request identification and initiation time.
The request identification is used to identify a transaction test request. The initiation time is the time at which the transaction test request is sent to the system under test.
Step 103: acquiring transaction processing information of a tested system aiming at each transaction test request; wherein the transaction processing information includes: request identification, processing start time, and processing end time.
The system under test is an asynchronous processing system. The processing start time is the start time of the tested system to process the transaction test request. The processing end time is the end time of the tested system for finishing the processing of the transaction test request.
Step 104: generating a plurality of transaction related records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining a system test result of the tested system according to the transaction related records.
Each transaction initiating message and transaction processing message contains a request identifier. And through the request identification, the transaction initiating information and the transaction processing information which have the same request identification are associated into a transaction association record. The transaction association record contains relevant test information of the same transaction test request. The transaction association record includes: request identification, initiation time, processing start time, processing end time, etc. And generating a test result of the transaction test request according to the transaction association record. And synthesizing the test results of the transaction test requests to obtain the system test result of the tested system.
The system test results may include a plurality of performance metrics such as total number of asynchronous processing tasks, average processing delay, processing efficiency, etc. The calculation logic of each performance index can be preset in the system, and is constructed based on transaction initiation information and transaction processing information. For example, the difference between the initiation time and the processing start time of the transaction test request is the processing delay of the transaction test request. The processing delay of each transaction test request is the average processing delay of the tested system. And calculating the average processing time length of the tested system according to the processing start time and the processing end time of each transaction test request.
After the system test result of the tested system is generated, the optimization strategy information of the tested system can be determined according to the system test result; and carrying out optimization processing on the tested system according to the optimization strategy information.
The optimization strategy information may include: emptying request wait queues, allocating additional system resources, shutting down processes running beyond a time threshold, reallocating system resources, etc. The mapping relation between the value range of the performance index and the optimization strategy information can be preset in the system. For example, if the average processing delay is greater than the delay threshold, then optimizing the policy information allocates additional system resources; and if the total number of the asynchronous processing tasks is greater than the number threshold, optimizing strategy information to empty a request waiting queue and the like. And determining the optimization strategy information of the tested system through the system test result so as to ensure the normal operation of the tested system and reduce the occurrence of server downtime and the like.
In the embodiment of the invention, under the condition that the tested system is an asynchronous processing system, in the process of carrying out system test on the tested system, not only the transaction processing information of each transaction test request, but also the transaction initiating information of each transaction test request are obtained. By comprehensively considering the transaction processing information and the transaction initiating information of each transaction test request, performance indexes such as the total number of asynchronous processing tasks, average processing delay, processing efficiency and the like of the tested system can be accurately obtained, and therefore the real performance condition of the tested system is obtained.
Fig. 2 is a flow chart of a system testing method according to a second embodiment of the present invention, as shown in fig. 2, the method includes:
step 201: a plurality of transaction test requests are generated.
Step 202: intercepting each transaction test request by using a pressure sending agent, and acquiring transaction initiation information of each transaction test request; wherein the transaction initiation information includes: request identification and initiation time.
The compression proxy may employ proxy software or a proxy server. After the transaction test request is generated, the transaction test request is intercepted by the pressure generating agent, and transaction initiation information is obtained.
Step 203: and sending the transaction test request to the tested system.
Step 204: acquiring transaction processing information of a tested system aiming at each transaction test request by using a service probe; wherein the transaction processing information includes: request identification, processing start time, and processing end time.
Step 205: receiving transaction initiation information of each transaction test request sent by a pressure receiving agent; transaction processing information of each transaction test request sent by the service probe is received.
Step 206: carrying out association processing on transaction initiating information and transaction processing information by using the request identifier to generate a plurality of transaction association records; wherein, the transaction association record comprises: request identification, initiation time, processing start time, and processing end time.
And carrying out association processing on transaction initiating information sent by the transmitting agent and transaction processing information sent by the service probe by using the request identifier to generate a plurality of transaction association records.
Step 207: and generating a system test result of the tested system according to the transaction association records.
Each transaction initiating message and transaction processing message contains a request identifier. And combining the transaction initiating information and the transaction processing information with the same request identifier into a transaction association record through the request identifier. The transaction association record contains relevant test information of the same transaction test request. And generating a test result of the transaction test request according to the transaction association record. And synthesizing the test results of the transaction test requests to obtain the system test result of the tested system.
In the scheme of the embodiment of the invention, the service probe is utilized to inject the tested service, and transaction processing information asynchronously processed by the tested service is recorded. The service probe adopts byte code enhancement technology, so that the code transformation of a tested system is not needed, the system service is not invaded, and the operation and maintenance of the system and the subsequent upgrading and transformation of the system are facilitated.
In one embodiment of the invention, determining a system test result of a system under test based on a plurality of transaction association records comprises: acquiring transaction association records corresponding to all transaction types; and generating a system test result of the tested system aiming at each transaction type according to the transaction association record corresponding to each transaction type.
The transaction type may be set according to business requirements. Different performance indexes and index calculation formulas can be set for different transaction types. And carrying out association processing on the transaction initiating information and the transaction processing information by using the request identification to generate a plurality of transaction association records. And obtaining the transaction type corresponding to each transaction association record. And calculating the performance index value of the tested system corresponding to each transaction type according to the transaction association record corresponding to each transaction type, the performance index corresponding to each transaction type and the index calculation formula.
In one embodiment of the present invention, after generating the system test result of the tested system for each transaction type, the method further comprises: determining display information corresponding to the transaction type; and loading a system test result of the transaction type according to the display information to generate a test result report of the tested system.
The presentation information may include: display position, display mode and the like in the test result report. The display modes can comprise: show fonts, show sizes, show ordering, etc. According to the display information corresponding to each transaction type, determining the display position corresponding to each transaction type, and displaying the index value corresponding to each transaction type in a display mode at the display position corresponding to each transaction type.
Fig. 3 is a flow chart of a system testing method according to a third embodiment of the present invention, as shown in fig. 3, the method includes:
step 301: a plurality of transaction test requests are generated.
Step 302: acquiring transaction initiation information of each transaction test request, and sending the transaction test request to a tested system; wherein the transaction initiation information includes: request identification and initiation time.
Step 303: acquiring transaction processing information of a tested system aiming at each transaction test request; wherein the transaction processing information includes: request identification, processing start time, and processing end time.
Step 304: generating a plurality of transaction related records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining a system test result of the tested system according to the transaction related records.
Step 305: it is determined whether a system test result of the system under test satisfies a first test condition.
The first inspection condition may be set according to specific business requirements. The first verification condition may be that the average processing latency is greater than a latency threshold, the total number of asynchronous processing tasks is greater than a number threshold, etc. The system test result of the tested system meets the first test condition, which indicates that the current operation pressure of the system is large, and the user is required to pay attention to or optimize.
Step 306: and responding to the system test result of the tested system to meet the first test condition, and acquiring the resource condition information of the tested system.
The resource case information may include: number of processes, CPU usage, physical memory, etc.
Step 307: and generating a test result report of the tested system according to the system test result and the resource condition information.
In the embodiment of the invention, under the condition that the system test result of the tested system meets the first test condition, a test result report containing the system test result and resource condition information is generated. The user can clearly learn the current running condition of the system, such as whether the system resource allocation is reasonable, whether the system pressure is overlarge, and the like, through the test result report. And the test result report helps the user to better perform system operation and maintenance.
In one embodiment of the present invention, after determining the system test result of the tested system according to the transaction association records, the method further comprises: determining whether a system test result of the tested system meets a second test condition; responding to the system test result of the tested system to meet the second test condition, generating a next batch of test requests, and sending the next batch of test requests to the tested system to send for testing; and generating alarm information that the tested system fails the test in response to the system test result of the tested system not meeting the second test condition.
The second inspection condition may be set according to specific business requirements. The second verification condition may be that the average processing latency is less than a latency threshold, the total number of asynchronous processing tasks is less than a number threshold, etc. And if the system test result of the tested system meets the second test condition, indicating that the system passes the test of the request of the current batch. At this time, a next batch of test requests is generated, and the tested system is continuously tested. If the system test result of the tested system does not meet the second test condition, generating alarm information that the tested system fails the test, so as to prompt a user to debug and optimize the tested system.
The embodiment of the invention also provides a test system. The test system can simulate the client to initiate asynchronous processing request, collect performance indexes of asynchronous processing and make statistics so as to obtain performance results such as average delay and processing efficiency of asynchronous processing. Fig. 4 is a schematic system configuration diagram of a test system according to an embodiment of the present invention. As shown in fig. 4, the test system is composed of a compression tool, a compression Agent (Proxy), a service probe (Agent), a message queue, a time sequence database, a relational database, a performance test service, and the like.
A pressure generating tool: the user is simulated to initiate HTTP, TCP, RPC a transaction test request of a protocol using a generic performance test tool, such as Jmeter, loadrunner.
A Proxy for generating pressure (Proxy): intercepting a transaction test request initiated by a pressure transmitting tool, and recording request transaction initiation information such as a request identifier, initiation time and the like. The transaction test request is then forwarded to the system under test and transaction initiation information is sent to the message queue.
The start time, end time and execution number of each test are recorded in a relational database.
Service probe (Agent): the service probe realized by adopting the byte code enhancement technology is injected into the tested service, and transaction test information such as request identification, processing starting time and ending time and the like, which are executed by asynchronous processing tasks of the tested system, are recorded. The system under test is an asynchronous processing system. Transaction processing information is sent to a message queue.
Message queues: transaction initiation information sent by a Proxy and transaction processing information sent by a service probe (Agent) are received and stored.
A time sequence database: the performance index of each transaction test request is stored, including request identification, initiation time, processing end time, processing delay, etc.
Performance testing service: for each transaction test request, the initiation time and the processing end time of the transaction test request are obtained from the message queue, the processing delay is calculated, and the result is written into the time sequence database.
For each performance test, reading test results from the time sequence database in the range from the test start time to the test end time, calculating performance indexes such as the total number of asynchronous processing tasks, average processing delay, processing efficiency and the like, and writing the results into the related coefficient database.
The scheme of the embodiment of the invention adopts the byte code enhancement technology to acquire the execution state information of the tested service, does not need to modify the tested system, and has no business invasion. Performance indexes such as processing delay, processing efficiency and the like of the asynchronous processing system can be accurately obtained.
Fig. 5 is a schematic structural diagram of a system testing device according to an embodiment of the present invention, as shown in fig. 5, the device includes:
a request generation module 501 for generating a plurality of transaction test requests;
the first obtaining module 502 is configured to obtain transaction initiation information of each transaction test request, and send the transaction test request to the tested system; wherein the transaction initiation information includes: request identification and initiation time;
a second obtaining module 503, configured to obtain transaction processing information of each transaction test request by the tested system; wherein the transaction processing information includes: request identification, processing start time and processing end time;
the result generating module 504 is configured to generate a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request, and determine a system test result of the tested system according to the plurality of transaction association records.
Optionally, the first obtaining module 502 is specifically configured to:
intercepting each transaction test request by using a pressure sending agent, and acquiring transaction initiation information of each transaction test request;
the second obtaining module 502 is specifically configured to:
and acquiring transaction processing information of the tested system for each transaction test request by using the service probe.
Optionally, the result generating module 504 is specifically configured to:
receiving transaction initiation information of each transaction test request sent by a pressure receiving agent;
receiving transaction processing information of each transaction test request sent by a service probe;
carrying out association processing on transaction initiating information and transaction processing information by using the request identifier to generate a plurality of transaction association records; wherein, the transaction association record comprises: request identification, initiation time, processing start time, and processing end time.
Optionally, the result generating module 504 is specifically configured to:
acquiring transaction association records corresponding to all transaction types;
and generating a system test result of the tested system aiming at each transaction type according to the transaction association record corresponding to each transaction type.
Optionally, the method further comprises:
the report generation module is used for determining display information corresponding to the transaction type;
and loading a system test result of the transaction type according to the display information to generate a test result report of the tested system.
Optionally, the report generating module is further configured to:
determining whether a system test result of the tested system meets a first test condition;
responding to the system test result of the tested system to meet the first test condition, and acquiring the resource condition information of the tested system;
and generating a test result report of the tested system according to the system test result and the resource condition information.
Optionally, the method further comprises:
the execution module is used for determining whether a system test result of the tested system meets a second test condition;
responding to the system test result of the tested system to meet the second test condition, generating a next batch of test requests, and sending the next batch of test requests to the tested system to send for testing;
and generating alarm information that the tested system fails the test in response to the system test result of the tested system not meeting the second test condition.
The embodiment of the invention provides electronic equipment, which comprises:
one or more processors;
storage means for storing one or more programs,
when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the methods of any of the embodiments described above.
The embodiment of the invention provides a computer program product, which comprises a computer program, wherein the computer program realizes the enterprise risk assessment method in the embodiment of the invention when being executed by a processor.
Referring now to FIG. 6, there is illustrated a schematic diagram of a computer system 600 suitable for use in implementing an embodiment of the present invention. The terminal device shown in fig. 6 is only an example, and should not impose any limitation on the functions and the scope of use of the embodiment of the present invention.
As shown in fig. 6, the computer system 600 includes a Central Processing Unit (CPU) 601, which can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM) 602 or a program loaded from a storage section 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the system 600 are also stored. The CPU 601, ROM 602, and RAM 603 are connected to each other through a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
The following components are connected to the I/O interface 605: an input portion 606 including a keyboard, mouse, etc.; an output portion 607 including a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, a speaker, and the like; a storage section 608 including a hard disk and the like; and a communication section 609 including a network interface card such as a LAN card, a modem, or the like. The communication section 609 performs communication processing via a network such as the internet. The drive 610 is also connected to the I/O interface 605 as needed. Removable media 611 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is installed as needed on drive 610 so that a computer program read therefrom is installed as needed into storage section 608.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication portion 609, and/or installed from the removable medium 611. The above-described functions defined in the system of the present invention are performed when the computer program is executed by a Central Processing Unit (CPU) 601.
The computer readable medium shown in the present invention may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of the computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules involved in the embodiments of the present invention may be implemented in software or in hardware. The described modules may also be provided in a processor, for example, as: the device comprises a request generation module, a first acquisition module, a second acquisition module and a result generation module. The names of these modules do not constitute a limitation on the module itself in some cases, and for example, the request generation module may also be described as "a module that generates a plurality of transaction test requests".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be present alone without being fitted into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to include:
generating a plurality of transaction test requests;
acquiring transaction initiation information of each transaction test request, and sending the transaction test requests to a tested system; wherein the transaction initiation information includes: request identification and initiation time;
acquiring transaction processing information of the tested system for each transaction test request; wherein the transaction processing information includes: request identification, processing start time and processing end time;
generating a plurality of transaction related records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining a system test result of the tested system according to the transaction related records.
According to the technical scheme of the embodiment of the invention, under the condition that the tested system is an asynchronous processing system, in the process of carrying out system test on the tested system, not only the transaction processing information of each transaction test request, but also the transaction initiating information of each transaction test request are obtained. By comprehensively considering the transaction processing information and the transaction initiating information of each transaction test request, performance indexes such as the total number of asynchronous processing tasks, average processing delay, processing efficiency and the like of the tested system can be accurately obtained, and therefore the real performance condition of the tested system is obtained.
The above embodiments do not limit the scope of the present invention. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives can occur depending upon design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the scope of the present invention.

Claims (16)

1. A system testing method, comprising:
generating a plurality of transaction test requests;
acquiring transaction initiation information of each transaction test request, and sending the transaction test requests to a tested system; wherein the transaction initiation information includes: request identification and initiation time;
acquiring transaction processing information of the tested system for each transaction test request; wherein the transaction processing information includes: request identification, processing start time and processing end time;
generating a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining a system test result of the tested system according to the transaction association records.
2. The method of claim 1, wherein said obtaining transaction initiation information for each of said transaction test requests comprises:
intercepting each transaction test request by using a pressure generating agent, and acquiring transaction initiation information of each transaction test request;
the acquiring transaction processing information of the tested system for each transaction test request includes:
and acquiring transaction processing information of the tested system for each transaction test request by using a service probe.
3. The method of claim 2, wherein generating a plurality of transaction association records based on the transaction initiation information and the transaction processing information of each of the transaction test requests comprises:
receiving transaction initiation information of each transaction test request sent by the pressure generating agent;
receiving transaction processing information of each transaction test request sent by the service probe;
carrying out association processing on the transaction initiating information and the transaction processing information by using the request identification to generate a plurality of transaction association records; wherein, the transaction association record comprises: request identification, initiation time, processing start time, and processing end time.
4. The method of claim 1, wherein determining the system test results for the system under test based on the plurality of transaction-related records comprises:
acquiring transaction association records corresponding to all transaction types;
and generating a system test result of the tested system for each transaction type according to the transaction association record corresponding to each transaction type.
5. The method of claim 4, wherein after generating the system test result of the tested system for each transaction type according to the transaction association record corresponding to each transaction type, further comprises:
determining display information corresponding to the transaction type;
and loading the system test result of the transaction type according to the display information to generate a test result report of the tested system.
6. The method of claim 1, wherein after determining the system test result of the system under test based on the plurality of transaction-related records, further comprising:
determining whether a system test result of the tested system meets a first test condition;
responding to the system test result of the tested system to meet the first test condition, and acquiring resource condition information of the tested system;
and generating a test result report of the tested system according to the system test result and the resource condition information.
7. The method of claim 1, wherein after determining the system test result of the system under test based on the plurality of transaction-related records, further comprising:
determining whether a system test result of the tested system meets a second test condition;
responding to the system test result of the tested system to meet the second test condition, generating a next batch of test requests, and sending the next batch of test requests to the tested system to be tested;
and generating alarm information that the tested system fails to pass the test and check in response to the system test result of the tested system not meeting the second check condition.
8. A system testing apparatus, comprising:
the request generation module is used for generating a plurality of transaction test requests;
the first acquisition module is used for acquiring transaction initiation information of each transaction test request and sending the transaction test requests to a tested system; wherein the transaction initiation information includes: request identification and initiation time;
the second acquisition module is used for acquiring transaction processing information of the tested system for each transaction test request; wherein the transaction processing information includes: request identification, processing start time and processing end time;
the result generation module is used for generating a plurality of transaction association records according to the transaction initiation information and the transaction processing information of each transaction test request, and determining the system test result of the tested system according to the transaction association records.
9. The apparatus of claim 8, wherein the first acquisition module is specifically configured to:
intercepting each transaction test request by using a pressure generating agent, and acquiring transaction initiation information of each transaction test request;
the second obtaining module is specifically configured to:
and acquiring transaction processing information of the tested system for each transaction test request by using a service probe.
10. The apparatus of claim 9, wherein the result generation module is specifically configured to:
receiving transaction initiation information of each transaction test request sent by the pressure generating agent;
receiving transaction processing information of each transaction test request sent by the service probe;
carrying out association processing on the transaction initiating information and the transaction processing information by using the request identification to generate a plurality of transaction association records; wherein, the transaction association record comprises: request identification, initiation time, processing start time, and processing end time.
11. The apparatus of claim 8, wherein the result generation module is specifically configured to:
acquiring transaction association records corresponding to all transaction types;
and generating a system test result of the tested system for each transaction type according to the transaction association record corresponding to each transaction type.
12. The apparatus as recited in claim 11, further comprising:
the report generation module is used for determining display information corresponding to the transaction type;
and loading the system test result of the transaction type according to the display information to generate a test result report of the tested system.
13. The apparatus of claim 12, wherein the report generation module is further configured to:
determining whether a system test result of the tested system meets a first test condition;
responding to the system test result of the tested system to meet the first test condition, and acquiring resource condition information of the tested system;
and generating a test result report of the tested system according to the system test result and the resource condition information.
14. An electronic device, comprising:
one or more processors;
storage means for storing one or more programs,
when executed by the one or more processors, causes the one or more processors to implement the method of any of claims 1-7.
15. A computer readable medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the method according to any of claims 1-7.
16. A computer program product comprising a computer program which, when executed by a processor, implements the method according to any of claims 1-7.
CN202310734485.6A 2023-06-20 2023-06-20 System testing method and device Pending CN116737576A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310734485.6A CN116737576A (en) 2023-06-20 2023-06-20 System testing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310734485.6A CN116737576A (en) 2023-06-20 2023-06-20 System testing method and device

Publications (1)

Publication Number Publication Date
CN116737576A true CN116737576A (en) 2023-09-12

Family

ID=87902535

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310734485.6A Pending CN116737576A (en) 2023-06-20 2023-06-20 System testing method and device

Country Status (1)

Country Link
CN (1) CN116737576A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117370216A (en) * 2023-12-08 2024-01-09 天津华来科技股份有限公司 Callback interface performance test method based on python language

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117370216A (en) * 2023-12-08 2024-01-09 天津华来科技股份有限公司 Callback interface performance test method based on python language

Similar Documents

Publication Publication Date Title
CN116737576A (en) System testing method and device
US11526413B2 (en) Distributed tracing of huge spans for application and dependent application performance monitoring
WO2022068316A1 (en) Data reconciliation method and apparatus, device, and storage medium
CN107688626B (en) Slow query log processing method and device and electronic equipment
CN113656174A (en) Resource allocation method, system, computer device and storage medium
CN110955640A (en) Cross-system data file processing method, device, server and storage medium
US20180005152A1 (en) Technologies for correlation based data selection
CN110033242B (en) Working time determining method, device, equipment and medium
CN111913861A (en) Performance test method, device, equipment and medium of Internet of things system
CN116757816A (en) Information approval method, device, equipment and storage medium
CN112631879A (en) Data acquisition method and device, computer readable medium and electronic equipment
CN111125168A (en) Data processing method and device, electronic equipment and storage medium
CN112148762A (en) Statistical method and device for real-time data stream
CN112131257B (en) Data query method and device
CN113852610A (en) Message processing method and device, computer equipment and storage medium
CN112801688A (en) Method and device for positioning reason of estimation failure
US8881156B2 (en) Apportioning summarized metrics based on unsummarized metrics in a computing system
CN112184406A (en) Data processing method, system, electronic device and computer readable storage medium
CN110908886A (en) Data sending method and device, electronic equipment and storage medium
CN108628909B (en) Information pushing method and device
CN113254325A (en) Test case processing method and device
CN112579428A (en) Interface testing method and device, electronic equipment and storage medium
CN113282471B (en) Equipment performance testing method and device and terminal equipment
TWI817128B (en) Enterprise resource planning device and smart debugging method thereof
CN109634868B (en) Processing method and device for automatic test result of financial data analysis system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination