|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IBackingRepositoryLifecycleManager
Allows external code to do initialization work on the backing repository at certain lifecycle milestones. An example
of a backing repository is JCR. Note that there is no code dependency between this interface and
IUnifiedRepository
. This interface is for code that initializes any backing repository.
Methods in this class must be called by an external caller (see example below). A caller can get a reference to the
IBackingRepositoryLifecycleManager
usingPentahoSystem
. Methods should be able to be called more than
once with the same arguments with no adverse effects.
Example: When a servlet-based application starts up, a ServletContextListener
calls startup()
.
When a user logs in, newTenant(String)
and #onNewUser(String)
are called. Finally, the
ServletContextListener
calls shutdown()
.
This class is necessary since some implementations cannot observe logins. Example: JCR cannot observe logins--only node and property events.
Method Summary | |
---|---|
void |
newTenant()
To be called before any users belonging to the current tenant interact with the backing repository. |
void |
newTenant(String tenantId)
To be called before any users belonging to a particular tenant interact with the backing repository. |
void |
newUser()
To be called before current user interacts with the backing repository. |
void |
newUser(String tenantId,
String username)
To be called before user indicated by username interacts with the backing repository. |
void |
shutdown()
To be called on repository shutdown. |
void |
startup()
To be called before any (non-admin) users interact with the backing repository. |
Method Detail |
---|
void startup()
void shutdown()
void newTenant(String tenantId)
tenantId
- new tenant idvoid newTenant()
void newUser(String tenantId, String username)
username
interacts with the backing repository.
tenantId
- tenant to which the user belongsusername
- new usernamevoid newUser()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |