Data access method and device for PACS image storage system
The data access method for PACS image storage systems addresses performance and availability issues by using a management server to manage node lists based on heartbeat messages and secure TCP connections, ensuring high-performance and fault-tolerant data access.
Patent Information
- Application Number
- CN202110279356.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-03-16
- Publication Date
- 2024-12-27
- Estimated Expiration
- 2041-03-16
AI Technical Summary
PACS image storage systems face performance pressure during peak hours due to concurrent access from hundreds of workstations, necessitating improved data access methods to ensure high availability and fault tolerance.
A data access method involving a management server that maintains a list of available storage nodes based on heartbeat messages, selects nodes for access requests, and uses TCP connections secured with dynamic MD5 authentication to distribute requests across available nodes, ensuring high-performance and fault-tolerant data access.
This approach ensures high-performance and fault-tolerant access to PACS image data, maintaining data reading and writing performance and system availability by dynamically managing node availability and securing connections.
Smart Images

Figure CN112951385B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computers, and in particular to a data access method and device for a PACS image storage system. Background Art
[0002] Medical imaging is an important support for modern medicine. The diagnostic image files generated by radiological medical equipment and cardiovascular imaging equipment are written to network storage devices for use by radiologists and doctors for diagnosis and analysis. The size of PACS (Picture Archiving and Communication Systems) image files is usually several hundred KB to several MB, and one examination generates thousands of images. As the resolution of medical imaging diagnostic equipment continues to improve, the amount of PACS image data is growing rapidly. PACS image storage systems are usually composed of multiple storage nodes to achieve the purpose of expanding capacity and fault tolerance.
[0003] When making a diagnosis, doctors need to read files from PACS image storage devices and then display them on workstations. During peak hours, hundreds of workstations will read data from image storage devices concurrently, which puts a lot of performance pressure on the storage devices. Summary of the invention
[0004] An object of the present invention is to provide a data access method and device for a PACS image storage system.
[0005] According to one aspect of the present invention, a data access method for a PACS image storage system is provided, the method comprising:
[0006] Each storage node periodically sends a heartbeat message to the management server, wherein each storage node is used to store PACS image data;
[0007] The management server adds the storage node to the list of currently available storage nodes, or deletes the storage node from the list of currently available storage nodes based on the heartbeat message of each storage node;
[0008] The client sends a storage node access request to the management server;
[0009] The management server selects a currently available storage node from the list of currently available storage nodes in turn based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client;
[0010] The client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established.
[0011] Furthermore, in the above method, the management server adds the storage node to the list of currently available storage nodes based on the heartbeat message of each storage node, including:
[0012] Step S211, the management server records the heartbeat messages received from each storage node into the historical message queue corresponding to each storage node, each heartbeat message includes: the storage node number and the heartbeat time, wherein the historical message queue only records M heartbeat messages received recently from each storage node, where M is a positive integer;
[0013] Step S212: The management server determines whether each storage node belongs to the list of currently available storage nodes.
[0014] Step S213: if all storage nodes belong to the list of currently available storage nodes, return to step S211;
[0015] Step S214: If there is a storage node that belongs to the list of all storage nodes and does not belong to the list of the currently available storage nodes, the management server determines whether N heartbeat messages with consecutive recent heartbeat times sent by the storage node are received based on the historical message queue corresponding to the storage node, where M is greater than or equal to N, and the currently available storage node is selected from the list of all storage nodes;
[0016] Step S215, if the storage server receives N heartbeat messages with consecutive recent heartbeat times sent by the storage node, the storage node is added to the end of the list Lon of currently available storage nodes, and then the process returns to step S211;
[0017] Step S216: If the storage server does not receive N consecutive heartbeat messages sent by the storage node in the recent heartbeat time, return to step S211.
[0018] Furthermore, in the above method, the management server deletes the storage node from the list of currently available storage nodes based on the heartbeat message of each storage node, including:
[0019] Step S221, the management server periodically determines whether it has received N heartbeat messages with recent consecutive heartbeat times sent by each storage node in the list of currently available storage nodes based on the historical message queues corresponding to each storage node, where M is greater than or equal to N and N is a positive integer;
[0020] Step S222: if the management server receives N heartbeat messages with consecutive recent heartbeat times sent by all storage nodes in the list of currently available storage nodes, then the process returns to step S221;
[0021] Step S223, if the management server has not received N consecutive heartbeat messages sent by one or more storage nodes in the list of currently available storage nodes, it is determined whether the number of heartbeat messages received from the one or more storage nodes respectively within a preset recent time period T is greater than K, where K is a positive integer;
[0022] Step S224: if the number of heartbeat messages received by the management server from the one or more storage nodes within the preset recent time period T is greater than K, then return to step S221;
[0023] Step S225, if the number of heartbeat messages received by the management server from the one or more storage nodes in the preset recent time period T is less than or equal to K, then the one or more storage nodes are deleted from the list Lon of currently available storage nodes, and the process returns to step S221.
[0024] Furthermore, in the above method, the client sends an access request for a storage node to the management server, including:
[0025] The service workstation sends an access request of the storage node to the management server.
[0026] Further, in the above method, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client, including:
[0027] Based on the access request of the service workstation, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the service workstation.
[0028] Furthermore, in the above method, the client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established, including:
[0029] The business workstation establishes a TCP connection with the corresponding FTP server based on the received IP address;
[0030] The service workstation sends the user name of the service workstation to the FTP server through the established TCP connection;
[0031] After receiving the user name of the service workstation, the FTP server sends a unique character string that changes randomly over time to the service workstation;
[0032] The service workstation appends a preset password corresponding to the user name of the service workstation after the unique character string that changes randomly over time to obtain a first append result, performs MD5 calculation on the first append result to obtain a first MD5 character string, and sends the first MD5 character string to the FTP server;
[0033] The FTP server appends the password corresponding to the preset user name of the service workstation after the unique character string that changes randomly over time to obtain a second appended result, and performs MD5 calculation on the second appended result to obtain a second MD5 character string;
[0034] The FTP server compares the received MD5 first string with the calculated MD5 second string,
[0035] If the comparison result is consistent, the FTP server maintains the TCP connection to allow the service workstation to read the PACS image data from the corresponding currently available storage node through the FTP server;
[0036] If the comparison result is inconsistent, the FTP server closes the TCP connection.
[0037] Furthermore, in the above method, the client sends an access request for a storage node to the management server, including:
[0038] The examination equipment sends the PACS image data to the DICOM gateway via the DICOM protocol and the network;
[0039] The DICOM gateway sends an access request of a storage node to the management server.
[0040] Further, in the above method, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client, including:
[0041] Based on the access request of the DICOM gateway, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the DICOM gateway.
[0042] Furthermore, in the above method, the client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established, including:
[0043] The DICOM gateway establishes a TCP connection with the corresponding FTP server based on the received IP address;
[0044] The DICOM gateway sends the user name of the DICOM gateway to the FTP server through the established TCP connection;
[0045] After receiving the user name of the DICOM gateway, the FTP server sends a unique character string that changes randomly over time to the DICOM gateway;
[0046] The DICOM gateway appends a password corresponding to a preset user name of the DICOM gateway after the unique character string that changes randomly over time to obtain a third append result, performs MD5 calculation on the third append result to obtain a third character string of MD5, and sends the third character string of MD5 to the FTP server;
[0047] The FTP server appends the password corresponding to the preset user name of the DICOM gateway after the unique character string that changes randomly over time to obtain a fourth appended result, and performs MD5 calculation on the fourth appended result to obtain a fourth character string of MD5;
[0048] The FTP server compares the received MD5 third character string with the calculated MD5 fourth character string,
[0049] If the comparison result is consistent, the FTP server maintains the TCP connection to allow the DICOM gateway to write PACS image data to the corresponding currently available storage node through the FTP server;
[0050] If the comparison result is inconsistent, the FTP server closes the TCP connection.
[0051] According to another aspect of the present invention, a computer-readable medium is further provided, on which computer-readable instructions are stored. The computer-readable instructions can be executed by a processor to implement any of the above methods.
[0052] Compared with the prior art, the present invention determines a list of currently available storage nodes based on the heartbeat messages of each storage node through a management server. The management server selects currently available storage nodes from the list in turn based on the access request of the PACS image data, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the business workstation, so that PACS requests from different business workstations can be assigned to different currently available storage nodes, and when some storage nodes fail, other available storage nodes can still provide data access services; the business workstation establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the currently available storage node through the business workstation and the FTP server with which the TCP connection is established, thereby achieving high-performance and fault-tolerant access to PACS image data and ensuring data reading and writing performance and high availability of the business system. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Other features, objects and advantages of the present invention will become more apparent from the detailed description of non-limiting embodiments made with reference to the following drawings:
[0054] Figure 1 A network topology diagram of a medical PACS image data storage system according to an embodiment of the present application is shown;
[0055] Figure 2 A flowchart showing the heartbeat message processing of an embodiment of the present application is shown;
[0056] Figure 3 A flowchart of periodic checking of a management server according to an embodiment of the present application is shown.
[0057] The same or similar reference numerals in the drawings represent the same or similar components. DETAILED DESCRIPTION
[0058] The present invention is further described in detail below in conjunction with the accompanying drawings.
[0059] In a typical configuration of the present application, the terminal, the device of the service network and the trusted party all include one or more processors (CPU), input / output interfaces, network interfaces and memories.
[0060] The memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0061] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include non-transitory media such as modulated data signals and carrier waves.
[0062] The present invention provides a data access method for a PACS image storage system, the method comprising:
[0063] Step S1, each storage node periodically sends a heartbeat message to the management server, wherein each storage node is used to store PACS image data;
[0064] Here, the storage node sends heartbeat information to the management server periodically, and the typical period can be 1 second;
[0065] The PACS image storage system of the present invention comprises: a client, a management server, a plurality of storage nodes and an FTP server corresponding to the storage nodes;
[0066] like Figure 1 As shown, the client may include: a business workstation and an inspection device;
[0067] The inspection equipment may include: CT, MRI, ultrasound and other inspection equipment;
[0068] The business workstations may include: a radiologist workstation, an outpatient physician workstation, and an inpatient physician workstation;
[0069] The storage nodes may include: storage node 1, storage node 2, ..., storage node N;
[0070] Among them, each storage node is equipped with an FTP server;
[0071] Step S2, the management server adds the storage node to the list Lon of currently available storage nodes, or deletes the storage node from the list of currently available storage nodes based on the heartbeat message of each storage node;
[0072] Here, each storage node periodically sends heartbeat information to the management server service. The management server determines whether each storage node is in a normal working state based on the historical heartbeat information of the storage node, and organizes the normal storage nodes into a list set of currently available nodes;
[0073] When a storage node fails and cannot send heartbeat information to the management server, the management server will delete the failed storage node from the list of currently available nodes after a certain period of time.
[0074] Step S3, the client sends an access request for the storage node to the management server;
[0075] Step S4, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client;
[0076] Here, the access request may be, for example, a read or write request for PACS image data of each storage node;
[0077] Before the client accesses the corresponding storage node through the FTP server, it first sends a storage node access request to the management server. After receiving the request, the management server uses the polling method to select a currently available storage node from the list of currently available nodes in turn, and uses the IP address of the FTP server corresponding to the currently available node as a response, so that the access requests from different clients can be assigned to different currently available storage nodes;
[0078] For example, if the currently available storage node selected by the management server in the last poll is storage node 1, then the currently available storage node selected by the management server in the next poll is the next storage node 2 in the list of currently available storage nodes;
[0079] Step S5: the client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established.
[0080] Here, the present invention determines a list of currently available storage nodes based on the heartbeat messages of each storage node through a management server. The management server selects currently available storage nodes from the list in turn based on the access request of the PACS image data, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the business workstation, so that PACS requests from different business workstations can be assigned to different currently available storage nodes, and when some storage nodes fail, other available storage nodes can still provide data access services; the business workstation establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the currently available storage node through the business workstation and the FTP server with which the TCP connection is established, thereby achieving high-performance and fault-tolerant access to PACS image data and ensuring data reading and writing performance and high availability of the business system.
[0081] like Figure 2 As shown, in an embodiment of the data access method for a PACS image storage system of the present invention, step S2, the management server adds the storage node to the list of currently available storage nodes based on the heartbeat message of each storage node, including:
[0082] Step S211, the management server records the heartbeat messages received from each storage node into the historical message queue corresponding to each storage node, each heartbeat message includes the storage node number and the heartbeat time, wherein the historical message queue only records M heartbeat messages received recently from each storage node, where M is a positive integer;
[0083] Here, the management server always records only the M heartbeat messages sent by each storage node recently received. When the historical message queue exceeds M heartbeat messages, the new heartbeat message will overwrite the heartbeat message with the oldest heartbeat time among the M heartbeat messages, so as to ensure that only the useful M heartbeat messages of the recent time are stored in the historical message queue, saving data storage space;
[0084] For example, the storage node should periodically send heartbeat messages to the management server at an interval of 1 second. The management server can record the M (5) heartbeat messages received from storage node 1 in sequence as follows:
[0085] Storage node 1, heartbeat time: 9:01;
[0086] Storage node 1, heartbeat time: 9:02;
[0087] Storage node 1, heartbeat time: 9:03;
[0088] Storage node 1, heartbeat time: 9:06;
[0089] Storage node 1, heartbeat time: 9:18;
[0090] It can be seen that: heartbeat time: 9:01, heartbeat time: 9:02 and heartbeat time: 9:03 are continuous; heartbeat time: 9:03 and heartbeat time: 9:06 are not continuous; heartbeat time: 9:06 and heartbeat time: 9:18 are also not continuous.
[0091] For example, storage node 2 should periodically send heartbeat messages to the management server at an interval of 1 second. The management server can record the M (5) heartbeat messages received from storage node 2 in sequence as follows:
[0092] Storage node 2, heartbeat time: 14:18;
[0093] Storage node 2, heartbeat time: 14:19;
[0094] Storage node 2, heartbeat time: 14:23;
[0095] Storage node 2, heartbeat time: 14:24;
[0096] Storage node 2, heartbeat time: 14:25;
[0097] It can be seen here that heartbeat time: 14:19 and heartbeat time: 14:23 are not continuous; heartbeat time: 14:18 and heartbeat time: 14:19 are continuous; heartbeat time: 14:23, heartbeat time: 14:23 and heartbeat time: 14:24 are also continuous;
[0098] Step S212: The management server determines whether each storage node belongs to the list of currently available storage nodes.
[0099] Step S213: if all storage nodes belong to the list of currently available storage nodes, return to step S211;
[0100] Step S214: If there is a storage node that belongs to the list L of all storage nodes all and does not belong to the list of currently available storage nodes, the management server determines whether N heartbeat messages with consecutive recent heartbeat times sent by the storage node are received based on the historical message queue corresponding to the storage node, where M is greater than or equal to N, and the currently available storage node is selected from the list of all storage nodes;
[0101] Here, the management server maintains two lists: a list of all storage nodes and a list of currently available storage nodes; wherein the list of all storage nodes is not empty, and the list of currently available storage nodes may be empty or may include all or part of the storage nodes in the list of all storage nodes;
[0102] Step S215, if the storage server receives N heartbeat messages with consecutive recent heartbeat times sent by the storage node, the storage node is added to the end of the list Lon of currently available storage nodes, and then the process returns to step S211;
[0103] Step S216: If the storage server does not receive N consecutive heartbeat messages sent by the storage node in the recent heartbeat time, return to step S211.
[0104] For example, storage node 2 belongs to the list of all storage nodes and does not belong to the list of currently available storage nodes, N is 3, M is 5, and the storage node periodically sends heartbeat messages to the management server at an interval of 1 second. The management server can record the M (5) heartbeat messages received from storage node 1 in sequence as follows:
[0105] Storage node 2, heartbeat time: 14:18;
[0106] Storage node 2, heartbeat time: 14:19;
[0107] Storage node 2, heartbeat time: 14:23;
[0108] Storage node 2, heartbeat time: 14:24;
[0109] Storage node 2, heartbeat time: 14:25;
[0110] Then, storage node 2, heartbeat time: 14:23, heartbeat time: 14:24, heartbeat time: 14:25 (continuous heartbeat time), indicates that the storage server has received N=3 heartbeat messages with continuous recent heartbeat time sent by the storage node, and then adds the storage node to the tail of the list Lon of currently available storage nodes.
[0111] like Figure 3 As shown, in an embodiment of the data access method for a PACS image storage system of the present invention, step S2, the management server deletes the storage node from the list of currently available storage nodes based on the heartbeat message of each storage node, including:
[0112] Step S221, the management server periodically determines whether it has received N heartbeat messages with recent consecutive heartbeat times sent by each storage node in the list of currently available storage nodes based on the historical message queues corresponding to each storage node, where M is greater than or equal to N and N is a positive integer;
[0113] Here, the management server may check the historical heartbeat record of each storage node in the list of currently available storage nodes at a period of 1 second;
[0114] Step S222: if the management server receives N heartbeat messages with consecutive recent heartbeat times sent by all storage nodes in the list of currently available storage nodes, then the process returns to step S221;
[0115] Step S223, if the management server has not received N consecutive heartbeat messages sent by one or more storage nodes in the list of currently available storage nodes, it is determined whether the number of heartbeat messages received from the one or more storage nodes respectively within a preset recent time period T is greater than K, where K is a positive integer;
[0116] Here, K may be a positive integer less than or equal to N;
[0117] Step S224: if the number of heartbeat messages received by the management server from the one or more storage nodes within the preset recent time period T is greater than K, then return to step S221;
[0118] Step S225, if the number of heartbeat messages received by the management server from the one or more storage nodes in the preset recent time period T is less than or equal to K, then the one or more storage nodes are deleted from the list Lon of currently available storage nodes, and the process returns to step S221.
[0119] For example, storage node 1 belongs to the list of all storage nodes and to the list of currently available storage nodes, N is 3, M is 5, T is 6 seconds, and K is 3; the storage node should periodically send heartbeat messages to the management server at an interval of 1 second, and the management server can record the M (5) heartbeat messages received from storage node 1 in sequence as follows:
[0120] Storage node 1, heartbeat time: 9:01;
[0121] Storage node 1, heartbeat time: 9:02;
[0122] Storage node 1, heartbeat time: 9:03;
[0123] Storage node 1, heartbeat time: 9:06;
[0124] Storage node 1, heartbeat time: 9:18;
[0125] It can be seen that: heartbeat time: 9:01, heartbeat time: 9:02 and heartbeat time: 9:03 are continuous; heartbeat time: 9:03 and heartbeat time: 9:06 are not continuous; heartbeat time: 9:06 and heartbeat time: 9:18 are also not continuous.
[0126] Since the heartbeat time: 9:03 and the heartbeat time: 9:06 are not continuous; the heartbeat time: 9:06 and the heartbeat time: 9:18 are also not continuous, so the heartbeat time of the recent N=3 heartbeat messages is not continuous, so the management server has not received the recent heartbeat time continuous N=3 heartbeat messages sent by one or more storage nodes in the list of currently available storage nodes; and within the preset recent time period T=6 seconds, only 1 heartbeat message was received at a heartbeat time of 9:18, so the number of heartbeat messages received by the management server from the one or more storage nodes is 1, and the number of heartbeat messages is less than or equal to K=3, then the storage node 1 is deleted from the list of currently available storage nodes Lon.
[0127] In this embodiment, when a storage node fails and cannot send heartbeat information to the management server, after a certain period of time, the management server may delete the node from the set of available nodes, and the client will no longer access the storage node.
[0128] In addition, when the failed storage node returns to normal, the storage node sends a heartbeat message to the management server, and the management server can re-add the storage node to the list of currently available storage nodes.
[0129] In an embodiment of the data access method for a PACS image storage system of the present invention, step S3, the client sends an access request for a storage node to the management server, including:
[0130] The service workstation sends an access request of the storage node to the management server;
[0131] Step S4, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client, including:
[0132] The management server selects a currently available storage node from the list of currently available storage nodes in turn based on the access request of the business workstation, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the business workstation;
[0133] Step S5, the client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established, including:
[0134] Step S511, the service workstation establishes a TCP connection with the corresponding FTP server based on the received IP address;
[0135] Step S512, the service workstation sends the user name of the service workstation to the FTP server through the established TCP connection;
[0136] Here, the user name of the service workstation may be, for example: "USER xxx";
[0137] Step S513, after receiving the user name of the service workstation, the FTP server sends a unique character string that changes randomly over time to the service workstation;
[0138] Here, the unique character string that changes randomly over time may be, for example: "331compute md5yyy", and the length of the unique character string that changes randomly over time may be 8 to 128 bytes;
[0139] Step S514, the service workstation appends a preset password corresponding to the user name of the service workstation after the unique character string that changes randomly over time to obtain a first append result, performs MD5 calculation on the first append result to obtain a first MD5 character string, and sends the first MD5 character string to the FTP server;
[0140] Here, the service workstation adds the "password" corresponding to the user name xxx of the service workstation after the character string "yyy", performs MD5 calculation, and sends the MD5 character string to the FTP server;
[0141] Step S515, the FTP server appends the password corresponding to the preset user name of the service workstation after the unique character string that changes randomly over time to obtain a second appended result, and performs MD5 calculation on the second appended result to obtain a second MD5 character string;
[0142] Step S516: the FTP server compares the received first MD5 string with the calculated second MD5 string.
[0143] Step S517, if the comparison result is consistent, the FTP server maintains the TCP connection to allow the business workstation to read the PACS image data from the corresponding currently available storage node through the FTP server;
[0144] Step S518: If the comparison result is inconsistent, the FTP server closes the TCP connection.
[0145] Here, the FTP server can perform the same calculation based on the locally configured user name and password. If the calculated second MD5 string is the same as the first MD5 string sent by the business workstation, the TCP connection is maintained and a "230Logged on" message can be sent to the business workstation. Subsequently, the business workstation can use standard FTP commands to read the PACS image data of the corresponding currently available storage node through the FTP server; otherwise, the TCP connection is closed and a "530Login Authentication Error" can be sent to the business workstation.
[0146] The improved FTP protocol of this embodiment is used to read and write data between the service workstation and the storage node, which can prevent the password from being transmitted in plain text over the network.
[0147] like Figure 1 As shown, in an embodiment of the data access method for a PACS image storage system of the present invention, step S3, the client sends an access request for a storage node to the management server, including:
[0148] Step S31, the inspection device sends the PACS image data to the DICOM gateway via the DICOM protocol and the network;
[0149] Step S32, the DICOM gateway sends an access request of the storage node to the management server;
[0150] Step S4, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client, including:
[0151] The management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the DICOM gateway, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the DICOM gateway;
[0152] Step S5, the client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established, including:
[0153] Step S521, the DICOM gateway establishes a TCP connection with the corresponding FTP server based on the received IP address;
[0154] Step S522, the DICOM gateway sends the user name of the DICOM gateway to the FTP server through the established TCP connection;
[0155] Here, the user name of the DICOM gateway may be, for example: "USER xxx";
[0156] Step S523, after receiving the user name of the DICOM gateway, the FTP server sends a unique character string that changes randomly over time to the DICOM gateway;
[0157] Here, the unique character string that changes randomly over time may be, for example: "331compute md5yyy", and the length of the unique character string that changes randomly over time may be 8 to 128 bytes;
[0158] Step S524, the DICOM gateway appends the password corresponding to the preset DICOM gateway user name after the unique character string that changes randomly over time to obtain a third append result, performs MD5 calculation on the third append result to obtain a third MD5 character string, and sends the third MD5 character string to the FTP server;
[0159] Here, the DICOM gateway appends the "password" corresponding to the DICOM gateway user name xxx after the character string "yyy", performs MD5 calculation, and sends the MD5 character string to the FTP server;
[0160] Step S525, the FTP server appends the password corresponding to the preset user name of the DICOM gateway after the unique character string that changes randomly over time to obtain a fourth appended result, and performs MD5 calculation on the fourth appended result to obtain a fourth MD5 character string;
[0161] Step S526: the FTP server compares the received MD5 third character string with the calculated MD5 fourth character string.
[0162] Step S527, if the comparison result is consistent, the FTP server maintains the TCP connection to allow the DICOM gateway to write PACS image data to the corresponding currently available storage node through the FTP server;
[0163] Step S528: If the comparison result is inconsistent, the FTP server closes the TCP connection.
[0164] Here, the data generated by various medical examination equipment is sent to the DICOM gateway through the network using the DICOM protocol, and the DICOM gateway writes the data into the storage node.
[0165] The FTP server can perform the same calculation based on the locally configured user name and password. If the calculated third character string of MD5 is the same as the fourth character string of MD5 sent by the DICOM gateway, the TCP connection is maintained and a "230Logged on" message can be sent to the DICOM gateway. Subsequently, the DICOM gateway can use standard FTP commands to read the PACS image data of the corresponding currently available storage node through the FTP server; otherwise, the TCP connection is closed and a "530Login Authentication Error" can be sent to the DICOM gateway.
[0166] The improved FTP protocol of this embodiment is used to read and write data between the DICOM gateway and the storage node, which can prevent the password from being transmitted in plain text over the network.
[0167] According to another aspect of the present invention, a computer-readable medium is further provided, on which computer-readable instructions are stored. The computer-readable instructions can be executed by a processor to implement any of the above methods.
[0168] For details of the various device and storage medium embodiments of the present invention, please refer to the corresponding parts of the various method embodiments, which will not be repeated here.
[0169] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.
[0170] It should be noted that the present invention can be implemented in software and / or a combination of software and hardware, for example, can be implemented using an application specific integrated circuit (ASIC), a general purpose computer or any other similar hardware device. In one embodiment, the software program of the present invention can be executed by a processor to implement the steps or functions described above. Similarly, the software program of the present invention (including related data structures) can be stored in a computer readable recording medium, for example, a RAM memory, a magnetic or optical drive or a floppy disk and the like. In addition, some steps or functions of the present invention can be implemented using hardware, for example, as a circuit that cooperates with a processor to perform each step or function.
[0171] In addition, a part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. The program instruction for calling the method of the present invention may be stored in a fixed or removable recording medium, and / or transmitted through a data stream in a broadcast or other signal-bearing medium, and / or stored in a working memory of a computer device that runs according to the program instruction. Here, according to an embodiment of the present invention, a device is included, the device including a memory for storing computer program instructions and a processor for executing program instructions, wherein, when the computer program instruction is executed by the processor, the device is triggered to run the method and / or technical solution based on the aforementioned multiple embodiments of the present invention.
[0172] It is obvious to those skilled in the art that the present invention is not limited to the details of the exemplary embodiments described above, and that the present invention can be implemented in other specific forms without departing from the spirit or essential features of the present invention. Therefore, from any point of view, the embodiments should be regarded as exemplary and non-restrictive, and the scope of the present invention is defined by the appended claims rather than the above description, and it is intended that all changes falling within the meaning and scope of the equivalent elements of the claims are included in the present invention. Any figure mark in the claims should not be regarded as limiting the claims involved. In addition, it is obvious that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. Multiple units or devices stated in the device claim can also be implemented by one unit or device through software or hardware. The words first, second, etc. are used to indicate names, and do not indicate any particular order.
Claims
1. A data access method for a PACS image storage system, wherein: The method includes: Each storage node periodically sends a heartbeat message to the management server, wherein each storage node is used to store PACS image data; The management server adds the storage node to the list of currently available storage nodes, or deletes the storage node from the list of currently available storage nodes based on the heartbeat message of each storage node; The client sends a storage node access request to the management server; The management server selects a currently available storage node from the list of currently available storage nodes in turn based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client; The client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established; The management server adds the storage node to the list of currently available storage nodes based on the heartbeat message of each storage node, including: Step S211, the management server records the heartbeat messages received from each storage node into the historical message queue corresponding to each storage node, each heartbeat message includes: the storage node number and the heartbeat time, wherein the historical message queue only records M heartbeat messages received recently from each storage node, where M is a positive integer; Step S212: The management server determines whether each storage node belongs to the list of currently available storage nodes. Step S213: if all storage nodes belong to the list of currently available storage nodes, return to step S211; Step S214: If there is a storage node that belongs to the list of all storage nodes and does not belong to the list of the currently available storage nodes, the management server determines whether N heartbeat messages with consecutive recent heartbeat times sent by the storage node are received based on the historical message queue corresponding to the storage node, where M is greater than or equal to N, and the currently available storage node is selected from the list of all storage nodes; Step S215, if the management server receives N consecutive heartbeat messages sent by the storage node in the recent period, the storage node is added to the tail of the list Lon of currently available storage nodes, and then the process returns to step S211; Step S216: If the management server does not receive N consecutive heartbeat messages sent by the storage node in the recent heartbeat time, return to step S211.
2. The method according to claim 1, wherein: The management server deletes the storage node from the list of currently available storage nodes based on the heartbeat message of each storage node, including: Step S221, the management server periodically determines whether it has received N heartbeat messages with recent consecutive heartbeat times sent by each storage node in the list of currently available storage nodes based on the historical message queues corresponding to each storage node, where M is greater than or equal to N and N is a positive integer; Step S222: if the management server receives N heartbeat messages with consecutive recent heartbeat times sent by all storage nodes in the list of currently available storage nodes, then the process returns to step S221; Step S223, if the management server has not received N consecutive heartbeat messages sent by one or more storage nodes in the list of currently available storage nodes, it is determined whether the number of heartbeat messages received from the one or more storage nodes respectively within a preset recent time period T is greater than K, where K is a positive integer; Step S224: if the number of heartbeat messages received by the management server from the one or more storage nodes within the preset recent time period T is greater than K, then return to step S221; Step S225, if the number of heartbeat messages received by the management server from the one or more storage nodes in the preset recent time period T is less than or equal to K, then the one or more storage nodes are deleted from the list Lon of currently available storage nodes, and the process returns to step S221.
3. The method according to claim 1, wherein: The client sends a storage node access request to the management server, including: The service workstation sends an access request of the storage node to the management server.
4. The method according to claim 3, wherein: Step S4, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client, including: Based on the access request of the service workstation, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the service workstation.
5. The method according to claim 4, wherein: The client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established, including: The business workstation establishes a TCP connection with the corresponding FTP server based on the received IP address; The service workstation sends the user name of the service workstation to the FTP server through the established TCP connection; After receiving the user name of the service workstation, the FTP server sends a unique character string that changes randomly over time to the service workstation; The service workstation appends a preset password corresponding to the user name of the service workstation after the unique character string that changes randomly over time to obtain a first append result, performs MD5 calculation on the first append result to obtain a first MD5 character string, and sends the first MD5 character string to the FTP server; The FTP server appends the password corresponding to the preset user name of the service workstation after the unique character string that changes randomly over time to obtain a second appended result, and performs MD5 calculation on the second appended result to obtain a second MD5 character string; The FTP server compares the received MD5 first string with the calculated MD5 second string, If the comparison result is consistent, the FTP server maintains the TCP connection to allow the service workstation to read the PACS image data from the corresponding currently available storage node through the FTP server; If the comparison result is inconsistent, the FTP server closes the TCP connection.
6. The method according to claim 1, wherein: The client sends a storage node access request to the management server, including: The examination equipment sends the PACS image data to the DICOM gateway via the DICOM protocol and the network; The DICOM gateway sends an access request of a storage node to the management server.
7. The method according to claim 6, wherein: The management server selects a currently available storage node from the list of currently available storage nodes in turn based on the access request of the client, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the client, including: Based on the access request of the DICOM gateway, the management server sequentially polls and selects currently available storage nodes from the list of currently available storage nodes, and returns the IP address corresponding to the FTP server of the selected currently available storage node to the DICOM gateway.
8. The method according to claim 7, wherein: The client establishes a TCP connection with the corresponding FTP server based on the received IP address, and accesses the corresponding currently available storage node through the client and the FTP server to which the TCP connection is established, including: The DICOM gateway establishes a TCP connection with the corresponding FTP server based on the received IP address; The DICOM gateway sends the user name of the DICOM gateway to the FTP server through the established TCP connection; After receiving the user name of the DICOM gateway, the FTP server sends a unique character string that changes randomly over time to the DICOM gateway; The DICOM gateway appends a password corresponding to a preset user name of the DICOM gateway after the unique character string that changes randomly over time to obtain a third append result, performs MD5 calculation on the third append result to obtain a third character string of MD5, and sends the third character string of MD5 to the FTP server; The FTP server appends the password corresponding to the preset user name of the DICOM gateway after the unique character string that changes randomly over time to obtain a fourth appended result, and performs MD5 calculation on the fourth appended result to obtain a fourth character string of MD5; The FTP server compares the received MD5 third character string with the calculated MD5 fourth character string, If the comparison result is consistent, the FTP server maintains the TCP connection to allow the DICOM gateway to write PACS image data to the corresponding currently available storage node through the FTP server; If the comparison result is inconsistent, the FTP server closes the TCP connection.
9. A computer-readable medium having computer-readable instructions stored thereon, wherein the computer-readable instructions can be executed by a processor to implement the method according to any one of claims 1 to 8.