public interface PersistenceService
The config framework provides a file-based implementation but new implementations - e.g. to memory, database, coherence - could be developped and used with the config framework.
| Modifier and Type | Method and Description |
|---|---|
void |
disposeSession(java.lang.String session)
callback to dispose a given session previously created but for which a persistence context has not been created.
|
java.util.Set<java.lang.String> |
getSessions()
returns the list of sessions that have been persisted.
|
void |
initialize(ConfigService configService)
callback to initialize the persistence service.
|
PersistenceContext |
newContext(ConfigContext context, boolean isLoad)
creates a new
PersistenceContext for the given ConfigContext. |
void initialize(ConfigService configService) throws java.lang.Exception
java.lang.Exceptionjava.util.Set<java.lang.String> getSessions()
throws java.lang.Exception
java.lang.Exceptionvoid disposeSession(java.lang.String session)
PersistenceContext newContext(ConfigContext context, boolean isLoad) throws java.lang.Exception
PersistenceContext for the given ConfigContext.
This method will be called during creation of the ConfigContext for the core state as well as any persisted sessions (load), and then for any newly created session.
isLoad - whether the persistence context is created for a session being loaded or created.java.lang.Exception