|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ChangeLog
A facade for the change log subsystem. It exposes the functionality needed to interact with the facility to query for changes, take snapshots, and revert the server to an earlier revision.
| Method Summary | |
|---|---|
void |
destroy()
Destroy the changeLog |
ChangeLogSearchEngine |
getChangeLogSearchEngine()
Gets the change log query engine which would be used to ask questions about what changed, when, how and by whom. |
ChangeLogStore |
getChangeLogStore()
|
long |
getCurrentRevision()
Gets the current revision for the server. |
Tag |
getLatest()
|
TagSearchEngine |
getTagSearchEngine()
Gets the tag search engine used to query the snapshots taken. |
void |
init(DirectoryService service)
Initialize the ChangeLog system. |
boolean |
isEnabled()
Checks whether or not the change log has been enabled to track changes. |
boolean |
isExposed()
|
boolean |
isLogSearchSupported()
Returns whether or not this ChangeLogService supports searching for changes. |
boolean |
isTagSearchSupported()
Returns whether or not this ChangeLogService supports searching for snapshot tags. |
boolean |
isTagStorageSupported()
Returns whether or not this ChangeLogService stores snapshot tags. |
ChangeLogEvent |
log(LdapPrincipal principal,
org.apache.directory.shared.ldap.ldif.LdifEntry forward,
org.apache.directory.shared.ldap.ldif.LdifEntry reverse)
Records a change as a forward LDIF, a reverse change to revert the change and the authorized principal triggering the revertable change event. |
ChangeLogEvent |
log(LdapPrincipal principal,
org.apache.directory.shared.ldap.ldif.LdifEntry forward,
java.util.List<org.apache.directory.shared.ldap.ldif.LdifEntry> reverses)
Records a change as a forward LDIF, some reverse changes to revert the change and the authorized principal triggering the revertable change event. |
void |
setChangeLogStore(ChangeLogStore store)
Set the underlying storage |
void |
setEnabled(boolean enabled)
Enable or disable the ChangeLog service |
void |
setExposed(boolean exposed)
Exposes the contents of ChangeLog to clients if set to true. |
void |
setPartitionSuffix(java.lang.String suffix)
The prefix of the partition. |
void |
setRevisionsContainerName(java.lang.String revContainerName)
The name of the revisions container under the partition. |
void |
setTagsContainerName(java.lang.String tagContainerName)
The name of the tags container under the partition. |
void |
sync()
Flush the changes to disk |
Tag |
tag()
Creates a snapshot of the server at the current revision. |
Tag |
tag(long revision)
Creates a tag for a snapshot of the server in a specific state at a revision. |
Tag |
tag(long revision,
java.lang.String description)
Creates a tag for a snapshot of the server in a specific state at a revision. |
Tag |
tag(java.lang.String description)
Creates a snapshot of the server at the current revision. |
| Method Detail |
|---|
boolean isEnabled()
void setEnabled(boolean enabled)
enabled - true to enable the service, flase to disable itChangeLogStore getChangeLogStore()
void setChangeLogStore(ChangeLogStore store)
store - The storage
long getCurrentRevision()
throws java.lang.Exception
java.lang.Exception - if there is a problem accessing this information
ChangeLogEvent log(LdapPrincipal principal,
org.apache.directory.shared.ldap.ldif.LdifEntry forward,
org.apache.directory.shared.ldap.ldif.LdifEntry reverse)
throws java.lang.Exception
principal - the authorized LDAP principal triggering the changeforward - LDIF of the change going to the next statereverse - LDIF (anti-operation): the change required to revert this change
java.lang.Exception - if there are problems logging the change
ChangeLogEvent log(LdapPrincipal principal,
org.apache.directory.shared.ldap.ldif.LdifEntry forward,
java.util.List<org.apache.directory.shared.ldap.ldif.LdifEntry> reverses)
throws java.lang.Exception
principal - the authorized LDAP principal triggering the changeforward - LDIF of the change going to the next statereverses - LDIF (anti-operation): the changes required to revert this change
java.lang.Exception - if there are problems logging the changeboolean isLogSearchSupported()
boolean isTagSearchSupported()
boolean isTagStorageSupported()
ChangeLogSearchEngine getChangeLogSearchEngine()
java.lang.UnsupportedOperationException - if the change log is not searchableTagSearchEngine getTagSearchEngine()
java.lang.UnsupportedOperationException - if the tag searching is not supported
Tag tag(long revision)
throws java.lang.Exception
revision - the revision to tag the snapshot
java.lang.Exception - if there is a problem taking a tag
java.lang.IllegalArgumentException - if the revision is out of range (less than 0
and greater than the current revision)
Tag tag(long revision,
java.lang.String description)
throws java.lang.Exception
revision - the revision to tag the snapshotdescription - some information about what the snapshot tag represents
java.lang.Exception - if there is a problem taking a tag
java.lang.IllegalArgumentException - if the revision is out of range (less than 0
and greater than the current revision)
Tag tag(java.lang.String description)
throws java.lang.Exception
description - some information about what the snapshot tag represents
java.lang.Exception - if there is a problem taking a tag
Tag tag()
throws java.lang.Exception
java.lang.Exception - if there is a problem taking a tag
Tag getLatest()
throws java.lang.Exception
java.lang.Exception - if there is a problem taking the latest tag
void init(DirectoryService service)
throws java.lang.Exception
service - The associated DirectoryService
java.lang.Exception
void sync()
throws java.lang.Exception
java.lang.Exception - If the flush failed
void destroy()
throws java.lang.Exception
java.lang.Exceptionvoid setExposed(boolean exposed)
exposed - true to expose the contents, false to not expose.boolean isExposed()
void setPartitionSuffix(java.lang.String suffix)
suffix - suffix value to be set for the changelog partitionvoid setRevisionsContainerName(java.lang.String revContainerName)
revContainerName - the name of the revisions containervoid setTagsContainerName(java.lang.String tagContainerName)
tagContainerName - the name of the revisions container
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||