CN115203204B - High-capacity decoupling flexible master station system and control method - Google Patents

High-capacity decoupling flexible master station system and control method Download PDF

Info

Publication number
CN115203204B
CN115203204B CN202210820341.8A CN202210820341A CN115203204B CN 115203204 B CN115203204 B CN 115203204B CN 202210820341 A CN202210820341 A CN 202210820341A CN 115203204 B CN115203204 B CN 115203204B
Authority
CN
China
Prior art keywords
real
picture
time
data
station system
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210820341.8A
Other languages
Chinese (zh)
Other versions
CN115203204A (en
Inventor
李德军
陈明恩
季玮
张拯民
施广德
李俊达
战锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guodian Nanjing Automation Co Ltd
Original Assignee
Guodian Nanjing Automation Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guodian Nanjing Automation Co Ltd filed Critical Guodian Nanjing Automation Co Ltd
Priority to CN202210820341.8A priority Critical patent/CN115203204B/en
Publication of CN115203204A publication Critical patent/CN115203204A/en
Application granted granted Critical
Publication of CN115203204B publication Critical patent/CN115203204B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2458Special types of queries, e.g. statistical queries, fuzzy queries or distributed queries
    • G06F16/2471Distributed queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/40169Flexible bus arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/14Multichannel or multilink protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • H04L69/163In-band adaptation of TCP data exchange; In-band control procedures
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Abstract

The invention discloses a high-capacity decoupling flexible main station system and a control method, comprising the following steps: the DCS master station system real-time database, a plurality of real-time data servers and a plurality of real-time clients; the invention supports the data interaction of the distributed system based on the network communication soft bus technology, combines the program design mode, the template class-object and the micro-service thinking as the working mode of the real-time data server, and the automatic master station system has the advantages of loose coupling relation, dispersed functions, dispersed regions, huge capacity, low computer configuration requirement on each operator station, effective reduction of hardware cost, no need of encoding new modules, effective dynamic expansion of each real-time inquiry or display client by adding the running process of the template class-object instance of the professional real-time data server, simple and efficient maintenance of the software program modules, and smooth upgrade to the new software architecture. Stable performance, reliability and high efficiency, and has wide application prospect.

Description

High-capacity decoupling flexible master station system and control method
Technical Field
The invention relates to a high-capacity decoupling flexible master station system and a control method, and belongs to the technical field of real-time data interaction.
Background
The general master station system is provided with a real-time database, accesses the real-time database in a classical way, provides a real-time database interface function in a shared memory way, and directly calls other related application processes app, such as real-time pictures, alarm modules, real-time curves, other real-time inquiry or browsing tools and the like. The master station system synchronizes a plurality of computer servers, and adopts a real-time database synchronization mode, as shown in figure 1;
the most similar technical scheme is as follows:
one end of a single real-time data server is connected with various clients, the other end of the single real-time data server is connected with a real-time database, various clients with different types have a plurality of interactive data points, the data are complex, the single real-time data server is suitable for a plurality of clients with different types, the real-time data server is in a pair of multimode modes, the requirements on design and programming are high, and once errors occur, all the clients cannot work normally.
A point-to-point professional real-time data server mode, as shown in fig. 3, a professional server corresponds to a professional client; thus, each real-time data server realizes data distribution and can bear large-capacity client data. However, the real-time data server corresponding to each type of client needs to be redesigned and encoded, so that the real-time data server has more modules, disordered codes and difficult maintenance.
The research is far insufficient for a large-capacity distributed master station system with strong real-time performance, once different places or multiple computers are required to be distributed in a scattered mode, the data among different real-time libraries need to be synchronized, the technology for realizing the multi-computer synchronous real-time database is complex, the distributed arrangement of different computers is difficult to realize, the large-range different-place deployment is more difficult to realize, the requirement on the hardware configuration of an operating computer is high, and the cost is high.
Disclosure of Invention
The invention aims to overcome the defects in the prior art, provides a high-capacity decoupling flexible master station system and a control method, supports data interaction of a distributed system based on a network communication soft bus technology, combines a program design mode, templates class-object and microservices think as a real-time data server working mode, can effectively and dynamically expand various real-time inquiry or display clients without adding a real-time data server code module, and is simple and efficient in maintenance of a software program module.
In order to achieve the above purpose, the invention is realized by adopting the following technical scheme:
in a first aspect, the present invention provides a high capacity decoupling flexible primary station system comprising: the DCS master station system real-time database, a plurality of real-time data servers and a plurality of real-time clients; the real-time clients are respectively connected with the real-time data servers in a one-to-one correspondence manner by adopting a TCP soft bus manner, and the real-time data servers are connected with a DCS master station system real-time database by adopting a shared memory function interface manner, wherein the real-time clients comprise any one or more of a real-time picture client, an alarm client and a real-time curve client;
the real-time client is connected with the real-time data server in a read-write behavior interface mode established based on a message mechanism;
the DCS master station system real-time database comprises a main database and a standby database which are synchronously arranged;
the real-time clients also comprise a read-write mode of a shared memory and are connected with the real-time database of the DCS master station system.
In a second aspect, the present invention provides a control method of a high capacity decoupling flexible master station system according to any one of the preceding claims, applied to a real time data server, comprising:
receiving a link establishment signal sent by a first real-time client side by taking any picture as a unit, and establishing a tcp link with the real-time client side by taking the picture;
establishing a server-client picture new thread, acquiring initialization information and real-time data information of the picture to establish a multi-dimensional index zone linked list, wherein the multi-dimensional index zone linked list comprises a picture index zone and a picture data zone which are respectively used for storing picture objects and picture data information points;
receiving real-time data information of any picture sent by a second real-time client, searching whether the picture index mark exists in a picture index area, if not, establishing a picture data area and a picture index area of the picture, and if so, sharing the picture data area and synchronously updating the picture index area;
inquiring/dynamically registering and notifying a data point objected set in the picture communication link thread to a DCS master station system real-time database; if new data is acquired from a DCS master station system real-time database, judging whether a configuration script exists in the objected point, if so, locking and writing the configuration script into a picture data area after the script runs data for reprocessing; and pushing the registration data points to all real-time clients establishing tcp links in the picture index area.
Further, when the real-time data server establishes a link signal with the real-time client, the method further includes:
and acquiring initialization information sent by the client, judging whether the initialization information is in a pre-established white list, and if so, establishing a tcp link with the real-time client by using the picture.
Further, the initialization information includes ip address information of the real-time client.
Further, the real-time data information includes the picture object and picture data information points, wherein the picture object or the virtual picture object is set up as an index flag.
Further, when the real-time client switches the frames or closes the frames, the tcp link established with the real-time data server is closed, if the tcp link of the frame is closed but the number of links is still more than 0, the index area information is synchronously updated, and the frame data area is not deleted; if all tcp links of the picture are closed, the relevant information of the picture index area is released, and the picture data area is still in a cache state and is not deleted immediately.
Furthermore, the real-time data server performs the searching and inquiring of the pictures by adopting two modes of a hash table and a list table, and synchronously maintains and updates the double tables, wherein,
by adopting a hash table query mode, the index region result can be immediately queried through retrieving the picture object;
the list table inquiring mode is adopted, the list table is provided with an object address pointer of a picture object data area, first-in first-out is adopted, the last use is to place the tail of the queue, if the object exists in the list, the current object is removed from the original position in the list and added to the tail of the list queue, and when the picture quantity reaches the set cache quantity, the corresponding index area is detected from the direction of the head of the queue and no effective information is deleted.
Further, after the real-time data server establishes a link with the real-time client, classifying the picture data points, including query and change notification, wherein the query is one-time query or multiple-time query, and the query is timing query and forwarding; the change notification point objected starts a registration notification mode and establishes association relations of a plurality of corresponding picture index areas and data areas for forwarding.
Further, the real-time client writes the real-time database of the DCS master station system in a manner of remote control or manual number setting to the real-time database, judges whether to update the data area according to the returned result, and forwards and pushes corresponding information to other real-time clients.
Further, when the real-time client closes the tcp link established with the real-time data server, the real-time data server immediately releases the thread corresponding to the picture communication link from the picture index area maintenance list, and removes the client information; when the tcp link number of the picture index area corresponding to different clients is 0, the real-time data server stops inquiring and acquiring data from a DCS master station system real-time database, the registered registration notification point cancels the registration notification, and the picture data is not refreshed any more by the real-time data server; after the re-linking of the corresponding tcp link of the picture is successful, the real-time data server re-starts to inquire and acquire data from the real-time database of the DCS master station system again, re-registers the registration notification, re-starts and refreshes the data, and selects whether to re-establish the picture data area according to whether the cache queue of the picture data area reaches a preset condition or not.
Furthermore, two sets of interface functions are adopted among the DCS master station system real-time database, the plurality of real-time data servers and the plurality of real-time clients to realize real-time data read-write operation, the two sets of interface functions comprise a shared memory function interface mode and a message mechanism read-write behavior interface mode, a function dictionary table is arranged in the real-time data servers to index and accurately match the two sets of interface functions, and two sets of mode interface functions are established to correspond to each other in a bridging association relation.
Compared with the prior art, the invention has the beneficial effects that:
the invention provides a high-capacity decoupling flexible master station system and a control method, which are based on a network communication soft bus technology to support data interaction of a distributed system, and combine a program design mode, wherein template class-object and micro-service thinking are used as real-time data server working modes. Stable performance, reliability and high efficiency, and has wide application prospect.
Drawings
FIG. 1 is a schematic diagram of a real-time database schema of a conventional master station system in the prior art;
FIG. 2 is a block diagram of a primary station system of a one-to-many small capacity real-time data server of the prior art;
FIG. 3 is a block diagram of a master station system for a point-to-point professional data server of the prior art;
FIG. 4 is a block diagram of a high capacity decoupling flexible primary station system provided by an embodiment of the present invention;
FIG. 5 is a flow chart of a control method of a high-capacity decoupling flexible master station system provided by an embodiment of the invention;
fig. 6 is a schematic diagram of a master station system architecture based on a template class-object micro-service idea according to an embodiment of the present invention.
Detailed Description
The invention is further described below with reference to the accompanying drawings. The following examples are only for more clearly illustrating the technical aspects of the present invention, and are not intended to limit the scope of the present invention.
Example 1
This embodiment describes a high capacity decoupling flexible master station system comprising: the DCS master station system real-time database, a plurality of real-time data servers and a plurality of real-time clients; the real-time clients are respectively connected with the real-time data servers in a one-to-one correspondence manner by adopting a TCP soft bus manner, and the real-time data servers are connected with a DCS master station system real-time database by adopting a shared memory function interface manner, wherein the real-time clients comprise any one or more of a real-time picture client, an alarm client and a real-time curve client;
the real-time client is connected with the real-time data server in a read-write behavior interface mode established based on a message mechanism;
the DCS master station system real-time database comprises a main database and a standby database which are synchronously arranged;
the real-time clients also comprise a read-write mode of a shared memory and are connected with the real-time database of the DCS master station system.
Example 2
The present embodiment provides a control method of the high-capacity decoupling flexible master station system according to any one of embodiment 1, applied to a real-time data server, including:
receiving a link establishment signal sent by a first real-time client side by taking any picture as a unit, and establishing a tcp link with the real-time client side by taking the picture;
establishing a server-client picture new thread, acquiring initialization information and real-time data information of the picture to establish a multi-dimensional index zone linked list, wherein the multi-dimensional index zone linked list comprises a picture index zone and a picture data zone which are respectively used for storing picture objects and picture data information points;
receiving real-time data information of any picture sent by a second real-time client, searching whether the picture index mark exists in a picture index area, if not, establishing a picture data area and a picture index area of the picture, and if so, sharing the picture data area and synchronously updating the picture index area;
inquiring/dynamically registering and notifying a data point objected set in the picture communication link thread to a DCS master station system real-time database; if new data is acquired from a DCS master station system real-time database, judging whether a configuration script exists in the objected point, if so, locking and writing the configuration script into a picture data area after the script runs data for reprocessing; and pushing the registration data points to all real-time clients establishing tcp links in the picture index area.
The application process of the control method of the high-capacity decoupling flexible master station system provided by the embodiment specifically relates to the following steps:
as shown in fig. 4 and fig. 5, based on the scheme of the template class-object and micro-service idea real-time data server mode, in view of the most complex real-time client, the present invention takes the object real-time data server 1 and real-time clients 1-n generated by the real-time data server class template as an example to illustrate the workflow, and other real-time data servers and real-time query or browsing clients work logic flows are similar to this. Each real-time client interacts with the commercial database data, and the invention is not described. In design and implementation, the following design points and technical features are followed:
(1) The calling process reads the configuration file, and parameters such as IP, port (Port), real-time server number and the like are transmitted to establish a plurality of real-time server running instances.
(2) The real-time data Server 1 works in Server mode according to IP and Port, and the TCP soft bus also works in Server mode to start interception. The real-time clients 1-n work in the Client mode, the TCP soft bus also works in the Client mode, and the first step of active chain establishment is carried out by taking each picture page of the Client as a unit. The real-time data server 1 checks whether the parameters are within the white list according to the ip address of the client. If yes, agreeing to build the chain. If not, the link is broken. Every time a frame is switched, the original frame link is closed, and a new tcp link is established for a new frame.
It is noted that, instead of using the whole client x of the real-time frame as the tcp link unit, the maintenance unit is designed for the tcp link per frame of the client. In all the clients of different categories, the real-time clients generally have the most pictures, the pictures are required to be frequently switched, the complexity is high, other real-time query software can perform similar reasoning and determination according to the number of data points, the actual conditions of operation behaviors and the like, and virtual picture objects similar to the pictures are established and used as keywords of an index area. The real-time data server thus establishes a picture data area and an index area in units of pictures, and establishes a bi-directional association relationship with each other 2.
Hiding or closing the picture, etc., the communication link is disconnected. Even if different picture clients can open a plurality of pictures, only a plurality of currently displayed working pictures are in an effective working state, and the hidden pictures are in the working state data which are not displayed currently and are not required to be refreshed, so that a server-side link does not need to be maintained in a working and data area.
Therefore, each picture is taken as design maintenance granularity, and the storage quantity and processing complexity of various data points in the data area of the real-time data server can be greatly reduced. The number of clients that can be supported by the real-time data server side is objectively increased. The data interaction pressure of the two parties is greatly reduced, the real-time data interaction efficiency and capacity are improved, and the unnecessary refreshing of the real-time data of the two parties is prevented.
(3) If the link is an effective link in the white list, a new thread of a server-Client picture is established, client information is acquired, and the ip information and threads of clients, picture objects and other multidimensional index zone linked lists are established.
(4) When a real-time client x opens any new picture, the link normally starts to send initialization information and real-time data information, and the information points are analyzed and decomposed at a server side, so that a picture data area is established. And uses the picture object as index mark unit. The objects of the same picture are unique in the host system regardless of which real-time client, and these picture objects and data information points are determined by the configuration software, configuration model software, etc. of the host system. When any real-time client runs, only the picture is loaded, and a data maintenance area is built according to information points in the picture. Pictures have global uniqueness and identity. The data area using the picture object as an index key has global uniqueness and identity, and the picture data area is shared by a plurality of identical pictures of the real-time client simultaneously running.
Whenever the real-time data server accepts a client x new picture initialization, it retrieves whether the picture index exists. If the thread does not exist, creating a thread, a picture index area such as a picture object, a tcp link and the like and a picture information point data area; if the information exists, the picture data area is shared, and the new threads of the index area, the new tcp links and the like are synchronously updated; this screen link is closed whenever the screen is switched or turned off. If the tcp link is closed but the number of links is still greater than 0, the index area information is updated synchronously, and the picture data area is not deleted. If the last tcp link of the picture is also closed. The relevant information of the picture index area is released, and the picture data area is still in a buffer state and is not deleted immediately. And realizing synchronous updating of the picture index area and caching of the picture data area.
The picture inquiry adopts a double-table maintenance mode: one is a hash table, the picture file uniquely identifies the objected, and as a key word, the index area result can be immediately queried in the hash. The other is list table, which is the object address pointer of the picture object data area, first in first out, and last in use, the tail of the queue is placed. If the object is already in the list, the current object is removed from the list in-situ and added to the list tail when used, thus forming the most recently used tail strategy. When the number of pictures reaches the set buffer number, deleting the corresponding index area when no effective information is detected from the head of the queue. The double table is synchronously maintained and updated. The design idea of the latest object is kept, and the rapidity of object access and the novelty of latest use are improved. This avoids frequent creation or deletion of picture data areas, picture index areas. The access rapidity is improved.
(5) The real-time data server 1 classifies the picture data points, including query (one query/multiple queries) and change notification class 2. The query is a timed query and forwarded. The change notification point objected starts a registration notification mode and establishes association relations of a plurality of corresponding picture index areas and data areas for forwarding. The hash table of the same object point in the same picture is unique at the end of the real-time data server 1 and is used for quickly indexing or accessing the data information of the same object point.
(6) The real-time data server 1 queries/dynamically registers the real-time database for a set of data points objected within the picture communication link thread. If new data is obtained from the real-time library, whether a configuration script exists in the objected point or not can be combined, if yes, after the script runs the data for reprocessing, the data is locked and written into the hash data area, so that the data is operated once in the real-time data server 1, and repeated operation on each client is not needed. And the operation pressure of the client computer is reduced. And pushing all the picture clients of the Client linked list to the registration class data points.
(7) The real-time client x remotely controls, manually writes the real-time database into the real-time database, and according to the returned result, whether to update the point data area or not, and forwards and pushes corresponding information to other picture clients.
(8) And the real-time data server immediately releases resources such as threads corresponding to the picture communication link from the picture index area maintenance list and removes the client information. When the tcp link number of the picture index area corresponding to different clients is 0, which indicates that the clients of the picture corresponding to the links are all closed, the real-time server 1 stops inquiring and acquiring data from the real-time database, the registered registration notification point cancels the registration notification, and the picture data is not refreshed any more. After the tcp link is successfully re-established (greater than 0), the real-time data server 1 re-starts to acquire data from the real-time database query, re-registers the registration notification, and re-starts refreshing the data. But the picture data area is not required to be re-established, so that the process time for establishing the data area is saved, and the efficiency is improved. And when the picture data area buffer queue reaches the preset condition, the index area and the data area of the picture data area buffer queue completely release resources. The index area and the data area are deleted synchronously. If the picture is built again corresponding to the client, a picture index area and a picture data area are newly built as in the first time of building the link.
(9) The real-time data read-write operation interface function realizes 2 sets, one set of shared memory mode, and one set of message mechanism adopting function name as key word realizes interface mode. In fig. 4, the interaction between the real-time data server 1 … n and the real-time database (which may also include the original real-time image, the original alarm interface, the original real-time curve, etc.) adopts the existing shared memory function interface mode, while the interaction between the remote clients and the real-time data server 1 … n adopts the message mechanism read-write behavior interface mode.
The real-time data server 1 … n internally sets a function dictionary table to index and accurately match two sets of interface functions, establishes two sets of mode interface functions to be in one-to-one correspondence bridging association relationship, and is similar to Remote Procedure Call (RPC) in operation. The various types of client code thus need not be changed. By replacing the 2-socket interface function, the local binding or remote separation working mode with the real-time library can be realized. This minimizes various client code changes, smoothing compatible upgrades, as shown in FIG. 6.
The control method of the high-capacity decoupling flexible master station system provided by the invention has the following effects:
(1) The master station system generally comprises interface display tools such as a real-time picture, a real-time curve, a real-time alarm and the like, and generally realizes data interaction with a real-time database in a shared memory mode, and has a strong coupling binding relationship with the real-time database. Decoupling of these modules from the real-time database is achieved in the present design by a dynamic real-time data server.
(2) And setting a real-time data server as a data interaction medium, and adopting a TCP soft bus to support interaction between a plurality of real-time clients, so that various clients can be distributed and deployed, and extension deployment is realized. A black list and a white list may be provided.
(3) Based on the template class-object and micro-service idea real-time data server mode, if only one real-time data server app is adopted, the one-to-many small-capacity real-time data server mode can be regarded as a special case, and has compatibility and flexibility of data interaction of various clients, but has strong module and capacity expansion capability.
(4) Based on the template class-object and micro-service idea real-time data server mode, if a plurality of real-time data servers are adopted, the excellent real-time performance and high-capacity data concurrent processing can be compared with the point-to-point professional real-time data server mode. Compared with the mode that each professional real-time data server needs to be realized, the mode code has the advantages of less code development quantity, simple maintenance work, no programming and compiling, dynamic expansion of the architecture at any time and any place, and hot plug function.
(5) When the real-time data server runs, a script can be run on related data points according to the configuration information, the real-time data can be reprocessed and stored or pushed and forwarded to other clients, the real-time running requirement of the clients is reduced, and the performance configuration of the client computer is reduced.
(6) The invention uses picture page as unit to build TCP soft bus to build link and close link, the real-time data server uses link id, picture object, client ip to build picture index area and picture data area. And 2, establishing a two-way association relation. Therefore, the real-time online data points of each picture are not more, more real-time clients can be supported, and the design is ingenious, simple and efficient. Other client principles can consult the picture to set virtual objects as appropriate.
(7) The real-time data server end adopts an index area and a data area to be arranged separately. The index area is synchronously updated according to different client links, and the picture index area and the data area 2 synchronously implement a caching strategy. The picture inquiry adopts double combination of hash and linked list, and the double list is synchronous, so that the aim of quickly hitting the data area to access the object is fulfilled, meanwhile, the first-in first-out is fulfilled, the latest object is moved to the tail of the queue, the invalid data area object is firstly removed and released from the head of the queue, the design thought of the latest data area object is reserved, and the rapidity and the latest use novelty of the data area object are improved. The picture index area and the data area are synchronously cached, maintained and deleted.
(8) The real-time data server 1 classifies the picture data points, including query (one query/multiple queries) and change notification class 2. The query is a timed query and forwarded. The change notification point objected starts a registration notification mode and establishes association relations of a plurality of corresponding picture index areas and data areas for forwarding. The hash table of the same object point in the same picture is unique at the end of the real-time data server 1 and is used for quickly indexing or accessing the data information of the same object point.
(9) The micro-service architecture principle simplifies the design of a real-time library and realizes load balancing. Because the clients do not share the memory to bind the real-time databases, the number of the real-time databases is greatly reduced, and only one main real-time database and one standby real-time database can be set, so that the synchronization is simple, and the complexity of the synchronous design and implementation of the real-time databases is greatly reduced. Meanwhile, different real-time databases can be correspondingly distributed according to information such as the number of clients, data traffic and the like by load balancing deployment of real-time data server app instances.
(10) The real-time data read-write operation interface function realizes 2 sets, one set of existing shared memory mode, and one set of message mechanism with function name as key word. The real-time data server sets a function dictionary table to index and accurately match two sets of socket functions, establishes a one-to-one corresponding bridging association relationship between the two parties, and is similar to remote procedure call during operation. The various types of client code thus need not be changed. By replacing the 2-socket interface function, the local binding or remote separation working mode with the real-time library can be realized. Therefore, the code changes of various clients can be reduced as much as possible, and the upgrade is smooth and compatible.
The foregoing is merely a preferred embodiment of the present invention, and it should be noted that modifications and variations could be made by those skilled in the art without departing from the technical principles of the present invention, and such modifications and variations should also be regarded as being within the scope of the invention.

Claims (10)

1. A high capacity decoupling flexible primary station system, comprising: the DCS master station system real-time database, a plurality of real-time data servers and a plurality of real-time clients; the real-time clients are respectively connected with the real-time data servers in a one-to-one correspondence manner by adopting a TCP soft bus manner, and the real-time data servers are connected with a DCS master station system real-time database by adopting a shared memory function interface manner, wherein the real-time clients comprise any one or more of a real-time picture client, an alarm client and a real-time curve client;
the real-time client is connected with the real-time data server in a read-write behavior interface mode established based on a message mechanism;
the DCS master station system real-time database comprises a main database and a standby database which are synchronously arranged;
the plurality of real-time clients also comprise a read-write mode of a shared memory and are connected with a real-time database of the DCS master station system;
the real-time data server includes:
the tcp link establishment module is used for receiving an establishment link signal sent by the first real-time client side by taking any picture as a unit and establishing a tcp link with the real-time client side by taking the picture;
the system comprises a multi-dimensional index zone linked list establishing module, a server-client side picture processing module and a multi-dimensional index zone linked list processing module, wherein the multi-dimensional index zone linked list establishing module is used for establishing a server-client side picture new thread, acquiring initialization information and real-time data information of a picture to establish a multi-dimensional index zone linked list, and the multi-dimensional index zone linked list comprises a picture index zone and a picture data zone which are respectively used for storing picture objects and picture data information points;
the retrieval module is used for receiving the real-time data information of any picture sent by the second real-time client, retrieving whether the picture index mark exists in the picture index area, if not, establishing the picture data area and the picture index area of the picture, if so, sharing the picture data area and synchronously updating the picture index area;
the inquiring and judging module is used for inquiring/dynamically registering and notifying a data point objected set in the picture communication link thread to the DCS master station system real-time database; if new data is acquired from a DCS master station system real-time database, judging whether a configuration script exists in the objected point, if so, locking and writing the configuration script into a picture data area after the script runs data for reprocessing; and pushing the registration data points to all real-time clients establishing tcp links in the picture index area.
2. A control method of a high capacity decoupling flexible master station system according to claim 1, applied to a real-time data server, comprising:
receiving a link establishment signal sent by a first real-time client side by taking any picture as a unit, and establishing a tcp link with the real-time client side by taking the picture;
establishing a server-client picture new thread, acquiring initialization information and real-time data information of the picture to establish a multi-dimensional index zone linked list, wherein the multi-dimensional index zone linked list comprises a picture index zone and a picture data zone which are respectively used for storing picture objects and picture data information points;
receiving real-time data information of any picture sent by a second real-time client, searching whether the picture index mark exists in a picture index area, if not, establishing a picture data area and a picture index area of the picture, and if so, sharing the picture data area and synchronously updating the picture index area;
inquiring/dynamically registering and notifying a data point objected set in the picture communication link thread to a DCS master station system real-time database; if new data is acquired from a DCS master station system real-time database, judging whether a configuration script exists in the objected point, if so, locking and writing the configuration script into a picture data area after the script runs data for reprocessing; and pushing the registration data points to all real-time clients establishing tcp links in the picture index area.
3. The method for controlling a high-capacity decoupling flexible master station system according to claim 2, wherein when the real-time data server establishes a link signal with the real-time client, the method further comprises:
and acquiring initialization information sent by the client, judging whether the initialization information is in a pre-established white list, and if so, establishing a tcp link with the real-time client by using the picture.
4. The control method of a high-capacity decoupling flexible master station system according to claim 2, wherein the initialization information includes ip address information of a real-time client; the real-time data information includes the picture object and picture data information points, wherein the picture object or the virtual picture object is set up as an index flag.
5. The control method of a high capacity decoupling flexible master station system according to claim 2, wherein whenever the real time client switches pictures or closes pictures, a tcp link established with a real time data server is closed, if the tcp link of the picture is closed but the number of links is still greater than 0, index area information is updated synchronously, and the picture data area is not deleted; if all tcp links of the picture are closed, the relevant information of the picture index area is released, and the picture data area is still in a cache state and is not deleted immediately.
6. The control method of the high-capacity decoupling flexible master station system as claimed in claim 2, wherein the real-time data server performs the search and query of the picture by using two modes of a hash table and a list table, and the double tables are synchronously maintained and updated,
by adopting a hash table query mode, the index region result can be immediately queried through retrieving the picture object;
the list table inquiring mode is adopted, the list table is provided with an object address pointer of a picture object data area, first-in first-out is adopted, the last use is to place the tail of the queue, if the object exists in the list, the current object is removed from the original position in the list and added to the tail of the list queue, and when the picture quantity reaches the set cache quantity, the corresponding index area is detected from the direction of the head of the queue and no effective information is deleted.
7. The control method of the high-capacity decoupling flexible master station system according to claim 2, wherein after the real-time data server establishes a link with the real-time client, classifying the picture data points, including two types of inquiry and change notification, wherein the inquiry is one inquiry or multiple inquiries, and the inquiry is timing inquiry and forwarding; the change notification point objected starts a registration notification mode and establishes association relations of a plurality of corresponding picture index areas and data areas for forwarding.
8. The control method of the high-capacity decoupling flexible master station system according to claim 2, wherein the real-time client writes in the real-time database of the DCS master station system by remote control or manual setting to the real-time database, judges whether to update the data area according to the returned result, and forwards and pushes the corresponding information to other real-time clients.
9. The control method of a high capacity decoupling flexible master station system according to claim 2, wherein when a real time client closes a tcp link established with a real time data server, the real time data server immediately releases a thread corresponding to the picture communication link from a picture index area maintenance list and removes the client information; when the tcp link number of the picture index area corresponding to different clients is 0, the real-time data server stops inquiring and acquiring data from a DCS master station system real-time database, the registered registration notification point cancels the registration notification, and the picture data is not refreshed any more by the real-time data server; after the re-linking of the corresponding tcp link of the picture is successful, the real-time data server re-starts to inquire and acquire data from the real-time database of the DCS master station system again, re-registers the registration notification, re-starts and refreshes the data, and selects whether to re-establish the picture data area according to whether the cache queue of the picture data area reaches a preset condition or not.
10. The control method of the high-capacity decoupling flexible master station system according to claim 2, wherein two sets of interface functions are adopted among the real-time database of the DCS master station system, the plurality of real-time data servers and the plurality of real-time clients to realize real-time data read-write type operation, the two sets of interface functions comprise a shared memory function interface mode and a message mechanism read-write behavior type interface mode, a function dictionary table is arranged in the real-time data servers to index and accurately match the two sets of interface functions, and two sets of mode interface functions are established to be in one-to-one correspondence bridging association relation.
CN202210820341.8A 2022-07-13 2022-07-13 High-capacity decoupling flexible master station system and control method Active CN115203204B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210820341.8A CN115203204B (en) 2022-07-13 2022-07-13 High-capacity decoupling flexible master station system and control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210820341.8A CN115203204B (en) 2022-07-13 2022-07-13 High-capacity decoupling flexible master station system and control method

Publications (2)

Publication Number Publication Date
CN115203204A CN115203204A (en) 2022-10-18
CN115203204B true CN115203204B (en) 2023-07-04

Family

ID=83580877

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210820341.8A Active CN115203204B (en) 2022-07-13 2022-07-13 High-capacity decoupling flexible master station system and control method

Country Status (1)

Country Link
CN (1) CN115203204B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102117309A (en) * 2010-01-06 2011-07-06 卓望数码技术(深圳)有限公司 Data caching system and data query method
EP3043447A1 (en) * 2015-01-06 2016-07-13 Accenture Global Services Limited Distribution transformer heavy loading and overloading mid-term and short-term pre-warning analytics model

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102420814A (en) * 2011-11-21 2012-04-18 航天科工深圳(集团)有限公司 Data access method and device, and server
FI20125700A (en) * 2012-06-21 2013-12-22 Tekla Corp Shared data with relationship information
US9928277B2 (en) * 2014-11-10 2018-03-27 International Business Machines Corporation Materialized query tables with shared data
CN108804579B (en) * 2018-05-24 2021-04-30 北京奇艺世纪科技有限公司 Application service system and data consistency control method
CN113497489A (en) * 2020-04-01 2021-10-12 南京南瑞继保电气有限公司 Provincial power distribution main station system meeting provincial and local integrated operation and maintenance requirements
CN113878212B (en) * 2021-09-30 2023-05-05 天津七所高科技有限公司 System and method for collecting data of electric resistance welding controller equipment based on MQTT framework

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102117309A (en) * 2010-01-06 2011-07-06 卓望数码技术(深圳)有限公司 Data caching system and data query method
EP3043447A1 (en) * 2015-01-06 2016-07-13 Accenture Global Services Limited Distribution transformer heavy loading and overloading mid-term and short-term pre-warning analytics model

Also Published As

Publication number Publication date
CN115203204A (en) 2022-10-18

Similar Documents

Publication Publication Date Title
US8224860B2 (en) Database management system
US8401994B2 (en) Distributed consistent grid of in-memory database caches
CN101568919B (en) Single view of data in a networked computer system with distributed storage
KR100592647B1 (en) System and method for a caching mechanism for a central synchronization server
US7115919B2 (en) Storage system for content distribution
US10831612B2 (en) Primary node-standby node data transmission method, control node, and database system
US6941327B2 (en) Apparatus and method for database synchronization in a duplex system
CN111177161B (en) Data processing method, device, computing equipment and storage medium
US20020198883A1 (en) Web system having clustered application servers and clustered databases
CN105512266A (en) Method and device for achieving operational consistency of distributed database
CN109344122B (en) Distributed metadata management method and system based on file pre-creation strategy
US20220035786A1 (en) Distributed database management system with dynamically split b-tree indexes
CN111597160A (en) Distributed database system, distributed data processing method and device
US6804710B1 (en) Configuration information management system, method, program, and program storage device
CN105407044A (en) Method for implementing cloud storage gateway system based on network file system (NFS)
CN113703917B (en) Multi-cluster resource data processing system and method and non-transient storage medium
CN115203204B (en) High-capacity decoupling flexible master station system and control method
CN113190523B (en) Distributed file system, method and client based on multi-client cooperation
CN114385577A (en) Distributed file system
CN112988879B (en) Method, system, device, storage medium and processor for accessing database
CN111400110A (en) Database access management system
CN112966047B (en) Method for realizing table copying function based on distributed database
CN115297130B (en) Distributed storage network data synchronization method based on block chain
CN116450718A (en) Trigger type management system based on double control equipment
KR19990080408A (en) External main memory database management system of mobile communication exchange

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Li Dejun

Inventor after: Chen Mingen

Inventor after: Ji Wei

Inventor after: Zhang Zhengmin

Inventor after: Shi Guangde

Inventor after: Li Junda

Inventor after: Zhan Feng

Inventor before: Chen Mingen

Inventor before: Ji Wei

Inventor before: Zhang Zhengmin

Inventor before: Shi Guangde

Inventor before: Li Junda

Inventor before: Li Dejun

Inventor before: Zhan Feng

GR01 Patent grant
GR01 Patent grant