aws-cdk-lib.IReusableStackSynthesizer

interface IReusableStackSynthesizer

LanguageType name
.NETAmazon.CDK.IReusableStackSynthesizer
Gogithub.com/aws/aws-cdk-go/awscdk/v2#IReusableStackSynthesizer
Javasoftware.amazon.awscdk.IReusableStackSynthesizer
Pythonaws_cdk.IReusableStackSynthesizer
TypeScript (source)aws-cdk-lib » IReusableStackSynthesizer

Implemented by AppStagingSynthesizer, BootstraplessSynthesizer, CliCredentialsStackSynthesizer, DefaultStackSynthesizer, LegacyStackSynthesizer

Interface for Stack Synthesizers that can be used for more than one stack.

Regular IStackSynthesizer instances can only be bound to a Stack once. IReusableStackSynthesizer instances.

For backwards compatibility reasons, this class inherits from IStackSynthesizer, but if an object implements IReusableStackSynthesizer, no other methods than reusableBind() will be called.

Properties

NameTypeDescription
bootstrapQualifier?stringThe qualifier used to bootstrap this stack.
lookupRole?stringThe role used to lookup for this stack.

bootstrapQualifier?

Type: string (optional, default: no qualifier)

The qualifier used to bootstrap this stack.


lookupRole?

Type: string (optional, default: no role)

The role used to lookup for this stack.

Methods

NameDescription
addDockerImageAsset(asset)Register a Docker Image Asset.
addFileAsset(asset)Register a File Asset.
bind(stack)Bind to the stack this environment is going to be used on.
reusableBind(stack)Produce a bound Stack Synthesizer for the given stack.
synthesize(session)Synthesize the associated stack to the session.

addDockerImageAsset(asset)

public addDockerImageAsset(asset: DockerImageAssetSource): DockerImageAssetLocation

Parameters

  • asset DockerImageAssetSource

Returns

  • DockerImageAssetLocation

Register a Docker Image Asset.

Returns the parameters that can be used to refer to the asset inside the template.


addFileAsset(asset)

public addFileAsset(asset: FileAssetSource): FileAssetLocation

Parameters

  • asset FileAssetSource

Returns

  • FileAssetLocation

Register a File Asset.

Returns the parameters that can be used to refer to the asset inside the template.


bind(stack)

public bind(stack: Stack): void

Parameters

  • stack Stack

Bind to the stack this environment is going to be used on.

Must be called before any of the other methods are called, and can only be called once.


reusableBind(stack)

public reusableBind(stack: Stack): IBoundStackSynthesizer

Parameters

  • stack Stack

Returns

  • IBoundStackSynthesizer

Produce a bound Stack Synthesizer for the given stack.

This method may be called more than once on the same object.


synthesize(session)

public synthesize(session: ISynthesisSession): void

Parameters

  • session ISynthesisSession

Synthesize the associated stack to the session.