Interface RepositoryPurge


public interface RepositoryPurge
Defines the administrative actions for purging a repository.
  • Method Details

    • markHomeForPurge

      @Deprecated void markHomeForPurge(AdaptationHome aDataSpaceOrSnapshot, Session aSession) throws OperationException
      Throws:
      OperationException
    • markHomeForHistoryPurge

      void markHomeForHistoryPurge(AdaptationHome aDataSpaceOrSnapshot, Session aSession) throws OperationException
      Marks the specified dataspace or snapshot for history purge.

      This method is equivalent to:

      RepositoryPurge.markHomeForHistoryPurge(aHome,aHome.getCreationDate(),new Date(),aSession);
      Throws:
      OperationException
      See Also:
    • markHomeForHistoryPurge

      void markHomeForHistoryPurge(AdaptationHome aHome, Date aStartDate, Date anEndDate, Session aSession) throws OperationException
      Marks the interval [aStartDate,anEndDate) for the specified dataspace or snapshot for history purge.

      This operation is definitive. This method only requests a purge but does not perform physical purge. The actual purge is not performed until a purge execution is requested (see method purgeAll(Session) purgeAll). Marking a dataspace or snapshot for history purge also marks all its descendants (that is, all child dataspaces and snapshots, recursively) and their initial snapshots.

      If the specified dataspace does not have any history in the selected interval nothing is done. The same holds for its child dataspaces.

      Parameters:
      aHome - the dataspace or snapshot to be marked for history purge.
      aSession - the session that performs the operation; the associated user must be administrator.
      aStartDate - the start date marking the beginning of the history purge interval; if null, the creation of the dataspace is considered as the beginning of the history purge.
      anEndDate - the end date marking the end of the history purge interval.
      Throws:
      OperationException - thrown if operation cannot complete (for example, if a dataspace or snapshot is not closed).
      IllegalArgumentException - thrown if anEndDate is null; thrown if anEndDate is after the current time; thrown if aStartDate is after anEndDate.
      Since:
      5.7.1
      See Also:
    • purgeAll

      void purgeAll(Session aSession) throws OperationException
      Performs a complete deletion of the physical entities that have been marked for purge.

      This operation is definitive.

      Dataspaces can be deleted either using the user interface or by calling the method Repository.deleteHome(AdaptationHome, Session).

      Dataspaces can be marked for history purge either by using the user interface or by calling methods markHomeForHistoryPurge, markHomeForHistoryPurge(AdaptationHome, Date, Date, Session)}.

      Mapped tables can be marked for purge by using the user interface.

      The purge process can be time-consuming for large or long-lived repositories. It is recommended to mark all relevant dataspaces first, before triggering the purge process by invoking this method.

      Parameters:
      aSession - the session that performs the operation; the associated user must be administrator.
      Throws:
      OperationException - thrown if operation cannot complete.