{-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE DuplicateRecordFields #-} {-# LANGUAGE NamedFieldPuns #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StrictData #-} {-# LANGUAGE NoImplicitPrelude #-} {-# OPTIONS_GHC -fno-warn-unused-imports #-} {-# OPTIONS_GHC -fno-warn-unused-matches #-} -- Derived from AWS service descriptions, licensed under Apache 2.0. -- | -- Module : Amazonka.CloudFront.Types.CacheBehavior -- Copyright : (c) 2013-2023 Brendan Hay -- License : Mozilla Public License, v. 2.0. -- Maintainer : Brendan Hay -- Stability : auto-generated -- Portability : non-portable (GHC extensions) module Amazonka.CloudFront.Types.CacheBehavior where import Amazonka.CloudFront.Types.AllowedMethods import Amazonka.CloudFront.Types.ForwardedValues import Amazonka.CloudFront.Types.FunctionAssociations import Amazonka.CloudFront.Types.LambdaFunctionAssociations import Amazonka.CloudFront.Types.TrustedKeyGroups import Amazonka.CloudFront.Types.TrustedSigners import Amazonka.CloudFront.Types.ViewerProtocolPolicy import qualified Amazonka.Core as Core import qualified Amazonka.Core.Lens.Internal as Lens import qualified Amazonka.Data as Data import qualified Amazonka.Prelude as Prelude -- | A complex type that describes how CloudFront processes requests. -- -- You must create at least as many cache behaviors (including the default -- cache behavior) as you have origins if you want CloudFront to serve -- objects from all of the origins. Each cache behavior specifies the one -- origin from which you want CloudFront to get objects. If you have two -- origins and only the default cache behavior, the default cache behavior -- will cause CloudFront to get objects from one of the origins, but the -- other origin is never used. -- -- For the current quota (formerly known as limit) on the number of cache -- behaviors that you can add to a distribution, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cloudfront-limits.html Quotas> -- in the /Amazon CloudFront Developer Guide/. -- -- If you don\'t want to specify any cache behaviors, include only an empty -- @CacheBehaviors@ element. Don\'t include an empty @CacheBehavior@ -- element because this is invalid. -- -- To delete all cache behaviors in an existing distribution, update the -- distribution configuration and include only an empty @CacheBehaviors@ -- element. -- -- To add, change, or remove one or more cache behaviors, update the -- distribution configuration and specify all of the cache behaviors that -- you want to include in the updated distribution. -- -- For more information about cache behaviors, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesCacheBehavior Cache Behavior Settings> -- in the /Amazon CloudFront Developer Guide/. -- -- /See:/ 'newCacheBehavior' smart constructor. data CacheBehavior = CacheBehavior' { CacheBehavior -> Maybe AllowedMethods allowedMethods :: Prelude.Maybe AllowedMethods, -- | The unique identifier of the cache policy that is attached to this cache -- behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- A @CacheBehavior@ must include either a @CachePolicyId@ or -- @ForwardedValues@. We recommend that you use a @CachePolicyId@. CacheBehavior -> Maybe Text cachePolicyId :: Prelude.Maybe Prelude.Text, -- | Whether you want CloudFront to automatically compress certain files for -- this cache behavior. If so, specify true; if not, specify false. For -- more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html Serving Compressed Files> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe Bool compress :: Prelude.Maybe Prelude.Bool, -- | This field is deprecated. We recommend that you use the @DefaultTTL@ -- field in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The default amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. The value that you -- specify applies only when your origin does not add HTTP headers such as -- @Cache-Control max-age@, @Cache-Control s-maxage@, and @Expires@ to -- objects. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe Integer defaultTTL :: Prelude.Maybe Prelude.Integer, -- | The value of @ID@ for the field-level encryption configuration that you -- want CloudFront to use for encrypting specific fields of data for this -- cache behavior. CacheBehavior -> Maybe Text fieldLevelEncryptionId :: Prelude.Maybe Prelude.Text, -- | This field is deprecated. We recommend that you use a cache policy or an -- origin request policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html Working with policies> -- in the /Amazon CloudFront Developer Guide/. -- -- If you want to include values in the cache key, use a cache policy. For -- more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- If you want to send values to the origin but not include them in the -- cache key, use an origin request policy. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-origin-requests.html#origin-request-create-origin-request-policy Creating origin request policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-origin-request-policies.html Using the managed origin request policies> -- in the /Amazon CloudFront Developer Guide/. -- -- A @CacheBehavior@ must include either a @CachePolicyId@ or -- @ForwardedValues@. We recommend that you use a @CachePolicyId@. -- -- A complex type that specifies how CloudFront handles query strings, -- cookies, and HTTP headers. CacheBehavior -> Maybe ForwardedValues forwardedValues :: Prelude.Maybe ForwardedValues, -- | A list of CloudFront functions that are associated with this cache -- behavior. CloudFront functions must be published to the @LIVE@ stage to -- associate them with a cache behavior. CacheBehavior -> Maybe FunctionAssociations functionAssociations :: Prelude.Maybe FunctionAssociations, -- | A complex type that contains zero or more Lambda\@Edge function -- associations for a cache behavior. CacheBehavior -> Maybe LambdaFunctionAssociations lambdaFunctionAssociations :: Prelude.Maybe LambdaFunctionAssociations, -- | This field is deprecated. We recommend that you use the @MaxTTL@ field -- in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The maximum amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. The value that you -- specify applies only when your origin adds HTTP headers such as -- @Cache-Control max-age@, @Cache-Control s-maxage@, and @Expires@ to -- objects. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe Integer maxTTL :: Prelude.Maybe Prelude.Integer, -- | This field is deprecated. We recommend that you use the @MinTTL@ field -- in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The minimum amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. -- -- You must specify @0@ for @MinTTL@ if you configure CloudFront to forward -- all headers to your origin (under @Headers@, if you specify @1@ for -- @Quantity@ and @*@ for @Name@). CacheBehavior -> Maybe Integer minTTL :: Prelude.Maybe Prelude.Integer, -- | The unique identifier of the origin request policy that is attached to -- this cache behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-origin-requests.html#origin-request-create-origin-request-policy Creating origin request policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-origin-request-policies.html Using the managed origin request policies> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe Text originRequestPolicyId :: Prelude.Maybe Prelude.Text, -- | The Amazon Resource Name (ARN) of the real-time log configuration that -- is attached to this cache behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/real-time-logs.html Real-time logs> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe Text realtimeLogConfigArn :: Prelude.Maybe Prelude.Text, -- | The identifier for a response headers policy. CacheBehavior -> Maybe Text responseHeadersPolicyId :: Prelude.Maybe Prelude.Text, -- | Indicates whether you want to distribute media files in the Microsoft -- Smooth Streaming format using the origin that is associated with this -- cache behavior. If so, specify @true@; if not, specify @false@. If you -- specify @true@ for @SmoothStreaming@, you can still distribute other -- content using this cache behavior if the content matches the value of -- @PathPattern@. CacheBehavior -> Maybe Bool smoothStreaming :: Prelude.Maybe Prelude.Bool, -- | A list of key groups that CloudFront can use to validate signed URLs or -- signed cookies. -- -- When a cache behavior contains trusted key groups, CloudFront requires -- signed URLs or signed cookies for all requests that match the cache -- behavior. The URLs or cookies must be signed with a private key whose -- corresponding public key is in the key group. The signed URL or cookie -- contains information about which public key CloudFront should use to -- verify the signature. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html Serving private content> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe TrustedKeyGroups trustedKeyGroups :: Prelude.Maybe TrustedKeyGroups, -- | We recommend using @TrustedKeyGroups@ instead of @TrustedSigners@. -- -- A list of Amazon Web Services account IDs whose public keys CloudFront -- can use to validate signed URLs or signed cookies. -- -- When a cache behavior contains trusted signers, CloudFront requires -- signed URLs or signed cookies for all requests that match the cache -- behavior. The URLs or cookies must be signed with the private key of a -- CloudFront key pair in the trusted signer\'s Amazon Web Services -- account. The signed URL or cookie contains information about which -- public key CloudFront should use to verify the signature. For more -- information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html Serving private content> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Maybe TrustedSigners trustedSigners :: Prelude.Maybe TrustedSigners, -- | The pattern (for example, @images\/*.jpg@) that specifies which requests -- to apply the behavior to. When CloudFront receives a viewer request, the -- requested path is compared with path patterns in the order in which -- cache behaviors are listed in the distribution. -- -- You can optionally include a slash (@\/@) at the beginning of the path -- pattern. For example, @\/images\/*.jpg@. CloudFront behavior is the same -- with or without the leading @\/@. -- -- The path pattern for the default cache behavior is @*@ and cannot be -- changed. If the request for an object does not match the path pattern -- for any cache behaviors, CloudFront applies the behavior in the default -- cache behavior. -- -- For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesPathPattern Path Pattern> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> Text pathPattern :: Prelude.Text, -- | The value of @ID@ for the origin that you want CloudFront to route -- requests to when they match this cache behavior. CacheBehavior -> Text targetOriginId :: Prelude.Text, -- | The protocol that viewers can use to access the files in the origin -- specified by @TargetOriginId@ when a request matches the path pattern in -- @PathPattern@. You can specify the following options: -- -- - @allow-all@: Viewers can use HTTP or HTTPS. -- -- - @redirect-to-https@: If a viewer submits an HTTP request, CloudFront -- returns an HTTP status code of 301 (Moved Permanently) to the viewer -- along with the HTTPS URL. The viewer then resubmits the request -- using the new URL. -- -- - @https-only@: If a viewer sends an HTTP request, CloudFront returns -- an HTTP status code of 403 (Forbidden). -- -- For more information about requiring the HTTPS protocol, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-https-viewers-to-cloudfront.html Requiring HTTPS Between Viewers and CloudFront> -- in the /Amazon CloudFront Developer Guide/. -- -- The only way to guarantee that viewers retrieve an object that was -- fetched from the origin using HTTPS is never to use any other protocol -- to fetch the object. If you have recently changed from HTTP to HTTPS, we -- recommend that you clear your objects\' cache because cached objects are -- protocol agnostic. That means that an edge location will return an -- object from the cache regardless of whether the current request protocol -- matches the protocol used previously. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing Cache Expiration> -- in the /Amazon CloudFront Developer Guide/. CacheBehavior -> ViewerProtocolPolicy viewerProtocolPolicy :: ViewerProtocolPolicy } deriving (CacheBehavior -> CacheBehavior -> Bool forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a /= :: CacheBehavior -> CacheBehavior -> Bool $c/= :: CacheBehavior -> CacheBehavior -> Bool == :: CacheBehavior -> CacheBehavior -> Bool $c== :: CacheBehavior -> CacheBehavior -> Bool Prelude.Eq, ReadPrec [CacheBehavior] ReadPrec CacheBehavior Int -> ReadS CacheBehavior ReadS [CacheBehavior] forall a. (Int -> ReadS a) -> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a readListPrec :: ReadPrec [CacheBehavior] $creadListPrec :: ReadPrec [CacheBehavior] readPrec :: ReadPrec CacheBehavior $creadPrec :: ReadPrec CacheBehavior readList :: ReadS [CacheBehavior] $creadList :: ReadS [CacheBehavior] readsPrec :: Int -> ReadS CacheBehavior $creadsPrec :: Int -> ReadS CacheBehavior Prelude.Read, Int -> CacheBehavior -> ShowS [CacheBehavior] -> ShowS CacheBehavior -> String forall a. (Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a showList :: [CacheBehavior] -> ShowS $cshowList :: [CacheBehavior] -> ShowS show :: CacheBehavior -> String $cshow :: CacheBehavior -> String showsPrec :: Int -> CacheBehavior -> ShowS $cshowsPrec :: Int -> CacheBehavior -> ShowS Prelude.Show, forall x. Rep CacheBehavior x -> CacheBehavior forall x. CacheBehavior -> Rep CacheBehavior x forall a. (forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a $cto :: forall x. Rep CacheBehavior x -> CacheBehavior $cfrom :: forall x. CacheBehavior -> Rep CacheBehavior x Prelude.Generic) -- | -- Create a value of 'CacheBehavior' with all optional fields omitted. -- -- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields. -- -- The following record fields are available, with the corresponding lenses provided -- for backwards compatibility: -- -- 'allowedMethods', 'cacheBehavior_allowedMethods' - Undocumented member. -- -- 'cachePolicyId', 'cacheBehavior_cachePolicyId' - The unique identifier of the cache policy that is attached to this cache -- behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- A @CacheBehavior@ must include either a @CachePolicyId@ or -- @ForwardedValues@. We recommend that you use a @CachePolicyId@. -- -- 'compress', 'cacheBehavior_compress' - Whether you want CloudFront to automatically compress certain files for -- this cache behavior. If so, specify true; if not, specify false. For -- more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html Serving Compressed Files> -- in the /Amazon CloudFront Developer Guide/. -- -- 'defaultTTL', 'cacheBehavior_defaultTTL' - This field is deprecated. We recommend that you use the @DefaultTTL@ -- field in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The default amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. The value that you -- specify applies only when your origin does not add HTTP headers such as -- @Cache-Control max-age@, @Cache-Control s-maxage@, and @Expires@ to -- objects. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. -- -- 'fieldLevelEncryptionId', 'cacheBehavior_fieldLevelEncryptionId' - The value of @ID@ for the field-level encryption configuration that you -- want CloudFront to use for encrypting specific fields of data for this -- cache behavior. -- -- 'forwardedValues', 'cacheBehavior_forwardedValues' - This field is deprecated. We recommend that you use a cache policy or an -- origin request policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html Working with policies> -- in the /Amazon CloudFront Developer Guide/. -- -- If you want to include values in the cache key, use a cache policy. For -- more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- If you want to send values to the origin but not include them in the -- cache key, use an origin request policy. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-origin-requests.html#origin-request-create-origin-request-policy Creating origin request policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-origin-request-policies.html Using the managed origin request policies> -- in the /Amazon CloudFront Developer Guide/. -- -- A @CacheBehavior@ must include either a @CachePolicyId@ or -- @ForwardedValues@. We recommend that you use a @CachePolicyId@. -- -- A complex type that specifies how CloudFront handles query strings, -- cookies, and HTTP headers. -- -- 'functionAssociations', 'cacheBehavior_functionAssociations' - A list of CloudFront functions that are associated with this cache -- behavior. CloudFront functions must be published to the @LIVE@ stage to -- associate them with a cache behavior. -- -- 'lambdaFunctionAssociations', 'cacheBehavior_lambdaFunctionAssociations' - A complex type that contains zero or more Lambda\@Edge function -- associations for a cache behavior. -- -- 'maxTTL', 'cacheBehavior_maxTTL' - This field is deprecated. We recommend that you use the @MaxTTL@ field -- in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The maximum amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. The value that you -- specify applies only when your origin adds HTTP headers such as -- @Cache-Control max-age@, @Cache-Control s-maxage@, and @Expires@ to -- objects. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. -- -- 'minTTL', 'cacheBehavior_minTTL' - This field is deprecated. We recommend that you use the @MinTTL@ field -- in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The minimum amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. -- -- You must specify @0@ for @MinTTL@ if you configure CloudFront to forward -- all headers to your origin (under @Headers@, if you specify @1@ for -- @Quantity@ and @*@ for @Name@). -- -- 'originRequestPolicyId', 'cacheBehavior_originRequestPolicyId' - The unique identifier of the origin request policy that is attached to -- this cache behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-origin-requests.html#origin-request-create-origin-request-policy Creating origin request policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-origin-request-policies.html Using the managed origin request policies> -- in the /Amazon CloudFront Developer Guide/. -- -- 'realtimeLogConfigArn', 'cacheBehavior_realtimeLogConfigArn' - The Amazon Resource Name (ARN) of the real-time log configuration that -- is attached to this cache behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/real-time-logs.html Real-time logs> -- in the /Amazon CloudFront Developer Guide/. -- -- 'responseHeadersPolicyId', 'cacheBehavior_responseHeadersPolicyId' - The identifier for a response headers policy. -- -- 'smoothStreaming', 'cacheBehavior_smoothStreaming' - Indicates whether you want to distribute media files in the Microsoft -- Smooth Streaming format using the origin that is associated with this -- cache behavior. If so, specify @true@; if not, specify @false@. If you -- specify @true@ for @SmoothStreaming@, you can still distribute other -- content using this cache behavior if the content matches the value of -- @PathPattern@. -- -- 'trustedKeyGroups', 'cacheBehavior_trustedKeyGroups' - A list of key groups that CloudFront can use to validate signed URLs or -- signed cookies. -- -- When a cache behavior contains trusted key groups, CloudFront requires -- signed URLs or signed cookies for all requests that match the cache -- behavior. The URLs or cookies must be signed with a private key whose -- corresponding public key is in the key group. The signed URL or cookie -- contains information about which public key CloudFront should use to -- verify the signature. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html Serving private content> -- in the /Amazon CloudFront Developer Guide/. -- -- 'trustedSigners', 'cacheBehavior_trustedSigners' - We recommend using @TrustedKeyGroups@ instead of @TrustedSigners@. -- -- A list of Amazon Web Services account IDs whose public keys CloudFront -- can use to validate signed URLs or signed cookies. -- -- When a cache behavior contains trusted signers, CloudFront requires -- signed URLs or signed cookies for all requests that match the cache -- behavior. The URLs or cookies must be signed with the private key of a -- CloudFront key pair in the trusted signer\'s Amazon Web Services -- account. The signed URL or cookie contains information about which -- public key CloudFront should use to verify the signature. For more -- information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html Serving private content> -- in the /Amazon CloudFront Developer Guide/. -- -- 'pathPattern', 'cacheBehavior_pathPattern' - The pattern (for example, @images\/*.jpg@) that specifies which requests -- to apply the behavior to. When CloudFront receives a viewer request, the -- requested path is compared with path patterns in the order in which -- cache behaviors are listed in the distribution. -- -- You can optionally include a slash (@\/@) at the beginning of the path -- pattern. For example, @\/images\/*.jpg@. CloudFront behavior is the same -- with or without the leading @\/@. -- -- The path pattern for the default cache behavior is @*@ and cannot be -- changed. If the request for an object does not match the path pattern -- for any cache behaviors, CloudFront applies the behavior in the default -- cache behavior. -- -- For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesPathPattern Path Pattern> -- in the /Amazon CloudFront Developer Guide/. -- -- 'targetOriginId', 'cacheBehavior_targetOriginId' - The value of @ID@ for the origin that you want CloudFront to route -- requests to when they match this cache behavior. -- -- 'viewerProtocolPolicy', 'cacheBehavior_viewerProtocolPolicy' - The protocol that viewers can use to access the files in the origin -- specified by @TargetOriginId@ when a request matches the path pattern in -- @PathPattern@. You can specify the following options: -- -- - @allow-all@: Viewers can use HTTP or HTTPS. -- -- - @redirect-to-https@: If a viewer submits an HTTP request, CloudFront -- returns an HTTP status code of 301 (Moved Permanently) to the viewer -- along with the HTTPS URL. The viewer then resubmits the request -- using the new URL. -- -- - @https-only@: If a viewer sends an HTTP request, CloudFront returns -- an HTTP status code of 403 (Forbidden). -- -- For more information about requiring the HTTPS protocol, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-https-viewers-to-cloudfront.html Requiring HTTPS Between Viewers and CloudFront> -- in the /Amazon CloudFront Developer Guide/. -- -- The only way to guarantee that viewers retrieve an object that was -- fetched from the origin using HTTPS is never to use any other protocol -- to fetch the object. If you have recently changed from HTTP to HTTPS, we -- recommend that you clear your objects\' cache because cached objects are -- protocol agnostic. That means that an edge location will return an -- object from the cache regardless of whether the current request protocol -- matches the protocol used previously. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing Cache Expiration> -- in the /Amazon CloudFront Developer Guide/. newCacheBehavior :: -- | 'pathPattern' Prelude.Text -> -- | 'targetOriginId' Prelude.Text -> -- | 'viewerProtocolPolicy' ViewerProtocolPolicy -> CacheBehavior newCacheBehavior :: Text -> Text -> ViewerProtocolPolicy -> CacheBehavior newCacheBehavior Text pPathPattern_ Text pTargetOriginId_ ViewerProtocolPolicy pViewerProtocolPolicy_ = CacheBehavior' { $sel:allowedMethods:CacheBehavior' :: Maybe AllowedMethods allowedMethods = forall a. Maybe a Prelude.Nothing, $sel:cachePolicyId:CacheBehavior' :: Maybe Text cachePolicyId = forall a. Maybe a Prelude.Nothing, $sel:compress:CacheBehavior' :: Maybe Bool compress = forall a. Maybe a Prelude.Nothing, $sel:defaultTTL:CacheBehavior' :: Maybe Integer defaultTTL = forall a. Maybe a Prelude.Nothing, $sel:fieldLevelEncryptionId:CacheBehavior' :: Maybe Text fieldLevelEncryptionId = forall a. Maybe a Prelude.Nothing, $sel:forwardedValues:CacheBehavior' :: Maybe ForwardedValues forwardedValues = forall a. Maybe a Prelude.Nothing, $sel:functionAssociations:CacheBehavior' :: Maybe FunctionAssociations functionAssociations = forall a. Maybe a Prelude.Nothing, $sel:lambdaFunctionAssociations:CacheBehavior' :: Maybe LambdaFunctionAssociations lambdaFunctionAssociations = forall a. Maybe a Prelude.Nothing, $sel:maxTTL:CacheBehavior' :: Maybe Integer maxTTL = forall a. Maybe a Prelude.Nothing, $sel:minTTL:CacheBehavior' :: Maybe Integer minTTL = forall a. Maybe a Prelude.Nothing, $sel:originRequestPolicyId:CacheBehavior' :: Maybe Text originRequestPolicyId = forall a. Maybe a Prelude.Nothing, $sel:realtimeLogConfigArn:CacheBehavior' :: Maybe Text realtimeLogConfigArn = forall a. Maybe a Prelude.Nothing, $sel:responseHeadersPolicyId:CacheBehavior' :: Maybe Text responseHeadersPolicyId = forall a. Maybe a Prelude.Nothing, $sel:smoothStreaming:CacheBehavior' :: Maybe Bool smoothStreaming = forall a. Maybe a Prelude.Nothing, $sel:trustedKeyGroups:CacheBehavior' :: Maybe TrustedKeyGroups trustedKeyGroups = forall a. Maybe a Prelude.Nothing, $sel:trustedSigners:CacheBehavior' :: Maybe TrustedSigners trustedSigners = forall a. Maybe a Prelude.Nothing, $sel:pathPattern:CacheBehavior' :: Text pathPattern = Text pPathPattern_, $sel:targetOriginId:CacheBehavior' :: Text targetOriginId = Text pTargetOriginId_, $sel:viewerProtocolPolicy:CacheBehavior' :: ViewerProtocolPolicy viewerProtocolPolicy = ViewerProtocolPolicy pViewerProtocolPolicy_ } -- | Undocumented member. cacheBehavior_allowedMethods :: Lens.Lens' CacheBehavior (Prelude.Maybe AllowedMethods) cacheBehavior_allowedMethods :: Lens' CacheBehavior (Maybe AllowedMethods) cacheBehavior_allowedMethods = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe AllowedMethods allowedMethods :: Maybe AllowedMethods $sel:allowedMethods:CacheBehavior' :: CacheBehavior -> Maybe AllowedMethods allowedMethods} -> Maybe AllowedMethods allowedMethods) (\s :: CacheBehavior s@CacheBehavior' {} Maybe AllowedMethods a -> CacheBehavior s {$sel:allowedMethods:CacheBehavior' :: Maybe AllowedMethods allowedMethods = Maybe AllowedMethods a} :: CacheBehavior) -- | The unique identifier of the cache policy that is attached to this cache -- behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- A @CacheBehavior@ must include either a @CachePolicyId@ or -- @ForwardedValues@. We recommend that you use a @CachePolicyId@. cacheBehavior_cachePolicyId :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Text) cacheBehavior_cachePolicyId :: Lens' CacheBehavior (Maybe Text) cacheBehavior_cachePolicyId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Text cachePolicyId :: Maybe Text $sel:cachePolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text cachePolicyId} -> Maybe Text cachePolicyId) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Text a -> CacheBehavior s {$sel:cachePolicyId:CacheBehavior' :: Maybe Text cachePolicyId = Maybe Text a} :: CacheBehavior) -- | Whether you want CloudFront to automatically compress certain files for -- this cache behavior. If so, specify true; if not, specify false. For -- more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/ServingCompressedFiles.html Serving Compressed Files> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_compress :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Bool) cacheBehavior_compress :: Lens' CacheBehavior (Maybe Bool) cacheBehavior_compress = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Bool compress :: Maybe Bool $sel:compress:CacheBehavior' :: CacheBehavior -> Maybe Bool compress} -> Maybe Bool compress) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Bool a -> CacheBehavior s {$sel:compress:CacheBehavior' :: Maybe Bool compress = Maybe Bool a} :: CacheBehavior) -- | This field is deprecated. We recommend that you use the @DefaultTTL@ -- field in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The default amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. The value that you -- specify applies only when your origin does not add HTTP headers such as -- @Cache-Control max-age@, @Cache-Control s-maxage@, and @Expires@ to -- objects. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_defaultTTL :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Integer) cacheBehavior_defaultTTL :: Lens' CacheBehavior (Maybe Integer) cacheBehavior_defaultTTL = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Integer defaultTTL :: Maybe Integer $sel:defaultTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer defaultTTL} -> Maybe Integer defaultTTL) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Integer a -> CacheBehavior s {$sel:defaultTTL:CacheBehavior' :: Maybe Integer defaultTTL = Maybe Integer a} :: CacheBehavior) -- | The value of @ID@ for the field-level encryption configuration that you -- want CloudFront to use for encrypting specific fields of data for this -- cache behavior. cacheBehavior_fieldLevelEncryptionId :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Text) cacheBehavior_fieldLevelEncryptionId :: Lens' CacheBehavior (Maybe Text) cacheBehavior_fieldLevelEncryptionId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Text fieldLevelEncryptionId :: Maybe Text $sel:fieldLevelEncryptionId:CacheBehavior' :: CacheBehavior -> Maybe Text fieldLevelEncryptionId} -> Maybe Text fieldLevelEncryptionId) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Text a -> CacheBehavior s {$sel:fieldLevelEncryptionId:CacheBehavior' :: Maybe Text fieldLevelEncryptionId = Maybe Text a} :: CacheBehavior) -- | This field is deprecated. We recommend that you use a cache policy or an -- origin request policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html Working with policies> -- in the /Amazon CloudFront Developer Guide/. -- -- If you want to include values in the cache key, use a cache policy. For -- more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- If you want to send values to the origin but not include them in the -- cache key, use an origin request policy. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-origin-requests.html#origin-request-create-origin-request-policy Creating origin request policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-origin-request-policies.html Using the managed origin request policies> -- in the /Amazon CloudFront Developer Guide/. -- -- A @CacheBehavior@ must include either a @CachePolicyId@ or -- @ForwardedValues@. We recommend that you use a @CachePolicyId@. -- -- A complex type that specifies how CloudFront handles query strings, -- cookies, and HTTP headers. cacheBehavior_forwardedValues :: Lens.Lens' CacheBehavior (Prelude.Maybe ForwardedValues) cacheBehavior_forwardedValues :: Lens' CacheBehavior (Maybe ForwardedValues) cacheBehavior_forwardedValues = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe ForwardedValues forwardedValues :: Maybe ForwardedValues $sel:forwardedValues:CacheBehavior' :: CacheBehavior -> Maybe ForwardedValues forwardedValues} -> Maybe ForwardedValues forwardedValues) (\s :: CacheBehavior s@CacheBehavior' {} Maybe ForwardedValues a -> CacheBehavior s {$sel:forwardedValues:CacheBehavior' :: Maybe ForwardedValues forwardedValues = Maybe ForwardedValues a} :: CacheBehavior) -- | A list of CloudFront functions that are associated with this cache -- behavior. CloudFront functions must be published to the @LIVE@ stage to -- associate them with a cache behavior. cacheBehavior_functionAssociations :: Lens.Lens' CacheBehavior (Prelude.Maybe FunctionAssociations) cacheBehavior_functionAssociations :: Lens' CacheBehavior (Maybe FunctionAssociations) cacheBehavior_functionAssociations = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe FunctionAssociations functionAssociations :: Maybe FunctionAssociations $sel:functionAssociations:CacheBehavior' :: CacheBehavior -> Maybe FunctionAssociations functionAssociations} -> Maybe FunctionAssociations functionAssociations) (\s :: CacheBehavior s@CacheBehavior' {} Maybe FunctionAssociations a -> CacheBehavior s {$sel:functionAssociations:CacheBehavior' :: Maybe FunctionAssociations functionAssociations = Maybe FunctionAssociations a} :: CacheBehavior) -- | A complex type that contains zero or more Lambda\@Edge function -- associations for a cache behavior. cacheBehavior_lambdaFunctionAssociations :: Lens.Lens' CacheBehavior (Prelude.Maybe LambdaFunctionAssociations) cacheBehavior_lambdaFunctionAssociations :: Lens' CacheBehavior (Maybe LambdaFunctionAssociations) cacheBehavior_lambdaFunctionAssociations = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe LambdaFunctionAssociations lambdaFunctionAssociations :: Maybe LambdaFunctionAssociations $sel:lambdaFunctionAssociations:CacheBehavior' :: CacheBehavior -> Maybe LambdaFunctionAssociations lambdaFunctionAssociations} -> Maybe LambdaFunctionAssociations lambdaFunctionAssociations) (\s :: CacheBehavior s@CacheBehavior' {} Maybe LambdaFunctionAssociations a -> CacheBehavior s {$sel:lambdaFunctionAssociations:CacheBehavior' :: Maybe LambdaFunctionAssociations lambdaFunctionAssociations = Maybe LambdaFunctionAssociations a} :: CacheBehavior) -- | This field is deprecated. We recommend that you use the @MaxTTL@ field -- in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The maximum amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. The value that you -- specify applies only when your origin adds HTTP headers such as -- @Cache-Control max-age@, @Cache-Control s-maxage@, and @Expires@ to -- objects. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_maxTTL :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Integer) cacheBehavior_maxTTL :: Lens' CacheBehavior (Maybe Integer) cacheBehavior_maxTTL = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Integer maxTTL :: Maybe Integer $sel:maxTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer maxTTL} -> Maybe Integer maxTTL) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Integer a -> CacheBehavior s {$sel:maxTTL:CacheBehavior' :: Maybe Integer maxTTL = Maybe Integer a} :: CacheBehavior) -- | This field is deprecated. We recommend that you use the @MinTTL@ field -- in a cache policy instead of this field. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-the-cache-key.html#cache-key-create-cache-policy Creating cache policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-cache-policies.html Using the managed cache policies> -- in the /Amazon CloudFront Developer Guide/. -- -- The minimum amount of time that you want objects to stay in CloudFront -- caches before CloudFront forwards another request to your origin to -- determine whether the object has been updated. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing How Long Content Stays in an Edge Cache (Expiration)> -- in the /Amazon CloudFront Developer Guide/. -- -- You must specify @0@ for @MinTTL@ if you configure CloudFront to forward -- all headers to your origin (under @Headers@, if you specify @1@ for -- @Quantity@ and @*@ for @Name@). cacheBehavior_minTTL :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Integer) cacheBehavior_minTTL :: Lens' CacheBehavior (Maybe Integer) cacheBehavior_minTTL = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Integer minTTL :: Maybe Integer $sel:minTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer minTTL} -> Maybe Integer minTTL) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Integer a -> CacheBehavior s {$sel:minTTL:CacheBehavior' :: Maybe Integer minTTL = Maybe Integer a} :: CacheBehavior) -- | The unique identifier of the origin request policy that is attached to -- this cache behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/controlling-origin-requests.html#origin-request-create-origin-request-policy Creating origin request policies> -- or -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-managed-origin-request-policies.html Using the managed origin request policies> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_originRequestPolicyId :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Text) cacheBehavior_originRequestPolicyId :: Lens' CacheBehavior (Maybe Text) cacheBehavior_originRequestPolicyId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Text originRequestPolicyId :: Maybe Text $sel:originRequestPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text originRequestPolicyId} -> Maybe Text originRequestPolicyId) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Text a -> CacheBehavior s {$sel:originRequestPolicyId:CacheBehavior' :: Maybe Text originRequestPolicyId = Maybe Text a} :: CacheBehavior) -- | The Amazon Resource Name (ARN) of the real-time log configuration that -- is attached to this cache behavior. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/real-time-logs.html Real-time logs> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_realtimeLogConfigArn :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Text) cacheBehavior_realtimeLogConfigArn :: Lens' CacheBehavior (Maybe Text) cacheBehavior_realtimeLogConfigArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Text realtimeLogConfigArn :: Maybe Text $sel:realtimeLogConfigArn:CacheBehavior' :: CacheBehavior -> Maybe Text realtimeLogConfigArn} -> Maybe Text realtimeLogConfigArn) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Text a -> CacheBehavior s {$sel:realtimeLogConfigArn:CacheBehavior' :: Maybe Text realtimeLogConfigArn = Maybe Text a} :: CacheBehavior) -- | The identifier for a response headers policy. cacheBehavior_responseHeadersPolicyId :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Text) cacheBehavior_responseHeadersPolicyId :: Lens' CacheBehavior (Maybe Text) cacheBehavior_responseHeadersPolicyId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Text responseHeadersPolicyId :: Maybe Text $sel:responseHeadersPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text responseHeadersPolicyId} -> Maybe Text responseHeadersPolicyId) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Text a -> CacheBehavior s {$sel:responseHeadersPolicyId:CacheBehavior' :: Maybe Text responseHeadersPolicyId = Maybe Text a} :: CacheBehavior) -- | Indicates whether you want to distribute media files in the Microsoft -- Smooth Streaming format using the origin that is associated with this -- cache behavior. If so, specify @true@; if not, specify @false@. If you -- specify @true@ for @SmoothStreaming@, you can still distribute other -- content using this cache behavior if the content matches the value of -- @PathPattern@. cacheBehavior_smoothStreaming :: Lens.Lens' CacheBehavior (Prelude.Maybe Prelude.Bool) cacheBehavior_smoothStreaming :: Lens' CacheBehavior (Maybe Bool) cacheBehavior_smoothStreaming = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe Bool smoothStreaming :: Maybe Bool $sel:smoothStreaming:CacheBehavior' :: CacheBehavior -> Maybe Bool smoothStreaming} -> Maybe Bool smoothStreaming) (\s :: CacheBehavior s@CacheBehavior' {} Maybe Bool a -> CacheBehavior s {$sel:smoothStreaming:CacheBehavior' :: Maybe Bool smoothStreaming = Maybe Bool a} :: CacheBehavior) -- | A list of key groups that CloudFront can use to validate signed URLs or -- signed cookies. -- -- When a cache behavior contains trusted key groups, CloudFront requires -- signed URLs or signed cookies for all requests that match the cache -- behavior. The URLs or cookies must be signed with a private key whose -- corresponding public key is in the key group. The signed URL or cookie -- contains information about which public key CloudFront should use to -- verify the signature. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html Serving private content> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_trustedKeyGroups :: Lens.Lens' CacheBehavior (Prelude.Maybe TrustedKeyGroups) cacheBehavior_trustedKeyGroups :: Lens' CacheBehavior (Maybe TrustedKeyGroups) cacheBehavior_trustedKeyGroups = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe TrustedKeyGroups trustedKeyGroups :: Maybe TrustedKeyGroups $sel:trustedKeyGroups:CacheBehavior' :: CacheBehavior -> Maybe TrustedKeyGroups trustedKeyGroups} -> Maybe TrustedKeyGroups trustedKeyGroups) (\s :: CacheBehavior s@CacheBehavior' {} Maybe TrustedKeyGroups a -> CacheBehavior s {$sel:trustedKeyGroups:CacheBehavior' :: Maybe TrustedKeyGroups trustedKeyGroups = Maybe TrustedKeyGroups a} :: CacheBehavior) -- | We recommend using @TrustedKeyGroups@ instead of @TrustedSigners@. -- -- A list of Amazon Web Services account IDs whose public keys CloudFront -- can use to validate signed URLs or signed cookies. -- -- When a cache behavior contains trusted signers, CloudFront requires -- signed URLs or signed cookies for all requests that match the cache -- behavior. The URLs or cookies must be signed with the private key of a -- CloudFront key pair in the trusted signer\'s Amazon Web Services -- account. The signed URL or cookie contains information about which -- public key CloudFront should use to verify the signature. For more -- information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/PrivateContent.html Serving private content> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_trustedSigners :: Lens.Lens' CacheBehavior (Prelude.Maybe TrustedSigners) cacheBehavior_trustedSigners :: Lens' CacheBehavior (Maybe TrustedSigners) cacheBehavior_trustedSigners = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Maybe TrustedSigners trustedSigners :: Maybe TrustedSigners $sel:trustedSigners:CacheBehavior' :: CacheBehavior -> Maybe TrustedSigners trustedSigners} -> Maybe TrustedSigners trustedSigners) (\s :: CacheBehavior s@CacheBehavior' {} Maybe TrustedSigners a -> CacheBehavior s {$sel:trustedSigners:CacheBehavior' :: Maybe TrustedSigners trustedSigners = Maybe TrustedSigners a} :: CacheBehavior) -- | The pattern (for example, @images\/*.jpg@) that specifies which requests -- to apply the behavior to. When CloudFront receives a viewer request, the -- requested path is compared with path patterns in the order in which -- cache behaviors are listed in the distribution. -- -- You can optionally include a slash (@\/@) at the beginning of the path -- pattern. For example, @\/images\/*.jpg@. CloudFront behavior is the same -- with or without the leading @\/@. -- -- The path pattern for the default cache behavior is @*@ and cannot be -- changed. If the request for an object does not match the path pattern -- for any cache behaviors, CloudFront applies the behavior in the default -- cache behavior. -- -- For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-values-specify.html#DownloadDistValuesPathPattern Path Pattern> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_pathPattern :: Lens.Lens' CacheBehavior Prelude.Text cacheBehavior_pathPattern :: Lens' CacheBehavior Text cacheBehavior_pathPattern = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Text pathPattern :: Text $sel:pathPattern:CacheBehavior' :: CacheBehavior -> Text pathPattern} -> Text pathPattern) (\s :: CacheBehavior s@CacheBehavior' {} Text a -> CacheBehavior s {$sel:pathPattern:CacheBehavior' :: Text pathPattern = Text a} :: CacheBehavior) -- | The value of @ID@ for the origin that you want CloudFront to route -- requests to when they match this cache behavior. cacheBehavior_targetOriginId :: Lens.Lens' CacheBehavior Prelude.Text cacheBehavior_targetOriginId :: Lens' CacheBehavior Text cacheBehavior_targetOriginId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {Text targetOriginId :: Text $sel:targetOriginId:CacheBehavior' :: CacheBehavior -> Text targetOriginId} -> Text targetOriginId) (\s :: CacheBehavior s@CacheBehavior' {} Text a -> CacheBehavior s {$sel:targetOriginId:CacheBehavior' :: Text targetOriginId = Text a} :: CacheBehavior) -- | The protocol that viewers can use to access the files in the origin -- specified by @TargetOriginId@ when a request matches the path pattern in -- @PathPattern@. You can specify the following options: -- -- - @allow-all@: Viewers can use HTTP or HTTPS. -- -- - @redirect-to-https@: If a viewer submits an HTTP request, CloudFront -- returns an HTTP status code of 301 (Moved Permanently) to the viewer -- along with the HTTPS URL. The viewer then resubmits the request -- using the new URL. -- -- - @https-only@: If a viewer sends an HTTP request, CloudFront returns -- an HTTP status code of 403 (Forbidden). -- -- For more information about requiring the HTTPS protocol, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/using-https-viewers-to-cloudfront.html Requiring HTTPS Between Viewers and CloudFront> -- in the /Amazon CloudFront Developer Guide/. -- -- The only way to guarantee that viewers retrieve an object that was -- fetched from the origin using HTTPS is never to use any other protocol -- to fetch the object. If you have recently changed from HTTP to HTTPS, we -- recommend that you clear your objects\' cache because cached objects are -- protocol agnostic. That means that an edge location will return an -- object from the cache regardless of whether the current request protocol -- matches the protocol used previously. For more information, see -- <https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/Expiration.html Managing Cache Expiration> -- in the /Amazon CloudFront Developer Guide/. cacheBehavior_viewerProtocolPolicy :: Lens.Lens' CacheBehavior ViewerProtocolPolicy cacheBehavior_viewerProtocolPolicy :: Lens' CacheBehavior ViewerProtocolPolicy cacheBehavior_viewerProtocolPolicy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b Lens.lens (\CacheBehavior' {ViewerProtocolPolicy viewerProtocolPolicy :: ViewerProtocolPolicy $sel:viewerProtocolPolicy:CacheBehavior' :: CacheBehavior -> ViewerProtocolPolicy viewerProtocolPolicy} -> ViewerProtocolPolicy viewerProtocolPolicy) (\s :: CacheBehavior s@CacheBehavior' {} ViewerProtocolPolicy a -> CacheBehavior s {$sel:viewerProtocolPolicy:CacheBehavior' :: ViewerProtocolPolicy viewerProtocolPolicy = ViewerProtocolPolicy a} :: CacheBehavior) instance Data.FromXML CacheBehavior where parseXML :: [Node] -> Either String CacheBehavior parseXML [Node] x = Maybe AllowedMethods -> Maybe Text -> Maybe Bool -> Maybe Integer -> Maybe Text -> Maybe ForwardedValues -> Maybe FunctionAssociations -> Maybe LambdaFunctionAssociations -> Maybe Integer -> Maybe Integer -> Maybe Text -> Maybe Text -> Maybe Text -> Maybe Bool -> Maybe TrustedKeyGroups -> Maybe TrustedSigners -> Text -> Text -> ViewerProtocolPolicy -> CacheBehavior CacheBehavior' forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b Prelude.<$> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "AllowedMethods") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "CachePolicyId") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "Compress") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "DefaultTTL") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "FieldLevelEncryptionId") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "ForwardedValues") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "FunctionAssociations") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "LambdaFunctionAssociations") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "MaxTTL") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "MinTTL") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "OriginRequestPolicyId") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "RealtimeLogConfigArn") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "ResponseHeadersPolicyId") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "SmoothStreaming") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "TrustedKeyGroups") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a) Data..@? Text "TrustedSigners") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String a Data..@ Text "PathPattern") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String a Data..@ Text "TargetOriginId") forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b Prelude.<*> ([Node] x forall a. FromXML a => [Node] -> Text -> Either String a Data..@ Text "ViewerProtocolPolicy") instance Prelude.Hashable CacheBehavior where hashWithSalt :: Int -> CacheBehavior -> Int hashWithSalt Int _salt CacheBehavior' {Maybe Bool Maybe Integer Maybe Text Maybe FunctionAssociations Maybe LambdaFunctionAssociations Maybe AllowedMethods Maybe ForwardedValues Maybe TrustedKeyGroups Maybe TrustedSigners Text ViewerProtocolPolicy viewerProtocolPolicy :: ViewerProtocolPolicy targetOriginId :: Text pathPattern :: Text trustedSigners :: Maybe TrustedSigners trustedKeyGroups :: Maybe TrustedKeyGroups smoothStreaming :: Maybe Bool responseHeadersPolicyId :: Maybe Text realtimeLogConfigArn :: Maybe Text originRequestPolicyId :: Maybe Text minTTL :: Maybe Integer maxTTL :: Maybe Integer lambdaFunctionAssociations :: Maybe LambdaFunctionAssociations functionAssociations :: Maybe FunctionAssociations forwardedValues :: Maybe ForwardedValues fieldLevelEncryptionId :: Maybe Text defaultTTL :: Maybe Integer compress :: Maybe Bool cachePolicyId :: Maybe Text allowedMethods :: Maybe AllowedMethods $sel:viewerProtocolPolicy:CacheBehavior' :: CacheBehavior -> ViewerProtocolPolicy $sel:targetOriginId:CacheBehavior' :: CacheBehavior -> Text $sel:pathPattern:CacheBehavior' :: CacheBehavior -> Text $sel:trustedSigners:CacheBehavior' :: CacheBehavior -> Maybe TrustedSigners $sel:trustedKeyGroups:CacheBehavior' :: CacheBehavior -> Maybe TrustedKeyGroups $sel:smoothStreaming:CacheBehavior' :: CacheBehavior -> Maybe Bool $sel:responseHeadersPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:realtimeLogConfigArn:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:originRequestPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:minTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:maxTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:lambdaFunctionAssociations:CacheBehavior' :: CacheBehavior -> Maybe LambdaFunctionAssociations $sel:functionAssociations:CacheBehavior' :: CacheBehavior -> Maybe FunctionAssociations $sel:forwardedValues:CacheBehavior' :: CacheBehavior -> Maybe ForwardedValues $sel:fieldLevelEncryptionId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:defaultTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:compress:CacheBehavior' :: CacheBehavior -> Maybe Bool $sel:cachePolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:allowedMethods:CacheBehavior' :: CacheBehavior -> Maybe AllowedMethods ..} = Int _salt forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe AllowedMethods allowedMethods forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Text cachePolicyId forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Bool compress forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Integer defaultTTL forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Text fieldLevelEncryptionId forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe ForwardedValues forwardedValues forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe FunctionAssociations functionAssociations forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe LambdaFunctionAssociations lambdaFunctionAssociations forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Integer maxTTL forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Integer minTTL forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Text originRequestPolicyId forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Text realtimeLogConfigArn forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Text responseHeadersPolicyId forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe Bool smoothStreaming forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe TrustedKeyGroups trustedKeyGroups forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Maybe TrustedSigners trustedSigners forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Text pathPattern forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` Text targetOriginId forall a. Hashable a => Int -> a -> Int `Prelude.hashWithSalt` ViewerProtocolPolicy viewerProtocolPolicy instance Prelude.NFData CacheBehavior where rnf :: CacheBehavior -> () rnf CacheBehavior' {Maybe Bool Maybe Integer Maybe Text Maybe FunctionAssociations Maybe LambdaFunctionAssociations Maybe AllowedMethods Maybe ForwardedValues Maybe TrustedKeyGroups Maybe TrustedSigners Text ViewerProtocolPolicy viewerProtocolPolicy :: ViewerProtocolPolicy targetOriginId :: Text pathPattern :: Text trustedSigners :: Maybe TrustedSigners trustedKeyGroups :: Maybe TrustedKeyGroups smoothStreaming :: Maybe Bool responseHeadersPolicyId :: Maybe Text realtimeLogConfigArn :: Maybe Text originRequestPolicyId :: Maybe Text minTTL :: Maybe Integer maxTTL :: Maybe Integer lambdaFunctionAssociations :: Maybe LambdaFunctionAssociations functionAssociations :: Maybe FunctionAssociations forwardedValues :: Maybe ForwardedValues fieldLevelEncryptionId :: Maybe Text defaultTTL :: Maybe Integer compress :: Maybe Bool cachePolicyId :: Maybe Text allowedMethods :: Maybe AllowedMethods $sel:viewerProtocolPolicy:CacheBehavior' :: CacheBehavior -> ViewerProtocolPolicy $sel:targetOriginId:CacheBehavior' :: CacheBehavior -> Text $sel:pathPattern:CacheBehavior' :: CacheBehavior -> Text $sel:trustedSigners:CacheBehavior' :: CacheBehavior -> Maybe TrustedSigners $sel:trustedKeyGroups:CacheBehavior' :: CacheBehavior -> Maybe TrustedKeyGroups $sel:smoothStreaming:CacheBehavior' :: CacheBehavior -> Maybe Bool $sel:responseHeadersPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:realtimeLogConfigArn:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:originRequestPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:minTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:maxTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:lambdaFunctionAssociations:CacheBehavior' :: CacheBehavior -> Maybe LambdaFunctionAssociations $sel:functionAssociations:CacheBehavior' :: CacheBehavior -> Maybe FunctionAssociations $sel:forwardedValues:CacheBehavior' :: CacheBehavior -> Maybe ForwardedValues $sel:fieldLevelEncryptionId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:defaultTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:compress:CacheBehavior' :: CacheBehavior -> Maybe Bool $sel:cachePolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:allowedMethods:CacheBehavior' :: CacheBehavior -> Maybe AllowedMethods ..} = forall a. NFData a => a -> () Prelude.rnf Maybe AllowedMethods allowedMethods seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Text cachePolicyId seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Bool compress seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Integer defaultTTL seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Text fieldLevelEncryptionId seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe ForwardedValues forwardedValues seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe FunctionAssociations functionAssociations seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe LambdaFunctionAssociations lambdaFunctionAssociations seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Integer maxTTL seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Integer minTTL seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Text originRequestPolicyId seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Text realtimeLogConfigArn seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Text responseHeadersPolicyId seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe Bool smoothStreaming seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe TrustedKeyGroups trustedKeyGroups seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Maybe TrustedSigners trustedSigners seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Text pathPattern seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf Text targetOriginId seq :: forall a b. a -> b -> b `Prelude.seq` forall a. NFData a => a -> () Prelude.rnf ViewerProtocolPolicy viewerProtocolPolicy instance Data.ToXML CacheBehavior where toXML :: CacheBehavior -> XML toXML CacheBehavior' {Maybe Bool Maybe Integer Maybe Text Maybe FunctionAssociations Maybe LambdaFunctionAssociations Maybe AllowedMethods Maybe ForwardedValues Maybe TrustedKeyGroups Maybe TrustedSigners Text ViewerProtocolPolicy viewerProtocolPolicy :: ViewerProtocolPolicy targetOriginId :: Text pathPattern :: Text trustedSigners :: Maybe TrustedSigners trustedKeyGroups :: Maybe TrustedKeyGroups smoothStreaming :: Maybe Bool responseHeadersPolicyId :: Maybe Text realtimeLogConfigArn :: Maybe Text originRequestPolicyId :: Maybe Text minTTL :: Maybe Integer maxTTL :: Maybe Integer lambdaFunctionAssociations :: Maybe LambdaFunctionAssociations functionAssociations :: Maybe FunctionAssociations forwardedValues :: Maybe ForwardedValues fieldLevelEncryptionId :: Maybe Text defaultTTL :: Maybe Integer compress :: Maybe Bool cachePolicyId :: Maybe Text allowedMethods :: Maybe AllowedMethods $sel:viewerProtocolPolicy:CacheBehavior' :: CacheBehavior -> ViewerProtocolPolicy $sel:targetOriginId:CacheBehavior' :: CacheBehavior -> Text $sel:pathPattern:CacheBehavior' :: CacheBehavior -> Text $sel:trustedSigners:CacheBehavior' :: CacheBehavior -> Maybe TrustedSigners $sel:trustedKeyGroups:CacheBehavior' :: CacheBehavior -> Maybe TrustedKeyGroups $sel:smoothStreaming:CacheBehavior' :: CacheBehavior -> Maybe Bool $sel:responseHeadersPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:realtimeLogConfigArn:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:originRequestPolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:minTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:maxTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:lambdaFunctionAssociations:CacheBehavior' :: CacheBehavior -> Maybe LambdaFunctionAssociations $sel:functionAssociations:CacheBehavior' :: CacheBehavior -> Maybe FunctionAssociations $sel:forwardedValues:CacheBehavior' :: CacheBehavior -> Maybe ForwardedValues $sel:fieldLevelEncryptionId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:defaultTTL:CacheBehavior' :: CacheBehavior -> Maybe Integer $sel:compress:CacheBehavior' :: CacheBehavior -> Maybe Bool $sel:cachePolicyId:CacheBehavior' :: CacheBehavior -> Maybe Text $sel:allowedMethods:CacheBehavior' :: CacheBehavior -> Maybe AllowedMethods ..} = forall a. Monoid a => [a] -> a Prelude.mconcat [ Name "AllowedMethods" forall a. ToXML a => Name -> a -> XML Data.@= Maybe AllowedMethods allowedMethods, Name "CachePolicyId" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Text cachePolicyId, Name "Compress" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Bool compress, Name "DefaultTTL" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Integer defaultTTL, Name "FieldLevelEncryptionId" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Text fieldLevelEncryptionId, Name "ForwardedValues" forall a. ToXML a => Name -> a -> XML Data.@= Maybe ForwardedValues forwardedValues, Name "FunctionAssociations" forall a. ToXML a => Name -> a -> XML Data.@= Maybe FunctionAssociations functionAssociations, Name "LambdaFunctionAssociations" forall a. ToXML a => Name -> a -> XML Data.@= Maybe LambdaFunctionAssociations lambdaFunctionAssociations, Name "MaxTTL" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Integer maxTTL, Name "MinTTL" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Integer minTTL, Name "OriginRequestPolicyId" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Text originRequestPolicyId, Name "RealtimeLogConfigArn" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Text realtimeLogConfigArn, Name "ResponseHeadersPolicyId" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Text responseHeadersPolicyId, Name "SmoothStreaming" forall a. ToXML a => Name -> a -> XML Data.@= Maybe Bool smoothStreaming, Name "TrustedKeyGroups" forall a. ToXML a => Name -> a -> XML Data.@= Maybe TrustedKeyGroups trustedKeyGroups, Name "TrustedSigners" forall a. ToXML a => Name -> a -> XML Data.@= Maybe TrustedSigners trustedSigners, Name "PathPattern" forall a. ToXML a => Name -> a -> XML Data.@= Text pathPattern, Name "TargetOriginId" forall a. ToXML a => Name -> a -> XML Data.@= Text targetOriginId, Name "ViewerProtocolPolicy" forall a. ToXML a => Name -> a -> XML Data.@= ViewerProtocolPolicy viewerProtocolPolicy ]