Class MediaPackageV2Origin.Builder

java.lang.Object
software.amazon.awscdk.services.mediapackagev2.alpha.MediaPackageV2Origin.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<MediaPackageV2Origin>
Enclosing class:
MediaPackageV2Origin

@Stability(Experimental) public static final class MediaPackageV2Origin.Builder extends Object implements software.amazon.jsii.Builder<MediaPackageV2Origin>
(experimental) A fluent builder for MediaPackageV2Origin.
  • Method Details

    • create

      @Stability(Experimental) public static MediaPackageV2Origin.Builder create(IOriginEndpoint endpoint)
      Parameters:
      endpoint - This parameter is required.
      Returns:
      a new instance of MediaPackageV2Origin.Builder.
    • connectionAttempts

      @Stability(Stable) public MediaPackageV2Origin.Builder connectionAttempts(Number connectionAttempts)
      The number of times that CloudFront attempts to connect to the origin;

      valid values are 1, 2, or 3 attempts.

      Default: 3

      Parameters:
      connectionAttempts - The number of times that CloudFront attempts to connect to the origin;. This parameter is required.
      Returns:
      this
    • connectionTimeout

      @Stability(Stable) public MediaPackageV2Origin.Builder connectionTimeout(Duration connectionTimeout)
      The number of seconds that CloudFront waits when trying to establish a connection to the origin.

      Valid values are 1-10 seconds, inclusive.

      Default: Duration.seconds(10)

      Parameters:
      connectionTimeout - The number of seconds that CloudFront waits when trying to establish a connection to the origin. This parameter is required.
      Returns:
      this
    • customHeaders

      @Stability(Stable) public MediaPackageV2Origin.Builder customHeaders(Map<String,String> customHeaders)
      A list of HTTP header names and values that CloudFront adds to requests it sends to the origin.

      Default: {}

      Parameters:
      customHeaders - A list of HTTP header names and values that CloudFront adds to requests it sends to the origin. This parameter is required.
      Returns:
      this
    • originAccessControlId

      @Stability(Stable) public MediaPackageV2Origin.Builder originAccessControlId(String originAccessControlId)
      The unique identifier of an origin access control for this origin.

      Default: - no origin access control

      Parameters:
      originAccessControlId - The unique identifier of an origin access control for this origin. This parameter is required.
      Returns:
      this
    • originId

      @Stability(Stable) public MediaPackageV2Origin.Builder originId(String originId)
      A unique identifier for the origin.

      This value must be unique within the distribution.

      Default: - an originid will be generated for you

      Parameters:
      originId - A unique identifier for the origin. This parameter is required.
      Returns:
      this
    • originShieldEnabled

      @Stability(Stable) public MediaPackageV2Origin.Builder originShieldEnabled(Boolean originShieldEnabled)
      Origin Shield is enabled by setting originShieldRegion to a valid region, after this to disable Origin Shield again you must set this flag to false.

      Default: - true

      Parameters:
      originShieldEnabled - Origin Shield is enabled by setting originShieldRegion to a valid region, after this to disable Origin Shield again you must set this flag to false. This parameter is required.
      Returns:
      this
    • originShieldRegion

      @Stability(Stable) public MediaPackageV2Origin.Builder originShieldRegion(String originShieldRegion)
      When you enable Origin Shield in the AWS Region that has the lowest latency to your origin, you can get better network performance.

      Default: - origin shield not enabled

      Parameters:
      originShieldRegion - When you enable Origin Shield in the AWS Region that has the lowest latency to your origin, you can get better network performance. This parameter is required.
      Returns:
      this
      See Also:
    • responseCompletionTimeout

      @Stability(Stable) public MediaPackageV2Origin.Builder responseCompletionTimeout(Duration responseCompletionTimeout)
      The time that a request from CloudFront to the origin can stay open and wait for a response.

      If the complete response isn't received from the origin by this time, CloudFront ends the connection.

      Valid values are 1-3600 seconds, inclusive.

      Default: undefined - AWS CloudFront default is not enforcing a maximum value

      Parameters:
      responseCompletionTimeout - The time that a request from CloudFront to the origin can stay open and wait for a response. This parameter is required.
      Returns:
      this
      See Also:
    • originPath

      @Stability(Stable) public MediaPackageV2Origin.Builder originPath(String originPath)
      An optional path that CloudFront appends to the origin domain name when CloudFront requests content from the origin.

      Must begin, but not end, with '/' (e.g., '/production/images').

      Default: '/'

      Parameters:
      originPath - An optional path that CloudFront appends to the origin domain name when CloudFront requests content from the origin. This parameter is required.
      Returns:
      this
    • channelGroup

      @Stability(Experimental) public MediaPackageV2Origin.Builder channelGroup(IChannelGroup channelGroup)
      (experimental) The channel group that the origin endpoint belongs to.

      Used to derive the egress domain for the CloudFront origin.

      Parameters:
      channelGroup - The channel group that the origin endpoint belongs to. This parameter is required.
      Returns:
      this
    • originAccessControl

      @Stability(Experimental) public MediaPackageV2Origin.Builder originAccessControl(IOriginAccessControlRef originAccessControl)
      (experimental) An optional Origin Access Control.

      Default: - an Origin Access Control will be created automatically.

      Parameters:
      originAccessControl - An optional Origin Access Control. This parameter is required.
      Returns:
      this
    • build

      @Stability(Experimental) public MediaPackageV2Origin build()
      Specified by:
      build in interface software.amazon.jsii.Builder<MediaPackageV2Origin>
      Returns:
      a newly built instance of MediaPackageV2Origin.