@pulumi/aws-native
Version:
The Pulumi AWS Cloud Control Provider enables you to build, deploy, and manage [any AWS resource that's supported by the AWS Cloud Control API](https://github.com/pulumi/pulumi-aws-native/blob/master/provider/cmd/pulumi-gen-aws-native/supported-types.txt)
38 lines • 2.66 kB
JavaScript
;
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.getCachePolicyOutput = exports.getCachePolicy = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* A cache policy.
* When it's attached to a cache behavior, the cache policy determines the following:
* + The values that CloudFront includes in the cache key. These values can include HTTP headers, cookies, and URL query strings. CloudFront uses the cache key to find an object in its cache that it can return to the viewer.
* + The default, minimum, and maximum time to live (TTL) values that you want objects to stay in the CloudFront cache.
*
* The headers, cookies, and query strings that are included in the cache key are also included in requests that CloudFront sends to the origin. CloudFront sends a request when it can't find a valid object in its cache that matches the request's cache key. If you want to send values to the origin but *not* include them in the cache key, use ``OriginRequestPolicy``.
*/
function getCachePolicy(args, opts) {
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invoke("aws-native:cloudfront:getCachePolicy", {
"id": args.id,
}, opts);
}
exports.getCachePolicy = getCachePolicy;
/**
* A cache policy.
* When it's attached to a cache behavior, the cache policy determines the following:
* + The values that CloudFront includes in the cache key. These values can include HTTP headers, cookies, and URL query strings. CloudFront uses the cache key to find an object in its cache that it can return to the viewer.
* + The default, minimum, and maximum time to live (TTL) values that you want objects to stay in the CloudFront cache.
*
* The headers, cookies, and query strings that are included in the cache key are also included in requests that CloudFront sends to the origin. CloudFront sends a request when it can't find a valid object in its cache that matches the request's cache key. If you want to send values to the origin but *not* include them in the cache key, use ``OriginRequestPolicy``.
*/
function getCachePolicyOutput(args, opts) {
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts || {});
return pulumi.runtime.invokeOutput("aws-native:cloudfront:getCachePolicy", {
"id": args.id,
}, opts);
}
exports.getCachePolicyOutput = getCachePolicyOutput;
//# sourceMappingURL=getCachePolicy.js.map