public class RebindManagerImpl extends java.lang.Object implements RebindManager
 Lifecycle is to create an instance of this, set it up (e.g. setPeriodicPersistPeriod(Duration), 
 setPersister(BrooklynMementoPersister); however noting that persist period must be set before the persister).
 
Usually done for you by the conveniences (such as the launcher).
| Modifier and Type | Class and Description | 
|---|---|
| static class  | RebindManagerImpl.RebindTrackerFor tracking if rebinding, for  AbstractBrooklynObject.isRebinding()etc. | 
RebindManager.RebindFailureMode| Modifier and Type | Field and Description | 
|---|---|
| static ConfigKey<RebindManager.RebindFailureMode> | ADD_POLICY_FAILURE_MODE | 
| static ConfigKey<RebindManager.RebindFailureMode> | DANGLING_REFERENCE_FAILURE_MODE | 
| static ConfigKey<RebindManager.RebindFailureMode> | LOAD_POLICY_FAILURE_MODE | 
| static org.slf4j.Logger | LOG | 
| static ConfigKey<RebindManager.RebindFailureMode> | REBIND_FAILURE_MODE | 
| Constructor and Description | 
|---|
| RebindManagerImpl(ManagementContextInternal managementContext) | 
| Modifier and Type | Method and Description | 
|---|---|
| void | forcePersistNow()Forcibly performs persistence, in the foreground | 
| ChangeListener | getChangeListener() | 
| BrooklynMementoPersister | getPersister() | 
| boolean | isPersistenceRunning() | 
| boolean | isReadOnlyRunning() | 
| java.util.List<Application> | rebind() | 
| java.util.List<Application> | rebind(java.lang.ClassLoader classLoader) | 
| java.util.List<Application> | rebind(java.lang.ClassLoader classLoader,
      RebindExceptionHandler exceptionHandler) | 
| java.util.List<Application> | rebind(java.lang.ClassLoader classLoaderO,
      RebindExceptionHandler exceptionHandlerO,
      ManagementNodeState modeO)Causes this management context to rebind, loading data from the given backing store. | 
| BrooklynMementoRawData | retrieveMementoRawData() | 
| void | setPeriodicPersistPeriod(Duration period)Must be called before setPerister() | 
| void | setPeriodicPersistPeriod(long periodMillis)Deprecated. 
 since 0.7.0; use  setPeriodicPersistPeriod(Duration) | 
| void | setPersister(BrooklynMementoPersister val) | 
| void | setPersister(BrooklynMementoPersister val,
            PersistenceExceptionHandler exceptionHandler) | 
| void | start()Starts the appropriate background processes,  RebindManager.startPersistence()ifManagementNodeState.MASTER,RebindManager.startReadOnly()ifManagementNodeState.HOT_STANDBY | 
| void | startPersistence()Starts the background persisting of state
 (if persister is set; otherwise will start persisting as soon as persister is set). | 
| void | startReadOnly()Perform an initial load of state read-only and starts a background process 
 reading (mirroring) state periodically. | 
| void | stop()Stops the appropriate background processes,  RebindManager.stopPersistence()orRebindManager.stopReadOnly(),
 waiting for activity there to cease (interrupting in the case ofRebindManager.stopReadOnly()). | 
| void | stopPersistence()Stops the background persistence of state. | 
| void | stopReadOnly()Stops the background reading (mirroring) of state. | 
| java.lang.String | toString() | 
| void | waitForPendingComplete(Duration timeout)waits for any needed or pending writes to complete | 
| void | waitForPendingComplete(long timeout,
                      java.util.concurrent.TimeUnit unit)Deprecated.  | 
public static final ConfigKey<RebindManager.RebindFailureMode> DANGLING_REFERENCE_FAILURE_MODE
public static final ConfigKey<RebindManager.RebindFailureMode> REBIND_FAILURE_MODE
public static final ConfigKey<RebindManager.RebindFailureMode> ADD_POLICY_FAILURE_MODE
public static final ConfigKey<RebindManager.RebindFailureMode> LOAD_POLICY_FAILURE_MODE
public static final org.slf4j.Logger LOG
public RebindManagerImpl(ManagementContextInternal managementContext)
public void setPeriodicPersistPeriod(Duration period)
public void setPeriodicPersistPeriod(long periodMillis)
setPeriodicPersistPeriod(Duration)public boolean isPersistenceRunning()
public boolean isReadOnlyRunning()
public void setPersister(BrooklynMementoPersister val)
setPersister in interface RebindManagerpublic void setPersister(BrooklynMementoPersister val, PersistenceExceptionHandler exceptionHandler)
setPersister in interface RebindManagerpublic BrooklynMementoPersister getPersister()
getPersister in interface RebindManagerpublic void startPersistence()
RebindManagerstartPersistence in interface RebindManagerpublic void stopPersistence()
RebindManagerstopPersistence in interface RebindManagerpublic void startReadOnly()
RebindManagerstartReadOnly in interface RebindManagerpublic void stopReadOnly()
RebindManagerstopReadOnly in interface RebindManagerpublic void start()
RebindManagerRebindManager.startPersistence() if ManagementNodeState.MASTER,
 RebindManager.startReadOnly() if ManagementNodeState.HOT_STANDBYstart in interface RebindManagerpublic void stop()
RebindManagerRebindManager.stopPersistence() or RebindManager.stopReadOnly(),
 waiting for activity there to cease (interrupting in the case of RebindManager.stopReadOnly()).stop in interface RebindManager@Deprecated
public void waitForPendingComplete(long timeout,
                                     java.util.concurrent.TimeUnit unit)
                            throws java.lang.InterruptedException,
                                   java.util.concurrent.TimeoutException
waitForPendingComplete in interface RebindManagerjava.lang.InterruptedExceptionjava.util.concurrent.TimeoutExceptionpublic void waitForPendingComplete(Duration timeout) throws java.lang.InterruptedException, java.util.concurrent.TimeoutException
RebindManagerwaitForPendingComplete in interface RebindManagerjava.lang.InterruptedExceptionjava.util.concurrent.TimeoutExceptionpublic void forcePersistNow()
RebindManagerforcePersistNow in interface RebindManagerpublic ChangeListener getChangeListener()
getChangeListener in interface RebindManagerpublic java.util.List<Application> rebind()
rebind in interface RebindManagerpublic java.util.List<Application> rebind(java.lang.ClassLoader classLoader)
rebind in interface RebindManagerpublic java.util.List<Application> rebind(java.lang.ClassLoader classLoader, RebindExceptionHandler exceptionHandler)
rebind in interface RebindManagerpublic java.util.List<Application> rebind(java.lang.ClassLoader classLoaderO, RebindExceptionHandler exceptionHandlerO, ManagementNodeState modeO)
RebindManagerManagementNodeState.MASTER 
 or periodically for a node in ManagementNodeState.HOT_STANDBY.rebind in interface RebindManagerpublic BrooklynMementoRawData retrieveMementoRawData() throws java.io.IOException
retrieveMementoRawData in interface RebindManagerjava.io.IOExceptionpublic java.lang.String toString()
toString in class java.lang.Object