Multisource message transmission method and system based on middleware

通过统一接口获取和解析中间件配置信息,动态加载消息接收器,实现微服务之间的消息传输,解决了传统桥接机制导致的性能瓶颈和稳定性问题,提升了系统的灵活性和可靠性。

CN119311435APending Publication Date: 2025-01-14FUJIAN FUNO MOBILE COMM TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411125563.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-16
Publication Date
2025-01-14

AI Technical Summary

Technical Problem

In modern enterprise IT architecture, efficient and reliable data exchange between microservices depends on message middleware, but traditional bridging mechanisms will become a performance bottleneck in high concurrency scenarios, reducing system stability and reliability, and limiting system Flexibility and scalability.

Method used

The middleware configuration information is obtained through a unified interface, parsed into a unified data structure, and the message receiver is loaded dynamically to realize message transmission between different middlewares, avoid additional bridging mechanisms, and simplify development and maintenance.

Benefits of technology

It improves the stability and reliability of the system, enhances flexibility and scalability, simplifies the development process, and accelerates business development.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119311435A_ABST
    Figure CN119311435A_ABST
Patent Text Reader

Abstract

The invention relates to a multi-source message transmission method and system based on middleware, and the method comprises the steps: obtaining middleware configuration information of middleware types of all associated systems through a uniform interface, analyzing the middleware configuration information according to a preset analysis rule, and analyzing the middleware configuration information into a uniform data structure; the standardized middleware configuration information is obtained, the middleware is dynamically loaded and initialized according to the type of the middleware to obtain a message receiver in which middleware interaction logic is packaged, and the message is received through the message receiver to achieve message transmission. Therefore, a uniform interface is provided for the outside, it is ensured that a service logic layer does not need to concern specific implementation of underlying message transmission, system architecture and maintenance work are simplified, message transmission is achieved through a message receiver, an additional bridging mechanism does not need to be constructed, complex partitioning and processing do not exist, seamless butt joint of various middleware is achieved, and the system reliability is improved. The stability and reliability of the system are improved, the flexibility and expansibility of the system are enhanced, and the development of services is accelerated.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data processing, and in particular to a method and system for multi-source message transmission based on middleware. Background Art

[0002] In modern enterprise IT architecture, as business continues to expand and become more complex, real-time data transmission and processing have become particularly important. Traditional monolithic systems have gradually been replaced by microservice architectures, and efficient and reliable data exchange between microservices relies on message middleware.

[0003] When enterprises using different message middleware transmit messages, they usually build additional bridging mechanisms. However, in high-concurrency scenarios, due to the need to frequently convert and adapt between different message protocols and design complex strategies to distinguish and process messages from different sources, additional bridging mechanisms may become a bottleneck for system performance, reducing system stability and reliability. In addition, when the middleware is updated or an enterprise system using new middleware is added, a new bridging mechanism needs to be rebuilt, which limits the flexibility and scalability of the system and hinders the rapid development of the business. Summary of the invention

[0004] The technical problem to be solved by the present invention is: the present invention provides a method and system for multi-source message transmission based on middleware, which dynamically realizes message transmission between different middlewares while simplifying development and reducing complexity, improving the stability and reliability of the system, and enhancing the flexibility and scalability of the system, thereby accelerating business development.

[0005] In order to solve the above technical problems, the technical solution adopted by the present invention is:

[0006] In a first aspect, the present invention provides a method for multi-source message transmission based on middleware, comprising:

[0007] Obtaining middleware configuration information of all related systems including middleware types through a unified interface, parsing the middleware configuration information according to a preset parsing rule and parsing it into a unified data structure to obtain standardized middleware configuration information;

[0008] Dynamically loading and initializing standardized middleware configuration information according to the middleware type to obtain a corresponding message receiver, wherein the message receiver encapsulates the middleware interaction logic;

[0009] When the associated system is monitored to transmit a message, a message receiver corresponding to the associated system is called to receive the message to realize the message transmission.

[0010] The beneficial effects of the present invention are: obtaining the middleware configuration information of all related systems through a unified interface, that is, providing a unified interface to the outside world, ensuring that the business logic layer does not need to care about the specific implementation of the underlying message transmission, simplifying the system architecture and maintenance work, and being able to parse the middleware configuration information and parse it into a unified data structure, improving the efficiency of subsequent dynamic loading and initialization processing, so as to obtain a message receiver that encapsulates the middleware interaction logic, and receiving messages through the message receiver to realize message transmission, that is, there is no need to build an additional bridging mechanism for each middleware, no need to modify the code, and no complicated partitioning and processing. By parsing the middleware configuration information to generate a message receiver, seamless docking of multiple middleware is achieved, simplifying development, improving the stability and reliability of the system, and enhancing the flexibility and scalability of the system, thereby accelerating business development.

[0011] Optionally, the middleware configuration information further includes a connection address, and the step of parsing the middleware configuration information according to a preset parsing rule and parsing the middleware configuration information into a unified data structure to obtain standardized middleware configuration information includes:

[0012] The middleware configuration information is parsed according to preset parsing rules, and a legality check is performed during the parsing process. If the legality check passes, the middleware configuration information is parsed into a unified data structure, and a connection test is performed according to the connection address after the parsing is completed. If the connection test is successful, standardized middleware configuration information is obtained, otherwise, a connection failure prompt is generated.

[0013] According to the above description, not only is the validity check performed during the parsing process, but a connection test is also performed after the parsing is completed, thereby ensuring the accuracy and stability of the obtained standardized middleware configuration information.

[0014] Optionally, the middleware configuration information further includes a port number, a user name and a password, and the legitimacy check is performed during the parsing process. If the legitimacy check passes, the middleware configuration information is parsed into a unified data structure, including:

[0015] Determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is generated.

[0016] According to the above description, the diversity of legitimacy verification further ensures the legitimacy and accuracy of standardized middleware configuration information.

[0017] Optionally, performing a connection test after parsing is completed includes:

[0018] After the parsing is completed, a connection test is performed by sending a heartbeat message or a query request to the connection address.

[0019] It can be seen from the above description that the diversity of connection tests improves the accuracy of connection test results.

[0020] Optionally, the calling a message receiver corresponding to the associated system to receive a message and realize message transmission includes:

[0021] Performing integrity verification and validity verification on the message, and if both the integrity verification and the validity verification pass, forwarding the message to achieve message transmission;

[0022] The integrity check includes:

[0023] Determine whether the message complies with a preset structure model, whether it complies with a preset type, whether it contains preset fields and whether it meets a preset field length. If so, the integrity check passes;

[0024] The validity verification includes:

[0025] It is determined whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission. If so, the validity verification is passed.

[0026] According to the above description, the message is checked for integrity and validity, that is, both the external and internal characteristics of the message are checked, and the message that passes both the integrity verification and the validity verification is forwarded to ensure the accuracy of the message transmission.

[0027] In a second aspect, the present invention provides a system for multi-source message transmission based on middleware, comprising:

[0028] A parsing module is used to obtain middleware configuration information of all related systems including middleware types through a unified interface, parse the middleware configuration information according to preset parsing rules and parse it into a unified data structure to obtain standardized middleware configuration information;

[0029] A dynamic generation module, used to dynamically load and initialize standardized middleware configuration information according to the middleware type to obtain a corresponding message receiver, in which the middleware interaction logic is encapsulated;

[0030] The transmission module is used to call a message receiver corresponding to the associated system to receive the message when monitoring the associated system to transmit the message, so as to realize the message transmission.

[0031] The beneficial effects of the present invention are: obtaining the middleware configuration information of all related systems through a unified interface, that is, providing a unified interface to the outside world, ensuring that the business logic layer does not need to care about the specific implementation of the underlying message transmission, simplifying the system architecture and maintenance work, and being able to parse the middleware configuration information and parse it into a unified data structure, improving the efficiency of subsequent dynamic loading and initialization processing, so as to obtain a message receiver that encapsulates the middleware interaction logic, and receiving messages through the message receiver to realize message transmission, that is, there is no need to build an additional bridging mechanism for each middleware, no need to modify the code, and no complicated partitioning and processing. By parsing the middleware configuration information to generate a message receiver, seamless docking of multiple middleware is achieved, simplifying development, improving the stability and reliability of the system, and enhancing the flexibility and scalability of the system, thereby accelerating business development.

[0032] Optionally, the middleware configuration information further includes a connection address, and the parsing module includes:

[0033] The verification module is used to parse the middleware configuration information according to preset parsing rules, and perform a legality check during the parsing process. If the legality check passes, the middleware configuration information is parsed into a unified data structure, and after the parsing is completed, a connection test is performed according to the connection address. If the connection test is successful, standardized middleware configuration information is obtained, otherwise, a connection failure prompt is generated.

[0034] According to the above description, not only is the validity check performed during the parsing process, but a connection test is also performed after the parsing is completed, thereby ensuring the accuracy and stability of the obtained standardized middleware configuration information.

[0035] Optionally, the middleware configuration information also includes a port number, a user name and a password, and the verification module is specifically:

[0036] Determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is generated.

[0037] According to the above description, the diversity of legitimacy verification further ensures the legitimacy and accuracy of standardized middleware configuration information.

[0038] Optionally, the verification module is specifically:

[0039] After the parsing is completed, a connection test is performed by sending a heartbeat message or a query request to the connection address.

[0040] It can be seen from the above description that the diversity of connection tests improves the accuracy of connection test results.

[0041] Optionally, the transmission module is specifically:

[0042] Performing integrity verification and validity verification on the message, and if both the integrity verification and the validity verification pass, forwarding the message to achieve message transmission;

[0043] The integrity check includes:

[0044] Determine whether the message complies with a preset structure model, whether it complies with a preset type, whether it contains preset fields and whether it meets a preset field length. If so, the integrity check passes;

[0045] The validity verification includes:

[0046] It is determined whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission. If so, the validity verification is passed.

[0047] According to the above description, the message is checked for integrity and validity, that is, both the external and internal characteristics of the message are checked, and the message that passes both the integrity verification and the validity verification is forwarded to ensure the accuracy of the message transmission. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] Figure 1 A flowchart of a method for multi-source message transmission based on middleware provided by an embodiment of the present invention;

[0049] Figure 2 A schematic diagram of the overall process of a method for multi-source message transmission based on middleware provided by an embodiment of the present invention;

[0050] Figure 3 A schematic diagram of the structure of a middleware-based multi-source message transmission system provided in an embodiment of the present invention.

[0051] [Description of Reference Numerals]

[0052] 1. A multi-source message transmission system based on middleware;

[0053] 2. Parsing module; 21. Verification module;

[0054] 3. Dynamically generate modules;

[0055] 4. Transmission module. DETAILED DESCRIPTION

[0056] In order to better understand the above technical solution, exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments described herein. On the contrary, these embodiments are provided to enable a clearer and more thorough understanding of the present invention and to fully convey the scope of the present invention to those skilled in the art.

[0057] Embodiment 1

[0058] Please refer to Figure 1 to Figure 2 The present invention provides a method for real-time data quality detection, comprising the steps of:

[0059] S1. Obtaining middleware configuration information of all related systems including middleware types through a unified interface, parsing the middleware configuration information according to a preset parsing rule and parsing it into a unified data structure to obtain standardized middleware configuration information;

[0060] In this embodiment, if Figure 2 As shown, a unified interface is provided to the outside world, and middleware configuration information of all related systems including middleware types is obtained through the unified interface. The middleware configuration information includes but is not limited to the connection address, configuration parameters, message queue name, port number, user name and password, so that the middleware configuration information is parsed according to the preset parsing rules and parsed into a unified data structure, such as the data structure of JSOM, the data structure of XML, etc., so as to obtain standardized middleware configuration information.

[0061] At this time, the middleware configuration information in step S1 also includes a connection address. The middleware configuration information is parsed according to a preset parsing rule and parsed into a unified data structure to obtain standardized middleware configuration information including:

[0062] S11. Parse the middleware configuration information according to preset parsing rules, and perform a legitimacy check during the parsing process. If the legitimacy check passes, parse the middleware configuration information into a unified data structure, and perform a connection test according to the connection address after the parsing is completed. If the connection test is successful, standardized middleware configuration information is obtained. Otherwise, a connection failure prompt is generated.

[0063] At this time, the middleware configuration information in step S11 also includes a port number, a user name and a password. The legitimacy check is performed during the parsing process. If the legitimacy check passes, the middleware configuration information is parsed into a unified data structure including:

[0064] S111. Determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is generated.

[0065] In this embodiment, if Figure 2 As shown, during the process of parsing the middleware configuration information according to the preset parsing rules, a legitimacy check is performed to determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes; if not, a parsing failure prompt is generated. At the same time, the middleware configuration information also includes configuration parameters. While performing the legitimacy check, a consistency check is also performed to determine whether the middleware type matches the configuration parameters. For example, the RabbitMQ middleware type requires configuration parameters related to the AMQP protocol, and the Kafka middleware type requires configuration parameters related to the Broker list. If the middleware type matches the configuration parameters, the consistency check passes, and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is also generated.

[0066] At this time, the connection test described in step S11 and performed after the parsing is completed includes:

[0067] After the parsing is completed, a connection test is performed by sending a heartbeat message or a query request to the connection address.

[0068] In this embodiment, if Figure 2 As shown, after the parsing is completed, a connection test will be performed, that is, a heartbeat message or query request is sent to the middleware of the associated system corresponding to the connection address to establish a short connection for connection test. If the connection test is successful, standardized middleware configuration information is obtained. Otherwise, if the connection test fails, a connection failure prompt is generated.

[0069] S2. Dynamically load and initialize the standardized middleware configuration information according to the middleware type to obtain a corresponding message receiver, in which the middleware interaction logic is encapsulated;

[0070] In this embodiment, if Figure 2As shown, the standardized middleware configuration information is dynamically loaded and initialized according to the middleware type to obtain the corresponding message receiver. For example, if the middleware type is RabbitMQ, the standardized middleware configuration information is dynamically loaded and initialized according to RabbitMQ to obtain the RabbitMQReceiver class, which is the message receiver of the middleware type RabbitMQ. If the middleware type is ActiveMQ, the standardized middleware configuration information is dynamically loaded and initialized according to ActiveMQ to obtain the ActiveMQReceiver class, which is the message receiver of the middleware type ActiveMQ. That is, the standardized middleware configuration information is dynamically loaded and initialized according to the middleware type to obtain the method class of the corresponding middleware type, namely the message receiver. The middleware interaction logic is encapsulated in the message receiver, and the middleware interaction logic includes but is not limited to: establishing a connection, monitoring a message queue, and processing messages.

[0071] S3. When the associated system is monitored to transmit a message, a message receiver corresponding to the associated system is called to receive the message to implement message transmission.

[0072] At this time, in step S3, calling the message receiver corresponding to the associated system to receive the message and realize message transmission includes:

[0073] S31, performing integrity verification and validity verification on the message, and if both the integrity verification and the validity verification pass, forwarding the message to achieve message transmission;

[0074] The integrity check includes:

[0075] Determine whether the message complies with a preset structure model, whether it complies with a preset type, whether it contains preset fields and whether it meets a preset field length. If so, the integrity check passes;

[0076] The validity verification includes:

[0077] It is determined whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission. If so, the validity verification is passed.

[0078] In this embodiment, if Figure 2As shown, before calling the message receiver to forward the message, the message will be verified for integrity and validity. The integrity verification mainly verifies the external characteristics of the message, such as whether it follows the preset structure model, whether it follows the preset type, whether it contains preset fields and whether it meets the preset field length. The validity verification mainly verifies the internal characteristics of the message, such as whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission, so that the message that passes both the integrity verification and the validity verification will be forwarded to realize message transmission.

[0079] Embodiment 2

[0080] Please refer to Figure 3 The present invention provides a middleware-based multi-source message transmission system 1, comprising: a parsing module 2, a verification module 21, a dynamic generation module 3 and a transmission module 4.

[0081] The parsing module 2 is used to obtain the middleware configuration information of all related systems including the middleware type through a unified interface, parse the middleware configuration information according to a preset parsing rule and parse it into a unified data structure to obtain standardized middleware configuration information;

[0082] Dynamic generation module 3, used for dynamically loading and initializing standardized middleware configuration information according to the middleware type to obtain a corresponding message receiver, in which the middleware interaction logic is encapsulated;

[0083] The transmission module 4 is used to call the message receiver corresponding to the associated system to receive the message when monitoring the associated system to transmit the message, so as to realize the message transmission.

[0084] Specifically, the middleware configuration information also includes a connection address, and the parsing module includes:

[0085] The verification module 21 is used to parse the middleware configuration information according to preset parsing rules, and perform a legality check during the parsing process. If the legality check passes, the middleware configuration information is parsed into a unified data structure, and after the parsing is completed, a connection test is performed according to the connection address. If the connection test is successful, standardized middleware configuration information is obtained, otherwise, a connection failure prompt is generated.

[0086] Specifically, the middleware configuration information also includes configuration parameters, message queue name, port number, user name and password, and the verification module 21 is specifically:

[0087] Determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is generated.

[0088] Specifically, the verification module 21 is specifically:

[0089] After the parsing is completed, a connection test is performed by sending a heartbeat message or a query request to the connection address.

[0090] Specifically, the transmission module 4 is specifically:

[0091] Performing integrity verification and validity verification on the message, and if both the integrity verification and the validity verification pass, forwarding the message to achieve message transmission;

[0092] The integrity check includes:

[0093] Determine whether the message complies with a preset structure model, whether it complies with a preset type, whether it contains preset fields and whether it meets a preset field length. If so, the integrity check passes;

[0094] The validity verification includes:

[0095] It is determined whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission. If so, the validity verification is passed.

[0096] Since the system / device described in the above embodiments of the present invention is a system / device used to implement the method of the above embodiments of the present invention, a person skilled in the art can understand the specific structure and deformation of the system / device based on the method described in the above embodiments of the present invention, and thus will not be described in detail here. All systems / devices used in the method of the above embodiments of the present invention belong to the scope of protection of the present invention.

[0097] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0098] The present invention is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present invention. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions.

[0099] It should be noted that in the claims, any reference numerals placed between brackets shall not be construed as limiting the claims. The word "comprising" does not exclude the presence of components or steps not listed in the claims. The word "a" or "an" preceding a component does not exclude the presence of a plurality of such components. The invention may be implemented by means of hardware comprising several different components and by means of a suitably programmed computer. In the claims enumerating several means, several of these means may be embodied by the same hardware. The use of the words first, second, third, etc., is for convenience of expression only and does not indicate any order. These words may be understood as part of the component name.

[0100] In addition, it should be noted that, in the description of this specification, the description of the terms "one embodiment", "some embodiments", "embodiment", "example", "specific example" or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. 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 may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, unless they are contradictory.

[0101] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments after knowing the basic creative concept. Therefore, the claims should be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present invention.

[0102] Obviously, those skilled in the art can make various modifications and variations to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention should also include these modifications and variations.

Claims

1. A method for multi-source message transmission based on middleware, characterized in that: include: Obtaining middleware configuration information of all related systems including middleware types through a unified interface, parsing the middleware configuration information according to a preset parsing rule and parsing it into a unified data structure to obtain standardized middleware configuration information; Dynamically loading and initializing standardized middleware configuration information according to the middleware type to obtain a corresponding message receiver, wherein the message receiver encapsulates the middleware interaction logic; When the associated system is monitored to transmit a message, a message receiver corresponding to the associated system is called to receive the message to realize the message transmission.

2. A method for multi-source message transmission based on middleware as claimed in claim 1, characterized in that: The middleware configuration information also includes a connection address. The middleware configuration information is parsed according to a preset parsing rule and parsed into a unified data structure to obtain standardized middleware configuration information including: The middleware configuration information is parsed according to preset parsing rules, and a legality check is performed during the parsing process. If the legality check passes, the middleware configuration information is parsed into a unified data structure, and a connection test is performed according to the connection address after the parsing is completed. If the connection test is successful, standardized middleware configuration information is obtained, otherwise, a connection failure prompt is generated.

3. A method for multi-source message transmission based on middleware as claimed in claim 2, characterized in that: The middleware configuration information also includes a port number, a user name and a password. The legitimacy check is performed during the parsing process. If the legitimacy check passes, the middleware configuration information is parsed into a unified data structure including: Determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is generated.

4. A method for multi-source message transmission based on middleware as claimed in claim 2, characterized in that: The connection test after parsing includes: After the parsing is completed, a connection test is performed by sending a heartbeat message or a query request to the connection address.

5. The method for multi-source message transmission based on middleware as claimed in claim 1, characterized in that: The calling of a message receiver corresponding to the associated system to receive a message and realize message transmission includes: Performing integrity verification and validity verification on the message, and if both the integrity verification and the validity verification pass, forwarding the message to achieve message transmission; The integrity check includes: Determine whether the message complies with a preset structure model, whether it complies with a preset type, whether it contains preset fields and whether it meets a preset field length. If so, the integrity check passes; The validity verification includes: It is determined whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission. If so, the validity verification is passed.

6. A multi-source message transmission system based on middleware, characterized in that: include: A parsing module is used to obtain middleware configuration information of all related systems including middleware types through a unified interface, parse the middleware configuration information according to preset parsing rules and parse it into a unified data structure to obtain standardized middleware configuration information; A dynamic generation module, used to dynamically load and initialize standardized middleware configuration information according to the middleware type to obtain a corresponding message receiver, in which the middleware interaction logic is encapsulated; The transmission module is used to call a message receiver corresponding to the associated system to receive the message when monitoring the associated system to transmit the message, so as to realize the message transmission.

7. A middleware-based multi-source message transmission system as claimed in claim 6, characterized in that: The middleware configuration information also includes a connection address, and the parsing module includes: The verification module is used to parse the middleware configuration information according to preset parsing rules, and perform a legality check during the parsing process. If the legality check passes, the middleware configuration information is parsed into a unified data structure, and after the parsing is completed, a connection test is performed according to the connection address. If the connection test is successful, standardized middleware configuration information is obtained, otherwise, a connection failure prompt is generated.

8. A middleware-based multi-source message transmission system as claimed in claim 7, characterized in that: The middleware configuration information also includes a port number, a user name and a password. The verification module is specifically: Determine whether the format of the connection address is correct, whether the port number is within the valid range, and whether the user name and password meet the security requirements. If so, the legitimacy check passes and the middleware configuration information is parsed into a unified data structure. If not, a parsing failure prompt is generated.

9. A middleware-based multi-source message transmission system as claimed in claim 7, characterized in that: The verification module is specifically: After the parsing is completed, a connection test is performed by sending a heartbeat message or a query request to the connection address.

10. A middleware-based multi-source message transmission system as claimed in claim 6, characterized in that: The transmission module is specifically: Performing integrity verification and validity verification on the message, and if both the integrity verification and the validity verification pass, forwarding the message to achieve message transmission; The integrity check includes: Determine whether the message complies with a preset structure model, whether it complies with a preset type, whether it contains preset fields and whether it meets a preset field length. If so, the integrity check passes; The validity verification includes: It is determined whether the field value of the message is within the valid value range, whether the message receiver has the receiving permission and whether the message sender has the sending permission. If so, the validity verification is passed.

Citation Information

Cited By

  • Multi-service message distribution method and device based on unified message processing service, storage medium and electronic device

    CN121334266A