Class PayloadStorageConfigurationBase

java.lang.Object
software.amazon.payloadoffloading.PayloadStorageConfigurationBase
Direct Known Subclasses:
PayloadStorageAsyncConfiguration, PayloadStorageConfiguration

@NotThreadSafe public abstract class PayloadStorageConfigurationBase extends Object

Base class for Amazon payload storage configuration options such as Amazon S3 client, bucket name, and payload size threshold for payloads.

See Also:
  • Constructor Details

    • PayloadStorageConfigurationBase

      public PayloadStorageConfigurationBase()
    • PayloadStorageConfigurationBase

      public PayloadStorageConfigurationBase(PayloadStorageConfigurationBase other)
  • Method Details

    • setPayloadSupportEnabled

      protected void setPayloadSupportEnabled(String s3BucketName)
      Enables support for payloads .
      Parameters:
      s3BucketName - Name of the bucket which is going to be used for storing payload. The bucket must be already created and configured in s3.
    • setPayloadSupportDisabled

      public void setPayloadSupportDisabled()
      Disables support for payloads.
    • isPayloadSupportEnabled

      public boolean isPayloadSupportEnabled()
      Check if the support for payloads if enabled.
      Returns:
      true if support for payloads is enabled.
    • getS3BucketName

      public String getS3BucketName()
      Gets the name of the S3 bucket which is being used for storing payload.
      Returns:
      The name of the bucket which is being used.
    • getPayloadSizeThreshold

      public int getPayloadSizeThreshold()
      Gets the payload size threshold for storing payloads in Amazon S3.
      Returns:
      payload size threshold which is being used for storing in Amazon S3. Default: 256KB.
    • setPayloadSizeThreshold

      public void setPayloadSizeThreshold(int payloadSizeThreshold)
      Sets the payload size threshold for storing payloads in Amazon S3.
      Parameters:
      payloadSizeThreshold - Payload size threshold to be used for storing in Amazon S3. Default: 256KB.
    • isAlwaysThroughS3

      public boolean isAlwaysThroughS3()
      Checks whether or not all payloads regardless of their size are being stored in Amazon S3.
      Returns:
      True if all payloads regardless of their size are being stored in Amazon S3. Default: false
    • setAlwaysThroughS3

      public void setAlwaysThroughS3(boolean alwaysThroughS3)
      Sets whether or not all payloads regardless of their size should be stored in Amazon S3.
      Parameters:
      alwaysThroughS3 - Whether or not all payloads regardless of their size should be stored in Amazon S3. Default: false
    • setServerSideEncryptionStrategy

      public void setServerSideEncryptionStrategy(ServerSideEncryptionStrategy serverSideEncryptionStrategy)
      Sets which method of server side encryption should be use, if required. This is optional, it is set only when you want to configure S3 Server Side Encryption with KMS.
      Parameters:
      serverSideEncryptionStrategy - The method of encryption required for S3 server side encryption with KMS.
    • getServerSideEncryptionStrategy

      public ServerSideEncryptionStrategy getServerSideEncryptionStrategy()
      The method of service side encryption which should be used, if required.
      Returns:
      The server side encryption method required. Default null.
    • setObjectCannedACL

      public void setObjectCannedACL(software.amazon.awssdk.services.s3.model.ObjectCannedACL objectCannedACL)
      Configures the ACL to apply to the Amazon S3 putObject request.
      Parameters:
      objectCannedACL - The ACL to be used when storing objects in Amazon S3
    • isObjectCannedACLDefined

      public boolean isObjectCannedACLDefined()
      Checks whether an ACL have been configured for storing objects in Amazon S3.
      Returns:
      True if ACL is defined
    • getObjectCannedACL

      public software.amazon.awssdk.services.s3.model.ObjectCannedACL getObjectCannedACL()
      Gets the AWS ACL to apply to the Amazon S3 putObject request.
      Returns:
      Amazon S3 object ACL