Heterogeneous system data sharing method and device based on self-built gateway and medium
By introducing self-built gateways into heterogeneous systems, the unified entrance authentication of traffic gateways and the parameter mapping and cropping functions of self-built gateways are solved, the limitations of heterogeneous system integration in the existing technology are improved, the system integration efficiency and adaptability are ensured, and system security and traceability are ensured.
Patent Information
- Application Number
- CN202411979704.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-04-15
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing heterogeneous system integration solutions have limitations in dealing with complex parameter mapping, interface cutting and customized logic, resulting in high development costs, high maintenance difficulties, high coupling between systems, and inability to quickly adapt to changes in business needs.
The heterogeneous system data sharing method based on self-built gateways is adopted, and unified entrance authentication is performed through the traffic gateway, and combined with the field mapping, parameter cropping and dynamic processing functions of self-built gateways, data sharing and adaptation between multiple systems is realized.
It significantly reduces the difficulty of development, improves the efficiency and adaptability of system integration, ensures the security and traceability of system operation, and supports rapid response to changes in business demands.
Smart Images

Figure CN119835045A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data sharing platforms, and in particular to a method, device and medium for sharing data of heterogeneous systems based on a self-built gateway. Background Art
[0002] With the rapid development of information technology, enterprises often need to integrate multiple business systems to improve efficiency during operations. However, the heterogeneity of existing business systems poses great challenges to data sharing and system integration. Different business systems are usually based on their own technical architectures and interface standards, which leads to the need for complex adaptation development for each interface for communication between systems, thereby increasing development costs, maintenance difficulties and coupling between systems.
[0003] Existing heterogeneous system integration solutions are usually based on traditional middleware architectures. However, these solutions have certain limitations when dealing with complex parameter mapping, interface tailoring, and customized logic. Specifically:
[0004] Complexity of interface parameter mapping: The interface definitions of different systems may have differences in field names, data types, and field logic. Existing technologies require manual writing of a large number of parameter mapping rules, which are expensive to maintain and prone to errors.
[0005] Insufficient flexibility in interface tailoring and dynamic logic: When interfaces need to tailor, combine, or dynamically process parameters based on business needs, existing technologies are usually unable to adapt quickly, especially in scenarios where rules change frequently. Existing solutions often require redevelopment or code modification, and lack configurable management tool support.
[0006] Insufficient system scalability: Faced with new business requirements or interface standards, traditional solutions cannot quickly complete the adaptation and development of new requirements, usually requiring a long development cycle, affecting the efficiency of business launch. Summary of the invention
[0007] The present invention aims to solve at least one of the above-mentioned technical problems existing in the prior art.
[0008] To this end, a first aspect of the present invention provides a heterogeneous system data sharing method based on a self-built gateway.
[0009] A second aspect of the present invention provides a computer device.
[0010] A third aspect of the present invention provides a computer-readable storage medium.
[0011] The present invention provides a heterogeneous system data sharing method based on a self-built gateway, comprising:
[0012] Receive interface requests from multiple business parties through the traffic gateway;
[0013] Authenticate the interface request in the traffic gateway to determine the legitimacy of the request. The authentication includes verifying the business party's identity authentication information and interface call authority.
[0014] According to the pre-configured routing rules, the interface request that passes the authentication is forwarded to the self-built gateway;
[0015] In the self-built gateway, according to the field requirements of the target interface, the parameters in the interface request are mapped and converted through the field mapping relationship. The mapping conversion includes field name conversion, data type conversion and field value logic processing;
[0016] The self-built gateway cuts or combines request parameters according to the requirements of the target interface, deletes redundant fields and reassembles the parameter structure; and customizes the request parameters according to the configured dynamic processing logic, including condition judgment, calculation and format adjustment;
[0017] Send the processed request to the target business capability interface, and complete the processing of relevant data in the target business capability interface;
[0018] The self-built gateway receives the response data returned by the business capability interface, performs reverse field mapping on the response data according to the interface requirements, and converts the target fields back to the source fields; the fields of the response data are trimmed or reorganized to meet the needs of the business side;
[0019] The processed response data is returned to the traffic gateway, and the response result is returned to the corresponding business party through the traffic gateway;
[0020] During the entire processing flow, log information is recorded for all interface requests and response data, including the request source, target interface, parameter content, and processing results, to support subsequent tracing and analysis.
[0021] The heterogeneous system data sharing method based on the self-built gateway according to the above technical solution of the present invention may also have the following additional technical features:
[0022] In the above technical solution, mapping and converting the parameters in the interface request through the field mapping relationship includes:
[0023] Based on the pre-existing field mapping rules, the source field name in the interface request is converted into the field name required by the target interface;
[0024] Performing format conversion on the source field value according to the data type requirements of the target field, the format conversion includes conversion of numerical type, date format and character encoding;
[0025] Perform operations on the source field values according to the logical requirements of the target field, including addition, multiplication, string concatenation, and conditional branching;
[0026] When the field mapping rules are incomplete or do not exist, the mapping rules are automatically generated and stored in the mapping rule library of the self-built gateway; the corresponding relationship between the source field and the target field is identified through semantic analysis technology, and matching rules are generated.
[0027] In the above technical solution, the method for automatically generating mapping rules includes:
[0028] Parse the target interface document and extract field definition information of the target interface, wherein the field definition information includes field name, data type and field semantics;
[0029] Compare the field definition information of the source interface document with the target interface field, and establish a preliminary correspondence based on the semantic similarity calculation of the field names;
[0030] When the semantic match of the field name is insufficient, a secondary match is performed based on the field's context information, data samples, and field scope;
[0031] The automatically generated field mapping rules are stored, and users are supported to manually adjust or confirm them in the self-built gateway interface.
[0032] In the above technical solution, the step of tailoring the request parameters according to the requirements of the target interface includes:
[0033] Parse the field specification document of the target interface and extract the field list required by the target interface;
[0034] Filter the fields required by the target interface from the interface request parameters and delete the fields not used by the target interface;
[0035] Reorganize the structure of the filtered fields. The methods of reorganizing the structure include adjusting the field order, nesting level and field grouping;
[0036] After the field trimming is completed, a parameter body matching the format required by the target interface is generated.
[0037] In the above technical solution, the customized processing of request parameters according to the configured dynamic processing logic includes:
[0038] Configure dynamic processing rules according to business needs, including logical judgment of field values, correlation operations between fields, and conditional branch processing;
[0039] Dynamic processing rules support encryption and decryption of field values, assignment or removal of field values based on conditional judgment, and calculation of multiple field values and storage of the results in new fields.
[0040] During the parameter processing, the execution results of the dynamic rules are verified to ensure that the processed parameters meet the business requirements of the target interface.
[0041] In the above technical solution, the traffic gateway allocates quotas to the request source, time period and target service through traffic control, including:
[0042] Configure different traffic restriction rules for different business parties, including the number of concurrent requests, request frequency, and request rate;
[0043] When the traffic exceeds the limit, the request is automatically blocked and a prompt indicating that the traffic limit has exceeded the limit is returned.
[0044] In the above technical solution, the traffic gateway encrypts and decrypts the request data through the data encryption and decryption function to ensure the security of data transmission.
[0045] In the above technical solution, the operation process of the traffic gateway and the self-built gateway supports dynamic expansion, including:
[0046] Dynamically add traffic gateway authentication rules and traffic control strategies based on new business needs;
[0047] Add interface clipping and mapping rules in the self-built gateway to adapt to the parameter format and field requirements of the target interface;
[0048] Provides configurable management tools that allow system administrators to quickly configure and publish authentication rules, mapping rules, and tailoring rules through the user interface.
[0049] A computer device provided by the present invention includes a processor and a memory, wherein a computer program is stored in the memory, and when the computer program is loaded and executed by the processor, a heterogeneous system data sharing method based on a self-built gateway as described in any one of the above technical solutions is implemented.
[0050] The present invention provides a computer-readable storage medium storing a program, which, when loaded by a processor, implements a heterogeneous system data sharing method based on a self-built gateway as described in any one of the above technical solutions.
[0051] In summary, due to the adoption of the above technical features, the beneficial effects of the present invention are:
[0052] The present invention proposes a heterogeneous system data sharing method based on a self-built gateway. The method realizes a unified entrance through a traffic gateway, authenticates the legitimacy of the request, and combines the field mapping and parameter clipping functions of the self-built gateway to realize data sharing and adaptation among multiple systems. The self-built gateway provides a flexible parameter processing mechanism, including field mapping, clipping, combination and customized processing capabilities, thereby significantly reducing the difficulty of development and improving the efficiency and adaptability of system integration. In addition, the traffic gateway works in conjunction with the self-built gateway to ensure the security and traceability of system operation through traffic control, data encryption and log auditing functions.
[0053] Additional aspects and advantages of the present invention will become apparent from the following description or may be learned by practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] The above and / or additional aspects and advantages of the present invention will become apparent and easily understood from the description of the embodiments in conjunction with the following drawings, in which:
[0055] Figure 1 It is a system architecture diagram of a heterogeneous system data sharing method based on a self-built gateway according to an embodiment of the present invention. DETAILED DESCRIPTION
[0056] In order to more clearly understand the above-mentioned purpose, features and advantages of the present invention, the present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be noted that the embodiments of the present application and the features in the embodiments can be combined with each other without conflict.
[0057] In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention may also be implemented in other ways different from those described herein. Therefore, the protection scope of the present invention is not limited to the specific embodiments disclosed below.
[0058] Refer to the following Figure 1 The following describes a heterogeneous system data sharing method based on a self-built gateway provided according to some embodiments of the present invention.
[0059] Some embodiments of the present application provide a heterogeneous system data sharing method based on a self-built gateway.
[0060] The first embodiment of the present invention proposes a heterogeneous system data sharing method based on a self-built gateway, including the following steps S1-S9.
[0061] S1. Receive interface requests from multiple business parties through the traffic gateway;
[0062] S2. Authenticate the interface request in the traffic gateway to determine the legitimacy of the request. The authentication includes verifying the identity authentication information and interface call authority of the business party.
[0063] S3. According to the pre-configured routing rules, the interface request that passes the authentication is forwarded to the self-built gateway;
[0064] S4. In the self-built gateway, according to the field requirements of the target interface, the parameters in the interface request are mapped and converted through the field mapping relationship, and the mapping conversion includes field name conversion, data type conversion and field value logic processing;
[0065] S5. The self-built gateway cuts the request parameters or combines the request parameters according to the requirements of the target interface, deletes redundant fields and reassembles the parameter structure; and customizes the request parameters according to the configured dynamic processing logic, and the customized processing includes condition judgment, calculation and format adjustment;
[0066] S6. Send the processed request to the target business capability interface, and complete the processing of relevant data in the target business capability interface;
[0067] S7. The self-built gateway receives the response data returned by the business capability interface, performs reverse field mapping on the response data according to the interface requirements, and converts the target field back to the source field; the fields of the response data are trimmed or reorganized to meet the needs of the business party;
[0068] S8. Return the processed response data to the traffic gateway, and return the response result to the corresponding business party through the traffic gateway;
[0069] S9. During the entire processing flow, log information is recorded for all interface requests and response data, including the request source, target interface, parameter content, and processing results, to support subsequent tracing and analysis.
[0070] In some embodiments, the step S4 of mapping and converting the parameters in the interface request through the field mapping relationship includes:
[0071] Based on the pre-existing field mapping rules, the source field name in the interface request is converted into the field name required by the target interface;
[0072] Performing format conversion on the source field value according to the data type requirements of the target field, the format conversion includes conversion of numerical type, date format and character encoding;
[0073] Perform operations on the source field values according to the logical requirements of the target field, including addition, multiplication, string concatenation, and conditional branching;
[0074] When the field mapping rules are incomplete or do not exist, the mapping rules are automatically generated and stored in the mapping rule library of the self-built gateway; the corresponding relationship between the source field and the target field is identified through semantic analysis technology, and matching rules are generated.
[0075] In a specific embodiment, the method for automatically generating mapping rules includes:
[0076] Parse the target interface document and extract field definition information of the target interface, wherein the field definition information includes field name, data type and field semantics;
[0077] Compare the field definition information of the source interface document with the target interface field, and establish a preliminary correspondence based on the semantic similarity calculation of the field names;
[0078] When the semantic match of the field name is insufficient, a secondary match is performed based on the field's context information, data samples, and field scope;
[0079] The automatically generated field mapping rules are stored, and users are supported to manually adjust or confirm them in the self-built gateway interface.
[0080] It should be noted that the reverse field mapping mentioned in step S7 can still adopt the specific method adopted in the above step S4.
[0081] In a specific embodiment, the step of performing reverse field mapping on the response data by the self-built gateway according to the interface requirements includes:
[0082] Based on the pre-stored reverse mapping rules, the field names returned by the target interface are converted into the field names requested by the business party;
[0083] According to the business side's field definition, reverse calculation or restoration of the target field value, including unit conversion, data format restoration and logical reverse deduction;
[0084] When a field required by the business party is missing, a default value or placeholder value is generated based on the business logic to fill in the response data;
[0085] The mapped field values are organized according to the field order of the business party, and a response body that complies with the business party interface protocol is generated.
[0086] In some embodiments, the step S5 of tailoring the request parameters according to the requirements of the target interface includes:
[0087] Parse the field specification document of the target interface and extract the field list required by the target interface;
[0088] Filter the fields required by the target interface from the interface request parameters and delete the fields not used by the target interface;
[0089] Reorganize the structure of the filtered fields. The methods of reorganizing the structure include adjusting the field order, nesting level and field grouping;
[0090] After the field trimming is completed, a parameter body matching the format required by the target interface is generated.
[0091] In some embodiments, the customized processing of the request parameters according to the configured dynamic processing logic in step S5 includes:
[0092] Configure dynamic processing rules according to business needs, including logical judgment of field values, correlation operations between fields, and conditional branch processing;
[0093] Dynamic processing rules support encryption and decryption of field values, assignment or removal of field values based on conditional judgment, and calculation of multiple field values and storage of the results in new fields.
[0094] During the parameter processing, the execution results of the dynamic rules are verified to ensure that the processed parameters meet the business requirements of the target interface.
[0095] In some embodiments, the traffic gateway allocates quotas to request sources, time periods, and target services through traffic control, including:
[0096] Configure different traffic restriction rules for different business parties, including the number of concurrent requests, request frequency, and request rate;
[0097] When the traffic exceeds the limit, the request is automatically blocked and a prompt indicating that the traffic limit has exceeded the limit is returned.
[0098] In some embodiments, the traffic gateway encrypts and decrypts the request data through a data encryption and decryption function to ensure data transmission security.
[0099] In some embodiments, the operation process of the traffic gateway and the self-built gateway supports dynamic expansion, including:
[0100] Dynamically add traffic gateway authentication rules and traffic control strategies based on new business needs;
[0101] Add interface clipping and mapping rules in the self-built gateway to adapt to the parameter format and field requirements of the target interface;
[0102] Provides configurable management tools that allow system administrators to quickly configure and publish authentication rules, mapping rules, and tailoring rules through the user interface.
[0103] In a specific embodiment, Figure 1In the system architecture shown, a heterogeneous system data sharing method based on a self-built gateway is adopted, in which the traffic gateway is a highly customized gateway based on spring gateway. The open platform capability relies on a unified gateway as the traffic entrance and exit to perform flow control, authentication, auditing and other behaviors. The traffic gateway can provide routing forwarding, traffic control, authentication, audit logs and data encryption and decryption. The self-built gateway provides parameter mapping, interface tailoring and custom script processing.
[0104] In terms of traffic control, the traffic gateway can accurately control the traffic entering the open platform according to the set rules. For example, the number of requests per unit time can be limited according to different API interfaces, client sources, or time periods. By configuring relevant RateLimiter strategies, such as those based on the token bucket algorithm or the leaky bucket algorithm, the system can be ensured not to crash due to instantaneous traffic peaks, and data loss caused by crawlers can be effectively prevented, effectively ensuring the stability and availability of the entire platform.
[0105] In terms of authentication and authorization, the traffic gateway uses the software industry standard authentication and authorization auth2 solution, and the gateway can be tightly integrated with the authentication server. When a request reaches the gateway, it intercepts the request and extracts the token identity information contained therein, and then sends this information to the authentication server for verification. Only legitimate requests that pass the verification will be allowed to continue to flow to the service resources within the open platform. This process effectively prevents illegal access and malicious attacks, and protects the security of platform data and services.
[0106] In terms of data encryption, the traffic gateway uses RSA asymmetric encryption to transmit the symmetric encryption key, and then uses symmetric encryption to encrypt the request parameters or interface return body data before API data transmission, effectively preventing data leakage caused by network packet capture and other means.
[0107] In terms of audit logs, the traffic gateway can record the key information of each request in detail, including the source IP address of the request, the timestamp of the request, the URI of the request, the parameters carried by the request, and the status code of the response. These audit logs not only help to trace and troubleshoot security issues, but also provide rich data support for the operation analysis of the platform, such as understanding the frequency of use of different APIs, the behavior patterns of clients, etc., in order to further optimize the performance and service strategies of the platform.
[0108] The gateway interface fully customizes the interface path while ensuring the domain name is correct, and can shield the internal details of the interface. Business services are deployed in multiple servers in the intranet according to microservices to prevent external network attacks, crawlers, etc., while also avoiding the risk of single server points; external network requests will pass through the traffic gateway, which will forward the request to the relevant business server for processing after passing the legality check and flow control check.
[0109] In terms of routing and forwarding, the API path exposed by the gateway is customized when configuring the API, which is inconsistent with the actual API path of the intranet server. The gateway performs unified routing and forwarding, which also effectively protects the security of the server interface.
[0110] In addition, relying on the self-built gateway platform, the functions that can be achieved include at least the ability to customize data conversion between different interfaces based on page configuration or js scripts, such as interface field names, type conversion, data calculation, trimming and combination, and other behaviors.
[0111] In the process of multi-party system docking, mapping of interface parameter names is one of the core tasks to achieve interface compatibility and data transmission. However, this process usually requires a lot of manual programming and debugging. Especially when docking multiple business parties, differences in parameter names may complicate the docking process and increase development and maintenance costs. Traditional methods usually rely on developers to implement mapping between different interface field names (i.e. parameter field codes) through code to ensure that each system can correctly understand and exchange data.
[0112] However, this approach has significant disadvantages in the following situations: Multi-party docking: When there are many parties to be docked and the types of interfaces are complex, each new interface or modification of the interface field name will make the original code difficult to maintain and increase the development cycle. Frequent docking in a short period of time: When the project cycle is short or the interface docking requirements change frequently, developers need to complete complex mapping work in a very short time, which increases labor costs and the risk of errors. A large number of interfaces: When the number of docking interfaces reaches hundreds or even thousands, manual coding is not only inefficient, but also difficult to ensure efficient updates and management.
[0113] In order to optimize the above process, step S4 of the present invention proposes a configurable mapping solution based on a self-built gateway, which is customized through interface configuration or simple JavaScript scripts to realize automatic mapping of interface parameters. Specifically, users can configure interfaces or script definition rules through a graphical interface to automatically generate parameter mapping relationships between different interfaces without writing a large amount of program code. Compared with traditional development methods, this method has the following advantages: Simplify the development process: Through interface configuration or simple scripts, developers can complete the mapping of interface parameters without in-depth writing of underlying code, which greatly reduces the difficulty of development and maintenance. Improve docking efficiency: When multiple system interfaces need to be docked, based on the configuration capabilities provided by the platform, data docking between different business systems can be quickly completed, reducing the development cycle and improving docking efficiency. Flexible adaptation to changes: Interface parameters may change over time. Through platform interface configuration or scripts, users can flexibly adjust mapping rules, quickly respond to changes in business needs, and avoid the trouble of rewriting and testing code in traditional development methods. Reduce labor costs: The workload of manual coding is reduced through interface configuration, allowing developers to focus more on business logic and high-level architecture design, thereby effectively reducing labor costs.
[0114] In multi-system data docking, interfaces often use different data formats and data types, which requires the docking platform to provide flexible data type conversion capabilities. Interface data type conversion refers to converting the data type (such as string, number, Boolean value, date, etc.) transmitted by a certain interface into the data type required by the target interface. This conversion is usually inevitable in data interaction between different systems, for example:
[0115] Number to string conversion: Some interfaces may receive numeric data as a string, while other interfaces require the same data to be transmitted as a number.
[0116] Date format conversion: Different systems often use different date formats (such as YYYY-MM-DD and MM / DD / YYYY), which need to be converted into a unified date format.
[0117] Boolean mapping: Boolean values may be represented differently, for example, "0" and "1" may represent "false" and "true", or "false" and "true" may represent Boolean values.
[0118] Complex data type conversion: The data transmitted by some interfaces may be nested JSON objects, and the target interface may need to extract certain fields or reorganize the format.
[0119] The self-built gateway disclosed in this disclosure can provide built-in rules for multiple data type conversions and support user-defined conversion rules. Users can configure data type conversion rules between different interfaces through a graphical interface or scripting. Specific functions include:
[0120] Automatically identify and convert common data types: The platform automatically identifies data types in different interfaces and provides a one-click conversion function to ensure that data between the source system and the target system is compatible and correctly transmitted;
[0121] Custom conversion rules: For more complex conversion requirements, the platform supports user-defined data conversion rules, such as implementing custom conversions through regular expressions, conditional judgments, etc.
[0122] Batch conversion: When connecting to multiple interfaces, users can batch configure multiple data type conversion rules to reduce repeated operations and improve configuration efficiency.
[0123] Data calculation means that during the interface docking process, the platform can perform real-time calculation, aggregation and processing of interface data to generate the data format required by the target system. Common calculation functions include:
[0124] Basic mathematical operations: such as addition, subtraction, multiplication, and division, are used to perform simple calculations on the numerical data passed by the interface.
[0125] Conditional judgment and calculation: Based on certain business rules or conditions, the platform can make branch judgments on the data transmitted by the interface and perform corresponding calculation operations according to different conditions. For example, when a field value is greater than a certain threshold, a specific calculation is performed, otherwise another calculation method is performed.
[0126] Summarization and statistics: During the data connection process, it is sometimes necessary to summarize or count the data transmitted by multiple interfaces, such as calculating the sum, average, maximum value, etc. of the data of multiple interfaces to generate the statistical data required by the target system.
[0127] Data conversion and processing: Some interfaces may need to pre-process the original data before transmitting it to the target system, such as calculating the percentage or weighted average of a certain indicator.
[0128] Through the calculation function provided by the self-built gateway of this disclosure, users can easily process data in real time during the docking process without having to manually calculate in each interface call. The calculation rules also support configuration through a graphical interface. Users can quickly configure the data calculation process by dragging, selecting formulas, conditional judgment, etc., or use scripts for more flexible customization.
[0129] In the interface connection between different systems, sometimes the transmitted data does not need to correspond one to one. Some data may need to be trimmed (that is, unnecessary fields may be removed), and some data may need to merge or combine data from multiple interfaces to form a new interface output. The interface trimming and combination functions provided by the self-built gateway mainly include:
[0130] Field trimming: According to the requirements of the target system, trim the redundant fields in the source interface to ensure that the transmitted data only contains the fields required by the target system. For example, the source interface may return a complex data object with multiple nested fields, but the target interface only needs some of the fields. Through the trimming function provided by the platform, users can configure which fields to retain and which fields to remove to ensure efficient and concise data transmission.
[0131] Data merging: When data from multiple interfaces needs to be merged into one interface, the platform can automatically combine fields from different sources to form data that conforms to the target interface structure. For example, users may need to merge different fields from two interfaces to generate a data flow for a new interface.
[0132] Data splitting and reassembling: In some business scenarios, the data returned by the source interface may be too complex or lengthy, and the target system may only need part of it, or the target system may need to split a field into multiple fields. The platform can automatically split the data in the source interface according to the configuration rules, and reassemble it according to the requirements of the target interface to form a suitable data format.
[0133] The self-built gateway allows users to flexibly specify which fields need to be trimmed, which fields need to be merged, or how to reconstruct data through a simple interface configuration, greatly simplifying the complexity of data processing.
[0134] The above embodiment provides a unified authentication authorization and API permission control mechanism to ensure the security and accuracy of data interaction between different business entities. On this basis, it expands a complete data operation audit log system, effective network traffic control and network security measures, including preventing network congestion, data leakage and malicious attacks, to ensure the stable operation of the business. It also provides an efficient and accurate data conversion and mapping method to solve the docking problems caused by differences in data formats and business domains of different business entities.
[0135] Some other embodiments of the present invention provide a computer device, including a processor and a memory, wherein the memory stores a computer program, and when the computer program is loaded and executed by the processor, the heterogeneous system data sharing method based on the self-built gateway as described in any of the above embodiments is implemented.
[0136] Some further embodiments of the present invention provide a computer-readable storage medium storing a program, which, when loaded by a processor, implements a heterogeneous system data sharing method based on a self-built gateway as described in any one of the above technical solutions.
[0137] In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0138] Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A heterogeneous system data sharing method based on a self-built gateway, characterized in that: include: Receive interface requests from multiple business parties through the traffic gateway; Authenticate the interface request in the traffic gateway to determine the legitimacy of the request. The authentication includes verifying the business party's identity authentication information and interface call authority. According to the pre-configured routing rules, the interface request that passes the authentication is forwarded to the self-built gateway; In the self-built gateway, according to the field requirements of the target interface, the parameters in the interface request are mapped and converted through the field mapping relationship. The mapping conversion includes field name conversion, data type conversion and field value logic processing; The self-built gateway cuts or combines request parameters according to the requirements of the target interface, deletes redundant fields and reassembles the parameter structure; and customizes the request parameters according to the configured dynamic processing logic, including condition judgment, calculation and format adjustment; Send the processed request to the target business capability interface, and complete the processing of relevant data in the target business capability interface; The self-built gateway receives the response data returned by the business capability interface, performs reverse field mapping on the response data according to the interface requirements, and converts the target field back to the source field; Tailor or reorganize the fields of the response data to suit the needs of the business side; The processed response data is returned to the traffic gateway, and the response result is returned to the corresponding business party through the traffic gateway; During the entire processing flow, log information is recorded for all interface requests and response data, including the request source, target interface, parameter content, and processing results, to support subsequent tracing and analysis.
2. The heterogeneous system data sharing method based on self-built gateway according to claim 1 is characterized in that: Mapping and converting the parameters in the interface request through the field mapping relationship includes: Based on the pre-existing field mapping rules, the source field name in the interface request is converted into the field name required by the target interface; Performing format conversion on the source field value according to the data type requirements of the target field, the format conversion includes conversion of numerical type, date format and character encoding; Perform operations on the source field values according to the logical requirements of the target field, including addition, multiplication, string concatenation, and conditional branching; When the field mapping rules are incomplete or do not exist, the mapping rules are automatically generated and stored in the mapping rule library of the self-built gateway; the corresponding relationship between the source field and the target field is identified through semantic analysis technology, and matching rules are generated.
3. The heterogeneous system data sharing method based on self-built gateway according to claim 2 is characterized in that: The method for automatically generating mapping rules comprises: Parse the target interface document and extract field definition information of the target interface, wherein the field definition information includes field name, data type and field semantics; Compare the field definition information of the source interface document with the target interface field, and establish a preliminary correspondence based on the semantic similarity calculation of the field names; When the semantic match of the field name is insufficient, a secondary match is performed based on the field's context information, data samples, and field scope; The automatically generated field mapping rules are stored, and users are supported to manually adjust or confirm them in the self-built gateway interface.
4. The method for sharing data among heterogeneous systems based on a self-built gateway according to claim 1, characterized in that: The step of tailoring the request parameters according to the requirements of the target interface includes: Parse the field specification document of the target interface and extract the field list required by the target interface; Filter the fields required by the target interface from the interface request parameters and delete the fields not used by the target interface; Reorganize the structure of the filtered fields. The methods of reorganizing the structure include adjusting the field order, nesting level and field grouping; After the field trimming is completed, a parameter body matching the format required by the target interface is generated.
5. The method for sharing heterogeneous system data based on a self-built gateway according to claim 1, characterized in that: The customized processing of request parameters according to the configured dynamic processing logic includes: Configure dynamic processing rules according to business needs, including logical judgment of field values, correlation operations between fields, and conditional branch processing; Dynamic processing rules support encryption and decryption of field values, assignment or removal of field values based on conditional judgment, and calculation of multiple field values and storage of the results in new fields. During the parameter processing, the execution results of the dynamic rules are verified to ensure that the processed parameters meet the business requirements of the target interface.
6. The method for sharing data among heterogeneous systems based on a self-built gateway according to claim 1, characterized in that: The traffic gateway allocates quotas to request sources, time periods, and target services through traffic control, including: Configure different traffic restriction rules for different business parties, including the number of concurrent requests, request frequency, and request rate; When the traffic exceeds the limit, the request is automatically blocked and a prompt indicating that the traffic limit has exceeded the limit is returned.
7. The method for sharing data among heterogeneous systems based on a self-built gateway according to claim 1, characterized in that: The traffic gateway encrypts and decrypts the request data through the data encryption and decryption function to ensure the security of data transmission.
8. The method for sharing heterogeneous system data based on a self-built gateway according to claim 1, characterized in that: The operation process of the traffic gateway and self-built gateway supports dynamic expansion, including: Dynamically add traffic gateway authentication rules and traffic control strategies based on new business needs; Add interface clipping and mapping rules in the self-built gateway to adapt to the parameter format and field requirements of the target interface; Provides configurable management tools that allow system administrators to quickly configure and publish authentication rules, mapping rules, and tailoring rules through the user interface.
9. A computer device, characterized in that: It comprises a processor and a memory, wherein a computer program is stored in the memory, and when the computer program is loaded and executed by the processor, a heterogeneous system data sharing method based on a self-built gateway as described in any one of claims 1 to 8 is implemented.
10. A computer-readable storage medium, characterized in that: A program is stored, and when the program is loaded by a processor, a heterogeneous system data sharing method based on a self-built gateway as described in any one of claims 1 to 8 is implemented.
Citation Information
Patent Citations
A configuration-based gateway system
CN112333009A
Service interface access method and device, electronic equipment and medium
CN112379951A
Outlet gateway request method, device, equipment and medium
CN114390032A
Managing subscriptions to resource updates made via a target interface
US11895192B1
Data computation in a multi-domain cloud environment
US20160119289A1
Cited By
Cross-system data processing method and device, equipment and medium
CN120336276A
Enterprise private domain data and cloud tenant deep integration system oriented to digital operation
CN120353973A
Cross-database Rest interface implementation method and system based on tagging dynamic configuration
CN120780690A
Standardized interface system and method for multi-scene service docking
CN120935288A