Amazon CloudFront
API Reference (API Version 2010-11-01)
Print this pageEmail this pageGo to the ForumsView the PDFShare this page on TwitterShare this page on FacebookBookmark this page on DeliciousSubmit this page to RedditSubmit this page to DiggDid this page help you?  Yes  No   Tell us about it...

StreamingDistributionConfig Complex Type

Description

The StreamingDistributionConfig complex type describes a streaming distribution's configuration information. For more information about streaming distributions, go to Working with Distributions and Streaming Media Files in the Amazon CloudFront Developer Guide.

Usage:

Syntax

<StreamingDistributionConfig xmlns="http://cloudfront.amazonaws.com/doc/2010-11-01/">
   <S3Origin>
      <DNSName>dns name</DNSName>
   </S3Origin>
   <CallerReference>ref</CallerReference>
   <CNAME>name;</CNAME>
   <CNAME>canonical name;/CNAME>
   <Comment>The comment.</Comment>
   <Enabled>true or false</Enabled>
      <Enabled>true or false</Enabled>
   <Logging>
      <Bucket>mylogs.s3.amazonaws.com</Bucket>
      <Prefix/>
   </Logging>
</StreamingDistributionConfig>

Elements

The following table describes the child elements in the StreamingDistributionConfig datatype. They're presented in the order they appear in the configuration.

NameDescriptionRequired

S3Origin

S3 Origin information to associate with the distribution.

Type: Complex

Default: None

S3Origin Children: see S3Origin Child Elements

Yes

CallerReference

A unique number that ensures the request can't be replayed.

If the CallerReference is new (no matter the content of the StreamingDistributionConfig object), a new streaming distribution is created.

If the CallerReference is a value you already sent in a previous request to create a streaming distribution, and the content of the StreamingDistributionConfig is identical to the original request (ignoring white space), the response includes the same information returned to the original request.

If the CallerReference is a value you already sent in a previous request to create a streaming distribution but the content of the StreamingDistributionConfig is different from the original request, CloudFront returns a DistributionAlreadyExists error.

Type: String

Constraints: Allowable characters are any Unicode code points that are legal in an XML 1.0 document. The UTF-8 encoding of the value must be less than 128 bytes.

Default: None

Yes

CNAME

A CNAME alias you want to associate with this streaming distribution. You can have up to 10 CNAME aliases per streaming distribution. For more information, go to Using CNAMEs in the Amazon CloudFront Developer Guide.

Only include a CNAME element if you have a CNAME to associate with the distribution. Don't include an empty CNAME element in the StreamingDistributionConfig object. If you do, CloudFront returns a MalformedXML error.

Type: String

Valid Value: The CNAME alias

Default: None

No

Comment

Any comments you want to include about the streaming distribution.

Type: String

Constraints: Maximum 128 characters

Default: None

No

Enabled

Whether the streaming distribution is enabled to accept end user requests for content.

Type: Boolean

Valid Values: false | true

Default: None

Yes

Logging

A complex type that controls whether access logs are written for the streaming distribution. If you want to turn on access logs, include this element; if you want to turn off access logs, remove this element. For more information, go to Access Logs in the Amazon CloudFront Developer Guide.

Type: Complex type

Children: Bucket, Prefix (for descriptions, see Logging Child Elements)

Default: None

No

TrustedSigners

A complex type that specifies any AWS accounts you want to permit to create signed URLs for private content. If you want the distribution to use signed URLs, include this element; if you want the distribution to use basic URLs, remove this element. For more information, go to Serving Private Content in the Amazon CloudFront Developer Guide.

Type: Complex type

Children: Self, AwsAccountNumber (for descriptions, see TrustedSigners Child Elements)

Default: None

No

S3Origin Child Elements

The following table describes the child elements of the S3Origin element.

NameDescriptionRequired

DNSName

The DNS name of your Amazon S3 bucket to associate with the distribution. For example: mybucket.s3.amazonaws.com.

Type: String

Default: None

Constraints: Maximum 128 characters

Yes

OriginAccessIdentity

The CloudFront origin access identity to associate with the streaming distribution. If you want the distribution to serve private content, include this element; if you want the streaming distribution to serve public content, remove this element. For more information, go to Serving Private Content in the Amazon CloudFront Developer Guide.

Type: String

Default: None

Constraints: Must be in format origin-access-identity/cloudfront/ID

Optional

Logging Child Elements

The following table describes the child elements of the Logging element.

NameDescriptionRequired

Bucket

The Amazon S3 bucket to store the access logs in. For example: mylogs.s3.amazonaws.com.

Type: String

Constraints: Maximum 128 characters

Default: None

Yes

Prefix

An optional string of your choice to prefix to the access log filenames for this distribution. For example: myprefix/.

If you decide not to use a prefix, you must still include the empty Prefix element in the Logging element.

Type: String

Constraints: Maximum 256 characters; the string must not start with a slash ( / ).

Default: None

No

Examples

Example without CNAMEs

The following example configuration is for a streaming distribution with no CNAMEs.

<StreamingDistributionConfig xmlns="http://cloudfront.amazonaws.com/doc/2010-11-01/">
   <S3Origin>
      <DNSName>mystreamingbucket.s3.amazonaws.com</DNSName>
   </S3Origin>
   <CallerReference>20091130090000</CallerReference>
   <Comment>My comments</Comment>
   <Enabled>true</Enabled>
</StreamingDistributionConfig>

Example with CNAMEs

The following configuration is for a streaming distribution with two CNAMEs and with logging enabled.

<StreamingDistributionConfig xmlns="http://cloudfront.amazonaws.com/doc/2010-11-01/">
   <S3Origin>
      <DNSName>mystreamingbucket.s3.amazonaws.com</DNSName>
   </S3Origin>
   <CallerReference>20091130090000</CallerReference>
   <CNAME>beagles.com</CNAME>
   <CNAME>beagles.dogs.com</CNAME>
   <Comment>My comments</Comment>
   <Enabled>true</Enabled>
      <Enabled>true</Enabled>
   <Logging>
      <Bucket>mylogs.s3.amazonaws.com</Bucket>
      <Prefix>myprefix/</Prefix>
   </Logging>
</StreamingDistributionConfig>