Interface StandaloneCleanupRepository


public interface StandaloneCleanupRepository
Represents a repository that is capable of specialized record pruning operations
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Performs an update on all records to prune all NotificationStates from NotificationStateAware.getNotificationStates() which satisfy the following criteria: NotificationState.isAcked() is true or NotificationState.isStopped() is true NotificationState.getChangeTimestamp() is before Instant.now() minus the beforeNow duration
  • Method Details

    • pruneRestingNotificationStates

      void pruneRestingNotificationStates(@NonNull Duration beforeNow)
      Performs an update on all records to prune all NotificationStates from NotificationStateAware.getNotificationStates() which satisfy the following criteria:
      • NotificationState.isAcked() is true or NotificationState.isStopped() is true
      • NotificationState.getChangeTimestamp() is before Instant.now() minus the beforeNow duration
      Parameters:
      beforeNow - NotificationStates whose timestamps are older than the current time minus this duration will be pruned