Intelligent station automatic switch station system and method based on message publishing and subscription

By introducing message publishing and subscription mechanisms in the automatic switching station system, using real-time database to decouple the automatic switching station client and server, the coupling and complexity problems in traditional systems are solved, and development efficiency and scalability are improved. It realizes more efficient system maintenance and backup service access.

CN115277730BActive Publication Date: 2024-12-10NANJING RAIL TRANSIT SYST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210838762.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-18
Publication Date
2024-12-10
Estimated Expiration
2042-07-18

AI Technical Summary

Technical Problem

In traditional automatic switch station systems, the server end of the automatic switch station is closely coupled to the client, resulting in difficulty in modular processing and complex maintenance. The communication complexity of the backup server is high when accessing, affecting the scalability and high availability of the system.

Method used

Adopt a smart station automatic switching station system based on message publishing and subscription. Through real-time database decoupling of data communication and synchronization, the automatic switching station client and server decoupling is realized, simplifying the access of backup servers, and improving the system development and maintenance efficiency. and scalability.

Benefits of technology

It reduces the maintenance complexity of the automatic switching station system, improves development efficiency and scalability, simplifies backup service access, and improves the overall performance of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115277730B_ABST
    Figure CN115277730B_ABST
Patent Text Reader

Abstract

The present invention discloses a smart station automatic switch station system and method based on message publishing and subscription, including: an automatic switch station client, a real-time database, a main automatic switch station server, a standby automatic switch station server and an automatic switch station equipment terminal; the present invention decouples data communication and data synchronization from the automatic switch station client and the automatic switch station server through the publishing and subscription of the real-time database, which is convenient for modular processing of the automatic switch station system and improves the development and maintenance efficiency of the automatic switch station system to a certain extent. Through the subscription and publishing of the real-time database, the access work of the standby automatic switch station server is simplified, and the scalability of the automatic switch station system is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of automatic switch stations, and specifically relates to a smart station automatic switch station system and method based on message publishing and subscription. Background Art

[0002] In addition to providing passengers with more intelligent and humanized services, smart stations can also help station operators improve their work efficiency. Automatic switch stations are a typical new technology to improve station operation efficiency. Automatic switch stations can quickly realize safety confirmation of station switches, system self-checking, equipment action and status feedback, reduce labor costs, improve the timeliness of station equipment management, improve the intelligent operation and operation management functions of stations, and provide intelligent and high-quality services for station management.

[0003] In the traditional automatic switch station system, the automatic switch station server and the automatic switch station client communicate by direct connection. The automatic switch station server and the automatic switch station client are tightly coupled, and the two are too dependent on each other, which is not conducive to modular processing and is not convenient for the efficient development of multiple working surfaces of the automatic switch station system.

[0004] In addition, when considering adding a backup automatic switch station service, the complexity of maintaining the communication between the automatic switch station client, the automatic switch station server, and the backup automatic switch station server will be very high, which is not conducive to the scalability and high availability of the system. Summary of the invention

[0005] In view of the deficiencies of the above-mentioned prior art, the purpose of the present invention is to provide a smart station automatic switch station system and method based on message publishing and subscription, which decouples data communication and data synchronization from the automatic switch station client and the automatic switch station server through the publishing and subscription of the real-time database, facilitates the modular processing of the automatic switch station system, and improves the development and maintenance efficiency of the automatic switch station system to a certain extent. Through the subscription and publication of the real-time database, the access work of the standby automatic switch station server is simplified, and the scalability of the automatic switch station system is improved.

[0006] To achieve the above object, the technical solution adopted by the present invention is as follows:

[0007] A smart station automatic switch station system based on message publishing and subscription of the present invention comprises: an automatic switch station client, a real-time database, a main automatic switch station server, a standby automatic switch station server and an automatic switch station equipment terminal;

[0008] The automatic switch station client is used to publish the execution status of the automatic switch station system to the real-time database to notify the main automatic switch station server or the standby automatic switch station server to control the automatic switch station equipment terminal; and subscribe to the execution status of the automatic switch station system to the real-time database to display the status of the automatic switch station equipment terminal;

[0009] The main automatic switch station server is used to subscribe to the execution status of the automatic switch station system from the real-time database to achieve control of the automatic switch station equipment terminal; and publish the execution status of the automatic switch station system to the real-time database to notify the automatic switch station client to update and display the status of the automatic switch station equipment terminal;

[0010] The standby automatic switch station server is used to subscribe to the execution status of the automatic switch station system and the working status signal of the main automatic switch station server to the real-time database; when the main automatic switch station server fails, it takes over the work of the main automatic switch station server;

[0011] A real-time database is used to receive the release of the execution status of the automatic switch station system by the main automatic switch station server and the automatic switch station client, and store the execution status of the automatic switch station system; receive the subscription of the execution status of the automatic switch station system by the main automatic switch station server, the standby automatic switch station server and the automatic switch station client, obtain the change of the execution status of the automatic switch station equipment terminal, and send the changed execution status to the subscriber; forward the control signal of the main automatic switch station server to the automatic switch station equipment terminal, and return the command execution result of the automatic switch station equipment terminal to the main automatic switch station server;

[0012] The automatic switch station equipment terminal receives the control signal of the main automatic switch station server forwarded by the real-time database in real time and executes the corresponding command action.

[0013] Furthermore, the execution status of the automatic switch station system specifically includes: control instructions and instruction execution results of the automatic switch station terminal equipment, wherein the control instructions include three states: start, execution completion, and execution end.

[0014] Furthermore, the publishing of the execution status of the automatic switch station system refers to the main automatic switch station server or the automatic switch station client sending the execution status of the automatic switch station system to the real-time database, and the real-time database updates the stored execution status of the automatic switch station system.

[0015] Furthermore, the receiving of subscription to the execution status of the automatic switch station system refers to the real-time database saving the socket connection list of all subscribers and the real-time database. When the execution status of the automatic switch station system stored in the real-time database is updated, the real-time database will send the updated execution status of the automatic switch station to all subscribers.

[0016] Furthermore, the subscribers refer to the main automatic switch station service end, the backup automatic switch station service end and the automatic switch station client end.

[0017] A method for realizing a smart station automatic switch station based on message publishing and subscription of the present invention is based on the above system, and the steps are as follows:

[0018] 1) The automatic switch station client publishes the execution status of the automatic switch station system to the real-time database;

[0019] 2) The real-time database sends the execution status of the automatic switch station system to the main automatic switch station server and the standby automatic switch station server;

[0020] 3) The main automatic switch station server sends the execution instruction of the automatic switch station equipment terminal to the real-time database;

[0021] 4) The real-time database forwards the execution instruction of the automatic switch station equipment terminal to the automatic switch station equipment terminal;

[0022] 5) The automatic switch station equipment terminal receives the command and executes it;

[0023] 6) The automatic switch station equipment terminal sends the execution results to the real-time database;

[0024] 7) The real-time database sends the execution results of the automatic switch station equipment terminal to the main automatic switch station server;

[0025] 8) The main automatic switch station server publishes the execution status of the automatic switch station system to the real-time database;

[0026] 9) The real-time database sends the execution status of the automatic switch station system to the automatic switch station client and the standby automatic switch station server;

[0027] 10) The automatic switch station client updates and displays the status of the automatic switch station equipment terminal;

[0028] 11) The automatic switch station client determines whether all automatic switch station equipment terminals have completed execution. If so, the process ends. If not, it returns to step 1).

[0029] Furthermore, the step 1) specifically includes: the automatic switch station client stores the execution status of the automatic switch station system, that is, the control instruction is set to start, and the instruction execution result of the automatic switch station terminal device is set to the initial value; the automatic switch client publishes the stored execution status of the automatic switch station system to the real-time database.

[0030] Furthermore, the step 2) specifically includes: the real-time database stores the execution status of the automatic switch station system published by the automatic switch station client, and sends it to the subscribers, namely the main and backup automatic switch station servers.

[0031] Furthermore, the step 3) specifically includes: the main automatic switch station service end analyzes the execution status of the automatic switch station system, and after the control instruction obtained from the analysis is start, sends the specific execution instruction of the automatic switch station equipment terminal to the real-time database.

[0032] Furthermore, the step 8) specifically includes: the main automatic switch station server stores the execution status of the automatic switch station system, that is, the control instruction is set to be executed, and the instruction execution result of the automatic switch station terminal device is set to the actual execution result; the main automatic switch station server publishes the stored execution status of the automatic switch station system to the real-time database.

[0033] Furthermore, the step 9) specifically includes: the real-time database stores the execution status of the automatic switch station system published by the main automatic switch station server, and sends it to the subscribers, namely the standby automatic switch station server and the automatic switch station client.

[0034] Furthermore, the step 10) specifically includes: the automatic switch station client parses the execution status of the automatic switch station system, and after the control instruction is parsed and executed, the terminal status of the automatic switch station device is updated and displayed according to the instruction execution result of the automatic switch station terminal device.

[0035] Beneficial effects of the present invention:

[0036] The present invention realizes the decoupling of the automatic switch station client and the automatic switch station server based on message publishing and subscription, reduces the maintenance complexity of the automatic switch station client and the automatic switch station server, improves the development and maintenance efficiency of the automatic switch station system, simplifies the data synchronization and sharing between the automatic switch station client and the automatic switch station server, reduces the complexity of the standby automatic switch station server access system, and improves the scalability of the automatic switch station system. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] Figure 1 It is a schematic diagram of the system structure of the present invention;

[0038] Figure 2 It is a schematic diagram of the process of the present invention. DETAILED DESCRIPTION

[0039] In order to facilitate the understanding of those skilled in the art, the present invention is further described below in conjunction with embodiments and drawings. The contents mentioned in the implementation modes are not intended to limit the present invention.

[0040] Reference Figure 1 As shown, a smart station automatic switch station system based on message publishing and subscription of the present invention includes: an automatic switch station client, a real-time database, a main automatic switch station server, a standby automatic switch station server and an automatic switch station equipment terminal;

[0041] The automatic switch station client is used to publish the execution status of the automatic switch station system to the real-time database to notify the main automatic switch station server or the standby automatic switch station server to control the automatic switch station equipment terminal; and subscribe to the execution status of the automatic switch station system to the real-time database to display the status of the automatic switch station equipment terminal;

[0042] The main automatic switch station server is used to subscribe to the execution status of the automatic switch station system from the real-time database to achieve control of the automatic switch station equipment terminal; and publish the execution status of the automatic switch station system to the real-time database to notify the automatic switch station client to update and display the status of the automatic switch station equipment terminal;

[0043] The standby automatic switch station server is used to subscribe to the execution status of the automatic switch station system and the working status signal of the main automatic switch station server to the real-time database; when the main automatic switch station server fails, it takes over the work of the main automatic switch station server;

[0044] A real-time database is used to receive the publication of the execution status of the automatic switch station system by the main automatic switch station server and the automatic switch station client, and store the execution status of the automatic switch station system; receive the subscription of the execution status of the automatic switch station system by the main automatic switch station server, the standby automatic switch station server and the automatic switch station client, obtain the change of the execution status of the automatic switch station equipment terminal, and send the changed execution status to the subscriber (referring to the main automatic switch station server, the standby automatic switch station server and the automatic switch station client); forward the control signal of the main automatic switch station server to the automatic switch station equipment terminal, and return the command execution result of the automatic switch station equipment terminal to the main automatic switch station server;

[0045] The automatic switch station equipment terminal receives the control signal of the main automatic switch station server forwarded by the real-time database in real time and executes the corresponding command action.

[0046] The execution status of the automatic switch station system specifically includes: control instructions and instruction execution results of the automatic switch station terminal equipment, wherein the control instructions include three states: start, execution completion, and execution end.

[0047] The publishing of the execution status of the automatic switch station system refers to the main automatic switch station server or the automatic switch station client sending the execution status of the automatic switch station system to the real-time database, and the real-time database updates the stored execution status of the automatic switch station system.

[0048] Among them, the receiving of subscription to the execution status of the automatic switch station system refers to the real-time database saving the socket connection list of all subscribers and the real-time database. When the execution status of the automatic switch station system stored in the real-time database is updated, the real-time database will send the updated execution status of the automatic switch station to all subscribers.

[0049] Reference Figure 2 As shown, a method for realizing a smart station automatic switch station based on message publishing and subscription of the present invention is based on the above system, and the steps are as follows:

[0050] 1) The automatic switch station client publishes the execution status of the automatic switch station system to the real-time database; specifically, the automatic switch station client stores the execution status of the automatic switch station system, that is, the control instruction is set to start, and the instruction execution result of the automatic switch station terminal device is set to the initial value; the automatic switch client publishes the stored execution status of the automatic switch station system to the real-time database.

[0051] 2) The real-time database sends the execution status of the automatic switch station system to the main automatic switch station server and the backup automatic switch station server; specifically, the real-time database stores the execution status of the automatic switch station system published by the automatic switch station client and sends it to the subscribers, namely the main and backup automatic switch station servers.

[0052] 3) The main automatic switch station server sends the execution instructions of the automatic switch station equipment terminal to the real-time database; specifically, the main automatic switch station server parses the execution status of the automatic switch station system, and after parsing the control instruction to start, it sends the specific execution instructions of the automatic switch station equipment terminal to the real-time database, such as open and close.

[0053] 4) The real-time database forwards the execution instruction of the automatic switch station equipment terminal to the automatic switch station equipment terminal;

[0054] 5) The automatic switch station equipment terminal receives the command and executes it;

[0055] 6) The automatic switch station equipment terminal sends the execution results to the real-time database;

[0056] 7) The real-time database sends the execution results of the automatic switch station equipment terminal to the main automatic switch station server;

[0057] 8) The main automatic switch station server publishes the execution status of the automatic switch station system to the real-time database; specifically, the main automatic switch station server stores the execution status of the automatic switch station system, that is, the control instruction is set to be executed, and the instruction execution result of the automatic switch station terminal device is set to the actual execution result; the main automatic switch station server publishes the stored execution status of the automatic switch station system to the real-time database.

[0058] 9) The real-time database sends the execution status of the automatic switch station system to the automatic switch station client and the backup automatic switch station server; specifically, the real-time database stores the execution status of the automatic switch station system published by the main automatic switch station server and sends it to the subscribers, namely the backup automatic switch station server and the automatic switch station client.

[0059] 10) The automatic switch station client updates and displays the status of the automatic switch station equipment terminal; specifically, the automatic switch station client parses the execution status of the automatic switch station system, and after the control instruction is parsed and executed, the automatic switch station equipment terminal status is updated and displayed according to the instruction execution result of the automatic switch station terminal device.

[0060] 11) The automatic switch station client determines whether all automatic switch station equipment terminals have completed execution. If so, the process ends. If not, it returns to step 1).

[0061] After the main and auxiliary automatic switch station servers are started, they will register with the real-time database. The automatic switch station server that registers first is the main automatic switch station server, and the automatic switch station server that registers later is the backup automatic switch station server. The main automatic switch station server and the backup automatic switch station server periodically send status information to the real-time database. When the real-time database obtains that the main automatic switch station server has a fault, the real-time database sends a message to the backup automatic switch station server to notify it to upgrade to the main automatic switch station server. When the original faulty main automatic switch station server successfully re-registers with the real-time database and works, it will be notified as the backup automatic switch station server.

[0062] The present invention has many specific application paths. The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements can be made without departing from the principle of the present invention. These improvements should also be regarded as the protection scope of the present invention.

Claims

1. A smart station automatic switch station system based on message publishing and subscription, It is characterized in that include: Automatic switch station client, real-time database, main automatic switch station server, standby automatic switch station server and automatic switch station equipment terminal; The automatic switch station client is used to publish the execution status of the automatic switch station system to the real-time database to notify the main automatic switch station server or the standby automatic switch station server to control the automatic switch station equipment terminal; and subscribe to the execution status of the automatic switch station system to the real-time database to display the status of the automatic switch station equipment terminal; The main automatic switch station server is used to subscribe to the execution status of the automatic switch station system from the real-time database to achieve control of the automatic switch station equipment terminal; and publish the execution status of the automatic switch station system to the real-time database to notify the automatic switch station client to update and display the status of the automatic switch station equipment terminal; The standby automatic switch station server is used to subscribe to the execution status of the automatic switch station system and the working status signal of the main automatic switch station server to the real-time database; when the main automatic switch station server fails, it takes over the work of the main automatic switch station server; A real-time database is used to receive the release of the execution status of the automatic switch station system by the main automatic switch station server and the automatic switch station client, and store the execution status of the automatic switch station system; receive the subscription of the execution status of the automatic switch station system by the main automatic switch station server, the standby automatic switch station server and the automatic switch station client, obtain the change of the execution status of the automatic switch station equipment terminal, and send the changed execution status to the subscriber; forward the control signal of the main automatic switch station server to the automatic switch station equipment terminal, and return the command execution result of the automatic switch station equipment terminal to the main automatic switch station server; The automatic switch station equipment terminal receives the control signal of the main automatic switch station server forwarded by the real-time database in real time and executes the corresponding command action.

2. According to claim 1, the intelligent station automatic switch station system based on message publishing and subscription, It is characterized in that The execution status of the automatic switch station system specifically includes: control instructions and instruction execution results of the automatic switch station terminal equipment, wherein the control instructions include three states: start, execution completion, and execution end.

3. According to claim 1, the intelligent station automatic switch station system based on message publishing and subscription, It is characterized in that The publishing of the execution status of the automatic switch station system refers to the main automatic switch station server or the automatic switch station client sending the execution status of the automatic switch station system to the real-time database, and the real-time database updates the stored execution status of the automatic switch station system.

4. According to claim 1, the intelligent station automatic switch station system based on message publishing and subscription, It is characterized in that The receiving of subscription to the execution status of the automatic switch station system means that the real-time database saves the socket connection list of all subscribers and the real-time database. When the execution status of the automatic switch station system stored in the real-time database is updated, the real-time database will send the updated execution status of the automatic switch station to all subscribers.

5. According to claim 1, the intelligent station automatic switch station system based on message publishing and subscription, It is characterized in that The subscribers refer to the main automatic switch station server, the backup automatic switch station server and the automatic switch station client.

6. A method for realizing a smart station automatic switch station based on message publishing and subscription, based on the system described in any one of claims 1 to 5, It is characterized in that Here are the steps: 1) The automatic switch station client publishes the execution status of the automatic switch station system to the real-time database; 2) The real-time database sends the execution status of the automatic switch station system to the main automatic switch station server and the standby automatic switch station server; 3) The main automatic switch station server sends the execution instruction of the automatic switch station equipment terminal to the real-time database; 4) The real-time database forwards the execution instruction of the automatic switch station equipment terminal to the automatic switch station equipment terminal; 5) The automatic switch station equipment terminal receives the command and executes it; 6) The automatic switch station equipment terminal sends the execution results to the real-time database; 7) The real-time database sends the execution results of the automatic switch station equipment terminal to the main automatic switch station server; 8) The main automatic switch station server publishes the execution status of the automatic switch station system to the real-time database; 9) The real-time database sends the execution status of the automatic switch station system to the automatic switch station client and the standby automatic switch station server; 10) The automatic switch station client updates and displays the status of the automatic switch station equipment terminal; 11) The automatic switch station client determines whether all automatic switch station equipment terminals have completed execution. If so, the process ends. If not, it returns to step 1).

7. According to claim 6, the method for realizing automatic switch station of smart station based on message publishing and subscription, It is characterized in that The step 1) specifically includes: the automatic switch station client stores the execution status of the automatic switch station system, that is, the control instruction is set to start, and the instruction execution result of the automatic switch station terminal device is set to the initial value; the automatic switch client publishes the stored execution status of the automatic switch station system to the real-time database.

8. According to claim 6, the method for realizing the automatic switch station of a smart station based on message publishing and subscription, It is characterized in that The step 8) specifically includes: the main automatic switch station server stores the execution status of the automatic switch station system, that is, the control instruction is set to be executed, and the instruction execution result of the automatic switch station terminal device is set to the actual execution result; the main automatic switch station server publishes the stored execution status of the automatic switch station system to the real-time database.

9. According to claim 6, the method for realizing the automatic switch station of a smart station based on message publishing and subscription, It is characterized in that Furthermore, the step 10) specifically includes: the automatic switch station client parses the execution status of the automatic switch station system, and after the control instruction is parsed and executed, the terminal status of the automatic switch station device is updated and displayed according to the instruction execution result of the automatic switch station terminal device.