HADOOP-9945. HAServiceState should have a state for stopped services. Contributed by Karthik Kambatla.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1523150 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Aaron Myers 2013-09-13 23:58:45 +00:00
parent 87d09e5ebe
commit 27c1c0079e
2 changed files with 8 additions and 3 deletions

View File

@ -129,6 +129,9 @@ Release 2.1.1-beta - UNRELEASED
HADOOP-9918. Add addIfService to CompositeService (Karthik Kambatla via HADOOP-9918. Add addIfService to CompositeService (Karthik Kambatla via
Sandy Ryza) Sandy Ryza)
HADOOP-9945. HAServiceState should have a state for stopped services.
(Karthik Kambatla via atm)
OPTIMIZATIONS OPTIMIZATIONS
BUG FIXES BUG FIXES

View File

@ -43,13 +43,15 @@ public interface HAServiceProtocol {
public static final long versionID = 1L; public static final long versionID = 1L;
/** /**
* An HA service may be in active or standby state. During * An HA service may be in active or standby state. During startup, it is in
* startup, it is in an unknown INITIALIZING state. * an unknown INITIALIZING state. During shutdown, it is in the STOPPING state
* and can no longer return to active/standby states.
*/ */
public enum HAServiceState { public enum HAServiceState {
INITIALIZING("initializing"), INITIALIZING("initializing"),
ACTIVE("active"), ACTIVE("active"),
STANDBY("standby"); STANDBY("standby"),
STOPPING("stopping");
private String name; private String name;