Class ReadToS3

java.lang.Object
org.cdlib.mrt.s3v2.action.ReadToS3

public class ReadToS3 extends Object
Before running this Java V2 code example, set up your development environment, including your credentials.

For more information, see the following documentation topic:

https://docs.aws.amazon.com/sdk-for-java/latest/developer-guide/get-started.html

  • Field Details

    • log4j

      protected static final org.apache.logging.log4j.Logger log4j
    • DEBUG

      protected static final boolean DEBUG
      See Also:
    • s3

      protected software.amazon.awssdk.services.s3.S3Client s3
    • bucketName

      protected String bucketName
    • s3Reader

      protected S3Reader s3Reader
    • keyName

      protected String keyName
    • digestTypesS

      protected String[] digestTypesS
    • checksumHandler

      protected ChecksumHandler checksumHandler
    • inObjectSize

      protected long inObjectSize
    • response

      protected RetrieveResponse response
    • fillSha256

      protected String fillSha256
    • fillSize

      protected long fillSize
  • Constructor Details

    • ReadToS3

      protected ReadToS3(software.amazon.awssdk.services.s3.S3Client s3, String bucketName, String keyName, String[] digestTypesS, S3Reader s3Reader) throws org.cdlib.mrt.utility.TException
      Throws:
      org.cdlib.mrt.utility.TException
  • Method Details

    • getReadToS3

      public static ReadToS3 getReadToS3(software.amazon.awssdk.services.s3.S3Client s3, String bucketName, String keyName, String[] digestTypesS, S3Reader s3Reader) throws org.cdlib.mrt.utility.TException
      Throws:
      org.cdlib.mrt.utility.TException
    • doUpload

      public RetrieveResponse doUpload() throws org.cdlib.mrt.utility.TException
      Throws:
      org.cdlib.mrt.utility.TException
    • validateWrite

      protected void validateWrite(RetrieveResponse response) throws org.cdlib.mrt.utility.TException
      Throws:
      org.cdlib.mrt.utility.TException
    • uploadFile

      public RetrieveResponse uploadFile(Map<String,String> metadata) throws org.cdlib.mrt.utility.TException
      Throws:
      org.cdlib.mrt.utility.TException
    • uploadFileParts

      public RetrieveResponse uploadFileParts(Map<String,String> metadata) throws org.cdlib.mrt.utility.TException
      Throws:
      org.cdlib.mrt.utility.TException
    • isExec

      public boolean isExec()
    • setExec

      public void setExec(boolean exec)
    • getResponse

      public RetrieveResponse getResponse()
    • getFillSha256

      public String getFillSha256()
    • getFillSize

      public Long getFillSize()
    • getChecksumHandler

      public ChecksumHandler getChecksumHandler()