Traffic recording and playback method, device, equipment and medium
By using AIGC technology to process and playback traffic data in traffic recording and playback methods, the problem of poor flexibility in the existing technology is solved, and a larger amount of traffic data and stronger flexibility is achieved to meet the usage needs in different scenarios.
Patent Information
- Application Number
- CN202411659527.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-19
- Publication Date
- 2025-03-14
AI Technical Summary
The traffic recording and playback methods provided by the prior art are poor in flexibility and cannot meet the usage needs of traffic data in different scenarios.
Artificial Intelligence Generated Content (AIGC) technology is used to process the truly recorded first traffic data, acquire the second traffic data, and playback both the second traffic data and the first traffic data into the service system during the playback operation.
Through AIGC technology, the amount of traffic data played back into the service system is increased, which meets the usage needs in different scenarios, and improves the flexibility of traffic recording and playback.
Smart Images

Figure CN119629075A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to data processing technology, and specifically to traffic recording and playback methods, devices, equipment and media. Background Art
[0002] Traffic recording and playback technology can quickly record the interface traffic produced by the business system and play it back in the test environment, development environment, and production environment, so as to improve the testing, development, and production efficiency of the business system, reduce the writing of automated scripts, and reuse online environment equipment and resources. It makes functional testing and regression verification testing more convenient and quick.
[0003] The traffic recording and playback method provided by the prior art includes the following steps:
[0004] The traffic data of all link nodes involved in the request message and / or response message is collected, and the collected traffic data is stored in the database to complete the traffic recording operation; wherein the request message and / or response message is generated by the interface of the business system.
[0005] In different scenarios, such as test environment, development environment or production environment, traffic data is obtained from the database, the traffic data is replayed into the business system, and the processing result of the traffic data by the business system is obtained to complete the traffic replay operation.
[0006] The traffic recording and playback method provided by the prior art can only perform simple recording-storage-playback on traffic data, which has poor flexibility and cannot meet the use requirements of traffic data in different scenarios. Summary of the invention
[0007] The embodiments of the present application propose site-integrated traffic recording and playback methods, devices, equipment and media to solve the problem that the traffic recording and playback methods provided by the prior art have poor flexibility and cannot meet the requirements for the use of traffic data in different scenarios.
[0008] In a first aspect, an embodiment of the present application provides a traffic recording and playback method, the method comprising:
[0009] Enable the traffic recording related function module, record the traffic of the business system, and obtain the first traffic data;
[0010] Using artificial intelligence to generate content AIGC technology, the first traffic data is processed to obtain second traffic data;
[0011] The first flow data and the second flow data are respectively played back to the business system.
[0012] In a second aspect, an embodiment of the present application provides a traffic recording and playback device, the device comprising:
[0013] A recording module, used to start a flow recording related function module, record the flow of the business system, and obtain the first flow data;
[0014] A processing module, configured to process the first traffic data using artificial intelligence generated content (AIGC) technology to obtain second traffic data;
[0015] A playback module is used to play back the first flow data and the second flow data to the business system respectively.
[0016] In a third aspect, an embodiment of the present application provides an electronic device, comprising: one or more processors; a storage device on which one or more programs are stored, and when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any embodiment of the first aspect.
[0017] In a fourth aspect, an embodiment of the present application provides a computer-readable medium having a computer program stored thereon, which, when executed by a processor, implements the method described in any embodiment of the first aspect.
[0018] The traffic recording and playback method, device, equipment and medium provided in the embodiment of the present application can use AIGC technology to process the first traffic data of the real recording to obtain the second traffic data. In the playback operation, both the second traffic data and the first traffic data can be played back into the business system, so that the amount of traffic data played back into the business system is larger, and it can better meet the use requirements of traffic data in different scenarios; and, because the second traffic data is obtained by using AIGC technology to process the first traffic data of the real recording, the second traffic data can be set according to the actual traffic playback application scenario, so that the technical solution provided by the embodiment is more flexible when performing traffic recording and playback, and solves the problem that the traffic recording and playback method provided by the prior art is poorly flexible and cannot meet the use requirements of traffic data in different scenarios. In addition, because the AIGC technology is used to realize the recording of the second traffic data, the technical solution provided by this embodiment can meet the needs of users who have no relevant business knowledge and technical knowledge, complete functional testing, performance testing, middleware testing and other operations, and complete automated testing without coding. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Other features, objects and advantages of the present application will become more apparent by reading the detailed description of non-limiting embodiments made with reference to the following drawings:
[0020] Figure 1is a flow chart of an embodiment of the traffic recording and playback method of the present application;
[0021] Figure 2 yes Figure 1 The flowchart of step 102 of the traffic recording and playback method of the present application is shown;
[0022] Figure 3 yes Figure 1 The algorithm flow diagram shown is used in the model training of the traffic recording and playback method of the present application;
[0023] Figure 4 It is a structural schematic diagram of an embodiment of the traffic recording and playback device of the present application;
[0024] Figure 5 It is a schematic diagram of the structure of an electronic device used to implement an embodiment of the present application. DETAILED DESCRIPTION
[0025] All actions to obtain signals, information or data in this application are carried out in compliance with the relevant data protection laws and policies of the country where they are located, and with the authorization given by the owner of the corresponding device.
[0026] The present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the relevant invention, rather than to limit the invention. It is also necessary to explain that, for ease of description, only the parts related to the relevant invention are shown in the accompanying drawings.
[0027] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0028] Please refer to Figure 1 , which shows a process 100 of an embodiment of a traffic recording and playback method according to the present application. The traffic recording and playback method can be applied to various electronic devices with data processing functions. For example, the above electronic devices may include but are not limited to cloud servers, physical servers, etc. The execution subject of the automatic discovery method of the topological relationship may be a processor in the above electronic device.
[0029] The traffic recording and playback method comprises the following steps:
[0030] Step 101: Start a flow recording related function module, record the flow of the business system, and obtain first flow data.
[0031] In this embodiment, the traffic recording related function module may include any one or a combination of the following plug-ins:
[0032] 1. Service-Oriented Architecture Plug-in
[0033] Exemplarily, in this embodiment, the service-oriented architecture plug-in may specifically be: service-oriented architecture (Service-Oriented Architecture, SOA).
[0034] SOA can split different functional units of an application (called services) and connect these services through pre-defined interfaces and protocols, so that different services can interact in a unified and universal way.
[0035] SOA application in the traffic recording and playback method provided in this embodiment can improve the flexibility, scalability and maintainability of the software system.
[0036] 2. Database plug-in based on distributed file storage
[0037] Exemplarily, in this embodiment, the database plug-in based on distributed file storage may specifically be: Mongo.
[0038] Mongo is a product between relational databases and non-relational databases. It is the most feature-rich and relational database-like non-relational database. The data structure it supports is very loose, in a bson format similar to json, so it can store relatively complex data types.
[0039] The query language supported by Mongo is very powerful. Its syntax is somewhat similar to that of an object-oriented query language. It can implement almost all functions of single-table queries in relational databases, and also supports indexing of data. Mongo is applied in the traffic recording and playback method provided in this embodiment to achieve the purpose of flexibly operating the database used to store recorded data.
[0040] 3. Open source distributed search and analysis engine plug-in
[0041] Exemplarily, in this embodiment, the open source distributed search and analysis engine plug-in may specifically be: ES, namely Elasticsearch.
[0042] ES is a highly scalable full-text search engine that provides a RESTful API style interface, supports distributed and horizontal expansion, and can handle PB-level data volumes. ES is applied in the traffic recording and playback method provided in this embodiment to implement full-text retrieval and real-time data analysis of the replayed traffic data.
[0043] 4. Distributed publish-subscribe messaging system plug-in
[0044] Exemplarily, in this embodiment, the distributed publish-subscribe messaging system plug-in may specifically be: Kafka.
[0045] Kafka is a high-throughput distributed publish-subscribe messaging system that can process all action stream data of consumers on a website. Kafka is applied in the traffic recording and playback method provided in this embodiment to realize functions such as data transmission and buffering, data persistence and storage, and asynchronous processing and system decoupling.
[0046] 5. Duplex communication protocol plug-in
[0047] Exemplarily, in this embodiment, the duplex communication protocol plug-in may specifically be: WebSocket.
[0048] WebSocket is a full-duplex communication protocol based on TCP, which allows persistent real-time two-way data transmission between the client and the server. WebSocket is applied in the traffic recording and playback method provided in this embodiment to realize the functions of real-time data transmission, two-way communication and persistent connection, and has the characteristics of high efficiency, flexibility and scalability.
[0049] 6. Message Broker Plugin
[0050] Exemplarily, in this embodiment, the message broker plug-in may specifically be: RabbitMQ.
[0051] RabbitMQ, as a message broker, is responsible for receiving messages sent by clients and distributing the messages to one or more queues according to routing rules, and then consumers obtain messages from the queues for processing. RabbitMQ is applied in the traffic recording and playback method provided in this embodiment to realize the buffering effect of the message queue.
[0052] It should be noted that the traffic recording related functional modules described above are only specific examples of this embodiment. In actual use, other traffic recording related functional modules can be set according to the specific needs of traffic recording and playback, which will not be repeated here.
[0053] By setting different traffic recording related functional modules, the traffic recording and playback method provided in this embodiment has richer functions, stronger adaptability, higher flexibility, and can better meet the needs of various application scenarios.
[0054] In this embodiment, step 101 can store the first traffic data in HDFS and Hive related libraries for use in subsequent steps.
[0055] Step 102: Use artificial intelligence generated content (AIGC) technology to process the first traffic data to obtain second traffic data.
[0056] In this embodiment, if Figure 2 As shown, step 102 may include the following steps:
[0057] Step 201: extract features from first flow data to obtain feature data.
[0058] In this embodiment, the characteristic data may specifically include: ports, parameters, and interface information, etc. Of course, in actual use, the characteristic data may also include other types of data, which will not be described one by one here.
[0059] Step 202: Generate second flow data based on the characteristic data using AIGC technology.
[0060] In this embodiment, step 202 can use AIGC technology to automatically generate ports, parameters and interface information of the first flow data, and use the automatically generated ports, parameters and interface information to replace the ports, parameters and interface information of the first flow data to obtain second flow data.
[0061] Optionally, in order to solve the problem that traffic characteristics of different business systems of the same type may be different, in this embodiment, step 201 may also include a step of standardizing the first traffic data and obtaining standardized traffic data. In this case, step 201 may be replaced by: extracting features from the standardized traffic data and obtaining feature data.
[0062] Step 103: Play back the first flow data and the second flow data to the business system respectively.
[0063] In this embodiment, step 103 replays the second traffic data to the business system, which may specifically include: using structured query language (SQL) traffic simulation technology to simulate the playback behavior of the first traffic data and replay the second traffic data to the business system.
[0064] Optionally, the traffic recording and playback method provided in this embodiment may further include the step of performing model training and obtaining a trained recording model. In this embodiment, model training can utilize machine learning capabilities to implement analysis of the first traffic data, using decision trees, support vector machines, and random forests, and selecting corresponding algorithms and parameters based on specific problems and the characteristics of the first traffic data, and performing cross-validation and tuning to obtain. In this embodiment, the algorithm flow used in model training can be exemplarily as follows: Figure 3As shown, no further description is given here.
[0065] Optionally, in this embodiment, after step 103, the method may further include obtaining a first playback result corresponding to the first traffic data and a second playback result corresponding to the second traffic data; and performing comparative analysis on the first playback result and the second playback result to generate an analysis report. By performing comparative analysis on the first playback result and the second playback result to generate an analysis report, the accuracy and availability of the second traffic data may be determined, thereby improving the adaptability of the traffic recording and playback method provided in this embodiment.
[0066] The method provided by the above-mentioned embodiment of the present application can use AIGC technology to process the first flow data of real recording to obtain the second flow data. In the playback operation, both the second flow data and the first flow data can be played back into the business system, so that the amount of flow data played back into the business system is larger, and it can better meet the use requirements of flow data in different scenarios; and, because the second flow data is obtained by using AIGC technology to process the first flow data of real recording, the second flow data can be set according to the actual flow playback application scenario, so that the technical solution provided by the embodiment is more flexible when performing flow recording and playback, and solves the problem that the flow recording and playback methods provided by the existing technology are poorly flexible and cannot meet the use requirements of flow data in different scenarios. In addition, because the AIGC technology is used to realize the recording of the second flow data, the technical solution provided by this embodiment can meet the needs of users who have no relevant business knowledge and technical knowledge, complete functional testing, performance testing, middleware testing and other operations, and complete automated testing without coding.
[0067] Please refer to Figure 4 As an implementation of the methods shown in the above figures, the present application provides an embodiment of a traffic recording and playback device, and the device embodiment is similar to Figure 1 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0068] like Figure 4 As shown, the traffic recording and playback device 400 of this embodiment includes:
[0069] The recording module 401 is used to start the flow recording related function module, record the flow of the business system, and obtain the first flow data;
[0070] A processing module 402 is used to process the first traffic data using artificial intelligence generated content AIGC technology to obtain second traffic data;
[0071] The playback module 403 is used to play back the first flow data and the second flow data to the business system respectively.
[0072] Optionally, the traffic recording related function module includes any one or a combination of the following plug-ins:
[0073] Service-oriented architecture plug-in, database plug-in based on distributed file storage, open source distributed search and analysis engine plug-in, distributed publish-subscribe messaging system plug-in, duplex communication protocol plug-in and message broker plug-in.
[0074] In this embodiment, the traffic recording related function module may include any one or a combination of the following plug-ins:
[0075] 1. Service-Oriented Architecture Plug-in
[0076] Exemplarily, in this embodiment, the service-oriented architecture plug-in may specifically be: SOA.
[0077] SOA can split different functional units of an application (called services) and connect these services through pre-defined interfaces and protocols, so that different services can interact in a unified and universal way.
[0078] SOA application in the traffic recording and playback method provided in this embodiment can improve the flexibility, scalability and maintainability of the software system.
[0079] 2. Database plug-in based on distributed file storage
[0080] Exemplarily, in this embodiment, the database plug-in based on distributed file storage may specifically be: Mongo.
[0081] Mongo is a product between relational databases and non-relational databases. It is the most feature-rich and relational database-like non-relational database. The data structure it supports is very loose, in a bson format similar to json, so it can store relatively complex data types.
[0082] The query language supported by Mongo is very powerful. Its syntax is somewhat similar to that of an object-oriented query language. It can implement almost all functions of single-table queries in relational databases, and also supports indexing of data. Mongo is applied in the traffic recording and playback method provided in this embodiment to achieve the purpose of flexibly operating the database used to store recorded data.
[0083] 3. Open source distributed search and analysis engine plug-in
[0084] Exemplarily, in this embodiment, the open source distributed search and analysis engine plug-in may specifically be: ES, namely Elasticsearch.
[0085] ES is a highly scalable full-text search engine that provides a RESTful API style interface, supports distributed and horizontal expansion, and can handle PB-level data volumes. ES is applied in the traffic recording and playback method provided in this embodiment to implement full-text retrieval and real-time data analysis of the replayed traffic data.
[0086] 4. Distributed publish-subscribe messaging system plug-in
[0087] Exemplarily, in this embodiment, the distributed publish-subscribe messaging system plug-in may specifically be: Kafka.
[0088] Kafka is a high-throughput distributed publish-subscribe messaging system that can process all action stream data of consumers on a website. Kafka is applied in the traffic recording and playback method provided in this embodiment to realize functions such as data transmission and buffering, data persistence and storage, and asynchronous processing and system decoupling.
[0089] 5. Duplex communication protocol plug-in
[0090] Exemplarily, in this embodiment, the duplex communication protocol plug-in may specifically be: WebSocket.
[0091] WebSocket is a full-duplex communication protocol based on TCP, which allows persistent real-time two-way data transmission between the client and the server. WebSocket is applied in the traffic recording and playback method provided in this embodiment to realize the functions of real-time data transmission, two-way communication and persistent connection, and has the characteristics of high efficiency, flexibility and scalability.
[0092] 6. Message Broker Plugin
[0093] Exemplarily, in this embodiment, the message broker plug-in may specifically be: RabbitMQ.
[0094] RabbitMQ, as a message broker, is responsible for receiving messages sent by clients and distributing the messages to one or more queues according to routing rules, and then consumers obtain messages from the queues for processing. RabbitMQ is applied in the traffic recording and playback method provided in this embodiment to realize the buffering effect of the message queue.
[0095] It should be noted that the traffic recording related functional modules described above are only specific examples of this embodiment. In actual use, other traffic recording related functional modules can be set according to the specific needs of traffic recording and playback, which will not be repeated here.
[0096] By setting different traffic recording related functional modules, the traffic recording and playback method provided in this embodiment has richer functions, stronger adaptability, higher flexibility, and can better meet the needs of various application scenarios.
[0097] In this embodiment, the recording module 401 can also be used to store the first traffic data in HDFS and Hive related libraries for use by other modules.
[0098] Optionally, in this embodiment, the processing module 402 is specifically used to extract features from the first traffic data to obtain feature data; and generate second traffic data based on the feature data using the AIGC technology.
[0099] Optionally, in this embodiment, the processing module 402 may also be used to perform standardization processing on the first flow data to obtain standardized flow data, perform feature extraction on the standardized flow data to obtain feature data.
[0100] Optionally, in this embodiment, the processing module 402 can also be used to perform model training to obtain a trained recording model, wherein the model training utilizes machine learning capabilities to analyze the first traffic data using decision trees, support vector machines, and random forests, and selects corresponding algorithms and parameters based on specific problems and the characteristics of the first traffic data, and performs cross-validation and tuning to obtain the second traffic data; the second traffic data is obtained from the first traffic data through the recording model.
[0101] Optionally, in this embodiment, the playback module 403 may be specifically used for SQL traffic simulation technology to simulate the playback behavior of the first traffic data and playback the second traffic data to the business system.
[0102] Optionally, in this embodiment, the playback module 403 can also be used to obtain a first playback result corresponding to the first traffic data and a second playback result corresponding to the second traffic data; compare and analyze the first playback result and the second playback result to generate an analysis report.
[0103] The device provided in the embodiment of the present application can use AIGC technology to process the first flow data of real recording to obtain the second flow data. In the playback operation, both the second flow data and the first flow data can be played back into the business system, so that the amount of flow data played back into the business system is larger, and it can better meet the use requirements of flow data in different scenarios; and, because the second flow data is obtained by using AIGC technology to process the first flow data of real recording, the second flow data can be set according to the actual flow playback application scenario, so that the technical solution provided by the embodiment is more flexible when performing flow recording and playback, and solves the problem that the flow recording and playback methods provided by the existing technology are poorly flexible and cannot meet the use requirements of flow data in different scenarios. In addition, because the AIGC technology is used to realize the recording of the second flow data, the technical solution provided by this embodiment can meet the needs of users who have no relevant business knowledge and technical knowledge, complete functional testing, performance testing, middleware testing and other operations, and complete automated testing without coding.
[0104] Reference below Figure 5 , which shows a schematic structural diagram of an electronic device for implementing some embodiments of the present application. Figure 5 The electronic device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0105] like Figure 5 As shown, the electronic device 500 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 into a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the electronic device 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.
[0106] Typically, the following devices may be connected to the I / O interface 505: an input device 506 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 507 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 508 including, for example, a disk, a hard disk, etc.; and a communication device 509. The communication device 509 may allow the electronic device 500 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 5 The electronic device 500 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead. Figure 4 Each block shown in the figure may represent one device, or may represent multiple devices as required.
[0107] In particular, according to some embodiments of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, some embodiments of the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In some such embodiments, the computer program can be downloaded and installed from the network through the communication device 509, or installed from the storage device 508, or installed from the ROM 502. When the computer program is executed by the processing device 501, the above-mentioned functions defined in the method of some embodiments of the present application are executed.
[0108] It should be noted that the computer-readable medium described in some embodiments of the present application may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In some embodiments of the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In some embodiments of the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0109] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.
[0110] The computer-readable medium may be included in the electronic device; or it may exist independently without being installed in the electronic device. The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: upon receiving a message sending request, obtains the message to be tested in the message sending request; extracts the text content in the message to be tested; detects the text content based on the keywords of historical spam messages, the hash values of historical spam messages, and the large language model to determine whether the message to be tested is a spam message; and intercepts the message to be tested in response to the message to be tested being a spam message.
[0111] Computer program code for performing the operations of some embodiments of the present application may be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++; and also conventional procedural programming languages such as "C" language or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, or may be connected to an external computer (e.g., through the Internet using an Internet service provider), including a local area network (LAN) or a wide area network (WAN).
[0112] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0113] The units described in some embodiments of the present application may be implemented by software or hardware. The units described may also be set in a processor, for example, it may be described as: a processor includes a first determination unit, a second determination unit, a selection unit, and a third determination unit. The names of these units do not, in some cases, constitute limitations on the units themselves.
[0114] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0115] The above description is only some preferred embodiments of the present application and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the embodiments of the present application is not limited to the technical solutions formed by the specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above invention concept. For example, the above features are replaced with (but not limited to) the technical features with similar functions disclosed in the embodiments of the present application to form a technical solution.
Claims
1. A traffic recording and playback method, characterized in that: The method comprises: Enable the traffic recording related function module, record the traffic of the business system, and obtain the first traffic data; Using artificial intelligence to generate content AIGC technology, the first traffic data is processed to obtain second traffic data; The first flow data and the second flow data are respectively played back to the business system.
2. The method according to claim 1, characterized in that The traffic recording related function module includes any one or a combination of the following plug-ins: Service-oriented architecture plug-in, database plug-in based on distributed file storage, open source distributed search and analysis engine plug-in, distributed publish-subscribe messaging system plug-in, duplex communication protocol plug-in and message broker plug-in.
3. The method according to claim 1, characterized in that The adopting the artificial intelligence to generate content AIGC technology to process the first traffic data to obtain the second traffic data includes: Performing feature extraction on the first flow data to obtain feature data; According to the characteristic data, the AIGC technology is adopted to generate the second flow data.
4. The method according to claim 3, characterized in that: Before extracting features from the first flow data and obtaining feature data, the method further includes: Performing standardization processing on the first flow data to obtain standardized flow data; The feature extraction is performed on the first flow data, and the obtained feature data is replaced with: Feature extraction is performed on the standardized flow data to obtain feature data.
5. The method according to claim 1, characterized in that The method further comprises: Performing model training to obtain a trained recording model, wherein the model training utilizes machine learning capabilities to analyze the first traffic data, and is implemented using a decision tree, a support vector machine, and a random forest, and corresponding algorithms and parameters are selected according to specific problems and characteristics of the first traffic data, and are obtained by cross-validation and tuning; The second traffic data is obtained from the first traffic data through the recording model.
6. The method according to claim 1, characterized in that The replaying the second traffic data to the business system includes: The structured query language SQL traffic simulation technology is adopted to simulate the playback behavior of the first traffic data, and the second traffic data is played back to the business system.
7. The method according to claim 1, characterized in that After respectively playing back the first flow data and the second flow data to the business system, the method further includes: Obtaining a first playback result corresponding to the first traffic data and a second playback result corresponding to the second traffic data; Compare and analyze the first playback result and the second playback result to generate an analysis report.
8. A traffic recording and playback device, characterized in that: The device comprises: A recording module, used to start a flow recording related function module, record the flow of the business system, and obtain the first flow data; A processing module, configured to process the first traffic data using artificial intelligence generated content (AIGC) technology to obtain second traffic data; A playback module is used to play back the first flow data and the second flow data to the business system respectively.
9. An electronic device, characterized in that: include: one or more processors; a storage device having one or more programs stored thereon, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.
10. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Method for generating automatic test case based on traffic recording
CN112749100A
Traffic playback method based on case template
CN112765045A
Service test method and device, computer equipment and storage medium
CN114328172A
Layered verification method and device based on traffic recording and playback, electronic equipment and storage medium
CN117215920A
Database performance test method, system and equipment and storage medium
CN118820028A