HttpVersion

class aws_cdk.aws_cloudfront.HttpVersion(*values)

Bases: Enum

The HTTP version(s) to enable on the distribution.

Note: Setting HTTP3 enables HTTP 3 only (not HTTP 2). To support both HTTP 2 and HTTP 3, use HTTP2_AND_3.

See:

https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html#cloudfront-UpdateDistribution-request-HttpVersion

ExampleMetadata:

infused

Example:

# Configure a distribution to use HTTP/2 and HTTP/3
cloudfront.Distribution(self, "myDist",
    default_behavior=cloudfront.BehaviorOptions(origin=origins.HttpOrigin("www.example.com")),
    http_version=cloudfront.HttpVersion.HTTP2_AND_3
)

Attributes

HTTP1_1

HTTP 1.1.

HTTP2

HTTP 2.

HTTP2_AND_3

HTTP 2 and HTTP 3.

HTTP3

HTTP 3 only (does not include HTTP 2).