A Beidou short message packet sending service cluster system
By designing the Beidou short newspaper group to send the service cluster system, the problem of data conversion and low user machine resource utilization in Beidou short newspapers in the communications of Beidou Shipping, and realized the efficient integration and resources of the Beidou user machine in the web system.
Patent Information
- Application Number
- CN202411638861.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-18
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2044-11-18
AI Technical Summary
In Beidou short message communication, it is difficult for the existing technology to effectively convert JSON format data into Beidou short message protocol, and when large data is sent, the sending opportunity of Beidou user machines is not fully utilized, resulting in hardware resource utilization Low.
A Beidou short newspaper group bag sends a service cluster system, including application service modules, group package service cluster modules, sending service cluster modules, network switch modules, and Beidou user machines. The system uses a counter -serialized JSON data to perform compression and protocol packages for Java objects, and uses message queues and registered center modules to achieve effective registration and resource use of Beidou user machines.
The conversion and group bags of the Beidou short newspaper protocol have been implemented, and the convenience and integration of Beidou user aircraft in the web system are enhanced, and the opportunities for sending the Beidou user aircraft will be used to improve the utilization rate of hardware resources.
Smart Images

Figure CN119154940B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of satellite communication data transmission, and in particular to a Beidou short message packet transmission service cluster system. Background Art
[0002] Beidou short message communication has gradually begun to be applied to various fields in daily life. When network connection is inconvenient, using Beidou short message is a very convenient means of communication. When users use browsers to display and send short message content, they need to convert the data format (JSON to Beidou short message protocol) and the transmission physical device (network port to serial port). Especially when the sending service needs to send large amounts of data, it is necessary not only to improve the convenience of connecting Beidou user terminals with the system, but also to make full use of the sending opportunities of Beidou user terminals.
[0003] In the Beidou-related web service system, assembling the data to be sent into messages according to the Beidou short message protocol is usually a pain point for web developers. Without understanding the Beidou protocol, it is impossible to use the Beidou user terminal using object-oriented thinking. Even after understanding the Beidou protocol, the data to be sent will be assembled according to the Beidou short message protocol. If a fixed pattern encoding is used, the scalability of subsequent services will be greatly reduced. Therefore, how to integrate the Beidou user terminal into the Web system as an "object" is a problem we should consider. Summary of the invention
[0004] The purpose of the invention provided by the present invention is to provide a Beidou short message packet sending service cluster system to solve the problems in the above-mentioned background technology.
[0005] To achieve the above objectives, the present invention is implemented through the following technical solutions: A Beidou short message package sending service cluster system, comprising:
[0006] The application service module is used to receive requests sent by users.
[0007] After receiving the package assembly request from the upstream application service module, the package assembly service cluster module deserializes the JSON data in the request into a Java object.
[0008] The sending service cluster module pulls the message from the message queue. After receiving the message, it performs a secondary confirmation on the Beidou user machine connection information and the Beidou user machine registration service in the message.
[0009] Network switch module, the switch provides multiple ports to allow multiple devices to connect and transmit data at the same time.
[0010] Beidou user terminal, Beidou user terminal is connected to the network device through the serial port server or its own network port, and the sending service will actively establish a communication link with the Beidou user terminal.
[0011] Registration center module, used to provide data.
[0012] There is a signal connection between the application service module and the package service cluster module, a signal connection between the package service cluster module and the sending service cluster module, a bidirectional signal connection between the sending service cluster module and the registration center module, a signal connection between the sending service cluster module and the network switch module, and a bidirectional signal connection between the network switch module and the Beidou user terminal.
[0013] Furthermore, the application service module is a web service used to receive user requests. The user selects the recipient card number to be sent in the browser interface, enters the message to be sent in the input box, and clicks the "Request to Send" button. After the application service module receives the sending request from the front-end page, it will perform a length check on the data. After the check is passed, it will carry the sent data and the sender card number information to initiate a package request to the package service cluster module.
[0014] Furthermore, the package service cluster module is also a web service, which is deployed in a clustered manner.
[0015] Furthermore, after receiving the package request initiated by the upstream application service module, the package service cluster module deserializes the JSON data in the request into a Java object, extracts the attribute information of the object for further compression, and after the compression is completed, combines the sender's card number information and the card number information of the available Beidou user terminal cached locally, and re-packages it into the Beidou short message protocol according to the Beidou short message protocol, calculates the protocol header and CRC check value, and serializes the data after the package is completed and pushes it to the message queue cluster.
[0016] Furthermore, the sending message queue cluster between the package assembly service cluster module and the sending service cluster module, other services are decoupled from the sending service cluster module through the sending message queue cluster, and the service that needs to send Beidou short messages will package the data and push it to the message queue. The sending service will actively pull the message from the message queue and send the message after secondary confirmation.
[0017] Furthermore, the sending service of the sending service cluster module is developed based on the Java language, supports cross-platform operation, and uses mature frameworks or services such as Netty, SpringBoot, MySQL, and redis.
[0018] Furthermore, the sending service of the sending service cluster module integrates the RabbitMQ client code, which will pull the message in the message queue. After receiving the message, the connection information of the Beidou user machine in the message and the Beidou user machine registration service are reconfirmed, and the Beidou short message data in the message is rechecked. After both items are confirmed to be correct, it is determined whether a connection has been established with the Beidou user machine through the Beidou user machine connection information.
[0019] Furthermore, if the Beidou user terminal has not established a connection, it is necessary to send a service to actively initiate a TCP connection to the Beidou user terminal. After the communication is successfully established, the Beidou short message data will be sent to the user terminal. The successfully sent Beidou short message data will be stored in the MySQL database for subsequent query.
[0020] Furthermore, the Beidou user terminal is connected to the network device through the serial port server or its own network port, and the sending service will actively establish a communication link with the Beidou user terminal.
[0021] Furthermore, after receiving the data transmitted by the sending service, the Beidou user terminal starts the sending process. After executing the sending process, it will feed back the communication results through the same link, that is, the sending service will receive a notification of whether the sending is successful. If it is a successful feedback, the sending service will request the Beidou user terminal to register the service, and notify that the used Beidou user terminal information will be set as temporarily unavailable, and will be set to available after the next sending cycle arrives. If the sending fails, the sending service will reselect the available Beidou user terminal and repeat the sending process until the sending is successful.
[0022] The present invention provides a Beidou short message grouping and sending service cluster system, which has the following beneficial effects:
[0023] It can perform protocol conversion and packaging, convert packaging from the JSON format commonly used on the Internet to the Beidou short message protocol, decouple the Beidou short message application system from the packaging sending service, improve the convenience of integrating Beidou user machines into Web system development, introduce Beidou user machine registration services, make full use of Beidou user machine sending opportunities, and improve hardware resource utilization. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] Figure 1 A schematic diagram of the system architecture of a Beidou short message packet sending service cluster system according to the present invention.
[0025] In the figure: 1. Application service module; 2. Packet service cluster module; 3. Sending service cluster module; 4. Network switch module; 5. Beidou user terminal; 6. Registration center module. DETAILED DESCRIPTION
[0026] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.
[0027] Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.
[0028] The present invention will be further described below in conjunction with the accompanying drawings and embodiments:
[0029] See also Figure 1 The present invention provides a technical solution: a Beidou short message package sending service cluster system, comprising:
[0030] Application service module 1 is used to receive user sending requests, package service cluster module 2, after receiving the package request raised by upstream application service module 1, deserializes the JSON data in the request into a Java object, sending service cluster module 3, pulls the message in the message queue, and after receiving the message, performs secondary confirmation on the Beidou user machine 5 connection information and Beidou user machine 5 registration service in the message, network switch module 4, the switch allows multiple devices to connect and transmit data at the same time by providing multiple ports, thereby significantly increasing the overall bandwidth of the network, Beidou user machine 5, Beidou user machine 5 is connected to the network device through a serial port server or its own network port, and the sending service will actively establish a communication link with the Beidou user machine 5, registration center module 6, for providing data, the data includes the IP and port information of the user machine, signal connection between application service module 1 and package service cluster module 2, signal connection between package service cluster module 2 and sending service cluster module 3, and bidirectional signal connection between sending service cluster module 3 and registration center module 6, which can realize the acquisition of card number and ip: port information. The signal connection between the sending service cluster module 3 and the network switch module 4 is established, and the bidirectional signal connection between the network switch module 4 and the Beidou user terminal 5 is established.
[0031] Application service module 1 is a web service used to receive user requests. Users can select the recipient card number to be sent in the browser interface, enter the message to be sent in the input box, and click the "Request to Send" button. After application service module 1 receives the sending request from the front-end page, it will perform a length check on the data. After the check passes, it will carry the sent data and the sender card number information to initiate a package request to the package service cluster module. The package service cluster module is also a web service and is deployed in a clustered manner. After receiving the package request initiated by the upstream application service module 1, the package service cluster module deserializes the JSON data in the request into a Java object, and extracts the object's attribute information for further compression. After the compression is completed, the sender's card number information and the card number information of the available Beidou user machine 5 cached locally are combined, and the Beidou short message protocol is re-packaged into the Beidou short message protocol. The protocol header and CRC check value are calculated. After the packaging is completed, the data is serialized and pushed to the message queue cluster. The sending message queue cluster between the packaging service cluster module 2 and the sending service cluster module 3, other services are decoupled from the sending service cluster module 3 through the sending message queue cluster. The service that needs to send Beidou short messages will package the data and push it to the message queue. The sending service will actively pull the message from the message queue, and send the message after a second confirmation. The sending service of the sending service cluster module 3 is developed based on the Java language, supports cross-platform operation, and uses Ne tty, SpringBoot, MySQL, redis mature framework or service, the sending service cluster module 3's sending service integrates the RabbitMQ client code, which will pull the message in the message queue. After receiving the message, the connection information of the Beidou user machine 5 in the message is double-confirmed with the Beidou user machine 5 registration service, and the Beidou short message data in the message is double-checked. After both items are confirmed, the Beidou user machine 5 connection information is used to determine whether a connection has been established with the Beidou user machine 5. If the Beidou user machine 5 has not established a connection, the sending service needs to actively initiate a TCP connection to the Beidou user machine 5. After the communication is successfully established, the Beidou short message data is sent to the user machine. The successfully sent Beidou short message The message data will be stored in the MySQL database for subsequent query. The Beidou user machine 5 is connected to the network device through the serial port server or its own network port. The sending service will actively establish a communication link with the Beidou user machine 5. After receiving the data transmitted by the sending service, the Beidou user machine 5 starts the sending process. After executing the sending process, it will feedback the communication result through the same link, that is, the sending service will receive a notification of whether the sending is successful. If the sending is successful, the sending service will request the Beidou user machine 5 to register the service, and notify that the used Beidou user machine 5 information will be set to temporarily unavailable, and it will be set to available after the next sending cycle arrives. If the sending fails, the sending service will reselect the available Beidou user machine 5 and repeat the sending process.Until the sending is successful.
[0032] Working principle:
[0033] The package service cluster module 2 is developed in Java language based on Spring Boot, and provides a message request interface to the application service module 1. The application service module 1 can use this interface to transmit the pre-sent data in JSON format using the http protocol. After receiving the pre-sent data, the package service cluster module deserializes the data in JSON format into a Java object, reads the attribute value of the object, and simplifies and indents the read attribute value according to the custom protocol content. For example, converting the character "A" to hexadecimal 0x1011 can save 4 bits, and the digital type "1" can be converted to hexadecimal 0x0001, which can also reduce 4 bits, Chinese characters are all encoded using GB2312. When encoding, the two highest bits 0xA1 are removed to reduce 2 bits. Each Chinese character occupies 14 bits. After the custom protocol part is packaged in the above manner, it is packaged again into the CCTXA protocol of the Beidou short message according to the recipient card number in the pre-sent data pushed by the upstream application service module 1, that is, the communication application protocol of the Beidou short message. After the package service cluster module completes the data packaging, it sends the communication data to the sending message queue of the sending service cluster module 3 through the http protocol. Beidou The Beidou short message sending service cluster module 3 is developed based on Java and SpringBoot, and introduces the RabbitMQ message queue and Netty asynchronous event-driven network application framework. It also uses MySQL database and Redis database services. When other services need to send Beidou short message messages, the Beidou user machine 5 information to be used, the sending content and the recipient address will be packaged and pushed to the message queue. The sending service cluster module 3 pulls the message to be sent from the RabbitMQ message queue, and takes out the Beidou user machine 5 information to be used and the Beidou user machine 5 service registration from the message. The registration service performs a secondary confirmation. If the user machine is offline or is in a sending gap, a new Beidou user machine 5 registration data is selected to be returned. Secondly, the sending content is taken out from the message for secondary verification. The content is XORed byte by byte according to the Beidou short message protocol. If the XOR result is consistent with the result carried in the sending content, it passes. The Beidou user machine 5 information contains the IP and Port information of the user machine. If the sending service has not yet established a connection with the Beidou user machine 5, a new TCP connection is initiated to the address. After completing the three-way handshake to establish a connection channel, the Beidou short message is sent to the Beidou user machine 5.
[0034] The above are only preferred embodiments of the present invention. It should be pointed out that a person skilled in the art can make several modifications and improvements without departing from the inventive concept of the present invention, and these all fall within the protection scope of the present invention.
Claims
1. A Beidou short message packet sending service cluster system, characterized in that: include: The application service module (1) is used to receive a request sent by a user; The package assembly service cluster module (2) receives the package assembly request raised by the upstream application service module (1), deserializes the JSON data in the request into a Java object; extracts the attribute information of the object for further compression; after the compression is completed, it combines the sender's card number information and the card number information of the available Beidou user machine (5) cached locally, re-assembles the package into the Beidou short message protocol according to the Beidou short message protocol, calculates the protocol header and CRC check value, and after the package assembly is completed, serializes the data and pushes it to the message queue cluster; The sending service cluster module (3) pulls the message in the message queue, and after receiving the message, performs a secondary confirmation on the Beidou user machine (5) connection information and the Beidou user machine (5) registration service in the message; A network switch module (4), wherein the switch provides multiple ports to allow multiple devices to be connected and transmit data at the same time; Beidou user terminal (5), Beidou user terminal (5) is connected to the network device through the serial port server or its own network port, and the sending service will actively establish a communication link with the Beidou user terminal (5); The registration center module (6) is used to provide data; A signal connection is established between the application service module (1) and the package assembly service cluster module (2), a signal connection is established between the package assembly service cluster module (2) and the sending service cluster module (3), a bidirectional signal connection is established between the sending service cluster module (3) and the registration center module (6), a signal connection is established between the sending service cluster module (3) and the network switch module (4), and a bidirectional signal connection is established between the network switch module (4) and the Beidou user terminal (5).
2. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: The application service module (1) is a web service for receiving a user's request to send. The user selects the recipient's card number to be sent on the browser interface, enters the message to be sent in the input box, and clicks the "Request to Send" button. After the application service module (1) receives the sending request from the front-end page, it will perform a length check on the data. After the check is passed, it will carry the sent data and the sender's card number information to initiate a package assembly request to the package assembly service cluster module.
3. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: The package service cluster module is a web service, which is deployed in a clustered manner.
4. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: Other services are decoupled from the sending service cluster module (3) through the sending message queue between the packetizing service cluster module (2) and the sending service cluster module (3). The service that needs to send Beidou short messages will package the data and push it to the message queue. The sending service will actively pull the message from the message queue and send the message after a second confirmation.
5. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: The sending service of the sending service cluster module (3) is developed based on the Java language, supports cross-platform operation, and uses the Netty framework, SpringBoot framework, MySQL service and redis service.
6. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: The sending service of the sending service cluster module (3) integrates the RabbitMQ client code, and will pull the message in the message queue. After receiving the message, the connection information of the Beidou user machine (5) in the message and the Beidou user machine (5) registration service are reconfirmed, and the Beidou short message data in the message is rechecked. After both items are confirmed to be correct, it is determined whether a connection has been established with the Beidou user machine (5) through the Beidou user machine (5) connection information.
7. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: If the Beidou user machine (5) has not established a connection, it is necessary to send a service to actively initiate a TCP connection to the Beidou user machine (5). After the communication is successfully established, the Beidou short message data is sent to the user machine. The successfully sent Beidou short message data will be stored in the MySQL database for subsequent query.
8. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: The Beidou user terminal (5) is connected to the network device via a serial port server or its own network port, and the sending service will actively establish a communication link with the Beidou user terminal (5).
9. A Beidou short message packet sending service cluster system according to claim 1, characterized in that: After receiving the data transmitted by the sending service, the Beidou user terminal (5) starts the sending process. After executing the sending process, the communication result will be fed back through the same link, that is, the sending service will receive a notification of whether the sending is successful. If the sending is successful, the sending service will request the Beidou user terminal (5) to register the service and notify that the information of the used Beidou user terminal (5) is set to be temporarily unavailable and set to be available after the next sending cycle arrives. If the sending fails, the sending service will reselect an available Beidou user terminal (5) and repeat the sending process until the sending is successful.
Citation Information
Patent Citations
Smart pasture livestock management information system based on Internet of Things
CN115237063A
Information transmission method and terminal
CN116170756A