public class OMRSAuditLog extends AuditLog
OMRSAuditLog is a class for managing the audit logging of activity for the OMAG components. Each auditing component will have their own instance of an OMRSAuditLog. OMRSAuditLog will ensure audit log records are written to disk in the common OMRSAuditLog for this local server. There are different severities of log record to cover all the activity of the OMRS. This audit log is critical to validate the behavior of the OMAG Service, particularly in the initial interaction of a new member in the OMRS Cohort. Note: There are two implementations in play. The original version was where all the function was provided by OMRS. When the Audit Log Framework (ALF) was added, the OMRS Audit Log was changed to inherit from it. This means that connectors and OMAG services can use the ALF. The original OMRS versions are maintained for backward compatibility. The interface used by the originator will have no difference to the output of the audit log connectors.
  • Constructor Details

    • OMRSAuditLog

      public OMRSAuditLog(OMRSAuditLogDestination omrsDestination, int componentId, ComponentDevelopmentStatus componentDevelopmentStatus, 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.
      Parameters:
      omrsDestination - destination for the log records
      componentId - numerical identifier for the component
      componentDevelopmentStatus - status of the component's implementation
      componentName - display name for the component
      componentDescription - description of the component
      componentWikiURL - link to more information
    • OMRSAuditLog

      public OMRSAuditLog(OMRSAuditLogDestination omrsDestination, OMRSAuditingComponent omrsReportingComponent)
      Constructor used to create the root audit log for OMRS
      Parameters:
      omrsDestination - new logging destination
      omrsReportingComponent - information about the component that will use this instance of the audit log.
  • Method Details

    • createNewAuditLog

      public OMRSAuditLog createNewAuditLog(int componentId, ComponentDevelopmentStatus componentDevelopmentStatus, String componentName, String componentDescription, String componentWikiURL)
      Clone request is used to create an audit log for a component outside of OMRS.
      Overrides:
      createNewAuditLog in class AuditLog
      Parameters:
      componentId - numerical identifier for the component
      componentDevelopmentStatus - status of the component's implementation
      componentName - display name for the component
      componentDescription - description of the component
      componentWikiURL - link to more information
      Returns:
      new logging destination
    • getFullReport

      public OMRSAuditLogReport getFullReport()
      Return a full report for the OMRS Audit log.
      Returns:
      details of the originator, children, and destinations