Application response simulation method and device
By introducing a simulated application response platform between client applications and server applications, the existing technology problem of heavy workload when client applications call server applications is solved, more efficient application response simulation is achieved, and system coupling is reduced. degree and improved flexibility.
Patent Information
- Application Number
- CN202111492662.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-08
- Publication Date
- 2025-01-21
- Estimated Expiration
- 2041-12-08
AI Technical Summary
In the prior art, when the client application calls the server application, the server needs to return a fixed value before the function development is completed, resulting in increased workload and reduced system flexibility. In the software testing phase, the database field value needs to be frequently modified to test different return values. In the case of this, the workload is large and the overall efficiency is inefficient.
An application response simulation method and device are provided. By adding a simulated application response platform between the client application and the server application, the request information of the client application is received, the corresponding server application and interface are determined, and transmission is performed based on the interface configuration. And receive and transmit the response data of the server application.
It reduces the workload, improves overall efficiency, reduces the coupling between client and server applications, and makes the system more flexible.
Smart Images

Figure CN114422487B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of application response simulation, and in particular to an application response simulation method and device. Background Art
[0002] In the technical architecture of today's Internet companies, mutual calls between applications are the most common way of communication between systems. For example, in a payment company, the business system must request multiple internal core systems such as the user system, merchant system, and account system in a payment transaction to verify whether the transaction elements meet the payment requirements.
[0003] In a project, when the client application calls the server application, the client application function is developed before the server application function. Before the server function is developed, the client application cannot call the backend interface. The current solution is that the server application returns a fixed value to the interface before the function is developed for the client application to call. This method also requires modifying the server system code after the development is complete, and then the entire system is debugged as a whole, which increases the workload and reduces the flexibility of the system. In addition, a frequent requirement during the software testing phase is to test the robustness of the client application under different return values of the server application. The current main testing method is to modify the field value in the database to return different values to the client application through the real interface of the server. This method not only has a large workload, but also has a high degree of coupling between the client and server applications, and the overall efficiency is low.
[0004] Therefore, an improved method is urgently needed to improve the above problems. Summary of the invention
[0005] In view of this, an object of the present invention is to provide an application response simulation method and device to improve the above technical problems.
[0006] In a first aspect, an embodiment of the present invention provides an application response simulation method, the method is applied to a simulation application response platform, the method comprising:
[0007] When receiving the request information sent by the client application, obtaining the server application and interface corresponding to the request information;
[0008] Based on the configuration of the interface, transmitting the request information to the server application in a transmission mode corresponding to the configuration;
[0009] Receive response data returned by the server application, and transmit the response data to the client application.
[0010] In combination with the first aspect, an embodiment of the present invention provides a first possible implementation manner of the first aspect, wherein, before obtaining the server application and interface corresponding to the request information when the request information is received, the method includes:
[0011] The control loader loads the add-ins required for the app to respond to the simulation process.
[0012] In combination with the first possible implementation of the first aspect, an embodiment of the present invention provides a second possible implementation of the first aspect, wherein when the request information sent by the client application is received, the server application and interface corresponding to the request information are obtained, including:
[0013] When receiving the request information sent by the client application, matching the request information with the add-on by controlling the identifier to obtain the add-on corresponding to the request information;
[0014] Based on the predetermined correspondence between the server application, the interface and the add-in, the server application and the interface corresponding to the request information are obtained.
[0015] In combination with the second possible implementation manner of the first aspect, an embodiment of the present invention provides a third possible implementation manner of the first aspect, wherein obtaining the server application and interface corresponding to the request information based on a predetermined correspondence between the server application, the interface and the add-in includes:
[0016] Parsing the address of the request information to obtain the path required for matching the address with the server application;
[0017] The path is matched with the add-on, and a predetermined corresponding relationship between the server application and the add-on is used to obtain a server application corresponding to the request information.
[0018] In combination with the second possible implementation of the first aspect, an embodiment of the present invention provides a fourth possible implementation of the first aspect, wherein the obtaining the server application and interface corresponding to the request information based on a predetermined correspondence between the server application, the interface and the add-on includes:
[0019] Determine a rule item in a rule base corresponding to the request information;
[0020] The rule item is matched with the add-on, and a predetermined corresponding relationship between the interface and the add-on is used to obtain an interface corresponding to the request information.
[0021] In combination with the first aspect, an embodiment of the present invention provides a fifth possible implementation of the first aspect, wherein the transmitting the request information to the server application in a transmission mode corresponding to the configuration based on the interface includes:
[0022] Based on the configuration of the interface, no simulation is required, transparently transmitting the request information to the server application;
[0023] Based on the configuration of the interface requiring simulation, interface parameters corresponding to the request information are loaded and transmitted to the server application.
[0024] In a second aspect, an embodiment of the present invention further provides an application response simulation device, which is applied to simulate an application response platform, and the device includes:
[0025] An information receiving module, used to obtain a server application and an interface corresponding to the request information when receiving the request information sent by the client application;
[0026] An information transmission module, used to transmit the request information to the server application in a transmission mode corresponding to the configuration based on the configuration of the interface;
[0027] The response data transmission module is used to receive the response data returned by the server application and transmit the response data to the client application.
[0028] In combination with the second aspect, an embodiment of the present invention provides a first possible implementation manner of the second aspect, wherein, before the information receiving module, the device further includes:
[0029] The add-in loading module is used to control the loader to load the add-ins required during the application response simulation process.
[0030] In combination with the second aspect, the embodiment of the present invention provides a second possible implementation manner of the second aspect, wherein the information transmission module is used to:
[0031] When receiving the request information sent by the client application, matching the request information with the add-on by controlling the identifier to obtain the add-on corresponding to the request information;
[0032] Based on the predetermined correspondence between the server application, the interface and the add-in, the server application and the interface corresponding to the request information are obtained.
[0033] In a third aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the method described above.
[0034] The embodiments of the present invention bring the following beneficial effects: the embodiment of the present invention provides an application response simulation method and device, first, when receiving the request information sent by the client application, obtain the server application and interface corresponding to the request information, then based on the configuration of the interface, transmit the request information to the server application in a corresponding transmission mode, and finally receive the response data returned by the server application, and transmit the response data to the client application. The application response simulation method and device of the embodiment of the present invention reduces the workload and improves the overall efficiency of the work by adding a simulated application response platform between the client application and the server application and using the simulated application response platform as a medium to perform mutual calls between applications.
[0035] Other features and advantages of the present invention will be described in the following description, and partly become apparent from the description, or be understood by practicing the present invention. The purpose and other advantages of the present invention are realized and obtained in the structures particularly pointed out in the description, claims and drawings.
[0036] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without paying any creative work.
[0038] Figure 1 A flowchart of an application response simulation method provided by an embodiment of the present invention;
[0039] Figure 2 A flowchart of another application response simulation method provided by an embodiment of the present invention;
[0040] Figure 3 A structural block diagram of an application response simulation device provided by an embodiment of the present invention;
[0041] Figure 4 A schematic diagram of the structure of a server provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0042] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0043] In the technical architecture of today's Internet companies, mutual calls between applications are the most common way of communication between systems. For example, in a payment company, the business system needs to request multiple internal core systems such as the user system, merchant system, and account system in a payment transaction to verify whether the transaction elements meet the payment requirements. In a project, when the client application calls the server application, the client application function is developed before the server application function. Before the server function is developed, the client application cannot call the backend interface. The current solution is that the server application returns a fixed value to the interface before the function is developed for the client application to call. This method also requires modifying the server system code after the development is complete, and then the entire system is debugged as a whole, which increases the workload and reduces the flexibility of the system. In addition, a frequent demand in the software testing phase is to test the robustness of the client application under different return values of the server application. The current main testing method is to modify the field value in the database to return different values to the client application through the real interface of the server. This method not only has a large workload, but also has a high degree of coupling between the client and server applications, and the overall efficiency is low. Based on this, an embodiment of the present invention provides an application response simulation method and device to alleviate the above problems.
[0044] In order to facilitate understanding of this embodiment, an application response simulation method disclosed in an embodiment of the present invention is first introduced in detail.
[0045] In a possible implementation manner, the present invention provides an application response simulation method, which is applied to simulate an application response platform, such as Figure 1 FIG. 1 is a flow chart of an application response simulation method provided by an embodiment of the present invention, the method comprising the following steps:
[0046] Step S102: when the request information sent by the client application is received, the server application and interface corresponding to the request information are obtained.
[0047] Step S104: Based on the configuration of the interface, the request information is transmitted to the server application in a transmission mode corresponding to the configuration.
[0048] Step S106: receiving the response data returned by the server application, and transmitting the response data to the client application.
[0049] In summary, the application response simulation method of the embodiment of the present invention first obtains the server application and interface corresponding to the request information when receiving the request information sent by the client application, then transmits the request information to the server application in a corresponding transmission mode based on the configuration of the interface, and finally receives the response data returned by the server application, and transmits the response data to the client application. The application response simulation method and device of the embodiment of the present invention reduces the workload and improves the overall efficiency of the work by adding a simulated application response platform between the client application and the server application and using the simulated application response platform as a medium to perform mutual calls between applications.
[0050] In order to explain the above process in more detail, the embodiment of the present invention Figure 2 FIG. 4 is a flowchart of another application response simulation method provided by an embodiment of the present invention, the method comprising the following steps:
[0051] Step S202: Control the loader to load the add-ons required in the application response simulation process.
[0052] Optionally, the above configuration items include but are not limited to: 1. Application level: application number, application path, application name, transparent address, interface matching identifier, interface message serialization / deserialization method; 2. Interface level: interface number, application number, interface value, interface name, return message data structure, interface simulation status, interface matching rule base; 3. Parameter level: interface number, parameter name, parameter identifier, parameter value.
[0053] Step S204: when the request information sent by the client application is received, the request information is matched with the above-mentioned add-on through the control identifier to obtain the add-on corresponding to the request information.
[0054] Step S206: Parse the address of the request information to obtain the path required for matching the address with the server application.
[0055] Step S208: Match the path with the add-on, and use the predetermined correspondence between the server application and the add-on to obtain the server application corresponding to the request information.
[0056] Optionally, step 206 and step 208 achieve the matching of the request information sent by the client application with the add-on so as to locate the server application. Specifically, the address in the request information of the client application is first parsed to obtain the path required for matching the address with the server application, and then matched with the add-on according to the path, and finally obtained the server application by using the predetermined correspondence between the server application and the add-on. For example, the address of the client request information is http: / / 10.10.1.10:8080 / rest2 / getUserid / userManger, and the simulation application response platform has loaded the request information with the path 8080 / rest2 / , then the simulation application response platform first intercepts the path 8080 / rest2 / according to the address, and then matches it with the above-mentioned loaded path to obtain the server application corresponding to this request information. Through steps 206 and 208, the simulation application response platform can provide simulation application response data for multiple server applications at the same time.
[0057] Step S210: Determine a rule item in a rule base that corresponds to the request information.
[0058] Step S212: Match the rule item with the add-on, and use the predetermined correspondence between the interface and the add-on to obtain the interface corresponding to the request information.
[0059] Optionally, step 210 and step 212 match the request information sent by the client application with the add-on item to locate the specific interface. Specifically, according to the rule base, the rule base is matched one by one by a rule engine (having the following functions: loading the rule set of the rule base model; matching the corresponding rule items according to the request information of the client application (3) obtaining the specific interface of the request information according to the matched rule items) to calculate the specific interface corresponding to the request information. The rule base is responsible for storing the rule logic matched to the specific interface, adding, deleting and modifying the rules, and taking effect in real time, including but not limited to matching the interface by address or matching the interface by interface message field. For example, the address of the request information of the client application is http: / / 10.10.1.10:8080 / rest2 / getUserid / userManger, and the interface matching identifier is rest2 / * / (rest2 is in the url), then the "getUserid" in the address of the request information is the specific interface. For another example, if the interface matching identifier is funcode=* (funcode is not in the url), the value corresponding to the funcode field in the response data is the specific interface.
[0060] Step S214: Based on the configuration of the interface, no simulation is required, and the request information is transparently transmitted to the server application.
[0061] Step S216: Based on the configuration of the interface, simulation is required, the interface parameters corresponding to the request information are loaded and transmitted to the server application.
[0062] Step S218: receiving the response data returned by the server application, and transmitting the response data to the client application.
[0063] Optionally, step 216 and step 218 first determine whether the configuration of the interface needs to be simulated. If simulation is not required, the request information is directly transparently transmitted to the server application, and the response data is obtained from the server application and returned to the client application; if simulation is required, the parameter set corresponding to the interface is first found according to the interface number, and then the parameter set is iterated, and the parameter set is encapsulated according to the preset response data structure, and then the parameter set of the interface is serialized according to the preset response data set serialization method, and finally the packaged response data is returned, that is, returned to the client application.
[0064] Optionally, the above response data, server application, interface and request information are correspondingly cached to a buffer memory, and after the server application meets the test conditions, the simulated application response platform automatically loads the above cached data and sends the client's request information to the designated server application.
[0065] It should be further explained that the above-mentioned simulated application response platform has the following advantages: returning the response data of the server application according to the configuration of the interface; transparently transmitting the request information to the server application to obtain the response data; caching the client application test data, and automatically calling the server to test the server application. It effectively improves the efficiency of the test link.
[0066] In summary, the application response simulation method of the present invention first obtains the server application and interface corresponding to the request information when receiving the request information sent by the client application, then transmits the request information to the server application in a corresponding transmission mode based on the configuration of the interface, and finally receives the response data returned by the server application, and transmits the response data to the client application. The application response simulation method and device of the embodiment of the present invention reduces the workload and improves the overall efficiency of the work by adding a simulated application response platform between the client application and the server application and using the simulated application response platform as a medium to perform mutual calls between applications.
[0067] In another possible implementation, corresponding to the application response simulation method provided in the above implementation, an embodiment of the present invention further provides an application response simulation device, which is applied to simulate an application response platform. Figure 3A structural block diagram of an application response simulation device provided by an embodiment of the present invention. Figure 3 The device comprises:
[0068] The information receiving module 301 is used to obtain the server application and interface corresponding to the request information when receiving the request information sent by the client application;
[0069] An information transmission module 302, configured to transmit the request information to the server application in a transmission mode corresponding to the configuration based on the configuration of the interface;
[0070] The response data transmission module 303 is used to receive the response data returned by the server application and transmit the response data to the client application.
[0071] In actual use, before the information receiving module 301, the device further includes:
[0072] The add-in loading module is used to control the loader to load the add-ins required during the application response simulation process.
[0073] In actual use, the information receiving module 301 is used to:
[0074] When receiving the request information sent by the client application, matching the request information with the add-on by controlling the identifier to obtain the add-on corresponding to the request information;
[0075] Based on the predetermined correspondence between the server application, the interface and the add-in, the server application and the interface corresponding to the request information are obtained.
[0076] In actual use, the information receiving module 301 is also used for:
[0077] Parsing the address of the request information to obtain the path required for matching the address with the server application;
[0078] The path is matched with the add-on, and a predetermined corresponding relationship between the server application and the add-on is used to obtain a server application corresponding to the request information.
[0079] In actual use, the information receiving module 301 is also used for:
[0080] Determine a rule item in a rule base corresponding to the request information;
[0081] The rule item is matched with the add-on, and a predetermined corresponding relationship between the interface and the add-on is used to obtain an interface corresponding to the request information.
[0082] In actual use, the information transmission module 302 is used to:
[0083] Based on the configuration of the interface, no simulation is required, transparently transmitting the request information to the server application;
[0084] Based on the configuration of the interface requiring simulation, interface parameters corresponding to the request information are loaded and transmitted to the server application.
[0085] In summary, the application response simulation device of the embodiment of the present invention first obtains the server application and interface corresponding to the request information when receiving the request information sent by the client application, then transmits the request information to the server application in a corresponding transmission mode based on the configuration of the interface, and finally receives the response data returned by the server application, and transmits the response data to the client application. The application response simulation method and device of the embodiment of the present invention reduces the workload and improves the overall efficiency of the work by adding a simulated application response platform between the client application and the server application and using the simulated application response platform as a medium to perform mutual calls between applications.
[0086] In another possible implementation manner, the embodiment of the present invention further provides a server, Figure 4 A schematic diagram of the structure of a server provided by an embodiment of the present invention is shown. Figure 4 The server includes: a processor 400, a memory 401, a data bus 402 and a communication interface 403, wherein the processor 400, the memory 401, the communication interface 403 are connected via the data bus 402; the processor 400 is used to execute an executable module stored in the memory 401, such as a computer program.
[0087] The memory 401 stores computer executable instructions that can be executed by the processor 400 , and the processor 400 executes the computer executable instructions to implement the method described above.
[0088] Furthermore, the memory 401 may include a high-speed random access memory (RAM), and may also include a non-volatile memory, such as at least one disk memory. The communication connection between the system network element and at least one other network element is realized through at least one communication interface 403 (which may be wired or wireless), and the Internet, wide area network, local area network, metropolitan area network, etc. may be used.
[0089] The data bus 402 may be an ISA data bus, a PCI data bus, or an EISA data bus, etc. The data bus may be divided into an address data bus, a data data bus, a control data bus, etc. For ease of representation, Figure 4 Only one bidirectional arrow is used in the diagram, but this does not mean that there is only one data bus or only one type of data bus.
[0090] Among them, the memory 401 is used to store programs, and the processor 400 executes the program after receiving the program execution instruction. The application response simulation method disclosed in any of the above-mentioned embodiments of the present invention can be applied to the processor 400, or implemented by the processor 400.
[0091] In addition, the processor 400 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the processor 400. The above processor 400 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present invention can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in conjunction with the embodiments of the present invention can be directly embodied as a hardware decoding processor for execution, or a combination of hardware and software modules in the decoding processor for execution. The software module may be located in a storage medium mature in the art, such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 401, and the processor 400 reads the information in the memory 401 and completes the steps of the above method in combination with its hardware.
[0092] In another possible implementation, an embodiment of the present invention further provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are called and executed by a processor, the computer-executable instructions prompt the processor to implement the method described above.
[0093] The application response simulation device provided in the embodiment of the present invention has the same technical features as the application response simulation method provided in the above embodiment, and can therefore solve the same technical problems and achieve the same technical effects.
[0094] The computer program product of the application response simulation method and device provided in the embodiment of the present invention includes a computer-readable storage medium storing program code. The instructions included in the program code can be used to execute the method described in the previous method embodiment. The specific implementation can be found in the method embodiment, which will not be repeated here.
[0095] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0096] In addition, in the description of the embodiments of the present invention, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, and it can be the internal communication of two components. For those skilled in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0097] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage media include: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, RanDom Access Memory), disk or optical disk, and other media that can store program codes.
[0098] In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc., indicating the orientation or positional relationship, are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as limiting the present invention. In addition, the terms "first", "second", and "third" are used for descriptive purposes only, and cannot be understood as indicating or implying relative importance.
[0099] Finally, it should be noted that the above embodiments are only specific implementations of the present invention, which are used to illustrate the technical solutions of the present invention, rather than to limit them. The protection scope of the present invention is not limited thereto. Although the present invention is described in detail with reference to the above embodiments, those skilled in the art should understand that any person skilled in the art can still modify the technical solutions recorded in the above embodiments within the technical scope disclosed by the present invention, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.
Claims
1. An application response simulation method, characterized in that: The method is applied to a simulation application response platform, and the method comprises: When the request information sent by the client application is received, the server application and interface corresponding to the request information are obtained, as follows: Parsing the address of the request information to obtain the path required for matching the address with the server application; Matching the path with the add-on, and using a predetermined correspondence between the server application and the add-on, obtaining a server application corresponding to the request information; Determine a rule item in a rule base corresponding to the request information; Matching the rule item with the add-on, and using a predetermined correspondence between an interface and the add-on, obtaining an interface corresponding to the request information; Based on the configuration of the interface, the request information is transmitted to the server application in a transmission mode corresponding to the configuration, as follows: Based on the configuration of the interface, no simulation is required, transparently transmitting the request information to the server application; Based on the configuration of the interface requiring simulation, loading interface parameters corresponding to the request information and transmitting the interface parameters to the server application; Receive response data returned by the server application, and transmit the response data to the client application.
2. The application response simulation method according to claim 1, characterized in that: When the request information sent by the client application is received, before obtaining the server application and interface corresponding to the request information, it includes: The control loader loads the add-ins required for the app to respond to the simulation process.
3. The application response simulation method according to claim 1, characterized in that: When receiving the request information sent by the client application, obtaining the server application and interface corresponding to the request information includes: When receiving the request information sent by the client application, matching the request information with the add-on by controlling the identifier to obtain the add-on corresponding to the request information; Based on the predetermined correspondence between the server application, the interface and the add-in, the server application and the interface corresponding to the request information are obtained.
4. An application response simulation device, characterized in that: The device is applied to a simulated application response platform, and the device comprises: The information receiving module is used to obtain the server application and interface corresponding to the request information when receiving the request information sent by the client application, as follows: Parsing the address of the request information to obtain the path required for matching the address with the server application; Matching the path with the add-on, and using a predetermined correspondence between the server application and the add-on, obtaining a server application corresponding to the request information; Determine a rule item in a rule base corresponding to the request information; Matching the rule item with the add-on, and using a predetermined correspondence between an interface and the add-on, obtaining an interface corresponding to the request information; An information transmission module is used to transmit the request information to the server application in a transmission mode corresponding to the configuration based on the configuration of the interface, specifically as follows: Based on the configuration of the interface, no simulation is required, transparently transmitting the request information to the server application; Based on the configuration of the interface requiring simulation, loading interface parameters corresponding to the request information and transmitting the interface parameters to the server application; The response data transmission module is used to receive the response data returned by the server application and transmit the response data to the client application.
5. The application response simulation device according to claim 4, characterized in that: Before the information receiving module, the device further includes: The add-in loading module is used to control the loader to load the add-ins required during the application response simulation process.
6. The application response simulation device according to claim 4, characterized in that: The information receiving module is used for: When receiving the request information sent by the client application, matching the request information with the add-on by controlling the identifier to obtain the add-on corresponding to the request information; Based on the predetermined correspondence between the server application, the interface and the add-in, the server application and the interface corresponding to the request information are obtained.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 3 is performed.
Citation Information
Patent Citations
Data transmission method and device
CN111953775A