Class AuditLoggingBase

java.lang.Object
org.odpi.openmetadata.frameworks.auditlog.AuditLoggingBase
Direct Known Subclasses:
AtlasIntegrationModuleBase, BitolFileCataloguer, DB2LUWDatabaseStatsExtractor, DirectoryBasedOpenMetadataArchiveStore, DirectoryBasedOpenMetadataArchiveStoreIterator, DirectoryToMonitor, DuckDBDatabaseStatsExtractor, DuckDBFederationExtractor, KafkaOpenMetadataEventConsumer, KafkaOpenMetadataEventConsumerConfiguration, KafkaOpenMetadataEventProducer, MendelDuplicateConsolidator, MSSQLDatabaseStatsExtractor, OracleDatabaseStatsExtractor, OSSUnityCatalogInsideCatalogSyncBase, PostgresDatabaseStatsExtractor, RESTClient

public abstract class AuditLoggingBase extends Object
AuditLoggingBase is the base class for helper classes that are given an audit log when they are created - for example, the classes that a connector delegates part of its work to. It provides the same logRecord and logExceptionRecord methods as the connector base classes, so the audit log can be used without first testing whether it was supplied. When it was not, the records are written to standard out.
  • Field Details

    • auditLog

      protected final AuditLog auditLog
      Logging destination - may be null.
  • Constructor Details

    • AuditLoggingBase

      protected AuditLoggingBase(AuditLog auditLog)
      Constructor.
      Parameters:
      auditLog - logging destination - may be null
  • Method Details

    • logRecord

      protected void logRecord(String actionDescription, AuditLogMessageDefinition messageDefinition)
      Log an audit log record for an event, decision, error, or exception.
      Parameters:
      actionDescription - calling method
      messageDefinition - description of the audit log record including specific resources involved
    • logRecord

      protected void logRecord(String actionDescription, AuditLogMessageDefinition messageDefinition, String additionalInformation)
      Log an audit log record for an event, decision, error, or exception, with supporting information.
      Parameters:
      actionDescription - calling method
      messageDefinition - description of the audit log record including specific resources involved
      additionalInformation - supporting information
    • logExceptionRecord

      protected void logExceptionRecord(String actionDescription, AuditLogMessageDefinition messageDefinition, Throwable exception)
      Log an audit log record for an exception.
      Parameters:
      actionDescription - calling method
      messageDefinition - description of the audit log record including specific resources involved
      exception - the exception associated with the message
    • logExceptionRecord

      protected void logExceptionRecord(String actionDescription, AuditLogMessageDefinition messageDefinition, String additionalInformation, Throwable exception)
      Log an audit log record for an exception, with supporting information.
      Parameters:
      actionDescription - calling method
      messageDefinition - description of the audit log record including specific resources involved
      additionalInformation - supporting information
      exception - the exception associated with the message