Struct aws_sdk_cloudfront::model::OriginRequestPolicy
source · #[non_exhaustive]pub struct OriginRequestPolicy { /* private fields */ }
Expand description
An origin request policy.
When it's attached to a cache behavior, the origin request policy determines the values that CloudFront includes in requests that it sends to the origin. Each request that CloudFront sends to the origin includes the following:
-
The request body and the URL path (without the domain name) from the viewer request.
-
The headers that CloudFront automatically includes in every origin request, including
Host
,User-Agent
, andX-Amz-Cf-Id
. -
All HTTP headers, cookies, and URL query strings that are specified in the cache policy or the origin request policy. These can include items from the viewer request and, in the case of headers, additional ones that are added by CloudFront.
CloudFront sends a request when it can't find an object in its cache that matches the request. If you want to send values to the origin and also include them in the cache key, use CachePolicy
.
Implementations§
source§impl OriginRequestPolicy
impl OriginRequestPolicy
sourcepub fn last_modified_time(&self) -> Option<&DateTime>
pub fn last_modified_time(&self) -> Option<&DateTime>
The date and time when the origin request policy was last modified.
sourcepub fn origin_request_policy_config(&self) -> Option<&OriginRequestPolicyConfig>
pub fn origin_request_policy_config(&self) -> Option<&OriginRequestPolicyConfig>
The origin request policy configuration.
source§impl OriginRequestPolicy
impl OriginRequestPolicy
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture OriginRequestPolicy
.
Trait Implementations§
source§impl Clone for OriginRequestPolicy
impl Clone for OriginRequestPolicy
source§fn clone(&self) -> OriginRequestPolicy
fn clone(&self) -> OriginRequestPolicy
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for OriginRequestPolicy
impl Debug for OriginRequestPolicy
source§impl PartialEq<OriginRequestPolicy> for OriginRequestPolicy
impl PartialEq<OriginRequestPolicy> for OriginRequestPolicy
source§fn eq(&self, other: &OriginRequestPolicy) -> bool
fn eq(&self, other: &OriginRequestPolicy) -> bool
self
and other
values to be equal, and is used
by ==
.