public enum State extends Enum<State>
Enum Constant and Description |
---|
DISABLED
Disabled master's backup state
|
INIT
Initial/Clean state.
|
INSTALL_FAILED
Install failed.
|
INSTALLED
State when install completed successfully.
|
INSTALLING
In the process of installing.
|
STARTED
State when start completed successfully.
|
STARTING
In the process of starting.
|
STOPPING
In the process of stopping.
|
UNINSTALLED
State when uninstall completed successfully.
|
UNINSTALLING
In the process of uninstalling.
|
UNKNOWN
State could not be determined.
|
UPGRADING
In the process of upgrading the host component deployed bits.
|
WIPING_OUT
In the process of wiping out the install.
|
Modifier and Type | Method and Description |
---|---|
static void |
checkUpdateConfiguration(ServiceComponentHost serviceComponentHost,
State currentState,
State desiredState)
Determine whether or not it is safe to update the configuration of the given service
component host for the given states.
|
boolean |
isRemovableState()
Indicates whether or not the resource with this state can be removed.
|
boolean |
isValidClientComponentState()
Indicates whether or not it is a valid state for the client component.
|
boolean |
isValidDesiredState()
Indicates whether or not it is a valid desired state.
|
static boolean |
isValidDesiredStateTransition(State startState,
State desiredState)
Utility method to determine whether or not the given desired state is valid for the given starting state.
|
static boolean |
isValidStateTransition(State startState,
State desiredState)
Utility method to determine whether or not a valid transition can be made from the given states.
|
static State |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static State[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final State INIT
public static final State INSTALLING
public static final State INSTALL_FAILED
public static final State INSTALLED
public static final State STARTING
public static final State STARTED
public static final State STOPPING
public static final State UNINSTALLING
public static final State UNINSTALLED
public static final State WIPING_OUT
public static final State UPGRADING
public static final State DISABLED
public static final State UNKNOWN
public static State[] values()
for (State c : State.values()) System.out.println(c);
public static State valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic boolean isValidDesiredState()
public boolean isValidClientComponentState()
public boolean isRemovableState()
public static boolean isValidStateTransition(State startState, State desiredState)
startState
- the starting statedesiredState
- the desired statepublic static boolean isValidDesiredStateTransition(State startState, State desiredState)
startState
- the starting statedesiredState
- the desired statepublic static void checkUpdateConfiguration(ServiceComponentHost serviceComponentHost, State currentState, State desiredState) throws org.apache.ambari.server.AmbariException
serviceComponentHost
- the service component hostcurrentState
- the current statedesiredState
- the desired stateorg.apache.ambari.server.AmbariException
- if the changing of configuration is not supportedCopyright © 2022 Apache Software Foundation. All rights reserved.