Execution management node restarting method and device, equipment and storage medium
By introducing a second execution management node to the autonomous driving system to monitor and restart the first execution management node, the unpredictable behavior problem of the system caused by the crash of the execution management node is solved, and the safety and stability of the autonomous driving system are improved.
Patent Information
- Application Number
- CN202411382101.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-30
- Publication Date
- 2025-01-03
AI Technical Summary
The execution management node crash in the autonomous driving system causes the system behavior to be unpredictable and affects security.
The second execution management node in the second software architecture is introduced, and the first execution management node in the first software architecture is monitored to crash and send a restart command to ensure that the system process management is restarted in time during the crash.
Improve the stability and reliability of the execution management nodes, ensuring the safety and controllability of the autonomous driving system.
Smart Images

Figure CN119248576A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of autonomous driving, and in particular to a method, device, equipment and storage medium for executing and managing node restart. Background Art
[0002] According to the standard requirements of AUTOSAR AP (AUTomotive Open System Architecture Adaptive Platform, an adaptive platform using an automotive open system architecture), it is necessary to implement state management (SM) and execution management (EM) in the autonomous driving middleware. Among them, the execution management node is the basis of the autonomous driving middleware. The autonomous driving middleware manages and monitors the process through the execution management node, such as managing the startup and shutdown of the process, monitoring the current state of the process, etc. At the same time, the execution management node also needs to report its own execution results to the state management node. However, current autonomous driving has high requirements for the stability and reliability of the execution management node. If the execution management node crashes and exits unexpectedly, it is easy to cause other processes in the entire autonomous driving system to lose control, making the behavior of the entire autonomous driving system unpredictable. Summary of the invention
[0003] In view of this, the purpose of the present invention is to provide an execution management node restart method, device, equipment and storage medium, which can introduce a second execution management node in a second software architecture to perform crash monitoring on a first execution management node in a first software architecture, thereby controlling the first execution management node that crashes to restart in time, and timely restore the management of system processes, thereby improving the safety of autonomous driving. The specific scheme is as follows:
[0004] In a first aspect, the present application provides an execution management node restart method, which is applied to a first execution management node in a first software architecture, comprising:
[0005] Obtaining a restart command sent by a second execution management node in a second software architecture after detecting that the first execution management node crashes;
[0006] Execute the restart command to restart itself, and after restarting, restore the management of the system process based on the process state of the system process, and re-establish the communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located in the process management node in the first software architecture;
[0007] After the first execution management node is restarted, a restart success notification message and the management status of the system process are sent to the second execution management node.
[0008] Optionally, the management of the system process based on the process state of the system process is restored, including:
[0009] The process agent in the first execution management node determines whether the process status reported by the system process is obtained, and based on the determination result, calls the tracking thread in the first execution management node to track the system process.
[0010] Optionally, calling the tracking thread in the first execution management node to track the system process based on the judgment result includes:
[0011] If the judgment result indicates that the process agent obtains the process status reported by the system process and the process status is normal, the process status is set to the corresponding status of the system process in the process agent, and the process ID of the system process is sent to the tracking thread, so that the tracking thread tracks the system process based on the process ID.
[0012] Optionally, calling the tracking thread in the first execution management node to track the system process based on the judgment result includes:
[0013] If the judgment result indicates that the process agent has not obtained the process status reported by the system process, or the obtained process status is an abnormal state, a process reconstruction instruction is sent to the process management node so that the process management node kills the system process and recreates a new system process, and returns the process identifier of the new system process to the process agent;
[0014] The process identifier of the new system process is sent to the tracking thread through the process agent, so that the tracking thread tracks the new system process based on the process identifier of the new system process.
[0015] Optionally, the method further includes:
[0016] If a state switching instruction sent by the state management node in the second software architecture based on the process state of the system process is obtained, controlling the process management node to perform a corresponding state switch on the system process based on the state switching instruction;
[0017] If the process state is an abnormal state, the process management node is controlled to switch the system process from an open state to a closed state.
[0018] In a second aspect, the present application provides an execution management node restart method, which is applied to a second execution management node in a second software architecture, comprising:
[0019] Perform crash monitoring on a first execution management node in a first software architecture, and after detecting that the first execution management node has crashed, send a restart command to the first execution management node, so that the first execution management node executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located in the process management node in the first software architecture;
[0020] Obtain a restart success notification message sent by the first execution management node after the restart is completed and the management status of the system process.
[0021] In a third aspect, the present application provides an execution management node restart device, which is applied to a first execution management node in a first software architecture, including:
[0022] A command acquisition module, used to acquire a restart command sent by a second execution management node in a second software architecture after detecting that the first execution management node crashes;
[0023] a restart module, configured to execute the restart command to restart itself, and after restarting, restore the management of the system process based on the process state of the system process, and re-establish the communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at the process management node in the first software architecture;
[0024] The message sending module is used to send a restart success notification message and the management status of the system process to the second execution management node after the first execution management node is restarted.
[0025] In a fourth aspect, the present application provides an execution management node restart device, which is applied to a second execution management node in a second software architecture, including:
[0026] A crash monitoring module, configured to perform crash monitoring on a first execution management node in a first software architecture, and after detecting that the first execution management node has crashed, send a restart command to the first execution management node, so that the first execution management node executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at a process management node in the first software architecture;
[0027] The message acquisition module is used to obtain the restart success notification message sent by the first execution management node after the restart is completed and the management status of the system process.
[0028] In a fifth aspect, the present application provides an electronic device, including:
[0029] Memory, used to store computer programs;
[0030] A processor is used to execute the computer program to implement the aforementioned execution management node restart method.
[0031] In a sixth aspect, the present application provides a computer-readable storage medium for storing a computer program, which, when executed by a processor, implements the aforementioned execution management node restart method.
[0032] In the present application, a first execution management node in a first software architecture obtains a restart command sent by a second execution management node in a second software architecture after detecting that the first execution management node has crashed; executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at the process management node in the first software architecture; after the restart of the first execution management node is completed, a restart success notification message and the management status of the system process are sent to the second execution management node. It can be seen that the present application monitors the crash of the first execution management node in the first software architecture through the second execution management node in the second software architecture, and sends a restart command to the first execution management node when it is detected that the first execution management node has crashed, so that the first execution management node can obtain and execute the restart command to restart itself and restore the management of the system process after restarting; in this way, the present application uses the first execution management node in the first software architecture as the managed node of the second execution management node in the second software architecture, so that after the managed node crashes, it can promptly control the restart of the managed node and promptly restore the management of the system process, thereby ensuring the stability and reliability of the execution management node, thereby improving the safety of autonomous driving. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0034] Figure 1 A flowchart of a method for restarting a management node disclosed in this application;
[0035] Figure 2 A schematic diagram of a software architecture disclosed in this application;
[0036] Figure 3 A flowchart for executing and managing node restart disclosed in this application;
[0037] Figure 4 A flowchart of another method for restarting a management node disclosed in this application;
[0038] Figure 5 A schematic diagram of the structure of a device for executing and managing node restart disclosed in this application;
[0039] Figure 6This is a schematic diagram of the structure of another device for executing and managing node restart disclosed in this application;
[0040] Figure 7 This is a structural diagram of an electronic device disclosed in this application. DETAILED DESCRIPTION
[0041] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0042] Considering that autonomous driving has high requirements for the stability and reliability of the execution management node, if the execution management node crashes and exits unexpectedly, it is easy to cause other processes in the entire autonomous driving system to lose control, making the behavior of the entire autonomous driving system unpredictable. To this end, the present application provides an execution management node restart method, which introduces a second execution management node in a second software architecture to monitor the crash of the first execution management node in the first software architecture, thereby controlling the first execution management node that crashed to restart in time, and promptly restore the management of the system process, thereby improving the safety of autonomous driving.
[0043] See also Figure 1 As shown, an embodiment of the present invention discloses a method for restarting an execution management node, which is applied to a first execution management node in a first software architecture, and includes:
[0044] Step S11: Obtain a restart command sent by the second execution management node in the second software architecture after detecting that the first execution management node crashes.
[0045] In the embodiment of the present invention, the first software architecture is a middleware architecture built based on the first execution management node and the process management node; the second software architecture is a middleware architecture built based on the second execution management node and the state management node, or the second software architecture is a system service provided by the operating system, for example, when the operating system is a Linux operating system, the system service may be sysemd (a management program for starting various services in the Linux operating system). The execution management node is used to manage the startup and shutdown of the system process and track the process status of the system process.
[0046] Specifically, the first execution management node is used as a managed node of the second execution management node, so that the second execution management node performs crash monitoring on the first execution management node, and after detecting that the first execution management node crashes, a restart command is sent to the first execution management node. Accordingly, the first execution management node can obtain the restart command sent by the second execution management node, so as to restart itself by executing the restart command.
[0047] Step S12, execute the restart command to restart itself, and after restarting, restore the management of the system process based on the process state of the system process, and re-establish the communication connection with the system process to complete the restart of the first execution management node; wherein, the system process is located in the process management node in the first software architecture.
[0048] In an embodiment of the present invention, after obtaining the restart command sent by the second execution management node, the first execution management node executes the restart command to restart itself in time, cleans up the occupied system resources after the restart, and then promptly restores the management of the system process based on the process status of the system process, re-establishes the communication connection with the system process, and updates the function group status, thereby completing the restart of the first execution management node. Among them, the system resources include but are not limited to shared memory and message queues. In this way, in this embodiment, when the first execution management node crashes, the first execution management node can be promptly restarted through the second execution management node, and the restarted first execution management node can promptly restore the management of the system process, thereby improving the stability and reliability of the execution management node.
[0049] It should be noted that the system process is located in the process management node of the first software architecture; and the process management node is used to manage the system process, that is, the first execution management node manages the system process by controlling the process management node.
[0050] It should also be noted that the function group is a logical grouping, which is mainly used to control system processes with the same function; assuming that system processes 1, 2, and 3 jointly complete the automatic parking function, and system processes 4, 5, and 6 jointly complete the OTA (Over-the-Air Technology) upgrade function, since system processes 1, 2, and 3 are functionally collaborative processes, and system processes 4, 5, and 6 are functionally collaborative processes, system processes 1, 2, and 3 can be divided into the same function group, and system processes 4, 5, and 6 can be divided into the same function group. The function group state is an operating mode, which is used to indicate which system processes need to run in this operating mode.
[0051] Furthermore, the management of the system process is restored based on the process status of the system process by the first execution management node after the restart, specifically, the process agent in the first execution management node determines whether the process status reported by the system process based on the preset status reporting interface is obtained, and the tracking thread in the first execution management node is called based on the judgment result to track the system process. Among them, the process status reported by the system process includes the stop state, waiting state, ready state, start state, completion state, etc., which are all normal states. At the same time, the process status reported by the system process also includes the alarm state, error state, etc., which are all abnormal states, and the process state of the system process is mostly switched linearly.
[0052] According to one of the embodiments, if the process status reported by the system process based on the preset status reporting interface is obtained through the process agent in the first execution management node, and the process status is normal, the process status is first set to the corresponding state of the system process in the process agent, that is, the current process state of the system process is saved in the process agent based on the process status reported by the system process, and then the process identifier of the system process is sent to the tracking thread in the first execution management node, so that the tracking thread in the first execution management node tracks the system process based on the process identifier. The process identifier of the system process is an identifier corresponding to the system process found by the process agent from the autonomous driving system, and the first software architecture and the second software architecture are both located in the autonomous driving system.
[0053] According to another embodiment, if the process status reported by the system process is not obtained through the process agent in the first execution management node, or the obtained process status is an abnormal state, a process reconstruction instruction is sent to the process management node in the first software architecture, so that the process management node kills the system process and recreates a new system process, and returns the process ID of the new system process to the process agent; then the process ID of the new system process is sent to the tracking thread in the first execution management node through the process agent, so that the tracking thread tracks the new system process based on the process ID of the new system process. Among them, the process agent is mainly used to obtain the process status of the system process, start and stop the system process, create the system process, and send the process ID of the system process to the tracking thread.
[0054] It should be noted that if the first execution management node in the first software architecture obtains the state switching instruction sent by the state management node in the second software architecture based on the process state of the system process, the process management node in the first software architecture is controlled to perform corresponding state switching on the system process based on the state switching instruction; wherein, if the process state of the system process is an abnormal state, the process management node is controlled to switch the system process from an open state to a closed state, that is, the process management node is controlled to close the open system process.
[0055] Step S13: After the first execution management node is restarted, a restart success notification message and the management status of the system process are sent to the second execution management node.
[0056] In an embodiment of the present invention, after the restart is completed, the first execution management node can send a restart success notification message and the management status of the system process to the second execution management node. In addition, the first execution management node can also send its own health status to the second execution management node, thereby facilitating the second execution management node to monitor the first execution management node.
[0057] It can be seen that the present application monitors the crash of the first execution management node in the first software architecture through the second execution management node in the second software architecture, and sends a restart command to the first execution management node when it is detected that the first execution management node has crashed, so that the first execution management node can obtain and execute the restart command to restart itself and restore the management of the system process after restarting; in this way, the present application uses the first execution management node in the first software architecture as the managed node of the second execution management node in the second software architecture, so that after the managed node crashes, it can promptly control the restart of the managed node and promptly restore the management of the system process, thereby ensuring the stability and reliability of the execution management node, thereby improving the safety of autonomous driving.
[0058] Combination Figure 2 and Figure 3 As shown, an embodiment of the present invention discloses a method for restarting an execution management node, comprising:
[0059] When the second execution management node in the second software architecture detects that the first execution management node in the first software architecture crashes, the second execution management node in the second software architecture sends a restart command to the first execution management node to control the first execution management node to restart.
[0060] After the first execution management node is restarted based on the restart command, it will first clean up the occupied system resources. Assuming that the system process 1-1 reports the normal process status to the process agent in the first execution management node at this time, the process agent will set its own process status to the corresponding status of the system process 1-1 when it obtains the normal process status reported by the system process 1-1, and then send the process identifier (PID) of the system process 1-1 to the tracking thread in the first execution management node. Further, after receiving the process identifier, the tracking thread calls the process tracking function and tracks the system process 1-1 based on the process identifier; wherein, the process tracking function can use the waitpid function.
[0061] Correspondingly, after the first execution management node is restarted based on the restart command, assuming that the system process 1-2 does not report its own process status or reports an abnormal process status to the process agent in the first execution management node at this time, the process agent will send a process reconstruction instruction to the process management node in the first software architecture when it fails to obtain the process status reported by the system process 1-2 or obtains the abnormal process status reported by the system process 1-2. The process management node executes the process reconstruction instruction to send a sig signal to the system process 1-2 based on the preset process management interface manageProcesses() to kill the system process 1-2 and recreate a new system process 1-2, and then returns the process identifier of the new system process 1-2 to the process agent. Thereafter, the process agent will send the process identifier returned by the process management node to the tracking thread in the first execution management node, and the tracking thread will further track the new system process 1-2 based on the process identifier sent by the process agent. It should be noted that the preset process management interface manageProcesses() can also realize the startup and shutdown of the system process.
[0062] It should be noted that the second software architecture also includes a process management node, and the process management node in the second software architecture also includes system processes, such as system process 2-1 and system process 2-2, so that the process status reported by system process 2-1 and system process 2-2 can be obtained through the second execution management node in the second software architecture, and the system process 2-1 and system process 2-2 can be started and closed through the process management node in the second software architecture.
[0063] It should also be noted that the state management node in the second software architecture can obtain the process state of any system process in the first software architecture and the second software architecture based on the local information receiving interface receiveHealthInfo(), and determine the corresponding state switching instruction based on the process state of any system process, and send the state switching instruction to the execution management node in the software architecture to which any system process belongs through the local state switching interface changeState(). When the execution management node in the software architecture to which any system process belongs receives the state switching instruction sent by the state management node, it can control the process management node in the required software architecture based on the state switching instruction to implement the state switching of any system process.
[0064] Furthermore, the execution management node includes a process start interface startProcesses() for starting the system process and a process shutdown interface stopProcesses() for shutting down the system process, etc. Moreover, the state management node in the second software architecture also includes a process update interface updateProcesses() for updating the system process, a communication stop interface stopCommunication() for stopping communication with the system process and the execution management node, a communication start interface startCommunication() for starting communication with the system process and the execution management node, and a condition check interface checkConditons() for checking the condition of the execution management node, etc.
[0065] It can be seen that the present application monitors the crash of the first execution management node in the first software architecture through the second execution management node in the second software architecture, and sends a restart command to the first execution management node when it is detected that the first execution management node has crashed, so that the first execution management node can obtain and execute the restart command to restart itself and restore the management of the system process after restarting; in this way, the present application uses the first execution management node in the first software architecture as the managed node of the second execution management node in the second software architecture, so that after the managed node crashes, it can promptly control the restart of the managed node and promptly restore the management of the system process, thereby ensuring the stability and reliability of the execution management node, thereby improving the safety of autonomous driving.
[0066] See also Figure 4 As shown, an embodiment of the present invention discloses a method for restarting an execution management node, which is applied to a second execution management node in a second software architecture, and includes:
[0067] Step S21: performing crash monitoring on a first execution management node in a first software architecture, and after detecting that the first execution management node crashes, sending a restart command to the first execution management node, so that the first execution management node executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located in the process management node in the first software architecture;
[0068] Step S22: Obtain a restart success notification message sent by the first execution management node after the restart is completed and the management status of the system process.
[0069] In an embodiment of the present invention, the first execution management node in the first software architecture is crash-monitored by the second execution management node in the second software architecture, and after detecting that the first execution management node crashes, a restart command is sent to the first execution management node, so that the first execution management node obtains and executes the restart command to restart itself, and cleans up the occupied system resources after restarting, and then restores the management of the system process based on the process state of the system process, and re-establishes the communication connection with the system process, and updates the function group state, thereby completing the restart of the first execution management node, and after the restart is completed, a restart success notification message and the management status of the system process are sent to the second execution management node. Correspondingly, the second execution management node will obtain the restart success notification message and the management status of the system process sent by the first execution management node after the restart is completed.
[0070] It can be seen that the present application monitors the crash of the first execution management node in the first software architecture through the second execution management node in the second software architecture, and sends a restart command to the first execution management node when it is detected that the first execution management node has crashed, so that the first execution management node can obtain and execute the restart command to restart itself and restore the management of the system process after restarting; in this way, the present application uses the first execution management node in the first software architecture as the managed node of the second execution management node in the second software architecture, so that after the managed node crashes, it can promptly control the restart of the managed node and promptly restore the management of the system process, thereby ensuring the stability and reliability of the execution management node, thereby improving the safety of autonomous driving.
[0071] See also Figure 5 As shown, an embodiment of the present invention discloses a device for restarting an execution management node, which is applied to a first execution management node in a first software architecture, and includes:
[0072] A command acquisition module 11 is used to acquire a restart command sent by the second execution management node in the second software architecture after detecting that the first execution management node crashes;
[0073] A restart module 12, configured to execute the restart command to restart itself, and after restarting, restore the management of the system process based on the process state of the system process, and re-establish the communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at the process management node in the first software architecture;
[0074] The message sending module 13 is used to send a restart success notification message and the management status of the system process to the second execution management node after the first execution management node is restarted.
[0075] It can be seen that the present application monitors the crash of the first execution management node in the first software architecture through the second execution management node in the second software architecture, and sends a restart command to the first execution management node when it is detected that the first execution management node has crashed, so that the first execution management node can obtain and execute the restart command to restart itself and restore the management of the system process after restarting; in this way, the present application uses the first execution management node in the first software architecture as the managed node of the second execution management node in the second software architecture, so that after the managed node crashes, it can promptly control the restart of the managed node and promptly restore the management of the system process, thereby ensuring the stability and reliability of the execution management node, thereby improving the safety of autonomous driving.
[0076] In some specific embodiments, the restart module 12 includes:
[0077] The process tracking submodule is used to determine whether the process status reported by the system process is obtained through the process agent in the first execution management node, and call the tracking thread in the first execution management node to track the system process based on the judgment result.
[0078] In some specific embodiments, the process tracking submodule includes:
[0079] The first process tracking unit is used to set the process status to the corresponding status of the system process in the process agent if the judgment result indicates that the process agent obtains the process status reported by the system process and the process status is normal, and send the process identifier of the system process to the tracking thread, so that the tracking thread tracks the system process based on the process identifier.
[0080] In some specific embodiments, the process tracking submodule includes:
[0081] a process reconstruction unit, configured to send a process reconstruction instruction to the process management node if the judgment result indicates that the process agent has not obtained the process status reported by the system process, or the obtained process status is an abnormal state, so that the process management node kills the system process and recreates a new system process, and returns the process identifier of the new system process to the process agent;
[0082] The second process tracking unit is used to send the process identifier of the new system process to the tracking thread through the process agent, so that the tracking thread tracks the new system process based on the process identifier of the new system process.
[0083] In some specific embodiments, the execution management node restart device further includes:
[0084] a state switching unit, configured to control the process management node to perform a corresponding state switch on the system process based on the state switching instruction if a state switching instruction sent by the state management node in the second software architecture based on the process state of the system process is obtained;
[0085] If the process state is an abnormal state, the process management node is controlled to switch the system process from an open state to a closed state.
[0086] See also Figure 6 As shown, an embodiment of the present invention discloses a device for restarting an execution management node, which is applied to a second execution management node in a second software architecture, and includes:
[0087] A crash monitoring module 21 is used to perform crash monitoring on a first execution management node in a first software architecture, and after detecting that the first execution management node crashes, send a restart command to the first execution management node so that the first execution management node executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at a process management node in the first software architecture;
[0088] The message acquisition module 22 is used to acquire the restart success notification message sent by the first execution management node after the restart is completed and the management status of the system process.
[0089] Since the embodiments of the device part correspond to the above embodiments, please refer to the description of the embodiments of the method part for the embodiments of the device part, and will not be repeated here.
[0090] It can be seen that the present application monitors the crash of the first execution management node in the first software architecture through the second execution management node in the second software architecture, and sends a restart command to the first execution management node when it is detected that the first execution management node has crashed, so that the first execution management node can obtain and execute the restart command to restart itself and restore the management of the system process after restarting; in this way, the present application uses the first execution management node in the first software architecture as the managed node of the second execution management node in the second software architecture, so that after the managed node crashes, it can promptly control the restart of the managed node and promptly restore the management of the system process, thereby ensuring the stability and reliability of the execution management node, thereby improving the safety of autonomous driving.
[0091] Furthermore, the present application also discloses an electronic device. Figure 7 This is a structural diagram of an electronic device 30 according to an exemplary embodiment. The content in the diagram cannot be regarded as any limitation on the scope of use of the present application.
[0092] Figure 7 A schematic diagram of the structure of an electronic device 30 provided in an embodiment of the present application. The electronic device 30 may specifically include: at least one processor 31, at least one memory 32, a power supply 33, a communication interface 34, an input / output interface 35, and a communication bus 36. The memory 32 is used to store a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the method for restarting the execution management node disclosed in any of the aforementioned embodiments. In addition, the electronic device 30 in this embodiment may specifically be an electronic computer.
[0093] In this embodiment, the power supply 33 is used to provide working voltage for each hardware device on the electronic device 30; the communication interface 34 can create a data transmission channel between the electronic device 30 and the external device, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present application, and is not specifically limited here; the input and output interface 35 is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs and is not specifically limited here.
[0094] In addition, the memory 32, as a carrier for storing resources, can be a read-only memory, a random access memory, a disk or an optical disk, etc. The resources stored thereon can include an operating system 321, a computer program 322, etc., and the storage method can be temporary storage or permanent storage.
[0095] The operating system 321 is used to manage and control the hardware devices and computer programs 322 on the electronic device 30, which can be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program that can be used to complete the execution management node restart method executed by the electronic device 30 disclosed in any of the aforementioned embodiments, the computer program 322 can further include a computer program that can be used to complete other specific tasks.
[0096] Furthermore, the present application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, the aforementioned disclosed execution management node restart method is implemented. For the specific steps of the method, reference may be made to the corresponding contents disclosed in the aforementioned embodiments, and no further description will be given here.
[0097] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.
[0098] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0099] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0100] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0101] The technical solution provided by the present application is introduced in detail above. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for general technicians in this field, according to the idea of the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A method for restarting an execution management node, characterized in that: A first execution management node applied in a first software architecture includes: Obtaining a restart command sent by a second execution management node in a second software architecture after detecting that the first execution management node crashes; Execute the restart command to restart itself, and after restarting, restore the management of the system process based on the process state of the system process, and re-establish the communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located in the process management node in the first software architecture; After the first execution management node is restarted, a restart success notification message and the management status of the system process are sent to the second execution management node.
2. The method for restarting an execution management node according to claim 1, characterized in that: The process state-based recovery of the management of the system process includes: The process agent in the first execution management node determines whether the process status reported by the system process is obtained, and based on the determination result, calls the tracking thread in the first execution management node to track the system process.
3. The method for restarting an execution management node according to claim 2, characterized in that: The calling the tracking thread in the first execution management node to track the system process based on the judgment result includes: If the judgment result indicates that the process agent obtains the process status reported by the system process and the process status is normal, the process status is set to the corresponding status of the system process in the process agent, and the process ID of the system process is sent to the tracking thread, so that the tracking thread tracks the system process based on the process ID.
4. The method for restarting an execution management node according to claim 2, characterized in that: The calling the tracking thread in the first execution management node to track the system process based on the judgment result includes: If the judgment result indicates that the process agent has not obtained the process status reported by the system process, or the obtained process status is an abnormal state, a process reconstruction instruction is sent to the process management node so that the process management node kills the system process and recreates a new system process, and returns the process identifier of the new system process to the process agent; The process identifier of the new system process is sent to the tracking thread through the process agent, so that the tracking thread tracks the new system process based on the process identifier of the new system process.
5. The method for restarting an execution management node according to any one of claims 1 to 4, characterized in that: Also includes: If a state switching instruction sent by the state management node in the second software architecture based on the process state of the system process is obtained, controlling the process management node to perform a corresponding state switch on the system process based on the state switching instruction; If the process state is an abnormal state, the process management node is controlled to switch the system process from an open state to a closed state.
6. A method for restarting an execution management node, characterized in that: The second execution management node applied in the second software architecture includes: Perform crash monitoring on a first execution management node in a first software architecture, and after detecting that the first execution management node has crashed, send a restart command to the first execution management node, so that the first execution management node executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located in the process management node in the first software architecture; Obtain a restart success notification message sent by the first execution management node after the restart is completed and the management status of the system process.
7. A device for executing and managing node restart, characterized in that: A first execution management node applied in a first software architecture includes: A command acquisition module, used to acquire a restart command sent by a second execution management node in a second software architecture after detecting that the first execution management node crashes; a restart module, configured to execute the restart command to restart itself, and after restarting, restore the management of the system process based on the process state of the system process, and re-establish the communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at the process management node in the first software architecture; The message sending module is used to send a restart success notification message and the management status of the system process to the second execution management node after the first execution management node is restarted.
8. A device for executing and managing node restart, characterized in that: The second execution management node applied in the second software architecture includes: A crash monitoring module, configured to perform crash monitoring on a first execution management node in a first software architecture, and after detecting that the first execution management node has crashed, send a restart command to the first execution management node, so that the first execution management node executes the restart command to restart itself, and after restarting, restores the management of the system process based on the process state of the system process, and re-establishes a communication connection with the system process to complete the restart of the first execution management node; wherein the system process is located at a process management node in the first software architecture; The message acquisition module is used to obtain the restart success notification message sent by the first execution management node after the restart is completed and the management status of the system process.
9. An electronic device, characterized in that: include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the method for restarting an execution management node as described in any one of claims 1 to 6.
10. A computer-readable storage medium, characterized in that: Used to store a computer program, which, when executed by a processor, implements the execution management node restart method according to any one of claims 1 to 6.
