public class OMRSAuditLog extends Object
| Constructor and Description |
|---|
OMRSAuditLog(int componentId,
String componentName,
String componentDescription,
String componentWikiURL)
Typical constructor: each component using the Audit log will create their own OMRSAuditLog instance and
will push log records to it.
|
OMRSAuditLog(OMRSAuditingComponent reportingComponent)
External constructor is used to create an audit log for a component outside of OMRS
|
| Modifier and Type | Method and Description |
|---|---|
static void |
initialize(String localServerName,
String localServerType,
String localOrganizationName,
List<OMRSAuditLogStore> auditLogStores)
Initialize the static values used in all log records.
|
void |
logException(String actionDescription,
String logMessageId,
OMRSAuditLogRecordSeverity severity,
String logMessage,
String additionalInformation,
String systemAction,
String userAction,
Throwable caughtException)
Log details of an unexpected exception detected by the OMRS.
|
void |
logRecord(String actionDescription,
String logMessageId,
OMRSAuditLogRecordSeverity severity,
String logMessage,
String additionalInformation,
String systemAction,
String userAction)
Log an audit log record for an event, decision, error, or exception detected by the OMRS.
|
static void |
setLocalMetadataCollectionId(String localMetadataCollectionId)
Set up the local metadata collection Id.
|
public OMRSAuditLog(int componentId,
String componentName,
String componentDescription,
String componentWikiURL)
componentId - numerical identifier for the component.componentName - display name for the component.componentDescription - description of the component.componentWikiURL - link to more information.public OMRSAuditLog(OMRSAuditingComponent reportingComponent)
reportingComponent - information about the component that will use this instance of the audit log.public static void initialize(String localServerName, String localServerType, String localOrganizationName, List<OMRSAuditLogStore> auditLogStores)
localServerName - name of the local serverlocalServerType - type of the local serverlocalOrganizationName - name of the organization that owns the local serverauditLogStores - list of destinations for the audit log recordspublic static void setLocalMetadataCollectionId(String localMetadataCollectionId)
localMetadataCollectionId - String unique identifier for the metadata collectionpublic void logRecord(String actionDescription, String logMessageId, OMRSAuditLogRecordSeverity severity, String logMessage, String additionalInformation, String systemAction, String userAction)
actionDescription - description of the activity creating the audit log recordlogMessageId - id for the audit log recordseverity - is this an event, decision, error or exception?logMessage - description of the audit log record including specific resources involvedadditionalInformation - additional data to help resolve issues of verify behaviorsystemAction - the related action taken by the OMRS.userAction - details of any action that an administrator needs to take.public void logException(String actionDescription, String logMessageId, OMRSAuditLogRecordSeverity severity, String logMessage, String additionalInformation, String systemAction, String userAction, Throwable caughtException)
actionDescription - description of the activity in progress when the error occurredlogMessageId - id for the type of exception caughtseverity - severity of the errorlogMessage - description of the exception including specific resources involvedadditionalInformation - additional data to help resolve issues of verify behaviorsystemAction - the action taken by the OMRS in response to the error.userAction - details of any action that an administrator needs to take.caughtException - the original exception.Copyright © 2017–2018 ODPi. All rights reserved.