FeatureFlags

class aws_cdk.core.FeatureFlags(*args, **kwargs)

Bases: object

Features that are implemented behind a flag in order to preserve backwards compatibility for existing apps.

The list of flags are available in the @aws-cdk/cx-api module.

The state of the flag for this application is stored as a CDK context variable.

Methods

is_enabled(feature_flag)

Check whether a feature flag is enabled.

If configured, the flag is present in the construct node context. Falls back to the defaults defined in the cx-api module.

Parameters

feature_flag (str) –

Return type

Optional[bool]

Static Methods

classmethod of(scope)

Inspect feature flags on the construct node’s context.

Parameters

scope (Construct) –

Return type

FeatureFlags