Package com.attivio.sdk.client.audit
Interface AuditWriterApi
-
- All Known Subinterfaces:
AieSystemAuditApi
- All Known Implementing Classes:
MockIngestAuditApi
public interface AuditWriterApiThe AuditWriterApi allows for the creation of audit information about the processing of documents. Clients can then access this information via theAuditReaderApi. These interfaces work with the same data but are separated to allow for differing security and implementation.This is an early-access version of the API. Interfaces and classes are subject to change. Change list:
- Cleanup methods
- Index zone details
$Revision$
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longaudit(AuditDetail audit)Writes the audit information to the store.longaudit(java.util.List<AuditDetail> audit)Writes a batch of audit information to the store.voidclientHeartbeat(java.util.UUID clientId)Updates the audit information to show that the client is still active so that the client will continue to be returned byAuditReaderApi.getActiveClients().voidclientName(java.util.UUID clientId, java.lang.String name)Sets a name to be associated with the client.voidmakeInactive(java.util.UUID clientId)Marks the clientId as inactive.voidpurge(java.util.Date start, java.util.Date end)Purges all audit data within the time range.voidpurge(java.util.UUID clientId)Purges all audit data associated with the client ID.intpurgeInactiveClients(long lastInactiveTimeToKeep)Purges the audit data for all clients that are inactive and went inactive beforelastInactiveTimeToKeep
-
-
-
Method Detail
-
audit
long audit(AuditDetail audit) throws AttivioException
Writes the audit information to the store. After this call completes, the client referenced by the audit record will be active and will be returned byAuditReaderApi.getActiveClients().- Parameters:
audit-- Returns:
- the sequence id for the audit record
- Throws:
AttivioException- if the audit information could not be stored
-
audit
long audit(java.util.List<AuditDetail> audit) throws AttivioException
Writes a batch of audit information to the store. After this call completes, the client referenced by the audit record will be active and will be returned byAuditReaderApi.getActiveClients(). Note, that if an exception is encountered while storing the audit information, the rest of the list will still be attempted to be stored. All exceptions encountered while persisting the list are returned with any exception after the first added as suppressed exceptions of the first.- Parameters:
audit-- Returns:
- the sequence id for the last audit record in the list.
- Throws:
AttivioException- if the audit information could not be stored
-
makeInactive
void makeInactive(java.util.UUID clientId) throws AttivioExceptionMarks the clientId as inactive. The client will no longer be returned byAuditReaderApi.getActiveClients().- Parameters:
clientId-- Throws:
AttivioException
-
clientHeartbeat
void clientHeartbeat(java.util.UUID clientId) throws AttivioExceptionUpdates the audit information to show that the client is still active so that the client will continue to be returned byAuditReaderApi.getActiveClients().- Parameters:
clientId-- Throws:
AttivioException
-
clientName
void clientName(java.util.UUID clientId, java.lang.String name) throws AttivioExceptionSets a name to be associated with the client. After calling this method,AuditReaderApi.getSummary(UUID)is guaranteed to return a non-nullvalue with clientName and lastActionTime having the value of the set time.- Parameters:
clientId-name-- Throws:
AttivioException
-
purge
void purge(java.util.UUID clientId) throws AttivioExceptionPurges all audit data associated with the client ID.- Parameters:
clientId- restricts results to clientId,nullnot allowed.- Throws:
AttivioException
-
purgeInactiveClients
int purgeInactiveClients(long lastInactiveTimeToKeep) throws AttivioExceptionPurges the audit data for all clients that are inactive and went inactive beforelastInactiveTimeToKeep- Parameters:
lastInactiveTimeToKeep-- Returns:
- number of clients that were purged
- Throws:
AttivioException
-
purge
void purge(java.util.Date start, java.util.Date end) throws AttivioExceptionPurges all audit data within the time range.
Ifstartandendare bothnull, deletes all records and summary records. Otherwise, summary records are retained. If deleting individual summary records is required, usepurge(UUID)instead- Parameters:
start- the inclusive start date.end- the exclusive end date.- Throws:
AttivioException
-
-