A twin process restart method, device, medical system and storage medium

Through the twin process restart method, the interchange of application processes and twin processes is solved, and the problem of untimely restarting of processes and long-term resource occupation is not released, achieving fast and efficient process restart and resource management, which is suitable for emergency situations such as medical care.

CN114860347BActive Publication Date: 2024-12-03SHANGHAI UNITED IMAGING HEALTHCARE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210632160.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-27
Publication Date
2024-12-03
Estimated Expiration
2042-05-27

AI Technical Summary

Technical Problem

The existing technology is difficult to efficiently restart the process, resulting in a long-term use of system resources and will not be released, affecting the normal operation of the system, especially in emergency situations such as medical care, which will cause inconvenience to production work.

Method used

Provide a method for restarting a twin process. By obtaining the running parameters of the application process, it determines whether the preset interchange conditions are met. If it is met, the application process and the alternate twin process will be exchanged, so that the interchangeable twin process will intervene in the system operation. , the interchangeable application process is used as a backup to solve memory leakage and resource utilization problems.

Benefits of technology

It realizes rapid restart of processes and efficient use of resources, avoids functional limitations and resource waste caused by the restart of the entire system, and improves the efficiency of system resources use.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114860347B_ABST
    Figure CN114860347B_ABST
Patent Text Reader

Abstract

The present invention relates to a twin process restart method, device, medical system and storage medium, the method comprising: obtaining the operating parameters of each application process in a process group; judging whether the operating parameters meet a preset exchange condition; if the preset exchange condition is met, exchanging the application process with the corresponding spare twin process, wherein the swapped twin process intervenes in the system operation, and the swapped application process serves as a spare. The present invention utilizes the swapping of application processes and twin processes to ensure the rapidity of restart, avoids restarting the entire system to solve memory leaks, and also solves the problem of processes occupying system resources and not releasing them for a long time, thereby improving the efficiency of using system resources.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of process management technology, and in particular to a twin process restart method, device, medical system and storage medium. Background Art

[0002] When the software system is running, a multi-process architecture is generally used. When the process provides services or logical processing, it takes up a lot of memory. The memory occupied by the process needs to be released in time, otherwise a memory leak will occur. When a process has a memory leak, the system's available memory will gradually decrease until it affects the normal operation of the system. Generally, the entire system needs to be restarted to solve the above problem, but this will bring unnecessary trouble to the site.

[0003] The restart process of large software may take more than ten minutes or even longer, which will cause inconvenience to production work. Especially when it comes to hardware system restart, such as restarting medical scanning equipment, when emergency patients need to be scanned urgently, but the relevant equipment is still restarting, it will affect both medical staff and patients. Therefore, how to ensure efficient restart of the process has become an urgent problem to be solved. Summary of the invention

[0004] In view of this, it is necessary to provide a twin process restart method, device, medical system and storage medium to overcome the problem that the process cannot be restarted efficiently in the prior art.

[0005] The present invention provides a twin process restart method, which is applicable to a data processing system, in which a process group is run, the process group includes multiple application processes, and at least one application process is correspondingly provided with a spare twin process, and the twin process restart method includes:

[0006] Get the running parameters of each application process in the process group;

[0007] Determining whether the operating parameters meet preset interchange conditions;

[0008] If the preset exchange condition is met, the application process and the backup twin process are exchanged, wherein the exchanged twin process intervenes in the operation of the data processing system, and the exchanged application process serves as a backup.

[0009] Furthermore, the operating parameter includes a memory value occupied by the application process in a non-working state, and the preset exchange condition includes a first exchange condition, and the first exchange condition includes:

[0010] When the monitored memory value reaches a preset memory threshold and the application process is asked whether it needs to be restarted, confirmation restart information of the application process is received.

[0011] Furthermore, if the preset exchange condition is met, the application process and the standby twin process are exchanged, including:

[0012] If the first interchange condition is met, the application process and the standby twin process are interchanged, wherein the interchanged twin process intervenes in the operation of the data processing system to implement the function of the application process, and the interchanged application process is restarted and used as a standby to implement the function of the twin process.

[0013] Furthermore, it also includes: if the first exchange condition is not met, continuing to monitor the memory value of each application process.

[0014] Further, the operating parameter includes the waiting time of the application process in a non-working state, and the preset exchange condition includes a second exchange condition, and the second exchange condition includes:

[0015] The application process monitors its own waiting time in a non-working state, and sends a restart request message when the waiting time reaches a preset time threshold.

[0016] Furthermore, if the preset exchange condition is met, the application process and the standby twin process are exchanged, including:

[0017] If the second interchange condition is met, the application process and the backup twin process are interchanged, wherein the interchanged twin process intervenes in the operation of the data processing system to realize the function of the application process, and the interchanged application process is restarted and used as a backup to realize the function of the twin process.

[0018] Furthermore, it also includes: if the second exchange condition is not met, the application process continues to monitor the waiting time of itself in the non-working state.

[0019] The present invention also provides a twin process restarting device, on which a computer program is stored. When the computer program is executed by a processor, the twin process restarting method as described above is implemented.

[0020] The present invention also provides a medical system, comprising operating software of at least one medical device and the twin process restart device as described above, wherein the twin process restart device is used to manage the restart of the application process in the running software.

[0021] The present invention also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the twin process restart method as described above is implemented.

[0022] Compared with the prior art, the beneficial effects of the present invention include: first, effectively obtaining the operating parameters of each application process; then, judging whether the application process meets the preset exchange conditions based on the operating parameters, so as to judge whether the application process has occupied system resources for no reason and memory leaks, so as to facilitate the subsequent corresponding restart processing; finally, when the preset exchange conditions are met, it means that the application process has occupied system resources for no reason, and the corresponding spare twin process and application process are exchanged, so that the exchanged twin process replaces the original application process and intervenes in the system operation, and the exchanged application process replaces the original twin process as a spare for the exchanged twin process, so that the problem of the application process occupying memory for a long time and without limit can be solved, the use efficiency of system resources can be enhanced, and efficient process restart can be performed. In summary, the present invention utilizes the exchange of application processes and twin processes to ensure the continuity of application process use and the rapidity of restart, avoids the function / service provided by the application process being limited due to restarting the entire system, and solves the problem of the process occupying system resources for a long time without releasing them, and improves the use efficiency of system resources. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 A schematic diagram of a scenario of an application system of an embodiment of a twin process restart method provided by the present invention;

[0024] Figure 2 A schematic diagram of a flow chart of an embodiment of a twin process restart method provided by the present invention;

[0025] Figure 3 A schematic structural diagram of an embodiment of a twin process restarting device provided by the present invention. DETAILED DESCRIPTION

[0026] The preferred embodiments of the present invention are described in detail below in conjunction with the accompanying drawings, wherein the accompanying drawings constitute a part of this application and are used together with the embodiments of the present invention to illustrate the principles of the present invention, but are not used to limit the scope of the present invention.

[0027] In the description of the present invention, the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0028] In the description of the present invention, reference to an "embodiment" means that a particular feature, structure, or characteristic described in conjunction with the embodiment may be included in at least one embodiment of the present invention. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive of other embodiments. It is explicitly and implicitly understood by those skilled in the art that the described embodiments may be combined with other embodiments.

[0029] The present invention provides a twin process restart method, which utilizes the exchange of a spare twin process and an application process to provide a new idea for further improving the rapidity of process restart. Before describing the specific embodiments, the technical terms involved are explained as follows:

[0030] Application process: It is a running activity of a program in a computer on a certain data set. It is the basic unit for resource allocation and scheduling of the system and the basis of the operating system structure. In the computer structure designed for threads, the process is the container of threads. The program is a description of instructions, data and their organizational form, and the process is the entity of the program;

[0031] Process group: refers to a group of processes that provide the same functional services. There will be many application processes on the integrated cluster. The process group is a group formed by multiple processes that implement the same functional services in the integrated cluster.

[0032] The specific embodiments are described in detail below:

[0033] The embodiment of the present invention provides an application system of a twin process restart method. Figure 1 A schematic diagram of a scenario of an application system of an embodiment of a twin process restart method provided by the present invention, wherein the system may include a server 100, in which a twin process restart device is integrated, such as Figure 1 Servers in .

[0034] In the embodiment of the present invention, the server 100 is mainly used for:

[0035] A process group is run in a data processing system, the process group includes multiple application processes, and at least one application process is correspondingly provided with a spare twin process, and the twin process restart method includes:

[0036] Get the running parameters of each application process in the process group;

[0037] Determine whether the operating parameters meet the preset interchange conditions;

[0038] If the preset exchange conditions are met, the application process and the backup twin process are exchanged, wherein the exchanged twin process intervenes in the operation of the data processing system, and the exchanged application process serves as a backup.

[0039] In the embodiment of the present invention, the server 100 may be an independent server, or a server network or server cluster composed of servers. For example, the server 100 described in the embodiment of the present invention includes but is not limited to a computer, a network host, a single network server, a plurality of network server sets or a cloud server composed of a plurality of servers. The cloud server is composed of a large number of computers or network servers based on cloud computing.

[0040] It is to be understood that the terminal 200 used in the embodiment of the present invention may be a device including both receiving and transmitting hardware, that is, a device having receiving and transmitting hardware capable of performing two-way communication on a two-way communication link. Such a device may include: a cellular or other communication device having a single-line display or a multi-line display or a cellular or other communication device without a multi-line display. The specific terminal 200 may be a desktop computer, a portable computer, a network server, a PDA (Personal Digital Assistant), a mobile phone, a tablet computer, a wireless terminal device, a communication device, an embedded device, etc. The present embodiment does not limit the type of the terminal 200.

[0041] Those skilled in the art will understand that Figure 1 The application environment shown in the figure is only one application scenario of the solution of the present invention and does not constitute a limitation on the application scenario of the solution of the present invention. Other application environments may also include Figure 1 More or fewer terminals as shown in Figure 1 Only two terminals are shown. It can be understood that the application system of the twin process restart method can also include one or more other terminals, which are not limited here.

[0042] In addition, if Figure 1 As shown, the application system of the twin process restart method may also include a memory 300 for storing data, such as operating parameters, preset exchange conditions, etc.

[0043] It should be noted that Figure 1 The scenario diagram of the application system of the twin process restart method shown is only an example. The application system and scenario of the twin process restart method described in the embodiment of the present invention are for more clearly illustrating the technical solution of the embodiment of the present invention, and do not constitute a limitation on the technical solution provided by the embodiment of the present invention. Ordinary technicians in this field can know that with the evolution of the application system of the twin process restart method and the emergence of new business scenarios, the technical solution provided by the embodiment of the present invention is also applicable to similar technical problems.

[0044] The embodiment of the present invention provides a twin process restart method, combined with Figure 2 Come and see, Figure 2 A schematic flow chart of an embodiment of a twin process restart method provided by the present invention includes steps S1 to S3, wherein:

[0045] In step S1, the operating parameters of each application process in the process group are obtained;

[0046] In step S2, it is determined whether the operating parameters meet the preset interchange conditions;

[0047] In step S3, if the preset exchange conditions are met, the application process and the corresponding spare twin process are exchanged, wherein the exchanged twin process intervenes in the system operation, and the exchanged application process serves as a spare.

[0048] In an embodiment of the present invention, first, the operating parameters of each application process are effectively obtained; then, based on the operating parameters, it is determined whether the application process meets the preset exchange conditions, so as to determine whether the application process occupies system resources for no reason or has memory leaks, so as to facilitate the subsequent corresponding restart processing; finally, when the preset exchange conditions are met, it means that the application process has occupied system resources for no reason, and the corresponding spare twin process and application process are exchanged, so that the swapped twin process replaces the original application process and intervenes in the system operation, and the swapped application process replaces the original twin process as a backup for the swapped twin process. In this way, the problem of unlimited long-term increase in memory occupied by application processes can be solved, the efficiency of system resource utilization can be enhanced, and efficient process restart can be performed.

[0049] It should be noted that the above method is applied to the process management server. The application process and the twin process are different instances of the same program. They are pure back-end service processes that provide functional services to other applications, and both can provide the same service functions. The process management server manages the operation of each application process in the process group. When the application process needs to be restarted, the application process and the corresponding twin process are exchanged in the process management server to ensure the speed of the restart and avoid waste of resources.

[0050] As a more specific embodiment, the above-mentioned operation parameters include the memory value occupied by the application process in the non-working state and / or the waiting time of the application process in the non-working state. In the embodiment of the present invention, through the memory value and the waiting time, using its operation characteristics, it is effectively identified whether the application process has occupied system resources for no reason and has memory leakage.

[0051] As a more specific embodiment, when the application process is started, a corresponding twin process is created as a backup, wherein the twin process has the same function as the application process. It should be noted that when the application process is running, the twin process does not participate in the operation of the system, but its resource occupancy is very small, and it is only in a backup state. When the application process needs to be restarted, the twin process can be swapped with the application process to effectively restart and release resources.

[0052] As a more specific embodiment, the interchanged twin process serves as a new application process, and the interchanged application process serves as a new twin process. It continues to monitor the operating parameters of the new application process and determines whether the operating parameters meet the preset interchange conditions. If the preset interchange conditions are met, the new application process and the new twin process are interchanged.

[0053] In an embodiment of the present invention, when an application process needs to be restarted due to various reasons (unlimited memory usage, too long waiting time), the twin process established when it was created is intervened to replace the operation of the application process, and the exchanged application process becomes a new twin process. When the new application process is found to meet the requirements for restart, that is, the new application process also has unlimited memory usage, too long waiting time, etc., and meets the requirements for restart, the new application process and the new twin process are exchanged, so as to perform unlimited exchange in a backup form, effectively release the system, do not delay the operation of the process, and save system resources.

[0054] As a more specific embodiment, the above-mentioned interchange of the application process and the corresponding standby twin process specifically includes: replacing the configuration information corresponding to the application process with the configuration information corresponding to the corresponding twin process to realize the interchange. In the embodiment of the present invention, the interchange of the application process and the corresponding standby twin process is realized by the interchange of configuration information, so that the application function or the standby function is realized correspondingly.

[0055] In a specific embodiment of the present invention, application process A and the corresponding twin process A' both provide addition operations. Then all applications with addition operation requests find application process A through configuration information. After receiving the command, application process A responds to the request and provides application services for addition operations. When exchanged, the configuration information changes (such as the IP and port are replaced by those of twin process A'). The configuration information of application process A is replaced by the configuration information of twin process A'. At this time, the addition operation request command will be sent to twin process A', and application process A starts to restart. At this time, twin process A' replaces application process A and becomes a new application process to provide addition operation services to the outside world.

[0056] As a preferred embodiment, the operating parameters include the memory value occupied by the application process in a non-working state, and the preset exchange conditions include a first exchange condition. The first exchange condition includes: when the monitored memory value reaches a preset memory threshold and asks the application process whether it needs to be restarted, a confirmation restart information of the application process is received.

[0057] In the embodiment of the present invention, the memory value occupied by the application process is used to effectively monitor the memory leakage situation, and the application process in the process group is regularly monitored to determine whether it has a restart requirement, so as to perform subsequent restart processing.

[0058] As a preferred embodiment, if the preset exchange conditions are met, the application process and the correspondingly created twin process are exchanged, including: if the first exchange condition is met, the application process and the standby twin process are exchanged, wherein the exchanged twin process intervenes in the operation of the data processing system, replaces the application process to implement the function of providing services, and the exchanged application process is restarted and used as a standby, replacing the twin process to implement the standby function.

[0059] In an embodiment of the present invention, when the first swap condition is met, it indicates that a certain application process has reached the memory threshold and needs to be restarted to release memory to avoid unlimited memory occupation. Therefore, the application process and the backup twin process are swapped, thereby avoiding the situation where memory leakage causes the memory occupied by a certain process to increase unlimitedly.

[0060] As a preferred embodiment, if the preset exchange condition is met, the application process and the correspondingly created twin process are exchanged, and it also includes: if the first exchange condition is not met, the memory value of each application process continues to be monitored.

[0061] In the embodiment of the present invention, when the first exchange condition is not met, it means that the corresponding application process does not need to be restarted, or the application process is in a working state, then the next polling is performed to continue monitoring the memory value of the application process.

[0062] As a preferred embodiment, the operating parameters include the waiting time of the application process in a non-working state, the preset exchange condition includes a second exchange condition, and the second exchange condition includes: receiving a request to restart information from the application process, wherein the application process monitors its own waiting time in a non-working state, and when the waiting time reaches a preset time threshold, a request to restart information is issued.

[0063] In an embodiment of the present invention, when the second exchange condition is met, it means that an application process monitors the waiting time when it is in a non-working state. At this time, the application has been in a non-working state for a long time and has been occupying resources ineffectively for a long time. Therefore, when the application process sends a request to restart the information, the application process and the backup twin process are exchanged, thereby better improving the utilization efficiency of system resources.

[0064] It should be noted that database connections, cached data, and certain locks may cause an application process to be idle for a long time and occupy system resources.

[0065] As a preferred embodiment, if the preset exchange condition is met, the application process and the corresponding created twin process are exchanged, including: if the second exchange condition is met, the application process and the standby twin process are exchanged, wherein the exchanged twin process intervenes in the operation of the data processing system, replaces the application process to implement the function of providing services, and the exchanged application process is restarted and used as a standby, replacing the twin process to implement the standby function.

[0066] In an embodiment of the present invention, a second interchange condition is set to effectively identify that an application process has been inactive for a long time. At this time, in order to avoid wasting memory resources, measures are taken to interchange the application process and the spare twin process, thereby releasing the system resource memory occupied by a process that has been inactive for a long time.

[0067] As a preferred embodiment, if the preset exchange condition is met, the application process and the correspondingly created twin process are exchanged, and it also includes: if the second exchange condition is not met, the application process continues to monitor its own waiting time in the non-working state.

[0068] In the embodiment of the present invention, when the second exchange condition is not met, it means that the corresponding application process does not need to be restarted yet, and the next polling is performed, and the waiting time of the application process is continued to be monitored.

[0069] It is understandable that the above operating parameters include but are not limited to memory value and waiting time, and are not limited here as long as the situation that the application process needs to be restarted can be accurately identified.

[0070] The technical solution of the present invention is better illustrated by a specific application example. For a medical scanning system, there are applications formed by multiple scanning devices. When the application process is application process A and the corresponding twin process is twin process A_bkp (it should be noted that A_bkp is a backup file automatically generated by the system), the overall restart process is as follows:

[0071] First, when the system starts, the process management server starts application process A and creates twin process A_bkp at the same time, and sets the memory threshold and time threshold of application process A in the non-working state. The twin process A_bkp has the same running function as application process A, but does not participate in the system operation for the time being, and occupies very little resources. When application process A is running, it serves as its backup;

[0072] Second, the process management server periodically monitors which application process in the process group has reached the memory threshold. When the memory occupied by application process A reaches the memory threshold, the management server will ask application process A whether it can be restarted. If application process A replies yes (that is, it generates confirmation restart information), the twin process A_bkp intervenes and participates in the system operation. At this time, the twin process A_bkp replaces application process A and becomes the new application process. Subsequently, the swapped application process A restarts as a new twin process and waits for the next switch. Here, it can be understood that the identities of application process A and twin process A_bkp in the process management server have been exchanged; and when application process A replies no (that is, no confirmation restart information is generated), the process management server waits for the next polling;

[0073] Third, application process A monitors its own waiting time in the non-working state. If it reaches the set time threshold but still does not enter the working state, it means that application process A only occupies system memory but is not working. Then application process A notifies the process management server to replace itself with the twin process A_bkp to intervene in the system operation. Application process A restarts as a new twin process and waits for the next switch.

[0074] The embodiment of the present invention also provides a twin process restart device, combined with Figure 3 Come and see, Figure 3 This is a structural diagram of an embodiment of a twin process restart device provided by the present invention, wherein the twin process restart device 003 includes:

[0075] The acquisition unit 301 is used to acquire the operation parameters of each application process in the process group;

[0076] A judging unit 302 is used to judge whether the operating parameters meet the preset interchange conditions;

[0077] The restart unit 303 is used to exchange the application process and the corresponding spare twin process if the preset exchange condition is met, wherein the exchanged twin process intervenes in the system operation, and the exchanged application process serves as a spare.

[0078] The more specific implementation methods of each unit of the twin process restart device can be found in the description of the above-mentioned twin process restart method, and have similar beneficial effects, so they will not be repeated here.

[0079] An embodiment of the present invention also provides a twin process restarting device, on which a computer program is stored. When the computer program is executed by a processor, the twin process restarting method as described above is implemented.

[0080] The more specific implementation methods of each unit of the twin process restart device can be found in the description of the above-mentioned twin process restart method, and have similar beneficial effects, so they will not be repeated here.

[0081] An embodiment of the present invention also provides a medical system, comprising operating software of at least one medical device and the twin process restart device as described above, wherein the twin process restart device is used to manage the restart of the application process in the running software.

[0082] The more specific implementation methods of each unit of the medical system can be found in the description of the above-mentioned twin process restart method, and have similar beneficial effects, so they will not be repeated here.

[0083] An embodiment of the present invention also provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the twin process restart method as described above is implemented.

[0084] Generally speaking, the computer instructions for implementing the method of the present invention can be carried by any combination of one or more computer-readable storage media. Non-transitory computer-readable storage media can include any computer-readable media except for the signal itself that is temporarily propagating.

[0085] Computer-readable storage media can be, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or devices, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection with one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, a computer-readable storage medium can be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, device, or device.

[0086] Computer program code for performing the operation of the present invention can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" language or similar programming languages, in particular, Python language suitable for neural network computing and platform frameworks based on TensorFlow, PyTorch, etc. can be used. The program code can be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, using an Internet service provider to connect through the Internet).

[0087] An embodiment of the present invention also provides a computing device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the twin process restart method as described above is implemented.

[0088] The computer-readable storage medium and computing device provided according to the above embodiments of the present invention can be implemented with reference to the specific description of the twin process restart method as described above according to the present invention, and have similar beneficial effects as the twin process restart method as described above, which will not be repeated here.

[0089] The present invention discloses a twin process restart method, equipment, medical system and storage medium. First, the operating parameters of each application process are effectively obtained; then, based on the operating parameters, it is judged whether the application process meets the preset exchange conditions, so as to judge whether the application process occupies system resources for no reason and has memory leaks, so as to facilitate subsequent corresponding processing; finally, when the preset exchange conditions are met, it means that the application process occupies system resources for no reason, and the corresponding spare twin process and application process are exchanged, so that the swapped twin process replaces the original application process and intervenes in the system operation, and the swapped application process replaces the original twin process as a backup for the swapped twin process. In this way, the problem of unlimited increase in memory occupied by the application process for a long time can be solved, the utilization efficiency of system resources can be enhanced, and efficient process restart can be performed.

[0090] The technical solution of the present invention utilizes the interchange of application processes and twin processes to ensure the rapidity of restart, avoiding the restriction of functions / services provided by the application process due to restarting the entire system, while also solving the problem of processes occupying system resources and not releasing them for a long time, thereby improving the efficiency of system resource utilization.

[0091] The above description is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by any technician familiar with the technical field within the technical scope disclosed by the present invention should be covered within the protection scope of the present invention.

Claims

1. A twin process restart method, applicable to a data processing system, characterized in that: A process group is run in the data processing system, the process group includes a plurality of application processes, and at least one application process is correspondingly provided with a spare twin process, and the twin process restart method includes: Obtaining operating parameters of each application process in the process group, wherein the operating parameters include a memory value occupied by the application process in a non-working state and / or a waiting time of the application process in a non-working state; Determine whether the operating parameters meet the preset exchange conditions; the preset exchange conditions include a first exchange condition, the first exchange condition includes: when the monitored memory value reaches a preset memory threshold, inquiring whether the application process needs to be restarted, the received confirmation restart information of the application process; the preset exchange condition includes a second exchange condition, the second exchange condition includes: the application process monitors its own waiting time in a non-working state, and when the waiting time reaches a preset time threshold, sends a request to restart information; If the preset exchange condition is met, the application process and the standby twin process are exchanged, wherein the exchanged twin process intervenes in the operation of the data processing system, and the exchanged application process serves as a standby; The exchanging of the application process and the spare twin process includes: replacing the configuration information for implementing the application function from the configuration information corresponding to the application process with the configuration information corresponding to the spare twin process to achieve the exchange.

2. The twin process restart method according to claim 1, characterized in that: If the preset exchange condition is met, exchanging the application process and the standby twin process includes: If the first interchange condition is met, the application process and the standby twin process are interchanged, wherein the interchanged twin process intervenes in the operation of the data processing system, replacing the application process to implement the function of providing services, and the interchanged application process is restarted and used as a standby, replacing the twin process to implement the standby function.

3. The twin process restart method according to claim 1, characterized in that: Also includes: If the first swap condition is not met, continue to monitor the memory value of each application process.

4. The twin process restart method according to claim 1, characterized in that: If the preset exchange condition is met, exchanging the application process and the standby twin process includes: If the second interchange condition is met, the application process and the standby twin process are interchanged, wherein the interchanged twin process intervenes in the operation of the data processing system, replacing the application process to implement the function of providing services, and the interchanged application process is restarted and used as a standby, replacing the twin process to implement the standby function.

5. The twin process restart method according to claim 1, characterized in that: Also includes: If the second exchange condition is not satisfied, the application process continues to monitor the waiting time of itself in the non-working state.

6. A twin process restart device, characterized in that: A computer program is stored thereon, and when the computer program is executed by a processor, the twin process restart method according to any one of claims 1 to 5 is implemented.

7. A medical system, characterized in that: It includes operating software of at least one medical device and a twin process restart device according to claim 6, wherein the twin process restart device is used to manage the restart of the application process in the operating software.

8. A computer-readable storage medium, characterized in that: A computer program is stored thereon, which, when executed by a processor, implements the twin process restart method according to any one of claims 1 to 5.