public abstract class GCUBERIPersistenceManager extends Object
| Modifier and Type | Class and Description |
|---|---|
protected class |
GCUBERIPersistenceManager.StateChangeConsumer
Consumer of state change events.
|
class |
GCUBERIPersistenceManager.StateNotFoundException
Signals the lack of remote state.
|
| Modifier and Type | Field and Description |
|---|---|
protected GCUBEServiceContext |
ctxt
The context of the service.
|
protected List<Pattern> |
excludes
List of excludes directives.
|
protected GCUBELog |
logger
Instance Logger
|
protected GCUBERIPersistenceManagerProfile |
profile
The configuration profile of the manager.
|
| Constructor and Description |
|---|
GCUBERIPersistenceManager(GCUBEServiceContext ctxt,
GCUBERIPersistenceManagerProfile profile)
Creates a new instance for a given service and from a given configuration profile.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
commit()
Commits the state of the running instance.
|
protected abstract void |
commitState()
Invoked by
commit() to commit the state of the running instance. |
void |
exclude(String... excludes)
Add one or more regular expressions as exclude directives.
|
protected boolean |
getCommit()
Returns the commit flag value.
|
void |
recover()
Recovers the state of the running instance.
|
protected abstract void |
recoverState()
Invoked by
recover() to recover the state of the running instance. |
void |
setCommit(boolean value)
Sets the commit flag.
|
void |
setLogger(GCUBELog logger)
Sets the instance logger.
|
protected GCUBELog logger
protected GCUBEServiceContext ctxt
protected GCUBERIPersistenceManagerProfile profile
public GCUBERIPersistenceManager(GCUBEServiceContext ctxt, GCUBERIPersistenceManagerProfile profile)
ctxt - the context of the service.profile - the configuration profile.public void setLogger(GCUBELog logger)
logger - the logger.public void setCommit(boolean value)
value - the flag value.protected boolean getCommit()
protected void commit()
throws Exception
Exception - if the state could not be committed.protected abstract void commitState()
throws Exception
commit() to commit the state of the running instance.Exception - if the state could not be committed.public void recover()
throws Exception
Exception - if the state could not be recovered.protected abstract void recoverState()
throws GCUBERIPersistenceManager.StateNotFoundException,
Exception
recover() to recover the state of the running instance.Exception - if the state could not be recovered.GCUBERIPersistenceManager.StateNotFoundExceptionpublic void exclude(String... excludes)
excludes - the regular expressions.Copyright © 2015. All Rights Reserved.