Business request processing method, device, equipment, storage medium and product

By converting service requests of different protocol types into the same data format and generating packets to be forwarded, the problem of excessive gateway connections is solved, the gateway pressure is reduced, and processing efficiency is improved.

CN114785854BActive Publication Date: 2024-11-26INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210423602.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-21
Publication Date
2024-11-26
Estimated Expiration
2042-04-21

AI Technical Summary

Technical Problem

The existing business request processing methods lead to too many gateway connections and excessive business pressure, which affects the processing efficiency of requests.

Method used

Convert service requests of different protocol types into request data in the same data format, and generate messages to be forwarded based on the request data and send them to the gateway. Only a connection is required to establish a connection with one thread to realize the processing of multiple protocol types.

Benefits of technology

Reduces the service pressure of the gateway, avoids gateway failures, and improves the efficiency of request processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114785854B_ABST
    Figure CN114785854B_ABST
Patent Text Reader

Abstract

The present disclosure provides a method, device, equipment, storage medium and product for processing business requests, which are applied in the field of big data. The method includes: obtaining at least one business request of at least one protocol type sent by a target application; converting at least one business request of the at least one protocol type into request data of the same data format; for each business request, generating a message to be forwarded according to the request data corresponding to the business request and the preset message address corresponding to each business request; sending the message to be forwarded corresponding to each business request to the target gateway, so that the target gateway performs data processing on the message to be forwarded corresponding to each business request. Therefore, the gateway only needs to establish a connection with one thread to realize the processing operation of business requests of multiple different protocol types, which reduces the business pressure of the gateway and avoids the failure of the gateway affecting the processing efficiency of the request.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of big data, and in particular to a business request processing method, device, equipment, storage medium and product. Background Art

[0002] With the improvement of terminal device hardware performance and the continuous advancement of artificial intelligence technology, more and more applications (APPs) are running on terminal devices. Correspondingly, more and more business requests are initiated by applications. Since there may be differences in the protocols of business requests initiated by applications, after obtaining business requests, the gateway often needs to distinguish and process different types of business requests.

[0003] In order to process different types of business requests, the gateway needs to connect to multiple threads on the application side at the same time, which results in too many gateway connections and too much business pressure. This may cause the performance of the gateway node to degrade, affecting the processing efficiency of the request. Summary of the invention

[0004] The present disclosure provides a business request processing method, device, equipment, storage medium and product, which are used to solve the technical problem that the existing business request processing method causes high gateway pressure and affects the processing efficiency of the request.

[0005] A first aspect of the present disclosure is to provide a service request processing method, comprising:

[0006] Obtain at least one service request of at least one protocol type sent by a target application;

[0007] Converting at least one service request of the at least one protocol type into request data in the same data format;

[0008] For each service request, generating a message to be forwarded according to the request data corresponding to the service request and a preset message address corresponding to each service request;

[0009] The to-be-forwarded messages corresponding to the service requests are sent to the target gateway, so that the target gateway performs data processing on the to-be-forwarded messages corresponding to the service requests.

[0010] A second aspect of the present disclosure is to provide a service request processing device, comprising:

[0011] An acquisition module, used for acquiring at least one service request of at least one protocol type sent by a target application;

[0012] A conversion module, used to convert at least one service request of the at least one protocol type into request data in the same data format;

[0013] A generating module, used for generating a message to be forwarded according to the request data corresponding to the service request and a preset message address corresponding to each service request for each service request;

[0014] The sending module is used to send the to-be-forwarded messages corresponding to the service requests to the target gateway, so that the target gateway performs data processing on the to-be-forwarded messages corresponding to the service requests.

[0015] A third aspect of the present disclosure is to provide an electronic device, comprising: a memory, a processor;

[0016] Memory; Memory for storing instructions executable by the processor;

[0017] The processor is used to call the program instructions in the memory to execute the service request processing method as described in the first aspect.

[0018] A fourth aspect of the present disclosure is to provide a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and when the computer-executable instructions are executed by a processor, they are used to implement the service request processing method as described in the first aspect.

[0019] A fifth aspect of the present disclosure is to provide a computer program product, including a computer program, which implements the service request processing method as described in the first aspect when executed by a processor.

[0020] The business request processing method, apparatus, device, storage medium and product provided by the present invention convert at least one business request of at least one protocol type sent by a target application into request data of the same data format after obtaining at least one business request of at least one protocol type, generate a message to be forwarded according to the request data corresponding to the business request and the preset message address corresponding to each business request, and send it to the gateway, so that the gateway only needs to establish a connection with one thread to realize the processing operation of business requests of multiple different protocol types, thereby reducing the business pressure of the gateway and avoiding the failure of the gateway affecting the processing efficiency of the request. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present disclosure, and a person skilled in the art can also obtain other drawings based on these drawings.

[0022] Figure 1 A system architecture diagram on which the existing business request method is based;

[0023] Figure 2 A schematic diagram of the system architecture on which the present disclosure is based;

[0024] Figure 3 A flowchart of a method for processing a business request provided by an embodiment of the present disclosure;

[0025] Figure 4 A flowchart of a method for processing a service request provided by another embodiment of the present disclosure;

[0026] Figure 5 A schematic diagram of the structure of a service request processing device provided by an embodiment of the present disclosure;

[0027] Figure 6 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0028] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, rather than all the embodiments. All other embodiments obtained based on the embodiments in the present disclosure belong to the scope of protection of the present disclosure.

[0029] It should be noted that the business request processing method, device, equipment, storage medium and product provided by the present disclosure can be used in the field of big data. It can also be used in any field other than the financial field. The business request processing method, device, equipment, storage medium and product provided by the present disclosure are not limited to the application field.

[0030] In response to the technical problem mentioned above that the existing service request processing method causes great pressure on the gateway and affects the processing efficiency of the request, the present disclosure provides a service request processing method, device, equipment, storage medium and product.

[0031] It should be noted that the business request processing method, apparatus, device, storage medium and product provided by the present disclosure can be used in various business request data processing scenarios.

[0032] Figure 1 This is the system architecture diagram based on the existing business request method, such as Figure 1 As shown, application A node 11 to application N node 12 can at least issue HTTP type, RPC type and SQL type transaction requests. Accordingly, in order to process transaction requests of different protocol types of each application node, the gateway 13 needs to establish communication connections with at least three threads 14 corresponding to each application node. This results in too many gateway connections and too much business pressure. This may further reduce the performance of the gateway node and affect the processing efficiency of the request.

[0033] In the process of solving the above technical problems, the inventors discovered through research that in order to reduce the pressure on the gateway, before sending the transaction requests of various different protocol types generated by the application node to the gateway, the transaction requests of various different protocol types can be converted into request data of the same data format, and a message to be forwarded is generated and sent to the gateway based on the request data of the same data format and the preset message address corresponding to each business request. In this way, the gateway only needs to establish a connection with one thread to realize the processing operations of business requests of various different protocol types, thereby reducing the business pressure of the gateway and avoiding gateway failures that affect the processing efficiency of requests.

[0034] Figure 2 This is a schematic diagram of the system architecture based on which the present disclosure is based. Figure 2 As shown, the system architecture based on the present disclosure at least includes: an application node 21 and a gateway 22, and the application node 21 is communicatively connected with the gateway 22. The application node 21 is provided with a target application 23 and a service request processing device 24, wherein the service request processing device 24 can be written in languages ​​such as C / C++, Java, Shell or Python.

[0035] Figure 3 A flow chart of a method for processing a business request provided by an embodiment of the present disclosure, such as Figure 3 As shown, the method includes:

[0036] Step 301: Obtain at least one service request of at least one protocol type sent by a target application.

[0037] The execution subject of this embodiment is a service request processing device, which can be coupled to a server. The server can communicate with a terminal device installed with a target application, so as to obtain a service request sent by the target application.

[0038] In this embodiment, the service request sent by the target application may be of multiple different protocol types, for example, the protocol type includes but is not limited to HTTP type, RPC type and SQL type. Accordingly, the service request processing device can obtain at least one service request of at least one protocol type sent by the target application.

[0039] Step 302: Convert at least one service request of the at least one protocol type into request data in the same data format.

[0040] In this embodiment, after obtaining at least one business request of at least one protocol type sent by the target application, in the prior art, in order to process transaction requests of different protocol types of each application node, the target gateway needs to establish communication connections with at least three threads corresponding to each application node. This results in too many connections to the target gateway and too much business pressure. Therefore, in order to reduce the business pressure of the target gateway, at least one business request of at least one protocol type can be converted into request data of the same data format before sending the business request to the target gateway. Therefore, the target gateway only needs to establish a communication connection with one thread, which greatly reduces the business pressure of the target gateway.

[0041] Step 303: For each service request, a message to be forwarded is generated according to the request data corresponding to the service request and a preset message address corresponding to each service request.

[0042] In this embodiment, each service request corresponds to a message address preset by the user. Therefore, after converting at least one service request of at least one protocol type into request data of the same data format, for each service request, a message to be forwarded can be generated according to the request data corresponding to the service request and the message address.

[0043] Step 304: Send the to-be-forwarded messages corresponding to the service requests to the target gateway, so that the target gateway performs data processing on the to-be-forwarded messages corresponding to the service requests.

[0044] In this embodiment, after generating a message to be forwarded according to the request data corresponding to the service request and the message address, the message to be forwarded can be sent to the target gateway, so that the target gateway can perform data processing operations on the message to be forwarded after receiving the message to be forwarded corresponding to each service request.

[0045] Further, based on any of the above embodiments, the at least one protocol type includes at least HTTP type, RPC type and SQL type; step 301 includes:

[0046] An interception operation is performed on at least one service request of the HTTP type through a preset HTTP interceptor to obtain at least one service request of the HTTP type.

[0047] An interception operation is performed on at least one service request of the RPC type through a preset RPC interceptor to obtain at least one service request of the RPC type.

[0048] An interception operation is performed on at least one service request of the SQL type through a preset SQL interceptor to obtain at least one service request of the SQL type.

[0049] In this embodiment, the protocol type includes but is not limited to HTTP type, RPC type and SQL type. In order to be able to obtain the business requests of different protocol types, the interceptors corresponding to the protocol types can be set in the business request processing device. Specifically, at least one business request of HTTP type can be intercepted by a preset HTTP interceptor to obtain at least one business request of HTTP type, wherein the HTTP interceptor can use springIntecepter technology to intercept at least one business request of HTTP type. At least one business request of RPC type is intercepted by a preset RPC interceptor to obtain at least one business request of RPC type, wherein the RPC interceptor can specifically be a dubbo interceptor. At least one business request of SQL type is intercepted by a preset SQL interceptor to obtain at least one business request of SQL type, wherein the SQL interceptor can use mybatis-intecepter technology to intercept at least one business request of SQL type.

[0050] The business request processing method provided in this embodiment converts at least one business request of at least one protocol type sent by the target application into request data of the same data format after obtaining at least one business request of at least one protocol type, generates a message to be forwarded according to the request data corresponding to the business request and the preset message address corresponding to each business request, and sends it to the gateway, so that the gateway only needs to establish a connection with one thread to realize the processing operations of business requests of multiple different protocol types, thereby reducing the business pressure of the gateway and avoiding the influence of gateway failure on the processing efficiency of the request.

[0051] Further, based on any of the above embodiments, step 302 includes:

[0052] Extract parameter information from each service request.

[0053] For each service request, a data splicing operation is performed on the parameter information corresponding to the service request in a preset order, and the spliced ​​parameter information is determined as request data converted into the same data format as the service request.

[0054] The parameter information includes, but is not limited to, node information, resource name, resource type, resource role, transaction input parameter, return structure, transaction tag, business status code, and transaction exception information.

[0055] In this embodiment, in order to realize the conversion of business requests of different protocol types into request data of the same data format, the corresponding parameters in the business request can be abstracted and extracted according to the preset parameter information. Specifically, the parameter information includes but is not limited to node information, resource name, resource type, resource role, transaction input parameter, return structure, transaction tag, business status code, and transaction exception information. Among them, the node information is mainly composed of application name, application node IP, and application node type, which is used to record the source of request data. Resource name is mainly used to define different resource names in the format of transaction name#resource type, for example: the resource name case of HTTP request is: / demo / helloworld#GET, the resource name case of RPC request is: / demo / helloRpc#RPC, and the resource name case of SQL is: select*from dual#SQL. Resource type is mainly divided into three categories: HTTP, RPC, and SQL. Resource role is marked as service provider and service consumer. HTTP and SQL type resources are generally service providers. RPC type resources are judged according to the request situation. Return structure, transaction result. Transaction tag is used to mark which business line the resource belongs to. Business status code, used to distinguish whether the transaction ends normally. Generally, the default value is success. When there is an exception, it is an exception code. Transaction exception, if there is an exception in the transaction, it can be recorded in this definition.

[0056] Therefore, after obtaining at least one service request of a different protocol type, the above-mentioned parameter information in the service request can be extracted for each service request, and multiple parameter information can be spliced ​​in a preset order, and the spliced ​​parameter information is determined as the request data converted into the same data format by the service request.

[0057] Further, based on any of the above embodiments, step 303 includes:

[0058] For each business request, the collection time, node information and transaction information are extracted from the request data corresponding to the business request.

[0059] The collection time, node information and transaction information are determined as a message body.

[0060] The message to be forwarded is generated according to the message address and the message body.

[0061] In this embodiment, after converting service requests of different protocol types into request data of the same data format, for each service request, the collection time, node information and transaction information can be extracted from the request data corresponding to the service request. The collection time, node information and transaction information are determined as a message body, so that a message to be forwarded can be generated according to the message body and the message address.

[0062] The service request processing method provided in this embodiment can convert service requests corresponding to multiple different protocols into request data of the same data format by pre-defining abstract parameters of the service request, so that the subsequent target gateway does not need to establish a thread for each protocol type, thereby reducing the processing pressure of the target gateway.

[0063] Figure 4 A flowchart of a method for processing a business request provided by another embodiment of the present disclosure is shown as follows: Figure 4 As shown, step 304 includes:

[0064] Step 401: Send the to-be-forwarded messages corresponding to the service requests to a preset message queue.

[0065] Step 402: When the message to be forwarded in the message queue meets a preset sending condition, the message to be forwarded in the message queue is asynchronously sent to the target gateway.

[0066] In this embodiment, after the message to be forwarded is generated, the message to be forwarded can be sent to a preset message queue. The message queue can be a fixed-length message queue. An asynchronous thread sdkThread can be established. The asynchronous thread can perform a monitoring operation on the message queue. When the message to be forwarded in the message queue is monitored to meet the preset sending condition, the message to be forwarded in the message queue is asynchronously sent to the target gateway.

[0067] Further, based on any of the above embodiments, step 402 includes:

[0068] When the number of the to-be-forwarded messages in the message queue reaches a preset number threshold, the to-be-forwarded messages in the message queue are asynchronously sent to the target gateway.

[0069] and / or,

[0070] When the time duration for sending the message to be forwarded to the message queue reaches a preset time duration threshold, the message to be forwarded in the message queue is asynchronously sent to the target gateway.

[0071] In this embodiment, the preset sending condition may be that the number of messages to be forwarded in the message queue reaches a preset number threshold. Therefore, when the asynchronous thread monitors that the number of messages to be forwarded in the message queue reaches the preset number threshold, the messages to be forwarded in the message queue are asynchronously sent to the target gateway. The number threshold may be 16, or may be set by the user according to actual needs, and the present disclosure does not limit this.

[0072] Alternatively, the preset sending condition may be that the time taken for the message to be forwarded to be sent to the message queue reaches a preset time threshold. Therefore, when the asynchronous thread monitors that the time taken for the message to be forwarded to be sent to the message queue reaches a preset time threshold, the message to be forwarded in the message queue is asynchronously sent to the target gateway. The preset time threshold may be five seconds, or may be a time set by the user according to actual needs, which is not limited in the present disclosure.

[0073] The above two implementation methods can be implemented separately or in combination. When they are implemented in combination, when the number of messages to be forwarded in the monitored message queue reaches a preset number threshold, the message to be forwarded is sent only when the time it takes for the message to be forwarded to be sent to the message queue reaches a preset time threshold.

[0074] Further, based on any of the above embodiments, step 402 includes:

[0075] When the message to be forwarded in the message queue meets the preset sending condition, a data compression operation is performed on the message to be forwarded in the message queue to obtain compressed data.

[0076] The compressed data is asynchronously sent to a target gateway.

[0077] In this embodiment, in order to further reduce the pressure on the gateway node, when the message to be forwarded is transmitted, the message to be forwarded can be compressed to reduce the amount of data transmitted. Specifically, when it is monitored that the message to be forwarded in the message queue meets the preset sending conditions, the message to be forwarded in the message queue can be compressed to obtain compressed data. The compressed data is asynchronously sent to the target gateway.

[0078] The service request processing method provided in this embodiment can reduce the frequency of sending messages to be forwarded by monitoring that the messages to be forwarded in the message queue meet the preset sending conditions, thereby effectively alleviating the pressure on the target gateway. Alternatively, before the data transmission of the messages to be forwarded, data compression operation is performed, thereby reducing the amount of data transmitted, further reducing the pressure on the target gateway.

[0079] Further, based on any of the above embodiments, after step 302, the method further includes:

[0080] The at least one request data in the same data format is sent to a preset data server for storage.

[0081] In this embodiment, in order to facilitate subsequent data analysis and other operations on business requests, after converting at least one business request of at least one protocol type into at least one request data in the same data format, the at least one request data in the same data format can be sent to a preset data server for storage.

[0082] Further, based on any of the above embodiments, after sending the at least one request data in the same data format to a preset data server for storage, the method further includes:

[0083] A data analysis request sent by a terminal device is obtained, wherein the data analysis request includes a transaction request identifier.

[0084] According to the transaction request identifier, target request data matching the transaction request identifier is obtained from the data server.

[0085] The target request data is fed back to the terminal device.

[0086] In this embodiment, users can perform data analysis operations such as distributed link tracking, application node monitoring, high availability assurance, and traffic recording and playback functions based on business requests according to actual needs. Specifically, a data analysis request sent by a terminal device can be obtained, and the data analysis request includes a transaction request identifier. After obtaining the data analysis request, target request data matching the transaction request identifier can be obtained from the data server. The target request data is fed back to the terminal device so that the user can perform data analysis operations based on the target request data.

[0087] The business request processing method provided in this embodiment can convert at least one business request of at least one protocol type into at least one request data in the same data format, and then send at least one request data in the same data format to a preset data server for storage, thereby facilitating subsequent data analysis and other operations on the business request.

[0088] Figure 5 A schematic diagram of the structure of a service request processing device provided by an embodiment of the present disclosure is shown in FIG. Figure 5As shown, the device includes: an acquisition module 51, a conversion module 52, a generation module 53 and a sending module 54. The acquisition module 51 is used to acquire at least one service request of at least one protocol type sent by the target application; the conversion module 52 is used to convert at least one service request of at least one protocol type into request data of the same data format; the generation module 53 is used to generate a message to be forwarded according to the request data corresponding to the service request and the preset message address corresponding to each service request for each service request; the sending module 54 is used to send the message to be forwarded corresponding to each service request to the target gateway, so that the target gateway performs data processing on the message to be forwarded corresponding to each service request.

[0089] Further, based on any of the above embodiments, the at least one protocol type includes at least HTTP type, RPC type and SQL type; the acquisition module includes: a first interception unit, configured to intercept at least one service request of HTTP type through a preset HTTP interceptor to obtain at least one service request of HTTP type;

[0090] The second interception unit is used to intercept at least one business request of the RPC type through a preset RPC interceptor to obtain at least one business request of the RPC type; the third interception unit is used to intercept at least one business request of the SQL type through a preset SQL interceptor to obtain at least one business request of the SQL type.

[0091] Further, based on any of the above embodiments, the conversion module includes: an extraction unit, used to extract parameter information in each business request; a splicing unit, used to perform data splicing operations on the parameter information corresponding to the business request in a preset order for each business request, and determine the spliced ​​parameter information as the request data converted into the same data format as the business request; wherein the parameter information includes but is not limited to node information, resource name, resource type, resource role, transaction input parameter, return structure, transaction tag, business status code, and transaction exception information.

[0092] Further, based on any of the above embodiments, the generation module includes: for each business request, extracting the collection time, node information and transaction information from the request data corresponding to the business request; a determination unit, used to determine the collection time, node information and transaction information as a message body; a generation unit, used to generate the message to be forwarded according to the message address and the message body.

[0093] Further, based on any of the above embodiments, the sending module includes: a sending unit, used to send the to-be-forwarded messages corresponding to each service request to a preset message queue; and a judgment unit, used to asynchronously send the to-be-forwarded messages in the message queue to the target gateway when the to-be-forwarded messages in the message queue meet the preset sending conditions.

[0094] Further, on the basis of any of the above embodiments, when the messages to be forwarded in the message queue meet the preset sending conditions, the messages to be forwarded in the message queue are asynchronously sent to the target gateway, including: when the number of messages to be forwarded in the message queue reaches a preset number threshold, the messages to be forwarded in the message queue are asynchronously sent to the target gateway; and / or, when the time for the messages to be forwarded to be sent to the message queue reaches a preset time threshold, the messages to be forwarded in the message queue are asynchronously sent to the target gateway.

[0095] Further, based on any of the above embodiments, when the messages to be forwarded in the message queue meet the preset sending conditions, the messages to be forwarded in the message queue are asynchronously sent to the target gateway, including: when the messages to be forwarded in the message queue meet the preset sending conditions, performing data compression operation on the messages to be forwarded in the message queue to obtain compressed data; and asynchronously sending the compressed data to the target gateway.

[0096] Further, based on any of the above embodiments, after converting at least one service request of at least one protocol type into request data of the same data format, it also includes: sending the at least one request data of the same data format to a preset data server for storage.

[0097] Further, based on any of the above embodiments, after sending at least one request data in the same data format to a preset data server for storage, it also includes: obtaining a data analysis request sent by a terminal device, wherein the data analysis request includes a transaction request identifier; obtaining target request data matching the transaction request identifier from the data server according to the transaction request identifier; and feeding back the target request data to the terminal device.

[0098] In order to implement the above embodiment, the present disclosure also provides an electronic device, including: a processor and a memory;

[0099] The memory stores computer-executable instructions;

[0100] The processor executes the computer-executable instructions stored in the memory, so that the processor executes the service request processing method as described in any of the above embodiments.

[0101] Figure 6 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure, such as Figure 6 As shown, the electronic device 600 may be a terminal device or a server. The terminal device may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers (Portable Android Devices, PADs), portable multimedia players (Portable Media Players, PMPs), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 6 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0102] like Figure 6 As shown, the electronic device 600 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 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 device 608 to a random access memory (RAM) 603. Various programs and data required for the operation of the electronic device 600 are also stored in the RAM 603. The processing device 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0103] Typically, the following devices may be connected to the I / O interface 605: input devices 606 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; output devices 607 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices 608 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 609. The communication device 609 may allow the electronic device 600 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 6 The electronic device 600 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.

[0104] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 609, or installed from the storage device 608, or installed from the ROM 602. When the computer program is executed by the processing device 601, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0105] Yet another embodiment of the present disclosure provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When a processor executes the computer-executable instructions, the service request processing method described in any of the above embodiments is implemented.

[0106] Yet another embodiment of the present disclosure provides a computer program product, including a computer program, and when the computer program is executed by a processor, the service request processing method as described in any of the above embodiments is implemented.

[0107] 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.

[0108] Those skilled in the art can understand that all or part of the steps of implementing the above-mentioned method embodiments can be completed by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, the steps of the above-mentioned method embodiments are executed; and the aforementioned storage medium includes: ROM, RAM, disk or optical disk and other media that can store program codes.

[0109] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present disclosure, rather than to limit them. Although the present disclosure has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present disclosure.

Claims

1. A method for processing a business request, characterized in that: include: Obtain at least one service request of at least one protocol type sent by a target application; Extract parameter information from each business request; For each business request, perform a data splicing operation on the parameter information corresponding to the business request in a preset order, and determine the spliced ​​parameter information as the request data converted into the same data format by the business request; wherein the parameter information includes node information, resource name, resource type, resource role, transaction input parameter, return structure, transaction tag, business status code, and transaction exception information; Sending at least one piece of request data in the same data format to a preset data server for storage; For each service request, extracting the collection time, node information and transaction information from the request data corresponding to the service request; determining the collection time, node information and transaction information as a message body; generating a message to be forwarded according to a preset message address corresponding to each service request and the message body; Sending the to-be-forwarded messages corresponding to the service requests to the target gateway, so that the target gateway performs data processing on the to-be-forwarded messages corresponding to the service requests; The sending the to-be-forwarded messages corresponding to the service requests to the target gateway includes: Send the to-be-forwarded messages corresponding to the service requests to a preset message queue, and establish an asynchronous thread, wherein the asynchronous thread is used to perform a monitoring operation on the message queue; When the number of messages to be forwarded in the message queue reaches a preset number threshold, and the time for the messages to be forwarded to be sent to the message queue reaches a preset time threshold, a data compression operation is performed on the messages to be forwarded in the message queue to obtain compressed data; and the compressed data is asynchronously sent to the target gateway through a thread.

2. The method according to claim 1, characterized in that The at least one protocol type includes at least HTTP type, RPC type and SQL type; The obtaining at least one service request of at least one protocol type sent by the target application includes: Performing an interception operation on at least one service request of the HTTP type through a preset HTTP interceptor to obtain at least one service request of the HTTP type; Intercepting at least one service request of the RPC type through a preset RPC interceptor to obtain at least one service request of the RPC type; An interception operation is performed on at least one service request of the SQL type through a preset SQL interceptor to obtain at least one service request of the SQL type.

3. The method according to claim 1, characterized in that: After sending the at least one request data in the same data format to a preset data server for storage, the method further includes: Acquire a data analysis request sent by a terminal device, wherein the data analysis request includes a transaction request identifier; Acquiring target request data matching the transaction request identifier from the data server according to the transaction request identifier; The target request data is fed back to the terminal device.

4. A service request processing device, characterized in that: include: An acquisition module, used for acquiring at least one service request of at least one protocol type sent by a target application; A conversion module, used to convert at least one service request of the at least one protocol type into request data in the same data format; A generating module, used for generating a message to be forwarded according to the request data corresponding to the service request and a preset message address corresponding to each service request for each service request; A sending module, used for sending the to-be-forwarded messages corresponding to the service requests to the target gateway, so that the target gateway performs data processing on the to-be-forwarded messages corresponding to the service requests; The sending module is specifically used to send the to-be-forwarded messages corresponding to the service requests to a preset message queue, and establish an asynchronous thread, wherein the asynchronous thread is used to perform a monitoring operation on the message queue; When the number of messages to be forwarded in the message queue reaches a preset number threshold, and the time for sending the messages to be forwarded to the message queue reaches a preset time threshold, performing a data compression operation on the messages to be forwarded in the message queue to obtain compressed data; Asynchronously sending the compressed data to the target gateway via a thread; The generating module includes: for each service request, extracting the collection time, node information and transaction information from the request data corresponding to the service request; a determining unit, used to determine the collection time, node information and transaction information as a message body; a generating unit, used to generate the message to be forwarded according to the message address and the message body; The conversion module includes: an extraction unit, which is used to extract parameter information from each business request; a splicing unit, which is used to perform data splicing operations on the parameter information corresponding to the business request in a preset order for each business request, and determine the spliced ​​parameter information as the request data converted into the same data format by the business request; wherein the parameter information includes node information, resource name, resource type, resource role, transaction input parameter, return structure, transaction tag, business status code, and transaction exception information; After converting the at least one service request of the at least one protocol type into request data in the same data format, the method further includes: sending the at least one request data in the same data format to a preset data server for storage.

5. An electronic device, characterized in that: include: Memory, processor; Memory; a memory for storing instructions executable by the processor; The processor is used to call the program instructions in the memory to execute the service request processing method according to any one of claims 1 to 3.

6. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and when the computer-executable instructions are executed by a processor, they are used to implement the service request processing method according to any one of claims 1 to 3.