Interface DownloadArtifactPostProcessor


  • @ConsumerType
    public interface DownloadArtifactPostProcessor
    This interface provides entry points for consumers to add custom processing of download artifacts.
    • Method Detail

      • processDownloadArtifact

        boolean processDownloadArtifact​(String downloadId,
                                        DownloadProgress progress,
                                        DownloadArtifact artifact,
                                        DownloadArtifactPostProcessor.DownloadArtifactBinary binary)

        Entry point for custom processing of download artifacts. Implementing will prevent wait for download functionality in DownloadServlet.

        This method is called as part of the AsyncArchiveProgressService.setArchiveBinary(String, String, ArchiveBinary), upon successfully setting the archive binary.

        Parameters:
        downloadId - Unique identifier for the download.
        progress - Can be used by the post processor to get information about the download.
        artifact - Item whose parameters can be used by the processor to retrieve binary information.
        binary - The archive binary.
        Returns:
        Value indicates whether the download artifact was handled.
      • purgeDownload

        boolean purgeDownload​(String downloadId)

        Entry point for custom purging of download artifacts.

        This method is called as part of DownloadStorageService.purgeDownload(String, ResourceResolver), upon successfully purging the archive binary.

        Parameters:
        downloadId - Unique identifier for the download.
        Returns:
        Value indicates whether the download artifact was handled.