Interface OMRSAuditLogStore
-
- All Known Implementing Classes:
OMRSAuditLogStoreConnectorBase
public interface OMRSAuditLogStoreOMRSAuditLogStore is the specialized data API for an Audit Log destination connector.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description OMRSAuditLogRecordgetAuditLogRecord(String logRecordId)Retrieve a specific audit log record.List<OMRSAuditLogRecord>getAuditLogRecordsByComponent(String component, Date startDate, Date endDate, int offset, int maximumRecords)Retrieve a list of log records written by a specific component.List<OMRSAuditLogRecord>getAuditLogRecordsBySeverity(String severity, Date startDate, Date endDate, int offset, int maximumRecords)Retrieve a list of log records that have specific severity.List<OMRSAuditLogRecord>getAuditLogRecordsByTimeStamp(Date startDate, Date endDate, int offset, int maximumRecords)Retrieve a list of log records written in a specified time period.StringgetDestinationName()Return the name of this audit log destination.List<String>getSupportedSeverities()Return the list of supported severities that this destination is configured to support.StringstoreLogRecord(OMRSAuditLogRecord logRecord)Store the audit log record in the audit log store.
-
-
-
Method Detail
-
getDestinationName
String getDestinationName()
Return the name of this audit log destination.- Returns:
- string display name suitable for messages.
-
getSupportedSeverities
List<String> getSupportedSeverities()
Return the list of supported severities that this destination is configured to support.- Returns:
- list of severity names (see OMRSAuditLogRecordSeverity)
-
storeLogRecord
String storeLogRecord(OMRSAuditLogRecord logRecord) throws InvalidParameterException, RepositoryErrorException
Store the audit log record in the audit log store.- Parameters:
logRecord- log record to store- Returns:
- unique identifier assigned to the log record
- Throws:
InvalidParameterException- indicates that the logRecord parameter is invalid.RepositoryErrorException- indicates that the audit log store is not available or has an error.
-
getAuditLogRecord
OMRSAuditLogRecord getAuditLogRecord(String logRecordId) throws InvalidParameterException, FunctionNotSupportedException, RepositoryErrorException
Retrieve a specific audit log record.- Parameters:
logRecordId- unique identifier for the log record- Returns:
- requested audit log record
- Throws:
InvalidParameterException- indicates that the logRecordId parameter is invalid.FunctionNotSupportedException- indicates that the audit log store does not support queries.RepositoryErrorException- indicates that the audit log store is not available or has an error.
-
getAuditLogRecordsByTimeStamp
List<OMRSAuditLogRecord> getAuditLogRecordsByTimeStamp(Date startDate, Date endDate, int offset, int maximumRecords) throws InvalidParameterException, PagingErrorException, FunctionNotSupportedException, RepositoryErrorException
Retrieve a list of log records written in a specified time period. The offset and maximumRecords parameters support a paging- Parameters:
startDate- start of time periodendDate- end of time periodoffset- offset of full collection to begin the return resultsmaximumRecords- maximum number of log records to return- Returns:
- list of log records from the specified time period
- Throws:
InvalidParameterException- indicates that the start and/or end date parameters are invalid.PagingErrorException- indicates that the offset or the maximumRecords parameters are invalid.FunctionNotSupportedException- indicates that the audit log store does not support queries.RepositoryErrorException- indicates that the audit log store is not available or has an error.
-
getAuditLogRecordsBySeverity
List<OMRSAuditLogRecord> getAuditLogRecordsBySeverity(String severity, Date startDate, Date endDate, int offset, int maximumRecords) throws InvalidParameterException, PagingErrorException, FunctionNotSupportedException, RepositoryErrorException
Retrieve a list of log records that have specific severity. The offset and maximumRecords parameters support a paging model.- Parameters:
severity- the severity value of messages to returnstartDate- start of time periodendDate- end of time periodoffset- offset of full collection to begin the return resultsmaximumRecords- maximum number of log records to return- Returns:
- list of log records from the specified time period
- Throws:
InvalidParameterException- indicates that the severity, start and/or end date parameters are invalid.PagingErrorException- indicates that the offset or the maximumRecords parameters are invalid.FunctionNotSupportedException- indicates that the audit log store does not support queries.RepositoryErrorException- indicates that the audit log store is not available or has an error.
-
getAuditLogRecordsByComponent
List<OMRSAuditLogRecord> getAuditLogRecordsByComponent(String component, Date startDate, Date endDate, int offset, int maximumRecords) throws InvalidParameterException, PagingErrorException, FunctionNotSupportedException, RepositoryErrorException
Retrieve a list of log records written by a specific component. The offset and maximumRecords parameters support a paging model.- Parameters:
component- name of the component to retrieve events fromstartDate- start of time periodendDate- end of time periodoffset- offset of full collection to begin the return resultsmaximumRecords- maximum number of log records to return- Returns:
- list of log records from the specified time period
- Throws:
InvalidParameterException- indicates that the component, start and/or end date parameters are invalid.PagingErrorException- indicates that the offset or the maximumRecords parameters are invalid.FunctionNotSupportedException- indicates that the audit log store does not support queries.RepositoryErrorException- indicates that the audit log store is not available or has an error.
-
-