CN103747034A - Terminal state-machine state conversion method and device - Google Patents
Terminal state-machine state conversion method and device Download PDFInfo
- Publication number
- CN103747034A CN103747034A CN201310712480.XA CN201310712480A CN103747034A CN 103747034 A CN103747034 A CN 103747034A CN 201310712480 A CN201310712480 A CN 201310712480A CN 103747034 A CN103747034 A CN 103747034A
- Authority
- CN
- China
- Prior art keywords
- state
- terminal
- execution
- conversion
- state machine
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Landscapes
- Information Transfer Between Computers (AREA)
- Computer And Data Communications (AREA)
Abstract
The embodiment of the invention discloses a terminal state-machine state conversion method. The method includes: a control terminal sends a control message for state-machine state conversion to all execution terminals according to the execution state of each execution terminal; the control terminal receives state information fed back by each execution terminal, wherein the state information is execution state information fed back by the execution terminals after performing state-machine state conversion according to the control message; the control terminal updates the execution state of each execution terminal according to the state information fed back by each execution terminal so as to send next control message for state-machine state conversion to all the execution terminals according to updated execution state of each execution terminal. The embodiment of the invention also discloses a device for state-machine station conversion. Specific advantages in adoption of the terminal state-machine state conversion method and device are that terminal state-machine state conversion efficiency can be improved and system reliability and user experience effects can be enhanced.
Description
Technical field
The present invention relates to communication technical field, relate in particular to a kind of method and device of state machine state conversion of terminal.
Background technology
In large-scale cluster distributed system, between each node when system is executed the task in system, exist dependence, when system is executed the task, must guarantee that all XM all complete current task and just can issue next task, system must guarantee that the state conversion that all XM have all completed state machine just can enter next state.For example, when group system executive system upgrade function, generally need several steps: before the upgrading of legacy version, check, the unloading of legacy version, the download of redaction, redaction is installed, redaction startup etc., if above-mentioned each step is set as to a state, in group system, XM in system is carried out in the process of upgrade function in system, need to carry out the state conversion of different conditions, for example, XM is carried out in the process of upgrade function in system, the state that state machine checks before need to the upgrading by legacy version is converted to the unloading of legacy version, unloading by legacy version is converted to download of redaction etc., the to the last upgrading of a state ability completion system.In system, carry out in the process of upgrade function, all XM in cluster could be carried out second state after all carrying out first state that is over, only have all XM all the conversion of completion status just can make whole group system be successfully completed the conversion of state.
In prior art, be mainly by client, to connect the control node of cluster, by controlling node, issue the control command of state machine state conversion, control each XM and carry out state machine state conversion.Control the control command of first state being changed when node plays a task (being converted to the second state by the first state) and be handed down to first node in group system, after this node completion status conversion, notice control node is finished, control node and again conversion command is handed down to second node, after being finished, this node controls node again to the 3rd node transmitting order to lower levels, so circulation is until after all nodes all execute state conversion, controls node and from first node, starts to issue again the conversion command of the state conversion of next task.In prior art, the serial of the order of each state conversion that control node sends in each XM of system carried out, and total duration when system is executed the task can increase along with the expansion of cluster scale, and execution efficiency is low.In addition, in the prior art, in order to guarantee to control the reliability of node failure, controlling node also will be synchronized to the execution result of each XM in each XM by other a piece of news, controlling node is separated to the control command of XM transmission and the state synchronization message of XM, the reliability of controlling node is low, the transmission meeting of state synchronization message strengthens difficulty along with the expansion of cluster scale, cause control node messages congested, make the state conversion efficiency of SOT state of termination low, user's experience effect is poor.
Summary of the invention
Embodiment of the present invention technical problem to be solved is, a kind of method of state machine state conversion of terminal is provided, and can improve the state conversion efficiency of state machine, and the reliability and the user that improve system experience.
Embodiment of the present invention first aspect provides a kind of method of state machine state conversion of terminal, and it can comprise:
The executing state that control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Described in described control terminal receives, respectively carry out the state information of terminal feedback, described state information is that described execution terminal is carried out the execution state information of feeding back after state machine state conversion according to described control message;
Described control terminal is according to the executing state of respectively carrying out terminal described in the described state information updating of respectively carrying out terminal feedback, to send the next control message of state machine state conversion to all described execution terminals according to the described executing state of respectively carrying out terminal after upgrading.
In conjunction with first aspect, in the possible implementation of the first, in the control message of described state machine conversion, also comprise: the execution object that carries out state conversion according to the status word in described control message;
Wherein, described execution object is to carry out terminal described at least one in described all described execution terminals.
In conjunction with first aspect or the possible implementation of first aspect the first, in the possible implementation of the second, the described executing state of respectively carrying out terminal comprises: describedly respectively carry out the residing state of terminal current state machine and describedly respectively carry out the implementation progress that terminal is carried out state machine state conversion.
In conjunction with the possible implementation of first aspect the second, in the third possible implementation, the executing state that described control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals, comprising:
Described control terminal judges that according to the described residing state of terminal current state machine of respectively carrying out whether all described execution terminal current state machines are in same state;
If described all described execution terminal current state machines are all in same state, according to the described terminal of carrying out described in each, carry out the implementation progress of state machine state conversion and judge the whether completion status machine state conversion of described all described execution terminals;
If described all described execution terminals are completion status machine state conversion all, to described all described execution terminals, issue the first status word of state machine state conversion, if there is the described execution terminal of unfinished state machine state conversion in described all described execution terminals, to described all described execution terminals, issue the second status word of state machine state conversion;
If the same state in described all described execution terminal current state machine places, issues to described all described execution terminals the second status word that state machine state is changed.
In conjunction with first aspect in the third possible implementation of first aspect any, in the 4th kind of possible implementation, in the control message of described state machine state conversion, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
The executing state that described control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals, comprising:
The executing state that described control terminal is carried out terminal according to each sends status word and the node hierarchy information of state machine state conversion to all described execution terminals, respectively to carry out terminal described in indicating, carry out state machine state conversion, and respectively carry out the next stage that terminal manages described in described control message is handed down to and carry out terminal by the described terminal of respectively carrying out.
Embodiment of the present invention second aspect provides a kind of method of state machine state conversion of terminal, and it can comprise:
Carry out the control message that terminal receives the state machine state conversion that control terminal sends, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Described execution terminal judges whether the conversion of executing state machine state according to the state of described status word and described execution terminal current state machine;
If the determination result is YES, according to described status word, carry out state machine state conversion, and to described control terminal feedback execution state information;
If the determination result is NO, to described control terminal feedback execution state information.
In conjunction with second aspect, in the possible implementation of the first, described execution terminal comprises to the described execution state information of described control terminal feedback: the residing state of described execution terminal current state machine, and the described execution terminal implementation progress of carrying out state machine state conversion.
In conjunction with first aspect or the possible implementation of first aspect the first, in the possible implementation of the second, described execution terminal judges whether the conversion of executing state machine state according to the state of described status word and described execution terminal current state machine, comprising:
Described execution terminal compares the described status word receiving from the described control terminal status word corresponding with the residing state of described execution terminal current state machine, and whether the status word receiving described in judgement is greater than status word corresponding to the residing state of described state machine;
If the determination result is YES, executing state machine state conversion;
If the determination result is NO, not executing state machine state conversion.
In conjunction with second aspect in the possible implementation of second aspect the second any, in the third possible implementation, in the control message that described execution terminal receives from described control terminal, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
After the control message of the state machine state conversion that described execution terminal reception control terminal sends, described method also comprises:
The next stage that described execution terminal is managed according to the described execution terminal of indicating in described node hierarchy information is carried out the information of terminal, sends the described control information receiving from described control terminal to execution terminal that described execution terminal is managed.
The embodiment of the present invention third aspect provides a kind of control terminal of state machine state conversion, it can comprise: sending module, for carrying out the executing state of terminal, send the control message of state machine state conversion to all described execution terminals, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion according to each;
Receiver module, for respectively carrying out the state information of terminal feedback described in receiving, to be described execution terminal carry out the execution state information of feedback after state machine state conversion according to described control message to described state information;
Update module, for according to the executing state of respectively carrying out terminal described in the described state information updating of respectively carrying out terminal feedback, to send the next control message of state machine state conversion by described sending module to all described execution terminals according to the described executing state of respectively carrying out terminal after upgrading.
In conjunction with the third aspect, in the possible implementation of the first, in the control message of the described state machine conversion that described sending module sends, also comprise: the execution object that carries out state conversion according to the status word in described control message;
Wherein, described execution object is to carry out terminal described at least one in described all described execution terminals.
In conjunction with the third aspect or the possible implementation of third aspect the first, in the possible implementation of the second, the described executing state of respectively carrying out terminal comprises: describedly respectively carry out the residing state of terminal current state machine and describedly respectively carry out the implementation progress that terminal is carried out state machine state conversion.
In conjunction with the possible implementation of third aspect the second, in the third possible implementation, described sending module, comprising:
The first judging unit, for judging that according to the described residing state of terminal current state machine of respectively carrying out whether all described execution terminal current state machines are in same state;
Whether the second judging unit, while for judgment result is that at described the first judging unit being, carrying out the implementation progress of state machine state conversion and judge the completion status machine state conversion of described all described execution terminals according to the described terminal of carrying out described in each;
Transmitting element, while for judgment result is that at described the second judging unit being, issues the first status word of state machine state conversion to described all described execution terminals;
Described transmitting element, when the determination result is NO at described the second judging unit, issues the second status word of state machine state conversion to described all described execution terminals;
Described transmitting element, also when the determination result is NO at described the first judging unit, issues the second status word of state machine state conversion to described all described execution terminals.
In conjunction with the third aspect in the third possible implementation of the third aspect any, in the 4th kind of possible implementation, in the control message of the described state machine state conversion that described sending module sends, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
Described sending module, specifically for:
The executing state that described control terminal is carried out terminal according to each sends status word and the node hierarchy information of state machine state conversion to all described execution terminals, respectively to carry out terminal described in indicating, carry out state machine state conversion, and respectively carry out the next stage that terminal manages described in described control message is handed down to and carry out terminal by the described terminal of respectively carrying out.
Embodiment of the present invention fourth aspect provides a kind of execution terminal of state machine state conversion, and it can comprise:
Receiver module, for receiving the control message of the state machine state conversion that control terminal sends, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Judge module, judges whether the conversion of executing state machine state for the state of the described status word that receives according to described receiver module and described execution terminal current state machine;
Processing module, while for judgment result is that at described judge module being, the described status word receiving according to described receiver module is carried out state machine state conversion;
Feedback module, for after described processing module is carried out state machine state conversion, to described control terminal feedback execution state information;
Described feedback module, when at described judge module, the determination result is NO, to described control terminal feedback execution state information.
In conjunction with fourth aspect, in the possible implementation of the first, described feedback module comprises to the described execution state information of described control terminal feedback: the residing state of described execution terminal current state machine, and the described execution terminal implementation progress of carrying out state machine state conversion.
In conjunction with fourth aspect or the possible implementation of fourth aspect the first, in the possible implementation of the second, described judge module specifically for:
The status word that the described status word receiving from described control terminal is corresponding with the residing state of described execution terminal current state machine compares, and whether the status word receiving described in judgement is greater than status word corresponding to the residing state of described state machine;
If the determination result is YES, judge the conversion of executing state machine state;
If the determination result is NO, judge not executing state machine state conversion.
In conjunction with fourth aspect to the possible implementation of fourth aspect the second, in the third possible implementation, in the control message that described receiver module receives, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
Described execution terminal, also comprises:
Sending module, the next stage of managing for the described execution terminal of indicating according to described node hierarchy information is carried out the information of terminal, sends the described control information receiving from described control terminal to execution terminal that described execution terminal is managed.
In embodiments of the present invention, the executing state that control terminal can be carried out terminal according to each transmits control message to all execution terminals, by this control message, indicate execution terminal to carry out state machine state conversion, also can receive execution terminal and according to above-mentioned control message, carry out the execution state information of feeding back after state machine state conversion, and upgrade according to the execution state information of each execution terminal feedback the executing state that each carries out terminal, and then according to the executing state of the execution terminal after upgrading, issue the control message of next state machine state conversion.In embodiments of the present invention, it is parallel transmission that the control message of state machine state conversion is carried out in terminal at each, each is carried out terminal and can executed in parallel state machine state changes and feed back executing state, can improve the efficiency of state machine state conversion, improve the reliability of control terminal, the user who strengthens the state machine state conversion of terminal experiences.
Accompanying drawing explanation
In order to be illustrated more clearly in the technical scheme in the embodiment of the present invention, below the accompanying drawing of required use during embodiment is described is briefly described, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skills, do not paying under the prerequisite of creative work, can also obtain according to these accompanying drawings other accompanying drawing.
Fig. 1 is the first embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention;
Fig. 2 is the second embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention;
Fig. 3 is the node structure schematic diagram in second embodiment of method of state machine state conversion of the terminal that provides of the embodiment of the present invention;
Fig. 4 is another node structure schematic diagram in second embodiment of method of state machine state conversion of the terminal that provides of the embodiment of the present invention;
Fig. 5 is the first example structure schematic diagram of the control terminal of the state machine state conversion that provides of the embodiment of the present invention;
Fig. 6 is the second example structure schematic diagram of the control terminal of the state machine state conversion that provides of the embodiment of the present invention;
Fig. 7 is the 3rd embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention;
Fig. 8 is the 4th embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention;
Fig. 9 is the first example structure schematic diagram of the execution terminal of the state machine state conversion that provides of the embodiment of the present invention;
Figure 10 is the second example structure schematic diagram of the execution terminal of the state machine state conversion that provides of the embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the present invention's part embodiment, rather than whole embodiment.Embodiment based in the present invention, those of ordinary skills, not making the every other embodiment obtaining under creative work prerequisite, belong to the scope of protection of the invention.
In specific implementation, terminal described in the embodiment of the present invention can comprise the control terminal of state machine state conversion and carry out terminal, wherein, above-mentioned control terminal (also claiming to control node) and execution terminal (also claiming XM) form all nodes of distributed cluster system, it is the corresponding terminal of each node in distributed cluster system, this terminal can be control terminal, also can be execution terminal.In specific implementation, user can be according to predefined election regulation, from terminal corresponding to all nodes of group system, choose a terminal as the control terminal of the SOT state of termination machine state conversion of group system, in order to the execution terminal to group system, send the control message of state machine state conversion.Concrete, from all terminals of group system, elect a terminal as after control terminal, other terminal is for carrying out terminal; In addition, in the process that group system is being executed the task, when the control terminal that above-mentioned user chooses sends fault, system also can be chosen according to predefined selection rule one and carry out terminal as new control terminal from above-mentioned execution terminal, in order to carry out the task of control terminal, wherein, any one is carried out terminal and is all likely chosen for control terminal, specifically can determine according to predefined rule.In specific implementation, the control terminal of distributed cluster system and carry out terminal and specifically can be computer described in the embodiment of the present invention.
Referring to Fig. 1, it is the first embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention.The method of the state machine state conversion of the terminal described in the present embodiment, comprises step:
S101, the executing state that control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals.
S102, respectively carries out the state information of terminal feedback described in described control terminal receives.
S103, described control terminal is according to the executing state of respectively carrying out terminal described in the described state information updating of respectively carrying out terminal feedback, to send the next control message of state machine state conversion to all described execution terminals according to the described executing state of respectively carrying out terminal after upgrading.
In some feasible execution modes, the control terminal described in the embodiment of the present invention comprises being used to indicate to the control message of carrying out the state machine state conversion that terminal sends carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset status word corresponding to above-mentioned each state, for example, the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., control terminal need to be carried out terminal and carry out state machine state when conversion, can send to all execution terminals the status word of state machine state conversion, for example, when carrying out terminal in the first state, when if control terminal need to be carried out terminal and is converted to the second state from the first state, can send status word B to carrying out terminal, carry out terminal and receive the state conversion that status word B can carry out state machine afterwards.
In some feasible execution modes, when control terminal starts to send the control message of state machine state conversion to execution terminal, because all execution terminals all also do not start to carry out the state conversion of state machine, therefore all residing states of execution terminal current state machine should be the first state, control terminal can directly transmit control message to all execution terminals according to each initial condition of carrying out terminal in system, be that control terminal can directly send status word B to all execution terminals, be used to indicate all execution terminals the state of state machine is converted to the second state from the first state.In specific implementation, after execution terminal receives the control message of control terminal transmission, can carry out state machine state conversion according to the status word in control message, and the executing state of state machine state conversion is fed back to control terminal, wherein, the executing state of above-mentioned state machine state conversion comprises the implementation progress that the residing state of current state machine and state machine carry out state conversion.For example, after execution terminal 1 receives the status word B of control terminal transmission, carry out 1, terminal and the state of its state machine can be converted to the second state from the first state, and the executing state of state machine state conversion can be fed back to control terminal.Concrete, can preset control terminal to the time interval of carrying out the control message of terminal transmission state machine state conversion, be that control terminal can regularly transmit control message to carrying out terminal, and control terminal is carried out the status word in terminal determines this transmission control message according to the executing state of the control message executing state conversion sending last time to carrying out the terminal Shi Junke that transmits control message according to each at every turn.While transmitting control message to execution terminal due to control terminal, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out after terminal receives the control message that control terminal sends and carry out state machine state conversion, to the time interval of control terminal feedback execution state information, so that control terminal is grasped the executing state that each carries out terminal more exactly.For example, after execution terminal 1 receives status word B and carries out state machine state conversion, can be on default feedback time interval to control terminal feedback, carry out the executing state that terminal be carried out state machine state conversion, comprise that carrying out the residing state of terminal 1 current state machine (for example the second state) and execution terminal 1 carries out the implementation progress of state machine state conversion (for example 50%).
In some feasible execution modes, after control terminal receives each state information of carrying out terminal feedback, can carry out according to each executing state of each execution terminal of state information updating of terminal feedback, to send the next control message of state machine state conversion to all execution terminals according to each executing state of carrying out terminal after upgrading.In specific implementation, for example, when control terminal does not receive the state information of any one execution terminal (carrying out terminal 1) feedback within the predefined time, control terminal can preset carries out terminal 1 in short-duration failure state, the executing state that can keep carrying out terminal 1 when now control terminal upgrades the executing state that each carries out terminal is constant, and then the executing state of carrying out terminal according to each issues to all execution terminals the control message that sent last time again.After if control terminal repeatedly (comprises at least 2 times) control message that issues transmission last time, within the default time interval, also do not receive the state information of carrying out terminal 1 feedback, can judge and carry out terminal 1 in malfunction or disconnected, being control terminal described in the embodiment of the present invention also can have the function of heartbeat detection to carrying out the control message that terminal issues, and can whether carry out terminal in normal connection status according to the situation judgement of carrying out terminal feedback state information.In specific implementation, control terminal can receive after execution terminal sends next control message carries out terminal according to the state information of feedback after this control message executing state conversion, and then again upgrade according to the state information receiving the executing state that each carries out terminal, according to each executing state of carrying out terminal after upgrading, to each, carry out terminal again and issue next control message, so circulation is until all execution terminals execute all state machine state conversions.When all execution terminals execute all state conversions, group system can complete the upgrading of software.
In embodiments of the present invention, control terminal can send the control message of state machine state conversion simultaneously to all execution terminals, indication is carried out terminal and is carried out state machine state conversion, and each carries out the executing state of terminal according to the state information updating of all execution terminal feedbacks, be control command and the state synchronization unification of the state machine state conversion described in the present embodiment, improve control terminal and eliminated the reliability of scene extremely such as sequential and fault, improved the execution efficiency of state machine state conversion; Control terminal described in the present embodiment also can judge and whether carry out terminal in normal connection status according to the execution state information of carrying out the whether normal feedback states machine state conversion of terminal, further guaranteed the execution efficiency of state machine state conversion, the efficiency that has improved the SOT state of termination machine state conversion of system, has strengthened system availability and user and has experienced.
Referring to Fig. 2, it is the second embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention.The method of the state machine state conversion of the terminal described in the present embodiment, comprises step:
S201, control terminal sends the initial status word of state machine state conversion to all execution terminals.
In some feasible execution modes, the control terminal described in the embodiment of the present invention comprises being used to indicate to the control message of carrying out the state machine state conversion that terminal sends carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset status word corresponding to above-mentioned each state, for example, the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., control terminal need to be carried out terminal and carry out state machine state when conversion, can send to all execution terminals the status word of state machine state conversion, for example, when carrying out terminal in the first state, when if control terminal need to be carried out terminal and is converted to the second state from the first state, can send status word B to carrying out terminal, carry out terminal and receive the state conversion that status word B can carry out state machine afterwards.
In some feasible execution modes, when control terminal starts to send the control message of state machine state conversion to execution terminal, because all execution terminals all also do not start to carry out the state conversion of state machine, therefore all residing states of execution terminal current state machine should be the first state, control terminal can be according to each initial condition of carrying out terminal in system directly to all execution terminals transmit control message (being that control terminal can directly send to all execution terminals the initial status word that state machine state be changed), be that control terminal can directly send status word B to all execution terminals, be used to indicate all execution terminals the state of state machine is converted to the second state from the first state.
S202, respectively carries out the state information of terminal feedback described in described control terminal receives.
S203, described control terminal is according to the executing state of respectively carrying out terminal described in the described state information updating of respectively carrying out terminal feedback.
In some feasible execution modes, in the control message that control terminal sends to all execution terminals, also can comprise: the execution object that carries out state conversion according to the status word in above-mentioned control message, in fact, above-mentioned execution object specifically can be in execution terminals all in system any one or a plurality of.The practical application request that is the control terminal function that can will realize according to system (carrying out of task) determines whether to need execution terminals all in system all to need to carry out state machine state conversion, or needs specifically which to carry out terminal by and carry out this function (concrete which execution terminal need to be carried out state machine state conversion).In specific implementation, for example in system, carry out, after terminal (carrying out terminal 1) receives the control message that control terminal sends, can first according to the execution object in control message, judge whether to carry out state machine state conversion, when carrying out terminal 1, according to the control message judgement receiving, learn that the execution object in control message comprises execution terminal 1, carry out 1, terminal and can carry out state machine state conversion according to the status word in control message, if judgement is learnt the execution object in control message and is not comprised execution terminal 1, carry out 1, terminal and do not carry out state machine state conversion.Concrete, when 1 judgement of execution terminal learns that need to carry out state machine state changes, after 1, terminal of execution can be carried out state machine state according to the status word in control message, and the executing state of state machine state conversion is fed back to control terminal; When 1 judgement of execution terminal learns that not needing to carry out state machine state changes, can directly to control terminal feedback, carry out the state of terminal 1 current state machine.Wherein, the executing state of above-mentioned state machine state conversion comprises the implementation progress that the residing state of current state machine and state machine carry out state conversion.For example, after execution terminal 1 receives the status word B of control terminal transmission, carry out 1, terminal and the state of its state machine can be converted to the second state from the first state, and the executing state of state machine state conversion can be fed back to control terminal.Concrete, can preset control terminal to the time interval of carrying out the control message of terminal transmission state machine state conversion, be that control terminal can regularly transmit control message to carrying out terminal, and control terminal is carried out the status word in terminal determines this transmission control message according to the executing state of the control message executing state conversion sending last time to carrying out the terminal Shi Junke that transmits control message according to each at every turn.While transmitting control message to execution terminal due to control terminal, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out after terminal receives the control message that control terminal sends and carry out state machine state conversion, to the time interval of control terminal feedback execution state information, so that control terminal is grasped the executing state that each carries out terminal more exactly.For example, after execution terminal 1 receives status word B and carries out state machine state conversion, can be on default feedback time interval to control terminal feedback, carry out the executing state that terminal be carried out state machine state conversion, comprise that carrying out the residing state of terminal 1 current state machine (for example the second state) and execution terminal 1 carries out the implementation progress of state machine state conversion (for example 50%).
In some feasible execution modes, after control terminal receives each state information of carrying out terminal feedback, can carry out according to each executing state of each execution terminal of state information updating of terminal feedback.
S204, judges that all described execution terminal current state machines, whether in same state, if the determination result is YES, perform step S205, if the determination result is NO, performs step S207.
S205, whether the implementation progress of carrying out state machine state conversion according to each execution terminal judges the completion status machine state conversion of all execution terminals, if the determination result is YES, performs step S206, if the determination result is NO, performs step S207.
S206, issues the first status word of state machine state conversion, and returns to step S202 to described all execution terminals, continue to carry out above-mentioned steps.
S207, issues the second status word of state machine state conversion, and returns to step S202 to described all execution terminals, continue to carry out up step.
In some feasible execution modes, after control terminal receives each state information of carrying out terminal feedback, can carry out according to each executing state of each execution terminal of state information updating of terminal feedback, to send the next control message of state machine state conversion to all execution terminals according to each executing state of carrying out terminal after upgrading.In specific implementation, after control terminal upgrades each executing state of carrying out terminal, when control terminal will send next control message to all execution terminals, the status word of the state machine state conversion that can issue according to each Determines of carrying out terminal after upgrading.Concrete, the residing state of each execution terminal current state machine that control terminal can be carried out terminal feedback according to each judges whether all execution terminal current state machines are in same state (whether all execution terminals have all been carried out state conversion), if judgement learns that all execution terminal current state machines are all in same state, can judge and learn that all execution terminals have all successfully carried out state conversion, and then can carry out terminal according to each and carry out the implementation progress of state machine state conversion and judge whether whether all execution terminals have all completed state machine state conversion.For example, in the state information of all execution terminal feedbacks, show that all execution terminals carry out the implementation progress of state machine state conversion and be 100%, can judge and learn that all execution terminals have all completed the state conversion of state machine, now, control terminal can send to all execution terminals first status word (the first status word described in the embodiment of the present invention specifically can be status word corresponding to next state that state machine need to be carried out) of state machine state conversion; In the state information of feeding back, show the execution terminal of unfinished state machine state conversion in all execution terminals, in all execution terminals, there is one or more implementation progress of carrying out terminal not reach 100%, can judge and learn and carry out in addition terminal unfinished state machine state conversion, now, control terminal can send to all execution terminals second status word (the second status word described in the embodiment of the present invention specifically can be the status word corresponding to state of the current execution of state machine) of state machine state conversion.When control terminal judgement learns that according to the state information judgement of all execution terminal feedbacks not every execution terminal is all in same state, exist indivedual terminals of carrying out also in Last status, and not successfully proceed to state corresponding to status word in the control message that control terminal sends, now, control terminal can send to all execution terminals the second status word of state machine state conversion.In specific implementation, control terminal can receive after execution terminal sends next control message carries out terminal according to the state information of feedback after this control message executing state conversion, and then again upgrade according to the state information receiving the executing state that each carries out terminal, according to each executing state of carrying out terminal after upgrading, to each, carry out terminal again and issue next control message, so circulation is until all execution terminals execute all state machine state conversions.When all execution terminals execute all state conversions, group system can complete the upgrading of software.The control command of the state machine state conversion described in the present embodiment and state synchronization unification, improved control terminal and eliminated the reliability of scene extremely such as sequential and fault, improved the execution efficiency of state machine state conversion.
In some feasible execution modes, control terminal has been set each and has been carried out terminal after the time interval of control terminal feedback states information, control terminal also can according to carry out terminal whether within the default time interval successful feedback information judge that whether this execution terminal is in normal connection status.For example, for example, when control terminal does not receive the state information of any one execution terminal (carrying out terminal 1) feedback within the predefined time, control terminal can preset carries out terminal 1 in short-duration failure state, the executing state that can keep carrying out terminal 1 when now control terminal upgrades the executing state that each carries out terminal is constant, and then the executing state of carrying out terminal according to each issues to all execution terminals the control message that sent last time again.After if control terminal repeatedly (comprises at least 2 times) control message that issues transmission last time, within the default time interval, also do not receive the state information of carrying out terminal 1 feedback, can judge and carry out terminal 1 in malfunction or disconnected, being control terminal described in the embodiment of the present invention also can have the function of heartbeat detection when carrying out the control message that terminal issues, can whether carry out terminal in normal connection status according to the situation judgement of carrying out terminal feedback state information, further guaranteed the execution efficiency of state machine state conversion, having strengthened system availability and user experiences.
In some feasible execution modes, in the control message that control terminal described in the invention process sends to execution terminal, also can comprise: node hierarchy information, above-mentioned node hierarchy information comprises the residing node grade of each execution terminal, or the next stage that each execution terminal is managed is carried out the information of terminal, wherein, the information of above-mentioned next stage execution terminal comprises: next stage is carried out the number of terminal and the sign of each execution terminal etc.In specific implementation, when group system larger, in order to guarantee that system has higher reliabilty and availability, all nodes in system can be carried out to classification, (as Fig. 3) such as one-level node, two-level node, three grades of nodes, and set carrying out terminal, to carry out the transmission rule of the control message that state machine state changes be the control message of higher leveled node to node (being the next stage node of its management) the transfer control node transmission of its next stage, wherein one-level node grade is higher than two-level node, and the grade of two-level node is higher than three grades of nodes etc.Set the node grade under each execution terminal in system, or after the next stage that each execution terminal is managed is carried out the information of terminal, control terminal sends status word and the node hierarchy information of state machine state conversion to all execution terminals executing state that Shi Zeke carries out terminal according to each that transmits control message to all execution terminals, by above-mentioned status word, indicate each to carry out terminal and carry out state machine state conversion, and by the corresponding terminal of carrying out of above-mentioned node hierarchy information indication, control information is handed down to the next stage execution terminal that this execution terminal is managed.As Fig. 3, if system comprises 7 nodes, can pre-define control terminal is one-level node, and define 2 two-level nodes, two three grades of nodes of each two-level node management, control terminal can transmit control message to two-level node (for example message 1), and message 1 comprises that two-level node need to carry out the information that next stage that the status word of state machine state conversion and the residing node grade of two-level node (being secondary) and two-level node manage is carried out terminal (three grades of nodes).Two-level node can issue the control message (for example message 2) that control terminal sends to three grades of nodes after receiving message 1, and message 2 comprises that three grades of nodes need to carry out the information of the next stage execution terminal (0) that the status word of state machine state conversion and three grades of residing node grades of node (three grades) and three grades of nodes manage.In specific implementation, each execution terminal can and be fed back corresponding state information to control terminal according to the status word executing state machine state conversion in control message after receiving control message.Concrete, as Fig. 3, three grades of nodes can be by status information feedback to two-level node (as message 4), after two-level node receives the message of three grades of nodes transmissions, can need to feed back to control terminal feedack to control terminal corresponding state information (as message 3) in conjunction with himself, the executing state of the next stage of the executing state of himself and management thereof being carried out to terminal feeds back to control terminal, and control terminal can be known according to two-level node feedack the executing state of all execution terminals in system.
In some feasible execution modes, the embodiment of the present invention, by the method for system node classification, makes system can support arbitrary node fault, the reliability of safeguards system.As Fig. 4, for example, when arbitrary node in system (one-level node) breaks down, system also can, according to predefined selection rule, be chosen new one-level node, the task of taking over former one-level node from all two-level nodes.For example, when some two-level nodes do not receive the message of one-level node within the default time interval, this two-level node can be chosen for to new one-level node, by this new one-level node, to other nodes, transmit control message, guarantee the normal operation of system.The embodiment of the present invention adopts the method for system node classification, by even higher level of node to photos and sending messages under next stage node or obtain the state information of next stage node by even higher level of node, can reduce the congested of node messages, solve the node messages bottleneck problem of large-scale cluster system, improved the efficiency of SOT state of termination machine state conversion of system and the reliability of system, the availability and the user that have strengthened system experience.
In embodiments of the present invention, control terminal can send the control message of state machine state conversion simultaneously to all execution terminals, indication is carried out terminal and is carried out state machine state conversion, and each carries out the executing state of terminal according to the state information updating of all execution terminal feedbacks, be control command and the state synchronization unification of the state machine state conversion described in the present embodiment, improve control terminal and eliminated the reliability of scene extremely such as sequential and fault, improved the execution efficiency of state machine state conversion; Control terminal described in the present embodiment also can judge and whether carry out terminal in normal connection status according to the execution state information of carrying out the whether normal feedback states machine state conversion of terminal, node hierarchy that also can back-up system, further guaranteed the execution efficiency of state machine state conversion, improved the efficiency of SOT state of termination machine state conversion of system and the reliability of large-scale cluster system, strengthened system availability and user and experienced.
Referring to Fig. 5, it is the first example structure schematic diagram of the control terminal of the state machine state conversion that provides of the embodiment of the present invention.Control terminal described in the present embodiment, comprising:
Sending module 10 sends the control message of state machine state conversion for carrying out the executing state of terminal according to each to all described execution terminals, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion.
In some feasible execution modes, the sending module 10 of the control terminal described in the embodiment of the present invention comprises being used to indicate to the control message of carrying out the state machine state conversion that terminal sends carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset the status word that above-mentioned each state is corresponding and be stored in control terminal, for example, can preset the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., control terminal need to be carried out terminal and carry out state machine state when conversion, can to all execution terminals, send by sending module 10 status word of state machine state conversion, for example, when carrying out terminal in the first state, when if control terminal need to be carried out terminal and is converted to the second state from the first state, can to carrying out terminal, send status word B by sending module 10, carry out terminal and receive the state conversion that status word B can carry out state machine afterwards.
In some feasible execution modes, when control terminal, need to carry out terminal and carry out state machine state conversion, and start when carrying out terminal and send the control message of state machine state conversion by sending module 10, because now all execution terminals all also do not start to carry out the state conversion of state machine, therefore all residing states of execution terminal current state machine should be the first state, control terminal can directly transmit control message to all execution terminals according to each initial condition of carrying out terminal in system, be that sending module 10 can directly send status word B to all execution terminals, be used to indicate all execution terminals the state of state machine is converted to the second state from the first state.In specific implementation, after execution terminal receives the control message of control terminal transmission, can carry out state machine state conversion according to the status word in control message, and the executing state of state machine state conversion is fed back to control terminal, wherein, the executing state of above-mentioned state machine state conversion comprises the implementation progress that the residing state of current state machine and state machine carry out state conversion.For example, after execution terminal 1 receives the status word B of control terminal transmission, carry out 1, terminal and the state of its state machine can be converted to the second state from the first state, and the executing state of state machine state conversion can be fed back to control terminal.Concrete, can preset sending module 10 to the time interval of carrying out the control message of terminal transmission state machine state conversion, be that control terminal can regularly transmit control message to carrying out terminal by sending module 10, and sending module 10 is carried out the status word in terminal determines this transmission control message according to the executing state of the control message executing state conversion sending last time to carrying out the terminal Shi Junke that transmits control message according to each at every turn.While transmitting control message to execution terminal due to sending module 10, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out after terminal receives the control message that control terminal sends and carry out state machine state conversion, to the time interval of control terminal feedback execution state information, so that control terminal is grasped the executing state that each carries out terminal more exactly.For example, after execution terminal 1 receives status word B and carries out state machine state conversion, can be on default feedback time interval to control terminal feedback, carry out the executing state that terminal be carried out state machine state conversion, comprise that carrying out the residing state of terminal 1 current state machine (for example the second state) and execution terminal 1 carries out the implementation progress of state machine state conversion (for example 50%).
In some feasible execution modes, after control terminal receives each state information of carrying out terminal feedback by receiver module 20,30 of update module can be carried out according to each executing state of each execution terminal of state information updating of terminal feedback, and each executing state of carrying out terminal after sending module 10 can upgrade according to update module 30 sends the next control message of state machine state conversion to all execution terminals.In specific implementation, for example, when the receiver module 20 of control terminal does not receive the state information of any one execution terminal (carrying out terminal 1) feedback within the predefined time, control terminal can preset carries out terminal 1 in short-duration failure state, the executing state that can keep carrying out terminal 1 when now the update module 20 of control terminal is upgraded the executing state that each carries out terminal is constant, and then the executing state of carrying out terminal according to each by sending module 30 issues to all execution terminals the control message that sent last time again.After if sending module more than 10 time (comprising at least 2 times) issues the control message sending last time, receiver module 20 does not also receive the state information of carrying out terminal 1 feedback within the default time interval, control terminal can judge to be carried out terminal 1 in malfunction or has disconnected, control terminal described in the embodiment of the present invention that hence one can see that also can have the function of heartbeat detection when carrying out the control message that terminal issues, and can whether carry out terminal in normal connection status according to the situation judgement of carrying out terminal feedback state information.In specific implementation, control terminal by sending module 10 to carrying out after terminal sends next control message, receiver module 20 can receive carries out terminal according to the state information of feedback after this control message executing state conversion, and then the state information receiving according to receiver module 20 by update module 30 is upgraded the executing state that each carries out terminal again, sending module 10 is carried out terminal according to each executing state of carrying out terminal after upgrading to each again and is issued next control message, so circulation is until all execution terminals execute all state machine state conversions.When all execution terminals execute all state conversions, group system can complete the upgrading of software.
In embodiments of the present invention, control terminal can send the control message of state machine state conversion simultaneously to all execution terminals, indication is carried out terminal and is carried out state machine state conversion, and each carries out the executing state of terminal according to the state information updating of all execution terminal feedbacks, be control command and the state synchronization unification of the state machine state conversion described in the present embodiment, improve control terminal and eliminated the reliability of scene extremely such as sequential and fault, improved the execution efficiency of state machine state conversion; Control terminal described in the present embodiment also can judge and whether carry out terminal in normal connection status according to the execution state information of carrying out the whether normal feedback states machine state conversion of terminal, further guaranteed the execution efficiency of state machine state conversion, the efficiency that has improved the SOT state of termination machine state conversion of system, has strengthened system availability and user and has experienced.
Referring to Fig. 6, it is the second example structure schematic diagram of the control terminal of the state machine state conversion that provides of the embodiment of the present invention.Control terminal described in the present embodiment, comprising:
Sending module 40 sends the control message of state machine state conversion for carrying out the executing state of terminal according to each to all described execution terminals, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion.
In some feasible execution modes, above-mentioned sending module 40, comprising:
The first judging unit 41, for judging that according to the described residing state of terminal current state machine of respectively carrying out whether all described execution terminal current state machines are in same state;
Whether the second judging unit 42, while for judgment result is that at described the first judging unit being, carrying out the implementation progress of state machine state conversion and judge the completion status machine state conversion of described all described execution terminals according to the described terminal of carrying out described in each;
Transmitting element 43, while for judgment result is that at described the second judging unit being, issues the first status word of state machine state conversion to described all described execution terminals;
Described transmitting element 43, when the determination result is NO at described the second judging unit, issues the second status word of state machine state conversion to described all described execution terminals;
Described transmitting element 43, also when the determination result is NO at described the first judging unit, issues the second status word of state machine state conversion to described all described execution terminals.
In some feasible execution modes, the sending module 40 of the control terminal described in the embodiment of the present invention comprises being used to indicate to the control message of carrying out the state machine state conversion that terminal sends carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset the status word that above-mentioned each state is corresponding and be stored in control terminal, for example, can preset the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., control terminal need to be carried out terminal and carry out state machine state when conversion, can to all execution terminals, send by sending module 40 status word of state machine state conversion, for example, when carrying out terminal in the first state, when if control terminal need to be carried out terminal and is converted to the second state from the first state, can to carrying out terminal, send status word B by sending module 40, carry out terminal and receive the state conversion that status word B can carry out state machine afterwards.
In some feasible execution modes, when control terminal, want to carry out terminal and carry out state machine state conversion, and start by sending module 40 when carrying out terminal and send the control message of state machine state conversion, because now all execution terminals all also do not start to carry out the state conversion of state machine, therefore all residing states of execution terminal current state machine should be the first state, control terminal can be according to each initial condition of carrying out terminal in system directly to all execution terminals transmit control message (being that sending module 40 can directly send to all execution terminals the initial status word that state machine state be changed), be that sending module 40 can directly send status word B to all execution terminals, be used to indicate all execution terminals the state of state machine is converted to the second state from the first state.
In some feasible execution modes, in the control message that the sending module 40 of control terminal sends to all execution terminals, also can comprise: the execution object that carries out state conversion according to the status word in above-mentioned control message, in fact, above-mentioned execution object specifically can be in execution terminals all in system any one or a plurality of.The practical application request that is the control terminal function that can will realize according to system (carrying out of task) determines whether to need execution terminals all in system all to need to carry out state machine state conversion, or needs specifically which to carry out terminal by and carry out this function (concrete which execution terminal need to be carried out state machine state conversion).In specific implementation, for example in system, carry out, after terminal (carrying out terminal 1) receives the control message that control terminal sends, can first according to the execution object in control message, judge whether to carry out state machine state conversion, when carrying out terminal 1, according to the control message judgement receiving, learn that the execution object in control message comprises execution terminal 1, carry out 1, terminal and can carry out state machine state conversion according to the status word in control message, if judgement is learnt the execution object in control message and is not comprised execution terminal 1, carry out 1, terminal and do not carry out state machine state conversion.Concrete, when 1 judgement of execution terminal learns that need to carry out state machine state changes, after 1, terminal of execution can be carried out state machine state according to the status word in control message, and the executing state of state machine state conversion is fed back to control terminal; When 1 judgement of execution terminal learns that not needing to carry out state machine state changes, can directly to control terminal feedback, carry out the state of terminal 1 current state machine.Wherein, the executing state of above-mentioned state machine state conversion comprises the implementation progress that the residing state of current state machine and state machine carry out state conversion.For example, after execution terminal 1 receives the status word B of control terminal transmission, carry out 1, terminal and the state of its state machine can be converted to the second state from the first state, and the executing state of state machine state conversion can be fed back to control terminal.Concrete, can preset the sending module 40 of control terminal to the time interval of carrying out the control message of terminal transmission state machine state conversion, be that sending module 40 can regularly transmit control message to carrying out terminal, and sending module 40 is carried out the status word in terminal determines this transmission control message according to the executing state of the control message executing state conversion sending last time to carrying out the terminal Shi Junke that transmits control message according to each at every turn.While transmitting control message to execution terminal due to sending module 40, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out after terminal receives the control message that control terminal sends and carry out state machine state conversion, to the time interval of control terminal feedback execution state information, so that control terminal is grasped the executing state that each carries out terminal more exactly.For example, after execution terminal 1 receives status word B and carries out state machine state conversion, can be on default feedback time interval to control terminal feedback, carry out the executing state that terminal be carried out state machine state conversion, comprise that carrying out the residing state of terminal 1 current state machine (for example the second state) and execution terminal 1 carries out the implementation progress of state machine state conversion (for example 50%).
In some feasible execution modes, after control terminal receives each state information of carrying out terminal feedback by receiver module 20,30 of update module can be carried out according to each executing state of each execution terminal of state information updating of terminal feedback.After the receiver module 20 of control terminal receives each state information of carrying out terminal feedback, 30 of update module can be carried out according to each executing state of each execution terminal of state information updating of terminal feedback, and sending module 40 can send the next control message of state machine state conversion according to each executing state of carrying out terminal after upgrading to all execution terminals.In specific implementation, after control terminal upgrades each executing state of carrying out terminal by update module 30, when control terminal will send next control message to all execution terminals, the status word of the state machine state conversion that each Determines of carrying out terminal after 40 of sending modules can upgrade according to update module 30 issues.Concrete, each residing state of each execution terminal current state machine of carrying out terminal feedback that the first judging unit 41 of sending module 40 can receive according to receiver module 20 judges whether all execution terminal current state machines are in same state (whether all execution terminals have all been carried out state conversion), if the first judging unit 41 judgements learn that all execution terminal current state machines are all in same state, can judge and learn that all execution terminals have all successfully carried out state conversion, the second 42 of judging units can be carried out terminal according to each and carry out the implementation progress of state machine state conversion and judge whether whether all execution terminals have all completed state machine state conversion.For example, in learning the state information of all execution terminal feedbacks, the second judging unit 41 judgement shows that all execution terminals carry out the implementation progress of state machine state conversion and be 100%, can judge and learn that all execution terminals have all completed the state conversion of state machine, now, control terminal can send first status word (the first status word described in the embodiment of the present invention specifically can be status word corresponding to next state that state machine need to be carried out) of state machine state conversion by the transmitting element 43 of sending module 40 to all execution terminals, when the execution terminal that shows the conversion of unfinished state machine state in the state information of feeding back in all execution terminals is learnt in the second judging unit 41 judgements, in all execution terminals, there is one or more implementation progress of carrying out terminal not reach 100%, can judge and learn and carry out in addition terminal unfinished state machine state conversion, now, control terminal can send by transmitting element 43 second status word (the second status word described in the embodiment of the present invention specifically can be the status word corresponding to state of the current execution of state machine) of state machine state conversion to all execution terminals.When the first judging unit 41 judgements learn that according to the state information judgement of all execution terminal feedbacks not every execution terminal is all in same state, exist indivedual terminals of carrying out also in Last status, and not successfully proceed to state corresponding to status word in the control message that control terminal sends, now, by 43 of transmitting elements, can send to all execution terminals the second status word of state machine state conversion.In specific implementation, sending module 40 is after execution terminal sends next control message, receiver module 20 can receive carries out the rear state information of feeding back of control message executing state conversion that terminal sends according to sending module 40, the state information that update module 30 can receive according to receiver module 20 is upgraded each executing state of carrying out terminal again, each executing state of carrying out terminal after sending module 40 can upgrade according to update module 30 is carried out terminal to each and is issued next control message, so circulation is until all execution terminals execute all state machine state conversions.When all execution terminals execute all state conversions, group system can complete the upgrading of software.The control command of the state machine state conversion that the control terminal described in the present embodiment sends and state synchronization unification, can improve the reliability that control terminal is eliminated the abnormal scene such as sequential and fault, improved the execution efficiency of state machine state conversion.
In some feasible execution modes, control terminal has been set each and has been carried out terminal after the time interval of control terminal feedback states information, also can according to carry out terminal whether within the default time interval successful feedback information judge that whether this execution terminal is in normal connection status.For example, for example, when receiver module 20 does not receive the state information of any one execution terminal (carrying out terminal 1) feedback within the predefined time, control terminal can preset carries out terminal 1 in short-duration failure state, the executing state that can keep carrying out terminal 1 when now the update module 30 of control terminal is upgraded the executing state that each carries out terminal is constant, and then the executing state of carrying out terminal in conjunction with each by sending module 40 issues to all execution terminals the control message that sent last time again.After if control terminal issues by sending module more than 40 time (comprising at least 2 times) control message sending last time, receiver module 20 does not also receive the state information of carrying out terminal 1 feedback within the default time interval, can judge and carry out terminal 1 in malfunction or disconnected, being control terminal described in the embodiment of the present invention also can have the function of heartbeat detection to carrying out the control message that terminal issues, can whether carry out terminal in normal connection status according to the situation judgement of carrying out terminal feedback state information, further guaranteed the execution efficiency of state machine state conversion, having strengthened system availability and user experiences.
In some feasible execution modes, in the control message of the described state machine state conversion that above-mentioned sending module 40 sends, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
Described sending module, also specifically for:
The executing state that described control terminal is carried out terminal according to each sends status word and the node hierarchy information of state machine state conversion to all described execution terminals, respectively to carry out terminal described in indicating, carry out state machine state conversion, and respectively carry out the next stage that terminal manages described in described control message is handed down to and carry out terminal by the described terminal of respectively carrying out.
In some feasible execution modes, in the control message that control terminal described in the invention process sends to execution terminal by sending module 40, also can comprise: node hierarchy information, above-mentioned node hierarchy information comprises the residing node grade of each execution terminal, or the next stage that each execution terminal is managed is carried out the information of terminal, wherein, the information of above-mentioned next stage execution terminal comprises: next stage is carried out the number of terminal and the sign of each execution terminal etc.In specific implementation, when group system larger, in order to guarantee that system has higher reliabilty and availability, all nodes in system can be carried out to classification, (as Fig. 3) such as one-level node, two-level node, three grades of nodes, and set carrying out terminal, to carry out the transmission rule of the control message that state machine state changes be the control message of higher leveled node to node (being the next stage node of its management) the transfer control node transmission of its next stage, wherein one-level node grade is higher than two-level node, and the grade of two-level node is higher than three grades of nodes etc.Set the node grade under each execution terminal in system, or after the next stage that each execution terminal is managed is carried out the information of terminal, sending module 40 sends status word and the node hierarchy information of state machine state conversion to all execution terminals executing state that Shi Zeke carries out terminal according to each that transmits control message to all execution terminals, by above-mentioned status word, indicate each to carry out terminal and carry out state machine state conversion, and by the corresponding terminal of carrying out of above-mentioned node hierarchy information indication, control information is handed down to the next stage execution terminal that this execution terminal is managed.As Fig. 3, if system comprises 7 nodes, can pre-define control terminal is one-level node, and define 2 two-level nodes, two three grades of nodes of each two-level node management, control terminal can transmit control message (for example message 1) to two-level node by sending module 40, and message 1 comprises that two-level node need to carry out the information that next stage that the status word of state machine state conversion and the residing node grade of two-level node (being secondary) and two-level node manage is carried out terminal (three grades of nodes).Two-level node can issue the control message (for example message 2) that control terminal sends to three grades of nodes after receiving message 1, and message 2 comprises that three grades of nodes need to carry out the information of the next stage execution terminal (0) that the status word of state machine state conversion and three grades of residing node grades of node (three grades) and three grades of nodes manage.In specific implementation, each execution terminal can and be fed back corresponding state information to control terminal according to the status word executing state machine state conversion in control message after receiving control message.Concrete, as Fig. 3, three grades of nodes can be by status information feedback to two-level node (as message 4), after two-level node receives the message of three grades of nodes transmissions, can need to feed back to control terminal feedack to control terminal corresponding state information (as message 3) in conjunction with himself, the executing state of the next stage of the executing state of himself and management thereof being carried out to terminal feeds back to control terminal, and control terminal can be known according to two-level node feedack the executing state of all execution terminals in system.
In some feasible execution modes, the embodiment of the present invention, by the method for system node classification, makes system can support arbitrary node fault, the reliability of safeguards system.As Fig. 4, (the one-level node for example of arbitrary node in system, be the control terminal described in the embodiment of the present invention) while breaking down, system also can be according to predefined selection rule, from all two-level nodes, choose new one-level node, take over the task of former one-level node, serve as the responsibility of the control terminal described in the embodiment of the present invention.For example, when some two-level nodes do not receive the message of one-level node (control terminal) within the default time interval, this two-level node can be chosen for to new one-level node, by this new one-level node, to other nodes, transmit control message, guarantee the normal operation of system.The residing group system of the described control terminal of the embodiment of the present invention adopts the method for system node classification, by even higher level of node to photos and sending messages under next stage node or obtain the state information of next stage node by even higher level of node, can reduce the congested of node messages, solve the node messages bottleneck problem of large-scale cluster system, improved the efficiency of SOT state of termination machine state conversion of system and the reliability of system, the availability and the user that have strengthened system experience.
Control terminal described in the embodiment of the present invention can send the control message of state machine state conversion simultaneously to all execution terminals, indication is carried out terminal and is carried out state machine state conversion, and each carries out the executing state of terminal according to the state information updating of all execution terminal feedbacks, be control command and the state synchronization unification of the state machine state conversion described in the present embodiment, improve control terminal and eliminated the reliability of scene extremely such as sequential and fault, improved the execution efficiency of state machine state conversion; Control terminal described in the present embodiment also can judge and whether carry out terminal in normal connection status according to the execution state information of carrying out the whether normal feedback states machine state conversion of terminal, node hierarchy that also can back-up system, further guaranteed the execution efficiency of state machine state conversion, improved the efficiency of SOT state of termination machine state conversion of system and the reliability of large-scale cluster system, strengthened system availability and user and experienced.
Referring to Fig. 7, it is the 3rd embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention.The method of the state machine state conversion of the terminal described in the present embodiment, comprises step:
S301, carries out the control message that terminal receives the state machine state conversion of control terminal transmission.
S302, described execution terminal judges whether the conversion of executing state machine state according to the state of described status word and described execution terminal current state machine, if the determination result is YES, performs step S303, if the determination result is NO, performs step S304.
S303, carries out state machine state conversion according to described status word, and to described control terminal feedback execution state information.
S304, to described control terminal feedback execution state information.
In some feasible execution modes, execution terminal described in the embodiment of the present invention is the terminal except control terminal in all terminals that in group system, all nodes are corresponding, carry out terminal and can from control terminal, obtain control message, according to the indication executing state machine state conversion of control message, realize the corresponding function of system.In specific implementation, the control message of the state machine state conversion that receiving terminal sends in real time when carrying out terminal in normal operation state, the control message of the state machine state conversion that wherein, above-mentioned execution terminal receives from control terminal comprises being used to indicate carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset status word corresponding to above-mentioned each state, for example, the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., control terminal need to be carried out terminal and carry out state machine state when conversion, can send to all execution terminals the status word of state machine state conversion, execution terminal receives the status word of control terminal transmission can carry out state machine state conversion afterwards, the state of state machine is converted to state corresponding to above-mentioned status word.
In some feasible execution modes, after execution terminal receives the control message of control terminal transmission, the status word that can comprise according to above-mentioned control message and the residing state of execution terminal current state machine judge whether the conversion of executing state machine state.For example, when carrying out terminal in the first state, if when carrying out terminal and receiving status word that control message that control terminal sends comprises and be status word B, can judge and learn when control terminal need to be carried out terminal and is converted to the second state from the first state, carry out terminal and receive the state conversion that status word B can carry out state machine afterwards, the state of state machine is converted to the second state from the first state, and the execution state information of changing to control terminal feedback states machine state.When carrying out terminal in the second state, if when carrying out terminal and receiving status word that control message that control terminal sends comprises and be status word B (because control terminal is to issue control message according to the executing state of carrying out terminal, when control terminal receives the state information of carrying out terminal feedback, carry out terminal also in carrying out the stage of state conversion, implementation progress does not also reach 100%, therefore control terminal issues status word B to current execution terminal), can judge and learn that control terminal need to carry out terminal and proceed state conversion, the state of state machine is converted to the second state, carry out terminal and receive the state conversion that status word B can proceed state machine afterwards, the state of state machine is converted to the second state, and the execution state information of changing to control terminal feedback states machine state.In specific implementation, technology contents described in the first embodiment of the method for the state machine state conversion of the terminal providing according to the invention described above embodiment is known, control terminal can regularly transmit control message to carrying out terminal, when control terminal transmits control message to execution terminal, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out terminal to the time interval of control terminal feedback execution state information, and by control message, the time interval of feedback be sent to execution terminal.Carry out terminal according to after the state conversion of the control message executing state machine of control terminal transmission, the execution state information that can change to control terminal feedback states machine state within the predefined time interval, control terminal can upgrade the executing state of carrying out terminal according to the execution state information of carrying out terminal feedback, to grasp more accurately the state of carrying out terminal.For example, after execution terminal receives status word B and carries out state machine state conversion, can be on default feedback time interval to control terminal feedback, carry out the executing state that terminal be carried out state machine state conversion, comprise that carrying out the residing state of terminal current state machine (for example the second state) and execution terminal carries out the implementation progress of state machine state conversion (for example 50%).
In embodiments of the present invention, carry out terminal and can receive in real time the control message that control terminal sends, the status word of the state machine state conversion comprising according to control message, in conjunction with the state of carrying out terminal current state machine, carry out the state conversion of state machine, and to control terminal feedback execution state information.Carrying out in embodiments of the present invention terminal can carry out state machine state conversion and feed back execution state information according to the control message of control terminal transmission, can improve and carry out the efficiency that terminal is carried out state machine state conversion, and the user of enhanced situation machine state conversion experiences.
Referring to Fig. 8, it is the 4th embodiment schematic flow sheet of method of the state machine state conversion of the terminal that provides of the embodiment of the present invention.The method of the state machine state conversion of the terminal described in the present embodiment, comprises step:
S401, carries out the control message that terminal receives the state machine state conversion of control terminal transmission.
In some feasible execution modes, execution terminal described in the embodiment of the present invention is the terminal except control terminal in all terminals that in group system, all nodes are corresponding, carry out terminal and can from control terminal, obtain control message, according to the indication executing state machine state conversion of control message, realize the corresponding function of system.In specific implementation, the control message of the state machine state conversion that receiving terminal sends in real time when carrying out terminal in normal operation state, the control message of the state machine state conversion that wherein, above-mentioned execution terminal receives from control terminal comprises being used to indicate carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset status word corresponding to above-mentioned each state, for example, the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., also can preset the size of each status word, for carrying out terminal, carry out the judgement of status word size and determine according to judged result whether executing state machine state is changed, for example, because A is the status word of the first state, B is the status word of the second state, execution terminal need to complete the first state and just can be converted to the second state, complete the second state and just can be converted to the third state etc., so can set the status word B that the status word A of the first state is less than the second state, the status word B of the second state is less than the status word C of the third state, and set D according to above-mentioned rule, E, the magnitude relationship of F, can set above-mentioned 6 status word A, B, C, D, E, in F, A is minimum, F maximum etc.Control terminal need to be carried out terminal and carry out state machine state when conversion, can send to all execution terminals the status word of state machine state conversion, the status word that execution terminal receives control terminal transmission can judge whether to carry out state machine state conversion with the magnitude relationship of the status word receiving according to status word corresponding to the current state of state machine afterwards, judgement is learnt in the time of need to carrying out state machine state conversion and the state of state machine is converted to state corresponding to status word receiving, do not need to carry out state machine state conversion and keep current state.
S402, described execution terminal compares the described status word receiving from the described control terminal status word corresponding with the residing state of described execution terminal current state machine.
S403, whether the status word receiving described in judgement is greater than status word corresponding to the residing state of described state machine, if the determination result is YES, performs step S404, if the determination result is NO, performs step S405.
S404, carries out state machine state conversion according to described status word, and to described control terminal feedback execution state information.
S405, to described control terminal feedback execution state information.
In some feasible execution modes, after execution terminal receives the control message of control terminal transmission, the status word that can comprise according to above-mentioned control message and the residing state of execution terminal current state machine judge whether the conversion of executing state machine state.Concrete, carrying out terminal can compare the status word the receiving status word corresponding with carrying out the residing state of terminal current state machine, whether the status word that judgement receives is greater than status word corresponding to the residing state of state machine, if being greater than, the status word receiving carries out status word corresponding to the terminal residing state of current state machine, can judge and learn that control terminal need to carry out terminal and switch to next state by carrying out the current state machine state of terminal, carry out the conversion of terminal executing state machine state; If the status word receiving equals to carry out status word corresponding to the residing state of terminal current state machine, can judge the conversion (may carry out the conversion of terminal last state does not also carry out to 100%) of learning that control terminal need to be carried out terminal and continues current state, until implementation progress is 100%, now carry out not executing state machine state conversion of terminal, but continue to carry out current task.For example, when carrying out terminal in the first state, if when carrying out terminal and receiving status word that control message that control terminal sends comprises and be status word B, can judge and learn when control terminal need to be carried out terminal and is converted to the second state from the first state, carry out terminal and receive the state conversion that status word B can carry out state machine afterwards, the state of state machine is converted to the second state from the first state, and the execution state information of changing to control terminal feedback states machine state.When carrying out terminal in the second state, if when carrying out terminal and receiving status word that control message that control terminal sends comprises and be status word B (because control terminal is to issue control message according to the executing state of carrying out terminal, when control terminal receives the state information of carrying out terminal feedback, carry out terminal also in carrying out the stage of state conversion, implementation progress does not also reach 100%, therefore control terminal issues status word B to current execution terminal), can judge and learn that control terminal need to carry out terminal and continue the conversion of last round of state, the state of state machine is converted to the second state, carry out terminal and receive the state conversion that status word B can continue last round of state machine afterwards, the state of state machine is converted to the second state completely, and the execution state information of changing to control terminal feedback states machine state.In specific implementation, technology contents described in the first embodiment of the method for the state machine state conversion of the terminal providing according to the invention described above embodiment is known, control terminal can regularly transmit control message to carrying out terminal, when control terminal transmits control message to execution terminal, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out terminal to the time interval of control terminal feedback execution state information, and by control message, the time interval of feedback be sent to execution terminal.Carry out terminal according to after the state conversion of the control message executing state machine of control terminal transmission, the execution state information that can change to control terminal feedback states machine state within the predefined time interval, control terminal can upgrade the executing state of carrying out terminal according to the execution state information of carrying out terminal feedback, to grasp more accurately the state of carrying out terminal.In specific implementation, above-mentioned execution terminal comprises to the described execution state information of described control terminal feedback: carry out the residing state of terminal current state machine, and carry out the implementation progress that terminal is carried out state machine state conversion.For example, after execution terminal receives status word B and carries out state machine state conversion, can be on default feedback time interval to control terminal feedback, carry out the executing state that terminal be carried out state machine state conversion, comprise that carrying out the residing state of terminal current state machine (for example the second state) and execution terminal carries out the implementation progress of state machine state conversion (for example 50%).
In some feasible execution modes, in the control message that execution terminal described in the invention process receives from control terminal, also can comprise: node hierarchy information, above-mentioned node hierarchy information comprises the residing node grade of each execution terminal, or the next stage that each execution terminal is managed is carried out the information of terminal, wherein, the information of above-mentioned next stage execution terminal comprises: next stage is carried out the number of terminal and the sign of each execution terminal etc.In specific implementation, when group system larger, in order to guarantee that system has higher reliabilty and availability, the cluster at the execution terminal place described in can the embodiment of the present invention carries out classification by all nodes in system, one-level node for example, two-level node, three grades of nodes etc. (as Fig. 3), and set carrying out terminal, to carry out the transmission rule of the control message that state machine state changes be the control message of higher leveled node to node (being the next stage node of its management) the transfer control node transmission of its next stage, wherein one-level node grade is higher than two-level node, the grade of two-level node is higher than three grades of nodes etc.Set the node grade under each execution terminal in system, or after the next stage that each execution terminal is managed is carried out the information of terminal, control terminal sends status word and the node hierarchy information of state machine state conversion to all execution terminals executing state that Shi Zeke carries out terminal according to each that transmits control message to all execution terminals, by above-mentioned status word, indicate each to carry out terminal and carry out state machine state conversion, and by the corresponding terminal of carrying out of above-mentioned node hierarchy information indication, control information is handed down to the next stage execution terminal that this execution terminal is managed.As Fig. 3, if system comprises 7 nodes, can pre-define control terminal is one-level node, and define 2 two-level nodes, two three grades of nodes of each two-level node management, control terminal can transmit control message to two-level node (for example message 1), and message 1 comprises that two-level node need to carry out the information that next stage that the status word of state machine state conversion and the residing node grade of two-level node (being secondary) and two-level node manage is carried out terminal (three grades of nodes).Execution terminal in two-level node can issue to the execution terminal in three grades of nodes the control message (for example message 2) that control terminal sends after receiving message 1, message 2 comprises that the execution terminal in three grades of nodes need to carry out the information of the next stage execution terminal (0) that the status word of state machine state conversion and the residing node grade of this executions terminal (three grades) and this execution terminal manage.
In specific implementation, the above-mentioned control message that execution terminal receives control terminal transmission can and feed back corresponding state information to control terminal according to the status word executing state machine state conversion in control message afterwards.Concrete, as Fig. 3, if above-mentioned execution terminal is in three grades of nodes, can be by status information feedback the execution terminal to two-level node (as message 4), after the execution terminal of two-level node receives the message of above-mentioned execution terminal transmission, can need to feed back to control terminal feedack to control terminal corresponding state information (as message 3) in conjunction with himself, the executing state of the next stage of the executing state of himself and management thereof being carried out to terminal (as the execution terminal described in the present embodiment) feeds back to control terminal, control terminal can be known according to two-level node feedack the executing state of all execution terminals in system.
In some feasible execution modes, the embodiment of the present invention, by the method for system node classification, makes system can support arbitrary node fault, the reliability of safeguards system.As Fig. 4, for example, when arbitrary node in system (one-level node) breaks down, system also can, according to predefined selection rule, be chosen new one-level node, the task of taking over former one-level node from all two-level nodes.For example, for example, when the execution terminal described in the present embodiment (in Fig. 4 from left to right first two-level node) does not receive the message of one-level node within the default time interval, above-mentioned execution terminal can be served as new one-level node and transmit control message to other nodes, guarantees the normal operation of system.The embodiment of the present invention adopts the method for system node classification, the current terminal of carrying out terminal served as occurs when abnormal at control terminal, also can serve as control terminal, exercise the right of control terminal, carry out the task of control terminal, improved the efficiency of SOT state of termination machine state conversion of system and the reliability of system, the availability and the user that have strengthened system experience.
In embodiments of the present invention, carry out terminal and can receive in real time the control message that control terminal sends, the status word of the state machine state conversion comprising according to control message, in conjunction with the state of carrying out terminal current state machine, carry out the state conversion of state machine, and to control terminal feedback execution state information; Carry out terminal and also can send the control message of control terminal transmission the execution terminal of the next stage of its management to, and can when control terminal sends fault, serve as control terminal, carry out the task dispatching of control terminal.Carrying out in embodiments of the present invention terminal can carry out state machine state conversion and feed back execution state information according to the control message of control terminal transmission, the control message also can transfer control terminal sending or serve as control terminal, can improve and carry out the efficiency that terminal is carried out state machine state conversion, the user of enhanced situation machine state conversion experiences, the reliability and stability of safeguards system, the availability and the user that improve system experience.
Referring to Fig. 9, it is the first example structure schematic diagram of the execution terminal of the state machine state conversion that provides of the embodiment of the present invention.Execution terminal described in the present embodiment, comprising:
Described feedback module 80, when at described judge module, the determination result is NO, to described control terminal feedback execution state information.
In some feasible execution modes, execution terminal described in the embodiment of the present invention is the terminal except control terminal in all terminals that in group system, all nodes are corresponding, carry out terminal and can from control terminal, obtain control message, according to the indication executing state machine state conversion of control message, realize the corresponding function of system.In specific implementation, when carrying out terminal in normal operation state, receiver module 50 can receive the control message of the state machine state conversion of control terminal transmission in real time, the control message of the state machine state conversion that wherein, the receiver module 50 of above-mentioned execution terminal receives from control terminal comprises being used to indicate carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset status word corresponding to above-mentioned each state, for example, the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., control terminal need to be carried out terminal and carry out state machine state when conversion, can send to all execution terminals the status word of state machine state conversion, the status word that execution terminal receives control terminal transmission by receiver module 50 can be carried out state machine state conversion afterwards, the state of state machine is converted to state corresponding to above-mentioned status word.
In some feasible execution modes, after the receiver module 50 of execution terminal receives the control message of control terminal transmission, 60 status words that can comprise according to above-mentioned control message of judge module and the residing state of execution terminal current state machine judge whether the conversion of executing state machine state.For example, when carrying out terminal in the first state, if judge module 60 judgement is learnt when receiver module 50 receives status word that control message that control terminal sends comprises and is status word B, can judge and learn when control terminal need to be carried out terminal and is converted to the second state from the first state, execution terminal receives the state that can carry out state machine by processing module 70 after status word B and changes, the state of state machine is converted to the second state from the first state, and the execution state information of changing to control terminal feedback states machine state by feedback module 80.When carrying out terminal in the second state, if judge module 60 judgement is learnt when carrying out terminal receives status word that control message that control terminal sends comprises and be status word B (because control terminal is to issue control message according to the executing state of carrying out terminal, when control terminal receives the state information of carrying out terminal feedback, carry out terminal also in carrying out the stage of state conversion, implementation progress does not also reach 100%, therefore control terminal issues status word B to current execution terminal), can judge and learn that control terminal need to carry out terminal and proceed state conversion, the state of state machine is converted to the second state, carrying out terminal receives after status word B the state that can proceed state machine by processing module 70 and changes, the state of state machine is converted to the second state, and the execution state information of changing to control terminal feedback states machine state by feedback module 80.In specific implementation, control terminal can regularly transmit control message to carrying out terminal, when control terminal transmits control message to execution terminal, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out terminal to the time interval of control terminal feedback execution state information, control terminal can send to execution terminal by the time interval of feedback by control message.After the state conversion of the control message executing state machine that the control terminal that the processing module 70 of execution terminal receives according to receiver module 50 sends, the execution state information that can change to control terminal feedback states machine state by feedback module 80 within the predefined time interval, control terminal can upgrade the executing state of carrying out terminal according to the execution state information of carrying out terminal feedback, to grasp more accurately the state of carrying out terminal.For example, after execution terminal receives status word B and carries out state machine state conversion, 80 of feedback modules can carry out to control terminal feedback the executing states that terminal be carried out state machine state conversion on default feedback time interval, comprise that carrying out the residing state of terminal current state machine (for example the second state) and execution terminal carries out the implementation progress of state machine state conversion (for example 50%).
Execution terminal described in the embodiment of the present invention can receive the control message that control terminal sends in real time, the status word of the state machine state conversion comprising according to control message, in conjunction with the state of carrying out terminal current state machine, carry out the state conversion of state machine, and to control terminal feedback execution state information.The control message that execution terminal described in the embodiment of the present invention can send according to control terminal carries out state machine state conversion and feeds back execution state information, can improve the efficiency of state machine state conversion, and the user of enhanced situation machine state conversion experiences.
Referring to Figure 10, it is the second example structure schematic diagram of the execution terminal of the state machine state conversion that provides of the embodiment of the present invention.Execution terminal described in the present embodiment, comprising:
Described feedback module 80, when at described judge module, the determination result is NO, to described control terminal feedback execution state information.
In some feasible execution modes, above-mentioned judge module 61, specifically for:
The status word that the described status word receiving from described control terminal is corresponding with the residing state of described execution terminal current state machine compares, and whether the status word receiving described in judgement is greater than status word corresponding to the residing state of described state machine;
If the determination result is YES, judge the conversion of executing state machine state;
If the determination result is NO, judge not executing state machine state conversion.
In some feasible execution modes, execution terminal described in the embodiment of the present invention is the terminal except control terminal in all terminals that in group system, all nodes are corresponding, carry out terminal and can from control terminal, obtain control message, according to the indication executing state machine state conversion of control message, realize the corresponding function of system.In specific implementation, can when carrying out terminal in normal operation state, receiver module 50 can receive the control message of the state machine state conversion of control terminal transmission in real time, the control message of the state machine state conversion that wherein, the receiver module 50 of above-mentioned execution terminal receives from control terminal comprises being used to indicate carries out the status word that terminal is carried out state machine state conversion.For example, group system is when the function of software upgrade, need to complete following step: before the upgrading of legacy version software, detect, the unloading of legacy version software, the download of new version software, the installation of new version software, the startup of new version software and checking etc., above-mentioned each step is defined as to a state, be in the whole process of software upgrading, the SOT state of termination machine of system need to carry out front detect (referred to as first state) of upgrading of above-mentioned legacy version software, the unloading of legacy version software (referred to as the second state), the download of new version software (referred to as the third state), the installation of new version software (referred to as the 4th state), the conversion of the states such as the startup of new version software (referred to as the 5th state) and checking (referred to as the 6th state).In specific implementation, can preset status word corresponding to above-mentioned each state, for example, the status word that the first state is corresponding is A, the status word that the second state is corresponding is B, status word corresponding to the third state is C, the status word that the 4th state is corresponding is D, the status word that the 5th state is corresponding is E, the status word that the 6th state is corresponding is F etc., also can preset the size of each status word, for carrying out terminal, carry out the judgement of status word size and determine according to judged result whether executing state machine state is changed, for example, because A is the status word of the first state, B is the status word of the second state, execution terminal need to complete the first state and just can be converted to the second state, complete the second state and just can be converted to the third state etc., so can set the status word B that the status word A of the first state is less than the second state, the status word B of the second state is less than the status word C of the third state, and set D according to above-mentioned rule, E, the magnitude relationship of F, can set above-mentioned 6 status word A, B, C, D, E, in F, A is minimum, F maximum etc.Control terminal need to be carried out terminal and carry out state machine state when conversion, can send to all execution terminals the status word of state machine state conversion, the status word that execution terminal receives control terminal transmission by receiver module 50 can judge whether to carry out state machine state conversion with the magnitude relationship of the status word receiving according to status word corresponding to the current state of state machine afterwards, judgement learns that need to carry out state machine state when conversion is converted to the state of state machine state corresponding to status word receiving, do not need to carry out state machine state conversion and keep current state.
In some feasible execution modes, after the receiver module 50 of execution terminal receives the control message of control terminal transmission, 61 status words that can comprise according to above-mentioned control message of judge module and the residing state of execution terminal current state machine judge whether the conversion of executing state machine state.Concrete, judge module 61 can compare the status word the receiving status word corresponding with carrying out the residing state of terminal current state machine, whether the status word that judgement receives is greater than status word corresponding to the residing state of state machine, if being greater than, the status word receiving carries out status word corresponding to the terminal residing state of current state machine, can judge and learn that control terminal need to carry out terminal and switch to next state by carrying out the current state machine state of terminal, carry out terminal and can change by processing module 70 executing state machine states; If judge module 61 judgements learn that the status word that receiver module 50 receives equals to carry out status word corresponding to the residing state of terminal current state machine, can judge the conversion (may carry out the conversion of terminal last state does not also carry out to 100%) of learning that control terminal need to be carried out terminal and continues current state, until implementation progress is 100%, now 70 not executing state machine state conversions of processing module, but continue to carry out current task.For example, when carrying out terminal in the first state, if judge module 61 judgement is learnt when receiver module 50 receives status word that control message that control terminal sends comprises and is status word B, can judge and learn when control terminal need to be carried out terminal and is converted to the second state from the first state, after the receiver module 50 of execution terminal receives status word B, 70 of processing modules can be carried out the state conversion of state machine, the state of state machine is converted to the second state from the first state, and the execution state information of changing to control terminal feedback states machine state by feedback module 80.When carrying out terminal in the second state, if judge module 61 judgement is learnt when receiver module 50 receives status word that control message that control terminal sends comprises and is status word B (because control terminal is to issue control message according to the executing state of carrying out terminal, when control terminal receives the state information of carrying out terminal feedback, carry out terminal also in carrying out the stage of state conversion, implementation progress does not also reach 100%, therefore control terminal issues status word B to current execution terminal), can judge and learn that control terminal need to carry out terminal and continue the conversion of last round of state, the state of state machine is converted to the second state, after the receiver module 50 of execution terminal receives status word B, 70 of processing modules can continue the state conversion of last round of state machine, the state of state machine is converted to the second state completely, and the execution state information of changing to control terminal feedback states machine state by feedback module 80.In specific implementation, control terminal can regularly transmit control message to carrying out terminal, when control terminal transmits control message to execution terminal, this transmits control message and sent last time and controls hour life period interval, therefore can preset and carry out terminal to the time interval of control terminal feedback execution state information, control terminal can send to execution terminal by the time interval of feedback by control message.Carry out terminal according to after the state conversion of the control message executing state machine of control terminal transmission, 80 execution state information that can change to control terminal feedback states machine state within the predefined time interval of feedback module, control terminal can upgrade the executing state of carrying out terminal according to the execution state information of carrying out terminal feedback, to grasp more accurately the state of carrying out terminal.In specific implementation, above-mentioned feedback module 80 comprises to the described execution state information of described control terminal feedback: carry out the residing state of terminal current state machine, and carry out the implementation progress that terminal is carried out state machine state conversion.For example, after the receiver module 50 of execution terminal receives status word B and carries out state machine state conversion, 80 of feedback modules can carry out to control terminal feedback the executing states that terminal be carried out state machine state conversion on default feedback time interval, comprise that carrying out the residing state of terminal current state machine (for example the second state) and execution terminal carries out the implementation progress of state machine state conversion (for example 50%).
In some feasible execution modes, in the control message that above-mentioned receiver module 50 receives, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
Execution terminal described in the present embodiment, also comprises:
Sending module 90, the next stage of managing for the described execution terminal of indicating according to described node hierarchy information is carried out the information of terminal, sends the described control information receiving from described control terminal to execution terminal that described execution terminal is managed.
In some feasible execution modes, in the control message that execution terminal described in the invention process receives from control terminal, also can comprise: node hierarchy information, above-mentioned node hierarchy information comprises the residing node grade of each execution terminal, or the next stage that each execution terminal is managed is carried out the information of terminal, wherein, the information of above-mentioned next stage execution terminal comprises: next stage is carried out the number of terminal and the sign of each execution terminal etc.In specific implementation, when group system larger, in order to guarantee that system has higher reliabilty and availability, all nodes in the group system at the execution terminal place described in the embodiment of the present invention can be carried out to classification, one-level node for example, two-level node, three grades of nodes etc. (as Fig. 3), and set carrying out terminal, to carry out the transmission rule of the control message that state machine state changes be the control message of higher leveled node to node (being the next stage node of its management) the transfer control node transmission of its next stage, wherein one-level node grade is higher than two-level node, the grade of two-level node is higher than three grades of nodes etc.Set the node grade under each execution terminal in system, or after the next stage that each execution terminal is managed is carried out the information of terminal, control terminal sends status word and the node hierarchy information of state machine state conversion to all execution terminals executing state that Shi Zeke carries out terminal according to each that transmits control message to all execution terminals, by above-mentioned status word, indicate each to carry out terminal and carry out state machine state conversion, and by the corresponding terminal of carrying out of above-mentioned node hierarchy information indication, control information is handed down to the next stage execution terminal that this execution terminal is managed.As Fig. 3, if system comprises 7 nodes, can pre-define control terminal is one-level node, and define 2 two-level nodes, two three grades of nodes of each two-level node management, control terminal can transmit control message to two-level node (for example message 1), and message 1 comprises that two-level node need to carry out the information that next stage that the status word of state machine state conversion and the residing node grade of two-level node (being secondary) and two-level node manage is carried out terminal (three grades of nodes).Execution terminal in two-level node (specifically can be the embodiment of the present invention described in execution terminal) can issue to the execution terminal in three grades of nodes the control message (for example message 2) that control terminal sends after receiving message 1, message 2 comprises that the execution terminal in three grades of nodes need to carry out the information of the next stage execution terminal (0) that the status word of state machine state conversion and the residing node grade of this executions terminal (three grades) and this execution terminal manage.
In specific implementation, the above-mentioned control message that execution terminal receives control terminal transmission can and feed back corresponding state information to control terminal according to the status word executing state machine state conversion in control message afterwards.Concrete, as Fig. 3, if above-mentioned execution terminal is in three grades of nodes, can be by status information feedback the execution terminal to two-level node (as message 4), after the execution terminal of two-level node receives the message of above-mentioned execution terminal transmission, can need to feed back to control terminal feedack to control terminal corresponding state information (as message 3) in conjunction with himself, the executing state of the next stage of the executing state of himself and management thereof being carried out to terminal (as the execution terminal described in the present embodiment) feeds back to control terminal, control terminal can be known according to two-level node feedack the executing state of all execution terminals in system.When carrying out next stage that control message that the receiver module 50 of terminal receives comprises that this executions terminal is managed and carry out the information of terminal, the information such as status word of carrying out the state machine state conversion that terminal can receive receiver module 50 by sending module 90 send to next stage execution terminal.Concrete, node hierarchy information in the control message that sending module 90 can receive according to receiver module 50, obtain next stage that this execution terminal manages and carry out the information of terminal, according to the information getting, send the control information receiving from receiver module 50 from control terminal to next stage and carry out terminal, and receiving by receiver module the execution state information that next stage is carried out terminal feedback, the execution state information of the next stage of the execution state information of himself and its management being carried out to terminal by feedback module feeds back to control terminal.
In some feasible execution modes, the group system at the execution terminal place described in the embodiment of the present invention can be passed through the method for system node classification, makes system can support arbitrary node fault, the reliability of safeguards system.As Fig. 4, for example, when arbitrary node in system (one-level node) breaks down, system also can, according to predefined selection rule, be chosen new one-level node, the task of taking over former one-level node from all two-level nodes.For example, for example, when the execution terminal described in the present embodiment (in Fig. 4 from left to right first two-level node) does not receive the message of one-level node within the default time interval, above-mentioned execution terminal can be served as new one-level node and transmit control message to other nodes, guarantees the normal operation of system.The described execution terminal of the embodiment of the present invention occurs when abnormal at control terminal, also can serve as control terminal, exercise the right of control terminal, carry out the task of control terminal, can improve the efficiency of SOT state of termination machine state conversion of system and the reliability of system, the availability and the user that have strengthened system experience.
Execution terminal described in the embodiment of the present invention can receive the control message that control terminal sends in real time, the status word of the state machine state conversion comprising according to control message, in conjunction with the state of carrying out terminal current state machine, carry out the state conversion of state machine, and to control terminal feedback execution state information; The control message that execution terminal described in the embodiment of the present invention also can send control terminal sends the execution terminal of the next stage of its management to, and can when control terminal sends fault, serve as control terminal, carries out the task dispatching of control terminal.Be that the control message that the execution terminal described in the embodiment of the present invention can send according to control terminal carry out state machine state conversion and feed back execution state information, the control message also can transfer control terminal sending or serve as control terminal, can improve and carry out the efficiency that terminal is carried out state machine state conversion, the user of enhanced situation machine state conversion experiences, the reliability and stability of safeguards system, the availability and the user that improve system experience.
One of ordinary skill in the art will appreciate that all or part of flow process realizing in above-described embodiment method, to come the hardware that instruction is relevant to complete by computer program, described program can be stored in computer read/write memory medium, this program, when carrying out, can comprise as the flow process of the embodiment of above-mentioned each side method.Wherein, described storage medium can be magnetic disc, CD, read-only store-memory body (Read-Only Memory, ROM) or random store-memory body (Random Access Memory, RAM) etc.
Above disclosed is only preferred embodiment of the present invention, certainly can not limit with this interest field of the present invention, and the equivalent variations of therefore doing according to the claims in the present invention, still belongs to the scope that the present invention is contained.
Claims (18)
1. a method for the state machine state of terminal conversion, is characterized in that, comprising:
The executing state that control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Described in described control terminal receives, respectively carry out the state information of terminal feedback, described state information is that described execution terminal is carried out the execution state information of feeding back after state machine state conversion according to described control message;
Described control terminal is according to the executing state of respectively carrying out terminal described in the described state information updating of respectively carrying out terminal feedback, to send the next control message of state machine state conversion to all described execution terminals according to the described executing state of respectively carrying out terminal after upgrading.
2. the method for claim 1, is characterized in that, also comprises: the execution object that carries out state conversion according to the status word in described control message in the control message of described state machine conversion;
Wherein, described execution object is to carry out terminal described at least one in described all described execution terminals.
3. method as claimed in claim 1 or 2, is characterized in that, the described executing state of respectively carrying out terminal comprises: describedly respectively carry out the residing state of terminal current state machine and describedly respectively carry out the implementation progress that terminal is carried out state machine state conversion.
4. method as claimed in claim 3, is characterized in that, the executing state that described control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals, comprising:
Described control terminal judges that according to the described residing state of terminal current state machine of respectively carrying out whether all described execution terminal current state machines are in same state;
If described all described execution terminal current state machines are all in same state, according to the described terminal of carrying out described in each, carry out the implementation progress of state machine state conversion and judge the whether completion status machine state conversion of described all described execution terminals;
If described all described execution terminals are completion status machine state conversion all, to described all described execution terminals, issue the first status word of state machine state conversion, if there is the described execution terminal of unfinished state machine state conversion in described all described execution terminals, to described all described execution terminals, issue the second status word of state machine state conversion;
If the same state in described all described execution terminal current state machine places, issues to described all described execution terminals the second status word that state machine state is changed.
5. the method as described in claim 1-4 any one, it is characterized in that, in the control message of described state machine state conversion, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
The executing state that described control terminal is carried out terminal according to each sends the control message of state machine state conversion to all described execution terminals, comprising:
The executing state that described control terminal is carried out terminal according to each sends status word and the node hierarchy information of state machine state conversion to all described execution terminals, respectively to carry out terminal described in indicating, carry out state machine state conversion, and respectively carry out the next stage that terminal manages described in described control message is handed down to and carry out terminal by the described terminal of respectively carrying out.
6. a method for the state machine state of terminal conversion, is characterized in that, comprising:
Carry out the control message that terminal receives the state machine state conversion that control terminal sends, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Described execution terminal judges whether the conversion of executing state machine state according to the state of described status word and described execution terminal current state machine;
If the determination result is YES, according to described status word, carry out state machine state conversion, and to described control terminal feedback execution state information;
If the determination result is NO, to described control terminal feedback execution state information.
7. method as claimed in claim 6, it is characterized in that, described execution terminal comprises to the described execution state information of described control terminal feedback: the residing state of described execution terminal current state machine, and the described execution terminal implementation progress of carrying out state machine state conversion.
8. the method as described in claim 6 or 7, is characterized in that, described execution terminal judges whether the conversion of executing state machine state according to the state of described status word and described execution terminal current state machine, comprising:
Described execution terminal compares the described status word receiving from the described control terminal status word corresponding with the residing state of described execution terminal current state machine, and whether the status word receiving described in judgement is greater than status word corresponding to the residing state of described state machine;
If the determination result is YES, executing state machine state conversion;
If the determination result is NO, not executing state machine state conversion.
9. the method as described in claim 6-8, it is characterized in that, in the control message that described execution terminal receives from described control terminal, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
After the control message of the state machine state conversion that described execution terminal reception control terminal sends, described method also comprises:
The next stage that described execution terminal is managed according to the described execution terminal of indicating in described node hierarchy information is carried out the information of terminal, sends the described control information receiving from described control terminal to execution terminal that described execution terminal is managed.
10. a control terminal for state machine state conversion, is characterized in that, comprising:
Sending module sends the control message of state machine state conversion for carrying out the executing state of terminal according to each to all described execution terminals, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Receiver module, for respectively carrying out the state information of terminal feedback described in receiving, to be described execution terminal carry out the execution state information of feedback after state machine state conversion according to described control message to described state information;
Update module, for according to the executing state of respectively carrying out terminal described in the described state information updating of respectively carrying out terminal feedback, to send the next control message of state machine state conversion by described sending module to all described execution terminals according to the described executing state of respectively carrying out terminal after upgrading.
11. control terminals as claimed in claim 10, is characterized in that, also comprise: the execution object that carries out state conversion according to the status word in described control message in the control message of the described state machine conversion that described sending module sends;
Wherein, described execution object is to carry out terminal described at least one in described all described execution terminals.
12. control terminals as described in claim 10 or 11, is characterized in that, the described executing state of respectively carrying out terminal comprises: describedly respectively carry out the residing state of terminal current state machine and describedly respectively carry out the implementation progress that terminal is carried out state machine state conversion.
13. control terminals as claimed in claim 12, is characterized in that, described sending module, comprising:
The first judging unit, for judging that according to the described residing state of terminal current state machine of respectively carrying out whether all described execution terminal current state machines are in same state;
Whether the second judging unit, while for judgment result is that at described the first judging unit being, carrying out the implementation progress of state machine state conversion and judge the completion status machine state conversion of described all described execution terminals according to the described terminal of carrying out described in each;
Transmitting element, while for judgment result is that at described the second judging unit being, issues the first status word of state machine state conversion to described all described execution terminals;
Described transmitting element, when the determination result is NO at described the second judging unit, issues the second status word of state machine state conversion to described all described execution terminals;
Described transmitting element, also when the determination result is NO at described the first judging unit, issues the second status word of state machine state conversion to described all described execution terminals.
14. control terminals as described in claim 10-13 any one, it is characterized in that, in the control message of the described state machine state conversion that described sending module sends, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
Described sending module, also specifically for:
The executing state that described control terminal is carried out terminal according to each sends status word and the node hierarchy information of state machine state conversion to all described execution terminals, respectively to carry out terminal described in indicating, carry out state machine state conversion, and respectively carry out the next stage that terminal manages described in described control message is handed down to and carry out terminal by the described terminal of respectively carrying out.
The execution terminal of 15. 1 kinds of state machine state conversions, is characterized in that, comprising:
Receiver module, for receiving the control message of the state machine state conversion that control terminal sends, described control message comprises and is used to indicate the status word that described execution terminal is carried out state machine state conversion;
Judge module, judges whether the conversion of executing state machine state for the state of the described status word that receives according to described receiver module and described execution terminal current state machine;
Processing module, while for judgment result is that at described judge module being, the described status word receiving according to described receiver module is carried out state machine state conversion;
Feedback module, for after described processing module is carried out state machine state conversion, to described control terminal feedback execution state information;
Described feedback module, when at described judge module, the determination result is NO, to described control terminal feedback execution state information.
16. execution terminals as claimed in claim 15, it is characterized in that, described feedback module comprises to the described execution state information of described control terminal feedback: the residing state of described execution terminal current state machine, and the described execution terminal implementation progress of carrying out state machine state conversion.
17. execution terminals as described in claim 15 or 16, is characterized in that, described judge module specifically for:
The status word that the described status word receiving from described control terminal is corresponding with the residing state of described execution terminal current state machine compares, and whether the status word receiving described in judgement is greater than status word corresponding to the residing state of described state machine;
If the determination result is YES, judge the conversion of executing state machine state;
If the determination result is NO, judge not executing state machine state conversion.
18. execution terminals as described in claim 15-17, it is characterized in that, in the control message that described receiver module receives, also comprise: node hierarchy information, described in described node hierarchy information comprises, respectively carry out the residing node grade of terminal, or describedly respectively carry out the information that next stage that terminal manages is carried out terminal;
Described execution terminal, also comprises:
Sending module, the next stage of managing for the described execution terminal of indicating according to described node hierarchy information is carried out the information of terminal, sends the described control information receiving from described control terminal to execution terminal that described execution terminal is managed.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310712480.XA CN103747034B (en) | 2013-12-20 | 2013-12-20 | A kind of method and device of the state machine state conversion of terminal |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310712480.XA CN103747034B (en) | 2013-12-20 | 2013-12-20 | A kind of method and device of the state machine state conversion of terminal |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103747034A true CN103747034A (en) | 2014-04-23 |
CN103747034B CN103747034B (en) | 2017-12-29 |
Family
ID=50504021
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310712480.XA Active CN103747034B (en) | 2013-12-20 | 2013-12-20 | A kind of method and device of the state machine state conversion of terminal |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103747034B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104866380A (en) * | 2015-06-18 | 2015-08-26 | 北京搜狐新媒体信息技术有限公司 | Method and device for processing state transition of cluster management system |
CN104954379A (en) * | 2015-06-23 | 2015-09-30 | 西安交大捷普网络科技有限公司 | Distributed type vulnerability scanning and evaluating method |
CN109741583A (en) * | 2017-12-31 | 2019-05-10 | 湖南汇博电子科技股份有限公司 | Fire disaster emergency apparatus control method, device, system and readable storage medium storing program for executing |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1731785A (en) * | 2004-08-04 | 2006-02-08 | 华为技术有限公司 | Method and system for supporting data framing protocol on multi-service transmission node equipment |
CN1937613A (en) * | 2005-10-14 | 2007-03-28 | 康佳集团股份有限公司 | Method for realizing real-time flow protocol control utilizing state machine |
US7362185B1 (en) * | 2005-01-27 | 2008-04-22 | Cypress Semiconductor Corporation | Analog based, state machine controlled, frequency smooth switching method for frequency timing generators |
CN101169651A (en) * | 2007-10-19 | 2008-04-30 | 上海微电子装备有限公司 | Parallel control method for silicon chip transfusion system |
-
2013
- 2013-12-20 CN CN201310712480.XA patent/CN103747034B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1731785A (en) * | 2004-08-04 | 2006-02-08 | 华为技术有限公司 | Method and system for supporting data framing protocol on multi-service transmission node equipment |
US7362185B1 (en) * | 2005-01-27 | 2008-04-22 | Cypress Semiconductor Corporation | Analog based, state machine controlled, frequency smooth switching method for frequency timing generators |
CN1937613A (en) * | 2005-10-14 | 2007-03-28 | 康佳集团股份有限公司 | Method for realizing real-time flow protocol control utilizing state machine |
CN101169651A (en) * | 2007-10-19 | 2008-04-30 | 上海微电子装备有限公司 | Parallel control method for silicon chip transfusion system |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104866380A (en) * | 2015-06-18 | 2015-08-26 | 北京搜狐新媒体信息技术有限公司 | Method and device for processing state transition of cluster management system |
CN104866380B (en) * | 2015-06-18 | 2018-07-06 | 北京搜狐新媒体信息技术有限公司 | A kind for the treatment of method and apparatus of the state conversion of cluster management system |
CN104954379A (en) * | 2015-06-23 | 2015-09-30 | 西安交大捷普网络科技有限公司 | Distributed type vulnerability scanning and evaluating method |
CN104954379B (en) * | 2015-06-23 | 2018-06-08 | 西安交大捷普网络科技有限公司 | Distributed Hole scans and appraisal procedure |
CN109741583A (en) * | 2017-12-31 | 2019-05-10 | 湖南汇博电子科技股份有限公司 | Fire disaster emergency apparatus control method, device, system and readable storage medium storing program for executing |
Also Published As
Publication number | Publication date |
---|---|
CN103747034B (en) | 2017-12-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106453648B (en) | Equipment state determination method and device for intelligent household equipment | |
CN103324495A (en) | Method and system for data center server boot management | |
CN103677946B (en) | Method and system for updating elevator device control programs | |
CN109582335A (en) | It is a kind of without interrupt storage cluster node online upgrading method, device and equipment | |
CN105224362A (en) | Host computer carries out the method and system of program upgrade to slave computer | |
CN104486394B (en) | In-service Software Upgrade method and device | |
CN106506595B (en) | Upgrade method based on point-to-point Internet of Things intelligent Community equipment | |
CN103076768A (en) | Distributive battery management system and identification distribution method thereof | |
CN103391210A (en) | ID distribution system and method of CAN bus network | |
CN112463535A (en) | Multi-cluster exception handling method and device | |
CN103747034A (en) | Terminal state-machine state conversion method and device | |
CN103139033A (en) | Primary device redundancy switching method of single main communication control bus | |
CN103581226A (en) | Method, system and device for synchronizing terminal capacity information | |
CN102571311B (en) | Master-slave switching communication system and master-slave switching communication method | |
CN113220421B (en) | Management method, management server and management system of server cluster | |
AU2006337975B2 (en) | Method for storing a data block containing data for controlling a technical process, and control and automation apparatus | |
CN108388108B (en) | Method and device for synchronizing data in multiple redundancy control system | |
CN105391755A (en) | Method and device for processing data in distributed system, and system | |
CN102231684B (en) | Interface board state detection method, multi-core central processing unit, interface board and router | |
CN1996894A (en) | A method and device for remote batch upgrade of the embedded device | |
CN110958139A (en) | Network control method, orchestrator, controller, and computer-readable storage medium | |
CN103914339A (en) | Server management system and server management method | |
CN112214466B (en) | Distributed cluster system, data writing method, electronic equipment and storage device | |
CN116107618A (en) | Flowmeter controller upgrading method, computer equipment and storage medium | |
CN102546313A (en) | Multi-activation detection method and multi-activation detection device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20220831 Address after: 611731 No. 1899, Xiyuan Avenue, high tech Zone (West District), Chengdu, Sichuan Patentee after: Chengdu Huawei Technologies Co.,Ltd. Address before: 518129 Bantian HUAWEI headquarters office building, Longgang District, Guangdong, Shenzhen Patentee before: HUAWEI TECHNOLOGIES Co.,Ltd. |