Show / Hide Table of Contents

Interface CfnDistribution.ICacheSettingsProperty

CacheSettings is a property of the AWS::Lightsail::Distribution resource. It describes the cache settings of an Amazon Lightsail content delivery network (CDN) distribution.

Namespace: Amazon.CDK.AWS.Lightsail
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface CfnDistribution.ICacheSettingsProperty
Syntax (vb)
Public Interface CfnDistribution.ICacheSettingsProperty
Remarks

These settings apply only to your distribution’s CacheBehaviors that have a Behavior of cache . This includes the DefaultCacheBehavior .

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.Lightsail;

             var cacheSettingsProperty = new CacheSettingsProperty {
                 AllowedHttpMethods = "allowedHttpMethods",
                 CachedHttpMethods = "cachedHttpMethods",
                 DefaultTtl = 123,
                 ForwardedCookies = new CookieObjectProperty {
                     CookiesAllowList = new [] { "cookiesAllowList" },
                     Option = "option"
                 },
                 ForwardedHeaders = new HeaderObjectProperty {
                     HeadersAllowList = new [] { "headersAllowList" },
                     Option = "option"
                 },
                 ForwardedQueryStrings = new QueryStringObjectProperty {
                     Option = false,
                     QueryStringsAllowList = new [] { "queryStringsAllowList" }
                 },
                 MaximumTtl = 123,
                 MinimumTtl = 123
             };

Synopsis

Properties

AllowedHttpMethods

The HTTP methods that are processed and forwarded to the distribution's origin.

CachedHttpMethods

The HTTP method responses that are cached by your distribution.

DefaultTtl

The default amount of time that objects stay in the distribution's cache before the distribution forwards another request to the origin to determine whether the content has been updated.

ForwardedCookies

An object that describes the cookies that are forwarded to the origin.

ForwardedHeaders

An object that describes the headers that are forwarded to the origin.

ForwardedQueryStrings

An object that describes the query strings that are forwarded to the origin.

MaximumTtl

The maximum amount of time that objects stay in the distribution's cache before the distribution forwards another request to the origin to determine whether the object has been updated.

MinimumTtl

The minimum amount of time that objects stay in the distribution's cache before the distribution forwards another request to the origin to determine whether the object has been updated.

Properties

AllowedHttpMethods

The HTTP methods that are processed and forwarded to the distribution's origin.

string? AllowedHttpMethods { get; }
Property Value

string

Remarks

You can specify the following options:

    If you specify GET,HEAD,OPTIONS,PUT,PATCH,POST,DELETE , you might need to restrict access to your distribution's origin so users can't perform operations that you don't want them to. For example, you might not want users to have permission to delete objects from your origin.

    See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-allowedhttpmethods

    CachedHttpMethods

    The HTTP method responses that are cached by your distribution.

    string? CachedHttpMethods { get; }
    Property Value

    string

    Remarks

    You can specify the following options:

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-cachedhttpmethods

      DefaultTtl

      The default amount of time that objects stay in the distribution's cache before the distribution forwards another request to the origin to determine whether the content has been updated.

      double? DefaultTtl { get; }
      Property Value

      double?

      Remarks
      The value specified applies only when the origin does not add HTTP headers such as <code>Cache-Control max-age</code> , <code>Cache-Control s-maxage</code> , and <code>Expires</code> to objects.
      

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-defaultttl

      ForwardedCookies

      An object that describes the cookies that are forwarded to the origin.

      object? ForwardedCookies { get; }
      Property Value

      object

      Remarks

      Your content is cached based on the cookies that are forwarded.

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-forwardedcookies

      ForwardedHeaders

      An object that describes the headers that are forwarded to the origin.

      object? ForwardedHeaders { get; }
      Property Value

      object

      Remarks

      Your content is cached based on the headers that are forwarded.

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-forwardedheaders

      ForwardedQueryStrings

      An object that describes the query strings that are forwarded to the origin.

      object? ForwardedQueryStrings { get; }
      Property Value

      object

      Remarks

      Your content is cached based on the query strings that are forwarded.

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-forwardedquerystrings

      MaximumTtl

      The maximum amount of time that objects stay in the distribution's cache before the distribution forwards another request to the origin to determine whether the object has been updated.

      double? MaximumTtl { get; }
      Property Value

      double?

      Remarks

      The value specified applies only when the origin adds HTTP headers such as Cache-Control max-age , Cache-Control s-maxage , and Expires to objects.

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-maximumttl

      MinimumTtl

      The minimum amount of time that objects stay in the distribution's cache before the distribution forwards another request to the origin to determine whether the object has been updated.

      double? MinimumTtl { get; }
      Property Value

      double?

      Remarks

      A value of 0 must be specified for minimumTTL if the distribution is configured to forward all headers to the origin.

      See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lightsail-distribution-cachesettings.html#cfn-lightsail-distribution-cachesettings-minimumttl

      Back to top Generated by DocFX