Interface IOriginGroupProps
Construction properties for OriginGroup
.
Namespace: Amazon.CDK.AWS.CloudFront.Origins
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface IOriginGroupProps
Syntax (vb)
Public Interface IOriginGroupProps
Remarks
ExampleMetadata: infused
Examples
var myBucket = new Bucket(this, "myBucket");
new Distribution(this, "myDist", new DistributionProps {
DefaultBehavior = new BehaviorOptions {
Origin = new OriginGroup(new OriginGroupProps {
PrimaryOrigin = S3BucketOrigin.WithOriginAccessControl(myBucket),
FallbackOrigin = new HttpOrigin("www.example.com"),
// optional, defaults to: 500, 502, 503 and 504
FallbackStatusCodes = new [] { 404 }
})
}
});
Synopsis
Properties
Fallback |
The fallback origin that should serve requests when the primary fails. |
Fallback |
The list of HTTP status codes that, when returned from the primary origin, would cause querying the fallback origin. |
Primary |
The primary origin that should serve requests for this group. |
Selection |
The selection criteria for the origin group. |
Properties
FallbackOrigin
The fallback origin that should serve requests when the primary fails.
IOrigin FallbackOrigin { get; }
Property Value
FallbackStatusCodes
The list of HTTP status codes that, when returned from the primary origin, would cause querying the fallback origin.
virtual double[] FallbackStatusCodes { get; }
Property Value
System.
Remarks
Default: - 500, 502, 503 and 504
PrimaryOrigin
The primary origin that should serve requests for this group.
IOrigin PrimaryOrigin { get; }
Property Value
SelectionCriteria
The selection criteria for the origin group.
virtual Nullable<OriginSelectionCriteria> SelectionCriteria { get; }
Property Value
System.
Remarks
Default: - OriginSelectionCriteria.DEFAULT