Interface CachePolicyConfig.Builder
- All Superinterfaces:
Buildable,CopyableBuilder<CachePolicyConfig.Builder,,CachePolicyConfig> SdkBuilder<CachePolicyConfig.Builder,,CachePolicyConfig> SdkPojo
- Enclosing class:
CachePolicyConfig
-
Method Summary
Modifier and TypeMethodDescriptionA comment to describe the cache policy.defaultTTL(Long defaultTTL) The default amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated.The maximum amount of time, in seconds, that objects stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated.The minimum amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated.A unique name to identify the cache policy.default CachePolicyConfig.BuilderparametersInCacheKeyAndForwardedToOrigin(Consumer<ParametersInCacheKeyAndForwardedToOrigin.Builder> parametersInCacheKeyAndForwardedToOrigin) The HTTP headers, cookies, and URL query strings to include in the cache key.parametersInCacheKeyAndForwardedToOrigin(ParametersInCacheKeyAndForwardedToOrigin parametersInCacheKeyAndForwardedToOrigin) The HTTP headers, cookies, and URL query strings to include in the cache key.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copyMethods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, buildMethods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFields
-
Method Details
-
comment
A comment to describe the cache policy. The comment cannot be longer than 128 characters.
- Parameters:
comment- A comment to describe the cache policy. The comment cannot be longer than 128 characters.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
name
A unique name to identify the cache policy.
- Parameters:
name- A unique name to identify the cache policy.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
defaultTTL
The default amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. CloudFront uses this value as the object's time to live (TTL) only when the origin does not send
Cache-ControlorExpiresheaders with the object. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.The default value for this field is 86400 seconds (one day). If the value of
MinTTLis more than 86400 seconds, then the default value for this field is the same as the value ofMinTTL.- Parameters:
defaultTTL- The default amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. CloudFront uses this value as the object's time to live (TTL) only when the origin does not sendCache-ControlorExpiresheaders with the object. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.The default value for this field is 86400 seconds (one day). If the value of
MinTTLis more than 86400 seconds, then the default value for this field is the same as the value ofMinTTL.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
maxTTL
The maximum amount of time, in seconds, that objects stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. CloudFront uses this value only when the origin sends
Cache-ControlorExpiresheaders with the object. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.The default value for this field is 31536000 seconds (one year). If the value of
MinTTLorDefaultTTLis more than 31536000 seconds, then the default value for this field is the same as the value ofDefaultTTL.- Parameters:
maxTTL- The maximum amount of time, in seconds, that objects stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. CloudFront uses this value only when the origin sendsCache-ControlorExpiresheaders with the object. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.The default value for this field is 31536000 seconds (one year). If the value of
MinTTLorDefaultTTLis more than 31536000 seconds, then the default value for this field is the same as the value ofDefaultTTL.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
minTTL
The minimum amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.
- Parameters:
minTTL- The minimum amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
parametersInCacheKeyAndForwardedToOrigin
CachePolicyConfig.Builder parametersInCacheKeyAndForwardedToOrigin(ParametersInCacheKeyAndForwardedToOrigin parametersInCacheKeyAndForwardedToOrigin) The HTTP headers, cookies, and URL query strings to include in the cache key. The values included in the cache key are also included in requests that CloudFront sends to the origin.
- Parameters:
parametersInCacheKeyAndForwardedToOrigin- The HTTP headers, cookies, and URL query strings to include in the cache key. The values included in the cache key are also included in requests that CloudFront sends to the origin.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
parametersInCacheKeyAndForwardedToOrigin
default CachePolicyConfig.Builder parametersInCacheKeyAndForwardedToOrigin(Consumer<ParametersInCacheKeyAndForwardedToOrigin.Builder> parametersInCacheKeyAndForwardedToOrigin) The HTTP headers, cookies, and URL query strings to include in the cache key. The values included in the cache key are also included in requests that CloudFront sends to the origin.
This is a convenience method that creates an instance of theParametersInCacheKeyAndForwardedToOrigin.Builderavoiding the need to create one manually viaParametersInCacheKeyAndForwardedToOrigin.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed toparametersInCacheKeyAndForwardedToOrigin(ParametersInCacheKeyAndForwardedToOrigin).- Parameters:
parametersInCacheKeyAndForwardedToOrigin- a consumer that will call methods onParametersInCacheKeyAndForwardedToOrigin.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-