Class S3JobArchiverImpl
- java.lang.Object
-
- com.netflix.genie.common.internal.services.impl.S3JobArchiverImpl
-
- All Implemented Interfaces:
JobArchiver
public class S3JobArchiverImpl extends java.lang.Object implements JobArchiver
Implementation ofJobArchiveServicefor S3 destinations.- Since:
- 4.0.0
-
-
Constructor Summary
Constructors Constructor Description S3JobArchiverImpl(S3ClientFactory s3ClientFactory)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanarchiveDirectory(@NotNull java.nio.file.Path directory, java.util.List<java.io.File> filesList, @NotNull java.net.URI target)Attempt to archive a directory located atdirectoryto thetarget.
-
-
-
Constructor Detail
-
S3JobArchiverImpl
public S3JobArchiverImpl(S3ClientFactory s3ClientFactory)
Constructor.- Parameters:
s3ClientFactory- The factory to use to get S3 client instances for a given S3 bucket.
-
-
Method Detail
-
archiveDirectory
public boolean archiveDirectory(@NotNull @NotNull java.nio.file.Path directory, java.util.List<java.io.File> filesList, @NotNull @NotNull java.net.URI target) throws JobArchiveExceptionAttempt to archive a directory located atdirectoryto thetarget. All existing data "under"targetshould be assumed to be overwritten/replaced.- Specified by:
archiveDirectoryin interfaceJobArchiver- Parameters:
directory- The directory to archivefilesList- The list of files to archivetarget- The root of a writable location to archive to.- Returns:
falseif this implementation doesn't support archiving totarget.trueif does support archiving totargetand the archival was successful- Throws:
JobArchiveException- If an exception happened during archival
-
-