public class NodeLostTrigger extends TriggerBase
TriggerEventType.NODELOST
eventModifier and Type | Class and Description |
---|---|
static class |
NodeLostTrigger.NodeLostEvent |
actions, cloudManager, enabled, eventType, isClosed, lastState, loader, name, processorRef, properties, requiredProperties, stateManager, validProperties, waitForSecond
Constructor and Description |
---|
NodeLostTrigger(String name) |
Modifier and Type | Method and Description |
---|---|
protected Map<String,Object> |
getState()
Prepare and return internal state of this trigger in a format suitable for persisting in ZK.
|
void |
init()
Called before a trigger is scheduled.
|
void |
restoreState(AutoScaling.Trigger old)
Set internal state of this trigger from another instance.
|
void |
run() |
protected void |
setState(Map<String,Object> state)
Restore internal state of this trigger from properties retrieved from ZK.
|
close, configure, equals, getActions, getEventType, getName, getProcessor, getProperties, getWaitForSecond, hashCode, isClosed, isEnabled, restoreState, saveState, setProcessor
public NodeLostTrigger(String name)
public void init() throws Exception
AutoScaling.Trigger
init
in interface AutoScaling.Trigger
init
in class TriggerBase
Exception
public void restoreState(AutoScaling.Trigger old)
AutoScaling.Trigger
protected Map<String,Object> getState()
TriggerBase
getState
in class TriggerBase
Utils.toJSON(Object)
.protected void setState(Map<String,Object> state)
TriggerBase
setState
in class TriggerBase
state
- never null but may be empty.public void run()
Copyright © 2000-2018 Apache Software Foundation. All Rights Reserved.