Message conversion method, device, equipment, storage medium and program product

By utilizing target request message templates and data item spaces, the problem of low message conversion efficiency in multi-line routing systems is solved, enabling configurable conversion methods, supporting rapid access for newly connected financial institutions, and improving conversion efficiency and resource utilization.

CN119484635BActive Publication Date: 2025-11-21CHINA CONSTRUCTION BANK +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411282671.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-13
Publication Date
2025-11-21
Estimated Expiration
2044-09-13

AI Technical Summary

Technical Problem

The existing multi-bank routing system requires pre-configuring message conversion methods for each bank when performing message conversion, which results in a large workload and low efficiency for developers, and the interface development for newly connected financial institutions is complex.

Method used

By acquiring the target request message template, request variable data item space, and constant data item space, configurable message transformation is achieved, reducing reliance on developers, improving transformation efficiency, and supporting rapid access for newly connected financial institutions.

Benefits of technology

It eliminates the need to manually write message conversion methods for each bank, reducing conversion difficulty and workload, improving conversion efficiency, and saving network transmission resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119484635B_ABST
    Figure CN119484635B_ABST
Patent Text Reader

Abstract

The application discloses a message conversion method and device, equipment, storage medium and program product, and relates to the technical field of data processing. The method comprises the following steps: obtaining a first analysis result of a first request message sent by a target client, and storing the first analysis result in a request variable data item space in an internal storage space; obtaining a target request message template and first configuration information according to identification information corresponding to the first request message; setting the value of each first standard variable field in the target request message template to the value of a first variable field corresponding to the first standard variable field according to the first configuration information and the request variable data item space, obtaining a request message template after instantiation of the variable field; and setting the value of each first standard constant field in the request message template after instantiation of the variable field to the value of the first standard constant field read from a constant data item space, obtaining a converted second request message. The method improves the message conversion efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data processing, and particularly relates to a message conversion method and device, equipment, a storage medium and a program product. BACKGROUND

[0002] In an enterprise financial management system, the bank accounts of an enterprise are opened in different banks. A multi-bank routing system can manage different bank accounts of an enterprise, and is responsible for distributing a request message sent by the enterprise financial management system to a corresponding bank front-end system according to the bank to which the bank account belongs. Since the required message formats of various banks are different, after receiving a request message, the multi-bank routing system needs to send the request message after performing message conversion according to the required message format of the bank to which the request message is sent.

[0003] At present, after receiving a request message sent by an enterprise financial management system, the multi-bank routing system judges the bank corresponding to the request message, and sends the request message after converting the request message into a message required by the bank according to a preconfigured message conversion mode of the bank.

[0004] However, in the above message conversion process, for each bank, its corresponding message conversion mode needs to be preconfigured in the multi-bank routing system, which requires a developer to write the message conversion mode of each bank, and is difficult and has a large workload, resulting in low message conversion efficiency. SUMMARY

[0005] The present application provides a message conversion method, device, equipment, storage medium and program product, to solve the technical problem of low conversion efficiency when performing message conversion in the related art.

[0006] In a first aspect, the present application provides a message conversion method, comprising:

[0007] obtaining a first analysis result of a first request message sent by a target client, and storing the first analysis result in a request variable data item space in an internal storage space; wherein the first analysis result comprises each first variable field and the value of the first variable field;

[0008] obtaining a target request message template and first configuration information according to the identification information corresponding to the first request message; wherein the target request message template comprises a first standard variable field and a first standard constant field, and the first configuration information is used to indicate the corresponding relationship between the first standard variable field and the first variable field;

[0009] According to the first configuration information and the request variable data item space, a value of each first standard variable field in the target request message template is set as a value of a first variable field corresponding to the first standard variable field, to obtain a request message template after variable field instantiation;

[0010] In the request message template after variable field instantiation, a value of each first standard constant field is set as a value of the first standard constant field read from a constant data item space, to obtain a converted second request message; the constant data item space is located in the internal storage space.

[0011] In a second aspect, the present application provides a message conversion device, which comprises:

[0012] A first obtaining module is configured to obtain a first analysis result of a first request message sent by a target client, and store the first analysis result in a request variable data item space in an internal storage space; the first analysis result comprises each first variable field and a value of the first variable field;

[0013] A second obtaining module is configured to obtain a target request message template and first configuration information according to identification information corresponding to the first request message; the target request message template comprises first standard variable fields and first standard constant fields, and the first configuration information is used to indicate a corresponding relationship between the first standard variable fields and the first variable fields;

[0014] A first setting module is configured to, according to the first configuration information and the request variable data item space, set a value of each first standard variable field in the target request message template as a value of a first variable field corresponding to the first standard variable field, to obtain a request message template after variable field instantiation;

[0015] A second setting module is configured to, in the request message template after variable field instantiation, set a value of each first standard constant field as a value of the first standard constant field read from a constant data item space, to obtain a converted second request message; the constant data item space is located in the internal storage space.

[0016] In a third aspect, the present application further provides an electronic device, which comprises a memory, a processor, and a computer program stored in the memory and executable on the processor; when the processor executes the program, the message conversion method according to any of the present application is implemented.

[0017] In a fourth aspect, the present application further provides a computer readable storage medium, which stores a computer program; when the program is executed by a processor, the message conversion method according to any of the present application is implemented.

[0018] In a fifth aspect, the present application provides a computer program product comprising a computer program which, when executed by a processor, implements the message conversion method according to any one of the present application.

[0019] The technical scheme provided by the present application, on the one hand, the target request message template, the request variable data item space and the constant data item space are used to realize the conversion of the first request message, which realizes the configurable message conversion, and the developers no longer need to write the message conversion mode of each bank, thereby reducing the difficulty and workload of message conversion, thereby improving the message conversion efficiency, and at the same time, realizing the rapid access of the interface of the newly accessed financial institution. On the other hand, the first analysis result is stored in the request variable data item space in the internal storage space, which can realize the rapid reading of the value of the first variable field, thereby further improving the message conversion efficiency. On the other hand, by setting the constant data item space and by dividing the fields into the first standard constant field and the first standard variable field in the target request message template, the content of the constant field does not need to be included in the first request message, thereby reducing the data amount of the first request message under the premise of not affecting the normal operation of the business, thereby saving the network transmission resources. BRIEF DESCRIPTION OF DRAWINGS

[0020] In order to more clearly illustrate the technical scheme of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments. It should be understood that the following drawings only show some embodiments of the present application, and therefore should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.

[0021] Figure 1 A schematic diagram of an application scenario of the message conversion method provided by the embodiments of the present application;

[0022] Figure 2 A flowchart of a message conversion method provided by the embodiments of the present application;

[0023] Figure 3 A schematic diagram of a first request message in the embodiments of the present application;

[0024] Figure 4 A schematic diagram of a target request message template and first configuration information in the embodiments of the present application;

[0025] Figure 5 A schematic diagram of a second request message in the embodiments of the present application;

[0026] Figure 6 A flowchart of another message conversion method provided by the embodiments of the present application;

[0027] Figure 7 A flowchart of another message conversion method provided in an embodiment of the present application is shown in FIG. 6;

[0028] Figure 8 A flowchart of another message conversion method provided in an embodiment of the present application is shown in FIG. 6;

[0029] Figure 9 A flowchart of another message conversion method provided in an embodiment of the present application is shown in FIG. 6;

[0030] Figure 10 A schematic diagram of an application scenario in an embodiment of the present application is shown in FIG. 7;

[0031] Figure 11 A structural schematic diagram of a message conversion device provided in an embodiment of the present application is shown in FIG. 8;

[0032] Figure 12 A structural schematic diagram of an electronic device provided in an embodiment of the present application is shown in FIG. 9. DETAILED DESCRIPTION

[0033] The present application will be further described below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely intended for explaining the present application but not limiting the present application. In addition, it should be noted that only parts related to the present application are shown in the accompanying drawings for the purpose of description.

[0034] It should be noted that similar reference numerals and letters refer to similar items throughout the accompanying drawings, and thus, once an item is defined in one drawing, it need not be further defined and explained in subsequent drawings. Meanwhile, in the description of the present application, the terms "first" and "second" and the like are merely used for distinguishing description but cannot be understood as indicating or implying relative importance. The acquisition, storage, use, processing and the like of data in the technical solutions of the present application comply with the relevant provisions of the national laws and regulations. It should be noted that in the embodiments of the present application, some industry existing solutions, components, models and the like may be mentioned, which should be considered as exemplary, and the purpose is merely to illustrate the feasibility of the implementation of the technical solutions of the present application, but it does not mean that the applicant has or will necessarily use the solutions.

[0035] Figure 1 A schematic diagram of an application scenario of the message conversion method provided in an embodiment of the present application is shown in FIG. 5. As shown in FIG. 5, the message conversion method provided in the present embodiment can be applied to, for example, Figure 1 Figure 1 ​The electronic device 11 in the embodiment can be a computer device, a server, or the like. The electronic device 11 in the embodiment is disposed between the client 12 and the server 13 of the financial institution. The server 13 of the financial institution in the embodiment refers to servers of at least two financial institutions. Figure 1 The number of the financial institutions in the embodiment is exemplarily illustrated as three. The client in the embodiment can be installed in a user terminal such as a mobile phone, a personal computer device, a tablet computer, or a vehicle-mounted terminal. The electronic device 11 is installed with a multi-line routing system. Optionally, a public cloud external connection adaptation platform can be further disposed between the electronic device 11 and the client 12. A front-end machine system of each financial institution can be further disposed between the electronic device 11 and the server 13 of the financial institution. The front-end machine system of the financial institution can be deployed in the same machine as the electronic device 11 or can be separately deployed. The user can generate a request message sent to a corresponding financial institution through the client 12. The public cloud external connection adaptation platform sends the processed request message to the electronic device 11 after performing security processing on the request message. After receiving the request message, the electronic device 11 needs to perform message conversion on the request message according to the message format required by the financial institution to which the processed request message is sent. The electronic device 11 in the embodiment can convert the request message based on the request message template, the request variable data item space, and the constant data item space by executing the message conversion method provided in the embodiment, which realizes configurable message conversion and reduces the difficulty and workload of message conversion, thereby improving the message conversion efficiency.

[0036] The message conversion method of the present application is further described in detail through several specific embodiments.

[0037] Figure 2 A flowchart of a message conversion method provided in an embodiment of the present application. The method can be executed by a message conversion device, which can be realized in the form of hardware and / or software and can be configured in an electronic device. The electronic device herein can be a first electronic device in the Figure 1 The electronic device in the embodiment can be a server. As shown in Figure 2 The message conversion method provided in the embodiment includes the following steps.

[0038] Step 201: Obtain a first analysis result of a first request message sent by a target client and store the first analysis result in a request variable data item space in an internal storage space.

[0039] The first analysis result includes each first variable field and the value of the first variable field.

[0040] The target client in the embodiment refers to a client that needs to request a message. Alternatively, the client in the embodiment can be each client of an enterprise financial management system in an enterprise. The first request message in the embodiment refers to a request message sent to a server of a target financial institution. The financial institution in the embodiment can be a bank, a securities company, or an insurance company, etc.

[0041] A user can enter the client through a browser in a user terminal or an application installed in a user device. The first request message in the embodiment is used to implement business interaction with the server of the target financial institution. Illustratively, the first request message in the embodiment is used to obtain business-related data from the server of the target financial institution.

[0042] In the embodiment, in order to implement message conversion, a first analysis result of the first request message is obtained. In order to improve the efficiency of subsequent message conversion, the first analysis result is stored in a request variable data item space in an internal storage space. The first analysis result in the embodiment includes each first variable field and the value of the first variable field. The variable field in the embodiment refers to a field whose corresponding value will change.

[0043] Figure 3 A schematic diagram of a first request message in an embodiment of the present application is shown in FIG. 3. As shown in FIG. 3, it is assumed that the first request message has three first variable fields, and the three first variable fields and their values are as follows: the first variable field 311, the value of which is 312, the first variable field 321, the value of which is 322, and the first variable field 331, the value of which is 332. Figure 3

[0044] The internal storage space in the embodiment can be a memory, a cache, etc. in an electronic device. The request variable data item space in the embodiment refers to a storage space in the internal storage space that stores the first analysis result. Since the data in the internal storage space is read faster, storing the first analysis result in the internal storage space in the embodiment can facilitate fast reading of the values of the first variable fields when step 203 is subsequently executed, thereby improving the efficiency of message conversion.

[0045] ​Optionally, to further improve the flexibility of the message configuration of the client, before step 201, the message conversion method provided by the embodiment further includes the following steps: determining the variable field included in the request message of each client according to the data item and the message content requirement information of each client, wherein the data item is a set of variable fields; determining the request message configuration information of the client according to the variable field included in the request message of the client and the message format requirement information of the client, wherein the message formats indicated in the message format requirement information of at least two clients are different; and sending the request message configuration information to the client, so that the client generates the request message according to the request message configuration information when sending the request message. This implementation manner can determine the request message configuration information of the client according to the requirement of the client in the same transaction scenario, configure the request message configuration information required by different clients, and improve the flexibility of configuring the request message.

[0046] The message content requirement information of the client is used to indicate the variable field included in the request message of the client. The message format in the embodiment can be Extensible Markup Language (XML) or JavaScript Object Notation (JSON).

[0047] Step 202: obtaining the target request message template and the first configuration information according to the identification information corresponding to the first request message.

[0048] The target request message template includes the first standard variable field and the first standard constant field. The first configuration information is used to indicate the corresponding relationship between the first standard variable field and the first variable field.

[0049] The identification information corresponding to the first request message in the embodiment is used to indicate the server of the target financial institution to which the first request message needs to be sent. Optionally, the identification information corresponding to the first request message in the embodiment can include the financial institution code and / or the transaction code.

[0050] When the target request message template and the first configuration information are obtained, the target request message template and the first configuration information matched with the first request message can be obtained from the pre-stored multiple message templates and their configuration information according to the identification information corresponding to the first request message.

[0051] The target request message template in the embodiment includes two types of fields: the first standard variable field and the first standard constant field. The standard variable field in the embodiment refers to a variable field conforming to the regulation of the target financial institution. The constant field in the embodiment refers to a field with a fixed value, i.e., the value of the constant field in the converted request message sent by different clients of the same financial institution is the same. Exemplarily, the constant field can include at least one of the following: the Internet Protocol (IP) address of the financial institution server, the port, the data exchange class, and other required parameters.

[0052] Figure 4 FIG. 1 is a schematic diagram of a target request message template and first configuration information in an embodiment of the present application. As shown in FIG. 1, it is assumed that the target request message template includes four fields, three of which are first standard constant fields and one of which is a first standard variable field. The four fields are: first standard variable field 411, first standard variable field 421, first standard variable field 431, and first standard constant field 441. The values corresponding to the fields in the target request message template are empty or default values. Figure 4 Figure 4 FIG. 2 is a schematic diagram of the first configuration information in the embodiment. As shown in FIG. 2, the first configuration information indicates the correspondence between the first standard variable fields and the first variable fields: first standard variable field 411 corresponds to first variable field 331, first standard variable field 421 corresponds to first variable field 321, and first standard variable field 431 corresponds to first variable field 311. Figure 4

[0053] Optionally, before step 203, the request message template can be initialized. The initialization process of the request message template includes the following processes: loading the configuration information of each request message template; loading the request message template file of each financial institution in a polling manner; and initializing the request message template file to instantiate a template engine (e.g., freemarker). Exemplarily, the file name of the request message template file can be “interchange name-req.ftl”. After the initialization of the request message template, the target request message template can be quickly determined in step 202, further improving the message conversion efficiency.

[0054] Step 203: According to the first configuration information and the request variable data item space, the value of each first standard variable field in the target request message template is set to the value of the first variable field corresponding to the first standard variable field, to obtain the request message template after the instantiation of the variable field.

[0055] ​​Step 203 is used to dynamically map the first standard variable field in the target request message template, that is, to instantiate the variable field of the target request message template. The implementation process is to fill in the value of the standard variable field in the target request message template.

[0056] For each first standard variable field in the target request message template, based on the first configuration information, the value of the first variable field corresponding to the first standard variable field is read from the request variable data item space, and the value is used as the value of the first standard variable field.

[0057] Step 204: Set the value of each first standard constant field in the request message template after instantiating the variable fields to the value of the first standard constant field read from the constant data item space, and obtain the transformed second request message.

[0058] The constant data items are located in the internal storage space.

[0059] After the variable field is instantiated, the value of the standard constant field in the request message template has not yet been written. Therefore, in step 204, the standard constant field is instantiated.

[0060] In this embodiment, a constant data item space is pre-set. This constant data item space includes standard constant fields and their values. In step 204, the value of each first standard constant field in the request message template after instantiating the variable fields is set to the value of the first standard constant field read from the constant data item space, resulting in the converted second request message.

[0061] Figure 5 This is a schematic diagram of a second request message in an embodiment of this application. Assume... Figure 4 The value of the first standard constant field is 442. Figure 3 as well as Figure 4 On the basis of, such as Figure 5 As shown, the second request message after converting the first request message may include: a first standard variable field 411 and its value 332, a first standard variable field 421 and its value 322, a first standard variable field 431 and its value 312, and a first standard constant field 441 and its value 442.

[0062] In one implementation, in this embodiment, after receiving the second request message, the following operation can also be performed: sending the second request message to the target server. The target server is a server within a target financial institution determined based on the identification information corresponding to the first request message.

[0063] In another implementation, to improve the security in the process of message transmission, the following operation can be further performed after the second request message is obtained: the second request message is encrypted to obtain an encrypted second request message; the encrypted second request message is sent to a target server at a first time, wherein the target server is a server in a target financial institution determined according to the identification information corresponding to the first request message; and a key for decrypting the encrypted second request message is sent to the target server at a second time. The first time is different from the second time.

[0064] In this implementation, the encrypted second request message is sent at a time different from the time when the key for decrypting the encrypted second request message is sent, which avoids the possibility of tampering of the second request message, improves the security of the transmission of the second request message, and further improves the security of the operation of the business.

[0065] It should be noted that in the above two implementations, in the scenario where the financial institution front-end machine system is provided, the target server refers to a server where the front-end machine system of the target financial institution is located. The front-end machine system in this embodiment refers to a system that can call the interface of the financial institution. The front-end machine system can ensure the security of the interface call of the financial institution.

[0066] In related technologies, in a multi-line routing system, in the development process of a newly accessed financial institution interface, a developer needs to connect the interface of the corresponding bank, including assembly of a request message, a request method, message encryption and decryption, and analysis of a response message. However, the message conversion method provided in this embodiment only needs to configure a request message template and corresponding configuration information when a financial institution interface is newly accessed, which simplifies the development process of the newly accessed financial institution interface and improves the rapid access capability of the new financial institution interface.

[0067] Further, after a preset time period after the second request message is sent, the first analysis result in the request variable data item space can be deleted to release the storage space and save storage resources. To facilitate the use of the constant data item space in the subsequent message conversion process, the value in the constant data item space is always retained and does not need to be deleted.

[0068] The message conversion method provided by the embodiment can realize configurable message conversion, and thus the message conversion difficulty and workload are reduced, the message conversion efficiency is improved, and the quick access of a newly accessed financial institution interface is realized. In addition, the first analysis result is stored in the request variable data item space in the internal storage space, the value of the first variable field can be quickly read, and thus the message conversion efficiency is further improved. Furthermore, the constant data item space is set, the fields are divided into the first standard constant field and the first standard variable field in the target request message template, the content of the constant field is not included in the first request message, the data amount of the first request message is reduced without affecting the normal operation of the business, and thus the network transmission resource is saved.

[0069] Figure 6 The flowchart of another message conversion method provided by the embodiment of the application is shown in the figure. The embodiment is based on the embodiment shown in the figure and various optional implementation manners, and the implementation manner of how to obtain the first analysis result of the first request message is described in detail. Figure 2 Figure 6 The message conversion method provided by the embodiment includes the following steps.

[0070] Step 601: Determine the message format of the first request message.

[0071] In an implementation manner, step 601 is implemented by the following steps: determining the identification of the target client according to the source address of the first request message; determining the message format corresponding to the identification of the target client according to the mapping relationship between the identification of the client and the message format; and determining the message format corresponding to the identification of the target client as the message format of the first request message. Table 1 shows the mapping relationship between the identification of the client and the message format. This implementation manner can efficiently and accurately determine the message format of the first request message.

[0072] Table 1: Mapping relationship between identification of client and message format

[0073] Identification of the client Message format Identification 61 JSON Identification 62 XML Identification 63 XML

[0074] ​In another implementation, the step 601 is implemented by inputting the first request message into a pre-trained message format identification model to obtain a message format of the first request message output by the message format identification model. The message format identification model is a model trained according to training request messages. This implementation realizes the message format identification model trained based on big data to identify the message format of the request message, and improves the accuracy of the identified message format.

[0075] Step 602: Obtain a message analysis tool of the first request message according to the message format of the first request message.

[0076] The message analysis tool in this embodiment is a pre-packaged program for analyzing the message format of the request message. Different message formats correspond to different message analysis tools: an XML format corresponds to an XML analysis tool, and a JSON format corresponds to a JSON analysis tool.

[0077] Step 603: Analyze the first request message by using the message analysis tool of the first request message to obtain a first analysis result of the first request message, and store the first analysis result in a request variable data item space in an internal storage space.

[0078] The first analysis result includes each first variable field and the value of the first variable field.

[0079] In this embodiment, the first request message can be analyzed by using the message analysis tool of the first request message, which improves the efficiency of message analysis, and further improves the message conversion efficiency.

[0080] Step 604: Obtain a target request message template and first configuration information according to the identification information corresponding to the first request message.

[0081] The target request message template includes first standard variable fields and first standard constant fields. The first configuration information is used to indicate the corresponding relationship between the first standard variable fields and the first variable fields.

[0082] Step 605: According to the first configuration information and the request variable data item space, set the value of each first standard variable field in the target request message template to the value of the first variable field corresponding to the first standard variable field, to obtain a request message template after instantiation of the variable field.

[0083] Step 606: Set the value of each first standard constant field in the request message template after instantiation of the variable field to the value of the first standard constant field read from the constant data item space, to obtain a converted second request message.

[0084] The constant data item space is located in the internal storage space.

[0085] The implementation process and technical principles of steps 604, 202, 605, 203, and 606, 204 are similar, and are not described herein again.

[0086] The packet conversion method provided in this embodiment obtains the packet analysis tool of the first request packet according to the packet format of the first request packet, analyzes the first request packet by using the packet analysis tool of the first request packet, and obtains the first analysis result of the first request packet, thereby improving the packet analysis efficiency and further improving the packet conversion efficiency.

[0087] Figure 7 A flowchart of another packet conversion method provided in this embodiment is shown. In this embodiment, the packet conversion method includes the following steps. Figure 2 and Figure 6 Based on the embodiments and various optional implementation manners shown in the foregoing embodiments, the implementation manner of how to obtain the target request packet template and the first configuration information is described in detail. As shown in Figure 7 The packet conversion method provided in this embodiment includes the following steps.

[0088] Step 701: Obtain the first analysis result of the first request packet sent by the target client, and store the first analysis result in the request variable data item space in the internal storage space.

[0089] The first analysis result includes each first variable field and the value of the first variable field.

[0090] The implementation manner and technical principles of step 701 and step 201 are similar, and are not described herein again.

[0091] In this embodiment, the request packet template is a packet template stored after encryption, and the first configuration information is information stored after encryption, so that the packet template and the first configuration information are prevented from being attacked, the security in the request packet conversion process is improved, and the information security is ensured.

[0092] Step 702: Obtain the verification information of the first request packet sent by the target client.

[0093] The verification information of the first request packet in this embodiment is used to verify the security of the first request packet. For example, the verification information of the first request packet can be a cyclic redundancy check (CRC) code of the first request packet or a hash value of the first request packet.

[0094] Step 703: verifying the security of the first request message according to the verification information of the first request message, and obtaining a security verification result.

[0095] Optionally, the security of the first request message can be verified according to the verification information of the first request message and standard verification information pre-stored or obtained: if the verification information of the first request message is consistent with the standard verification information, the security verification result is verification passed; if the verification information of the first request message is inconsistent with the standard verification information, the security verification result is verification failed. The standard verification information refers to the verification information corresponding to the transmission of the correct first request message.

[0096] Step 704: if the security verification result is verification passed, obtaining the identification information corresponding to the first request message.

[0097] In the embodiment, the subsequent steps are executed only when it is determined that the security verification result of the first request message is verification passed, thereby improving the security of message conversion and the success rate of business.

[0098] Optionally, if the security verification result is verification failed, the message sending failure information is fed back to the target client.

[0099] Optionally, in the embodiment, the identification information corresponding to the first request message includes a financial institution code and / or a transaction code. In one implementation, in step 704, the identification information corresponding to the first request message can be determined according to the values of part of the first variable fields in each first variable field. In the implementation, the financial institution code and / or the transaction code are contained in the first request message. In another implementation, in step 704, the identification information corresponding to the first request message can be determined according to the target client. In the implementation, the identification information corresponding to the first request message can be determined based on the target client sending the first request message and the mapping relationship between the client and the identification information. The two implementations can accurately determine the identification information corresponding to the first request message, thereby improving the success rate of message conversion.

[0100] Step 705: obtaining the ciphertext of the target request message template and the ciphertext of the first configuration information according to the identification information corresponding to the first request message.

[0101] In the embodiment, the encryption mode of the target request message template and the first configuration information is not limited.

[0102] Step 706: decrypting the ciphertext of the target request message template to obtain the target request message template.

[0103] Step 707: decrypting the ciphertext of the first configuration information to obtain the first configuration information.

[0104] The target request message template includes a first standard variable field and a first standard constant field. The first configuration information is used to indicate a correspondence between the first standard variable field and the first variable field.

[0105] In step 706, the ciphertext of the target request message template is decrypted to obtain the target request message template. In step 707, the ciphertext of the first configuration information is decrypted to obtain the first configuration information.

[0106] Step 708: According to the first configuration information and the request variable data item space, the value of each first standard variable field in the target request message template is set to the value of the first variable field corresponding to the first standard variable field, to obtain a request message template after variable field instantiation.

[0107] Step 709: In the request message template after variable field instantiation, the value of each first standard constant field is set to the value of the first standard constant field read from the constant data item space, to obtain a converted second request message.

[0108] The constant data item space is located in the internal storage space.

[0109] The implementation manners and technical principles of steps 708, 203 and 709, 204 are similar, and will not be described here.

[0110] The message conversion method provided in this embodiment, on the one hand, by acquiring the verification information of the first request message sent by the target client, verifying the security of the first request message according to the verification information of the first request message, acquiring the security verification result, if the security verification result is verification passed, acquiring the identification information corresponding to the first request message, it is realized that when the security verification result of the first request message is verified, only the subsequent steps are executed, which improves the security of message conversion and the success rate of business. On the other hand, the request message template is an encrypted message template, and the first configuration information is encrypted information stored, so as to avoid the message template and the first configuration information being attacked, improve the security in the process of request message conversion, and ensure the information security.

[0111] Figure 8 Another flowchart of the message conversion method provided in this embodiment is shown. This embodiment is based on the embodiments shown in Figure 2 、 Figure 6 、 Figure 7 The message conversion method provided in this embodiment includes the following steps. Figure 8

[0112] ​Step 801: obtaining a first analysis result of a first request message sent by a target client, and storing the first analysis result in a request variable data item space in an internal storage space.

[0113] The first analysis result includes each first variable field and a value of the first variable field.

[0114] Step 802: obtaining a target request message template and first configuration information according to identification information corresponding to the first request message.

[0115] The target request message template includes a first standard variable field and a first standard constant field. The first configuration information is used to indicate a corresponding relationship between the first standard variable field and the first variable field.

[0116] The implementation process and technical principles of step 801 and step 201, and step 802 and step 202 are similar, and will not be repeated here.

[0117] Step 803: comparing a number of the first variable fields with a number of the first standard variable fields.

[0118] In the embodiment, in order to avoid conversion failure, the number of the first variable fields is compared with the number of the first standard variable fields, so as to avoid the conversion failure caused by the fact that part of the first standard variable fields in the target request message template cannot read corresponding values in the scenario where the number of the first variable fields is less than the number of the first standard variable fields.

[0119] Step 804: if the number of the first variable fields is greater than or equal to the number of the first standard variable fields, determining a step of performing step 806.

[0120] It can be understood that successful conversion can be realized in step 804.

[0121] Step 805: if the number of the first variable fields is less than the number of the first standard variable fields, processing according to a processing strategy corresponding to the target client.

[0122] In an implementation manner, if the number of the first variable fields is less than the number of the first standard variable fields, message sending failure information is sent to the target client.

[0123] In another implementation manner, step 805 includes steps 8051 to 8055.

[0124] Step 8051: determining a vacancy first standard variable field in the first standard variable field.

[0125] The vacancy first standard variable field is a field for which a corresponding value cannot be obtained from the request variable data item space.

[0126] Step 8052: determining, according to the first configuration information, a missing first variable field corresponding to the missing first standard variable field.

[0127] Step 8053: sending a data acquisition message to the target client.

[0128] The data acquisition message is used to instruct the target client to feed back the value of the missing first variable field.

[0129] Step 8054: if a data feedback message sent by the target client according to the data acquisition message is received, obtaining the first variable field and the corresponding value in the data feedback message, and storing the first variable field and the corresponding value in the data feedback message in the request variable data item space, and returning to step 803.

[0130] In step 8054, the data feedback message from the target client can be obtained, so that the first variable field and the corresponding value in the data feedback message are obtained, and the first variable field and the corresponding value in the data feedback message are stored in the request variable data item space. At this time, the execution of step 803 is returned.

[0131] Step 8055: if the data feedback message sent by the target client according to the data acquisition message is not received within a preset time length, sending a message sending failure information to the target client.

[0132] In step 8055, the target client does not feed back according to the data acquisition message within a preset time length, which means that the message conversion process cannot be successful, and the message sending failure information is sent to the target client.

[0133] Step 806: according to the first configuration information and the request variable data item space, setting the value of each first standard variable field in the target request message template to the value of the first variable field corresponding to the first standard variable field, to obtain a request message template after instantiation of the variable field.

[0134] Step 807: setting the value of each first standard constant field in the request message template after instantiation of the variable field to the value of the first standard constant field read from the constant data item space, to obtain a converted second request message.

[0135] The constant data item space is located in the internal storage space.

[0136] The implementation process and technical principles of step 806 and step 203, and step 807 and step 204 are similar, and will not be repeated here.

[0137] The message conversion method provided in the embodiment compares the number of first variable fields with the number of first standard variable fields. If the number of first variable fields is greater than or equal to the number of first standard variable fields, the step of instantiating the target request message template is determined to be performed. If the number of first variable fields is less than the number of first standard variable fields, the target client corresponding processing strategy is used for processing. The number of first variable fields is compared with the number of first standard variable fields, so that the conversion failure caused by the fact that part of the first standard variable fields in the target request message template cannot read the corresponding value in the scenario where the number of first variable fields is less than the number of first standard variable fields is avoided, and the message conversion success rate is improved.

[0138] Figure 9 The flowchart of another message conversion method provided in the embodiment is shown. Based on the embodiments shown in Figure 2 、 Figure 6 、 Figure 7 、 Figure 8 The steps of how to convert the response message fed back by the target server are described in detail. For simplicity, only the steps included in the message conversion method are described in the embodiment. As shown in Figure 9 The message conversion method provided in the embodiment further includes the following steps.

[0139] Step 901: A second request message is sent to a target server, and a first response message sent by the target server according to the second request message is received.

[0140] The target server is a server in a target financial institution determined according to the identification information corresponding to the first request message.

[0141] In the embodiment, after the second request message is converted, the second request message is sent to the target server. Exemplarily, the second request message can be sent through the Internet or through a dedicated line.

[0142] Optionally, in the scenario where a financial institution front-end system is arranged between the multi-line routing system and the server of the financial institution, in step 901, the second request message is sent to the target server through the front-end system of the target financial institution.

[0143] After the target server receives the second request message, the second request message is parsed. According to the parsing result, the response content is determined and encapsulated into the first response message, and then the first response message is directly sent or sent through the front-end system to the multi-line routing system.

[0144] Step 902: A second parsing result of the first response message is obtained, and the second parsing result is stored in a response variable data item space in an internal storage space.

[0145] The second analysis result includes each second standard variable field and a value of the second standard variable field.

[0146] Step 902 is similar to the implementation process and technical principle of step 201, which will not be described here. The difference is that the second analysis result in step 902 includes the second standard variable field and the corresponding value. The implementation manner of the response variable data item space is similar to that of the request variable data item space.

[0147] Step 903: obtaining a target response message template and second configuration information according to the identification information corresponding to the first response message.

[0148] The target response message template includes a second variable field, and the second configuration information is used to indicate the corresponding relationship between the second standard variable field and the second variable field.

[0149] Step 903 is similar to the implementation process and technical principle of step 202, which will not be described here. The difference is that the target response message template is obtained in step 903.

[0150] Optionally, before step 903, the initialization of the response message template can be performed. For example, the file name of the response message template file can be “interchange name-rsp.ftl”.

[0151] Step 904: setting the value of each second variable field in the target response message template to the value of the second standard variable field corresponding to the second variable field according to the second configuration information and the response variable data item space, to obtain a converted second response message.

[0152] Step 904 is similar to the implementation process and technical principle of step 203, which will not be described here. The difference is that in step 904, the value of each second variable field in the target response message template is set to the value of the second standard variable field corresponding to the second variable field.

[0153] Step 905: sending the second response message to the target client.

[0154] Optionally, the message conversion method provided in the embodiment further includes the following steps: obtaining a third analysis result of the first response message, wherein the third analysis result includes a second standard constant field and a value of the second standard constant field; and updating the field and the corresponding value in the second standard constant field which are not stored in the constant data item space to the constant data item space. This implementation manner realizes updating the constant data item space according to the standard constant field in the response message and the value of the standard constant field, so as to facilitate the use of the data in the constant data item space in the subsequent message conversion process, and further improves the message conversion efficiency.

[0155] Figure 10 Fig. 1 is a schematic diagram of an application scenario of an embodiment of the present application. As shown in Fig. 1, in the embodiment, the message conversion process includes a conversion process of a request message and a conversion process of a response message. Figure 10

[0156] The conversion process of the request message includes the following processes: the target client A sends a first request message; the multi-line routing system obtains a first analysis result of the first request message and stores the first analysis result in a request variable data item space; according to identification information corresponding to the first request message, a target request message template and first configuration information are obtained; steps 203 and 204 are performed to obtain a second request message, and the second request message is sent to the target server.

[0157] The conversion process of the response message includes the following processes: after the target server receives the second request message, a first response message is generated and sent; the multi-line routing system obtains a second analysis result of the first response message and stores the second analysis result in a response variable data item space; according to identification information corresponding to the first response message, a target response message template and second configuration information are obtained; step 904 is performed to obtain a second response message, and the second response message is sent to the target client A.

[0158] The message conversion method provided by the embodiment, on the one hand, realizes the conversion process of the request message and the conversion process of the response message, and improves the communication efficiency between the client and the server of the financial institution. On the other hand, the constant data item space is updated according to the standard constant field in the response message and the value of the standard constant field, so that the data in the constant data item space is used in the subsequent message conversion process, and the message conversion efficiency is further improved.

[0159] Figure 11 Fig. 2 is a structural schematic diagram of a message conversion device provided by an embodiment of the present application. As shown in Fig. 2, the message conversion device provided by the embodiment includes the following modules: a first obtaining module 111, a second obtaining module 112, a first setting module 113, and a second setting module 114. Figure 11

[0160] The first obtaining module 111 is configured to obtain a first analysis result of a first request message sent by a target client, and store the first analysis result in a request variable data item space in an internal storage space.

[0161] The first analysis result includes each first variable field and the value of the first variable field.

[0162] The second obtaining module 112 is configured to obtain a target request message template and first configuration information according to identification information corresponding to the first request message. ​​

[0163] The target request message template includes a first standard variable field and a first standard constant field. The first configuration information is used to indicate a correspondence between the first standard variable field and a first variable field.

[0164] The first setting module 113 is configured to set a value of each first standard variable field in the target request message template to a value of a first variable field corresponding to the first standard variable field according to the first configuration information and the request variable data item space, to obtain a request message template after instantiation of the variable field.

[0165] The second setting module 114 is configured to set a value of each first standard constant field in the request message template after instantiation of the variable field to a value of the first standard constant field read from a constant data item space, to obtain a converted second request message.

[0166] The constant data item space is located in the internal storage space.

[0167] In an embodiment, the apparatus further includes a first determining module, a second determining module, and a sending module.

[0168] The first determining module is configured to determine variable fields included in a request message of each client according to data items and message content requirement information of each client.

[0169] The data items are a set of variable fields.

[0170] The second determining module is configured to determine request message configuration information of the client according to the variable fields included in the request message of the client and message format requirement information of the client.

[0171] The message format requirement information of at least two clients indicates different message formats.

[0172] The sending module is configured to send the request message configuration information to the client, so that the client generates a request message according to the request message configuration information when sending the request message.

[0173] In an embodiment, the apparatus further includes a third determining module and a third obtaining module.

[0174] The third determining module is configured to determine a message format of the first request message.

[0175] The third obtaining module is configured to obtain a message parsing tool of the first request message according to the message format of the first request message.

[0176] In the aspect of obtaining the first analysis result of the first request message sent by the target client, the first obtaining module 111 is specifically configured to: analyze the first request message by using a message analysis tool of the first request message to obtain the first analysis result of the first request message.

[0177] In an embodiment, the third determining module is specifically configured to: determine the identity of the target client according to the source address of the first request message; determine the message format corresponding to the identity of the target client according to the mapping relationship between the identity of the client and the message format; and determine the message format corresponding to the identity of the target client as the message format of the first request message.

[0178] In an embodiment, the third determining module is specifically configured to: input the first request message into a pre-trained message format identification model to obtain the message format of the first request message output by the message format identification model. The message format identification model is a model obtained by training according to training request messages.

[0179] In an embodiment, the request message template is a message template stored after encryption, and the first configuration information is information stored after encryption. The device further includes a fourth obtaining module and a security verification module.

[0180] The fourth obtaining module is configured to obtain verification information of the first request message sent by the target client.

[0181] The security verification module is configured to verify the security of the first request message according to the verification information of the first request message to obtain a security verification result.

[0182] The second obtaining module 112 is specifically configured to: if the security verification result is verified, obtain the identity information corresponding to the first request message; obtain the ciphertext of the target request message template and the ciphertext of the first configuration information according to the identity information corresponding to the first request message; decrypt the ciphertext of the target request message template to obtain the target request message template; and decrypt the ciphertext of the first configuration information to obtain the first configuration information.

[0183] In an embodiment, the identity information corresponding to the first request message includes a financial institution code and / or a transaction code. In the aspect of obtaining the identity information corresponding to the first request message, the second obtaining module 112 is specifically configured to: determine the identity information corresponding to the first request message according to the values of part of the first variable fields in the first request message; or determine the identity information corresponding to the first request message according to the target client.

[0184] In an embodiment, the apparatus further comprises a comparison module, a fourth determination module and a processing module.

[0185] The comparison module is configured to compare the number of the first variable fields with the number of the first standard variable fields.

[0186] The fourth determination module is configured to determine to perform the steps performed by the first setting module 113 if the number of the first variable fields is greater than or equal to the number of the first standard variable fields.

[0187] The processing module is configured to perform processing according to the processing strategy corresponding to the target client if the number of the first variable fields is less than the number of the first standard variable fields.

[0188] In an embodiment, the processing module is specifically configured to determine a missing first standard variable field in the first standard variable fields, wherein the missing first standard variable field is a field for which a corresponding value cannot be obtained from the request variable data item space; determine a missing first variable field corresponding to the missing first standard variable field according to the first configuration information; send a data acquisition message to the target client, wherein the data acquisition message is used to instruct the target client to feed back the value of the missing first variable field; if a data feedback message sent by the target client according to the data acquisition message is received, obtain the first variable field and the corresponding value in the data feedback message and store the first variable field and the corresponding value in the request variable data item space, and return to perform the steps performed by the comparison module; and if the data feedback message sent by the target client according to the data acquisition message is not received within a preset time length, send a message sending failure information to the target client.

[0189] In an embodiment, the apparatus further comprises an encryption module. The encryption module is configured to encrypt the second request message to obtain an encrypted second request message. The sending module is further configured to send the encrypted second request message to a target server at a first time, wherein the target server is a server in a target financial institution determined according to the identification information corresponding to the first request message. The sending module is further configured to send a key for decrypting the encrypted second request message to the target server at a second time. The first time and the second time are different.

[0190] In an embodiment, the sending module is further configured to send the second request message to the target server and receive a first response message sent by the target server according to the second request message, wherein the target server is a server in a target financial institution determined according to the identification information corresponding to the first request message. The device further comprises a fifth obtaining module, a sixth obtaining module, and a third setting module.

[0191] The fifth obtaining module is configured to obtain a second analysis result of the first response message and store the second analysis result in a response variable data item space in the internal storage space, wherein the second analysis result comprises each second standard variable field and a value of the second standard variable field.

[0192] The sixth obtaining module is configured to obtain a target response message template and second configuration information according to the identification information corresponding to the first response message.

[0193] The target response message template comprises a second variable field, and the second configuration information is used to indicate a corresponding relationship between the second standard variable field and the second variable field.

[0194] The third setting module is configured to set a value of each second variable field in the target response message template to a value of the second standard variable field corresponding to the second variable field according to the second configuration information and the response variable data item space, to obtain a converted second response message.

[0195] The sending module is further configured to send the second response message to the target client.

[0196] In an embodiment, the device further comprises a seventh obtaining module and an updating module.

[0197] The seventh obtaining module is configured to obtain a third analysis result of the first response message, wherein the third analysis result comprises a second standard constant field and a value of the second standard constant field.

[0198] The updating module is configured to update a field and a corresponding value in the second standard constant field that are not stored in the constant data item space to the constant data item space.

[0199] The message conversion device provided by the embodiments of the present application can be used to execute the technical solutions of the message conversion method in the above embodiments, and has similar implementation principles and technical effects, which will not be described here.

[0200] It should be noted that the division of each module of the above apparatus is only a logical function division, and all or part of them can be integrated into a physical entity or physically separated when actually implemented. And these modules can all be realized in the form of software called by a processing element; all can be realized in the form of hardware; and part of the modules can be realized in the form of software called by a processing element, and part of the modules can be realized in the form of hardware. For example, the first acquisition module 111, the second acquisition module 112, the first setting module 113 and the second setting module 114 can be separate processing elements, or can be integrated in a chip of the above apparatus, in addition, they can also be stored in the form of program code in the memory of the above apparatus, and the functions of the above first acquisition module 111, the second acquisition module 112, the first setting module 113 and the second setting module 114 are called and executed by a processing element of the above apparatus. The implementation of other modules is similar. In addition, all or part of these modules can be integrated together or independently implemented. The processing element here can be an integrated circuit with signal processing capability. In the implementation process, each step of the above method or each module can be completed by integrated logic circuit of hardware or instruction of software in the processing element.

[0201] Figure 12 The structure schematic diagram of the electronic device provided by the embodiment of the application is shown in the figure. Figure 12 As shown in the figure, the electronic device can include a processor 142 and a memory 143.

[0202] The processor 142 executes the computer execution instructions stored in the memory, so that the processor 142 executes the scheme in the above embodiment. The processor 142 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 gate or transistor logic devices, discrete hardware components.

[0203] The memory 143 is connected with the processor 142 through a system bus and completes mutual communication, and the memory 143 is used for storing computer program instructions.

[0204] Optionally, the electronic device can further include a transceiver 141. The transceiver 141 can be used to receive the first request message. The transceiver 141 can also be used to send the second request message.

[0205] The system bus can be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, etc. The system bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or only one type of bus. The transceiver is used to realize the communication between the message conversion device and other computer equipment. The memory can include random access memory (RAM), and can also include non-volatile memory.

[0206] The embodiment of the present application also provides a chip for running instructions, which is used for executing the technical solutions of the message conversion method in the above embodiments.

[0207] The embodiment of the present application also provides a computer readable storage medium, which stores computer instructions, and when the computer instructions are run on a computer, the computer executes the technical solutions of the message conversion method in the above embodiments.

[0208] The embodiment of the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, the computer program implements the message conversion method provided by any embodiment of the present application.

[0209] In the implementation process of the computer program product, the computer program code for executing the operations of the present application can be written in one or more program design languages or combinations thereof, including object-oriented program design languages such as Java, Smalltalk, C++, and conventional procedural program design languages such as "C" language or similar program design languages. The program code can be completely executed on a user computer, partially executed on a user computer, executed as a separate software package, partially executed on a user computer and partially executed on a remote computer, or completely executed on a remote computer or server. In the case involving a remote computer, the remote computer can be connected to the user computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, connected to the Internet through an Internet service provider).

[0210] Note that the above merely describes preferred embodiments of the application and the principles of the application. It will be understood by those skilled in the art that the application is not limited to the specific embodiments described herein, and that changes, modifications and substitutions can be made by those skilled in the art without departing from the scope of the application. Therefore, although the application has been described in detail by the above embodiments, the application is not limited to the above embodiments, and can include more other equivalent embodiments without departing from the concept of the application, and the scope of the application is determined by the appended claims.

Claims

1. A message conversion method, characterized in that, include: Obtain the first parsing result of the first request message sent by the target client, and store the first parsing result in the request variable data item space in the internal storage space; wherein, the first parsing result includes each first variable field and the value of the first variable field; Based on the identification information corresponding to the first request message, a target request message template and first configuration information are obtained; wherein, the target request message template includes a first standard variable field and a first standard constant field, and the first configuration information is used to indicate the correspondence between the first standard variable field and the first variable field; Based on the first configuration information and the request variable data item space, the value of each first standard variable field in the target request message template is set to the value of the first variable field corresponding to the first standard variable field, so as to obtain the request message template after instantiating the variable fields; In the request message template after instantiating the variable fields, the value of each first standard constant field is set to the value of the first standard constant field read from the constant data item space to obtain the transformed second request message; wherein, the constant data item space is located in the internal storage space.

2. The method according to claim 1, characterized in that, Before obtaining the first parsing result of the first request message sent by the target client, the method further includes: Based on the data items and the message content requirements of each client, determine the variable fields included in the request message of each client; wherein, the data item is a set of variable fields; Based on the variable fields included in the client's request message and the client's message format requirement information, the client's request message configuration information is determined; wherein, at least two clients have different message formats indicated in their message format requirement information. The request message configuration information is sent to the client so that the client generates a request message based on the request message configuration information when sending a request message.

3. The method according to claim 1, characterized in that, Before obtaining the first parsing result of the first request message sent by the target client, the method further includes: Determine the message format of the first request message; Based on the message format of the first request message, obtain the message parsing tool for the first request message; The step of obtaining the first parsing result of the first request message sent by the target client includes: The first request message is parsed using the message parsing tool of the first request message to obtain the first parsing result of the first request message.

4. The method according to claim 3, characterized in that, Determining the message format of the first request message includes: The identifier of the target client is determined based on the source address of the first request message; Based on the mapping relationship between the client's identifier and the message format, determine the message format corresponding to the identifier of the target client; The message format corresponding to the identifier of the target client is determined as the message format of the first request message.

5. The method according to claim 3, characterized in that, Determining the message format of the first request message includes: The first request message is input into a pre-trained message format recognition model to obtain the message format of the first request message output by the message format recognition model; wherein, the message format recognition model is a model trained based on the training request message.

6. The method according to any one of claims 1 to 5, characterized in that, The request message template is an encrypted message template, and the first configuration information is encrypted information. Before obtaining the target request message template and the first configuration information based on the identifier information corresponding to the first request message, the method further includes: Obtain the verification information of the first request message sent by the target client; The security of the first request message is verified based on the verification information of the first request message, and the security verification result is obtained. The step of obtaining the target request message template and the first configuration information based on the identifier information corresponding to the first request message includes: If the security verification result is successful, then obtain the identification information corresponding to the first request message; Based on the identification information corresponding to the first request message, obtain the ciphertext of the target request message template and the ciphertext of the first configuration information; The ciphertext of the target request message template is decrypted to obtain the target request message template; The encrypted first configuration information is decrypted to obtain the first configuration information.

7. The method according to claim 6, characterized in that, The identification information corresponding to the first request message includes: financial institution code and / or transaction code; The step of obtaining the identifier information corresponding to the first request message includes: The identification information corresponding to the first request message is determined based on the values ​​of some of the first variable fields in each of the aforementioned first variable fields; or... Based on the target client, determine the identification information corresponding to the first request message.

8. The method according to any one of claims 1 to 5, characterized in that, Before setting the value of each first standard variable field in the target request message template to the value of the first variable field corresponding to the first standard variable field according to the first configuration information and the request variable data item space, and obtaining the request message template after instantiating the variable fields, the method further includes: Compare the number of fields in the first variable with the number of fields in the first standard variable; If the number of the first variable fields is greater than or equal to the number of the first standard variable fields, then the step of "setting the value of each first standard variable field in the target request message template to the value of the first variable field corresponding to the first standard variable field according to the first configuration information and the request variable data item space, so as to obtain the request message template after instantiating the variable fields" is executed. If the number of the first variable fields is less than the number of the first standard variable fields, then the processing is performed according to the processing strategy corresponding to the target client.

9. The method according to claim 8, characterized in that, If the number of the first variable fields is less than the number of the first standard variable fields, then processing is performed according to the processing strategy corresponding to the target client, including: Identify the missing first standard variable fields in the first standard variable fields; wherein, the missing first standard variable field is a field whose corresponding value cannot be obtained from the requested variable data item space; Based on the first configuration information, determine the missing first variable field corresponding to the missing first standard variable field; Send a data acquisition message to the target client; wherein the data acquisition message is used to instruct the target client to return the value of the missing first variable field; If a data feedback message is received from the target client based on the data acquisition message, the first variable field and its corresponding value in the data feedback message are obtained, and the first variable field and its corresponding value in the data feedback message are stored in the request variable data item space. Then, the step of "comparing the number of the first variable field with the number of the first standard variable field" is returned. If no data feedback message is received from the target client based on the data acquisition message within the preset time period, a message transmission failure message is sent to the target client.

10. The method according to any one of claims 1 to 5, characterized in that, The method further includes: The second request message is encrypted to obtain the encrypted second request message; The encrypted second request message is sent to the target server at a first moment; wherein the target server is a server in the target financial institution determined according to the identification information corresponding to the first request message; At a second moment, a key for decrypting the encrypted second request message is sent to the target server; wherein the first moment is different from the second moment.

11. The method according to any one of claims 1 to 5, characterized in that, The method further includes: Send the second request message to the target server and receive the first response message sent by the target server according to the second request message; wherein the target server is a server in the target financial institution determined according to the identification information corresponding to the first request message; Obtain the second parsing result of the first response message and store the second parsing result in the response variable data item space in the internal storage space; wherein, the second parsing result includes each second standard variable field and the value of the second standard variable field; Based on the identification information corresponding to the first response message, a target response message template and second configuration information are obtained; wherein, the target response message template includes a second variable field, and the second configuration information is used to indicate the second standard variable field and the correspondence between the second variable fields; Based on the second configuration information and the response variable data item space, the value of each second variable field in the target response message template is set to the value of the second standard variable field corresponding to the second variable field, so as to obtain the transformed second response message; Send the second response message to the target client.

12. The method according to claim 11, characterized in that, The method further includes: Obtain the third parsing result of the first response message; wherein, the third parsing result includes a second standard constant field and the value of the second standard constant field; Update the fields and corresponding values ​​in the second standard constant field that are not stored in the constant data item space to the constant data item space.

13. A message conversion device, characterized in that, include: The first acquisition module is used to acquire the first parsing result of the first request message sent by the target client, and store the first parsing result in the request variable data item space in the internal storage space; wherein, the first parsing result includes each first variable field and the value of the first variable field; The second acquisition module is used to acquire a target request message template and first configuration information based on the identification information corresponding to the first request message; wherein, the target request message template includes a first standard variable field and a first standard constant field, and the first configuration information is used to indicate the correspondence between the first standard variable field and the first variable field; The first setting module is used to set the value of each first standard variable field in the target request message template to the value of the first variable field corresponding to the first standard variable field according to the first configuration information and the request variable data item space, so as to obtain the request message template after instantiating the variable fields; The second setting module is used to set the value of each first standard constant field in the request message template after instantiating the variable field to the value of the first standard constant field read from the constant data item space, so as to obtain the converted second request message; wherein, the constant data item space is located in the internal storage space.

14. An electronic device, characterized in that, The method includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the message conversion method as described in any one of claims 1 to 12.

15. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the message conversion method as described in any one of claims 1 to 12.

16. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the message conversion method as described in any one of claims 1 to 12.

Citation Information

Patent Citations

  • Message conversion method and device, computer equipment and computer readable storage medium

    CN109617647A

  • Message assembling method and device

    CN111861695A