UNPKG

@cdktf/provider-aws

Version:

Prebuilt aws Provider for Terraform CDK (cdktf)

1,270 lines 338 kB
"use strict"; var _a, _b, _c, _d, _e, _f, _g, _h, _j; Object.defineProperty(exports, "__esModule", { value: true }); exports.DbInstance = exports.DbInstanceTimeoutsOutputReference = exports.DbInstanceS3ImportOutputReference = exports.DbInstanceRestoreToPointInTimeOutputReference = exports.DbInstanceBlueGreenUpdateOutputReference = exports.DbInstanceMasterUserSecretList = exports.DbInstanceMasterUserSecretOutputReference = exports.DbInstanceListenerEndpointList = exports.DbInstanceListenerEndpointOutputReference = void 0; exports.dbInstanceListenerEndpointToTerraform = dbInstanceListenerEndpointToTerraform; exports.dbInstanceListenerEndpointToHclTerraform = dbInstanceListenerEndpointToHclTerraform; exports.dbInstanceMasterUserSecretToTerraform = dbInstanceMasterUserSecretToTerraform; exports.dbInstanceMasterUserSecretToHclTerraform = dbInstanceMasterUserSecretToHclTerraform; exports.dbInstanceBlueGreenUpdateToTerraform = dbInstanceBlueGreenUpdateToTerraform; exports.dbInstanceBlueGreenUpdateToHclTerraform = dbInstanceBlueGreenUpdateToHclTerraform; exports.dbInstanceRestoreToPointInTimeToTerraform = dbInstanceRestoreToPointInTimeToTerraform; exports.dbInstanceRestoreToPointInTimeToHclTerraform = dbInstanceRestoreToPointInTimeToHclTerraform; exports.dbInstanceS3ImportToTerraform = dbInstanceS3ImportToTerraform; exports.dbInstanceS3ImportToHclTerraform = dbInstanceS3ImportToHclTerraform; exports.dbInstanceTimeoutsToTerraform = dbInstanceTimeoutsToTerraform; exports.dbInstanceTimeoutsToHclTerraform = dbInstanceTimeoutsToHclTerraform; const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); const cdktf = require("cdktf"); function dbInstanceListenerEndpointToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return {}; } function dbInstanceListenerEndpointToHclTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } const attrs = {}; return attrs; } class DbInstanceListenerEndpointOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param complexObjectIndex the index of this item in the list * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) { super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; } else { this.isEmptyObject = Object.keys(value).length === 0; } } // address - computed: true, optional: false, required: false get address() { return this.getStringAttribute('address'); } // hosted_zone_id - computed: true, optional: false, required: false get hostedZoneId() { return this.getStringAttribute('hosted_zone_id'); } // port - computed: true, optional: false, required: false get port() { return this.getNumberAttribute('port'); } } exports.DbInstanceListenerEndpointOutputReference = DbInstanceListenerEndpointOutputReference; _a = JSII_RTTI_SYMBOL_1; DbInstanceListenerEndpointOutputReference[_a] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceListenerEndpointOutputReference", version: "21.22.1" }; class DbInstanceListenerEndpointList extends cdktf.ComplexList { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, wrapsSet) { super(terraformResource, terraformAttribute, wrapsSet); this.terraformResource = terraformResource; this.terraformAttribute = terraformAttribute; this.wrapsSet = wrapsSet; } /** * @param index the index of the item to return */ get(index) { return new DbInstanceListenerEndpointOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.DbInstanceListenerEndpointList = DbInstanceListenerEndpointList; _b = JSII_RTTI_SYMBOL_1; DbInstanceListenerEndpointList[_b] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceListenerEndpointList", version: "21.22.1" }; function dbInstanceMasterUserSecretToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return {}; } function dbInstanceMasterUserSecretToHclTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } const attrs = {}; return attrs; } class DbInstanceMasterUserSecretOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param complexObjectIndex the index of this item in the list * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) { super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; } else { this.isEmptyObject = Object.keys(value).length === 0; } } // kms_key_id - computed: true, optional: false, required: false get kmsKeyId() { return this.getStringAttribute('kms_key_id'); } // secret_arn - computed: true, optional: false, required: false get secretArn() { return this.getStringAttribute('secret_arn'); } // secret_status - computed: true, optional: false, required: false get secretStatus() { return this.getStringAttribute('secret_status'); } } exports.DbInstanceMasterUserSecretOutputReference = DbInstanceMasterUserSecretOutputReference; _c = JSII_RTTI_SYMBOL_1; DbInstanceMasterUserSecretOutputReference[_c] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceMasterUserSecretOutputReference", version: "21.22.1" }; class DbInstanceMasterUserSecretList extends cdktf.ComplexList { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, wrapsSet) { super(terraformResource, terraformAttribute, wrapsSet); this.terraformResource = terraformResource; this.terraformAttribute = terraformAttribute; this.wrapsSet = wrapsSet; } /** * @param index the index of the item to return */ get(index) { return new DbInstanceMasterUserSecretOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.DbInstanceMasterUserSecretList = DbInstanceMasterUserSecretList; _d = JSII_RTTI_SYMBOL_1; DbInstanceMasterUserSecretList[_d] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceMasterUserSecretList", version: "21.22.1" }; function dbInstanceBlueGreenUpdateToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return { enabled: cdktf.booleanToTerraform(struct.enabled), }; } function dbInstanceBlueGreenUpdateToHclTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } const attrs = { enabled: { value: cdktf.booleanToHclTerraform(struct.enabled), isBlock: false, type: "simple", storageClassType: "boolean", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DbInstanceBlueGreenUpdateOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._enabled !== undefined) { hasAnyValues = true; internalValueResult.enabled = this._enabled; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._enabled = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._enabled = value.enabled; } } get enabled() { return this.getBooleanAttribute('enabled'); } set enabled(value) { this._enabled = value; } resetEnabled() { this._enabled = undefined; } // Temporarily expose input value. Use with caution. get enabledInput() { return this._enabled; } } exports.DbInstanceBlueGreenUpdateOutputReference = DbInstanceBlueGreenUpdateOutputReference; _e = JSII_RTTI_SYMBOL_1; DbInstanceBlueGreenUpdateOutputReference[_e] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceBlueGreenUpdateOutputReference", version: "21.22.1" }; function dbInstanceRestoreToPointInTimeToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return { restore_time: cdktf.stringToTerraform(struct.restoreTime), source_db_instance_automated_backups_arn: cdktf.stringToTerraform(struct.sourceDbInstanceAutomatedBackupsArn), source_db_instance_identifier: cdktf.stringToTerraform(struct.sourceDbInstanceIdentifier), source_dbi_resource_id: cdktf.stringToTerraform(struct.sourceDbiResourceId), use_latest_restorable_time: cdktf.booleanToTerraform(struct.useLatestRestorableTime), }; } function dbInstanceRestoreToPointInTimeToHclTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } const attrs = { restore_time: { value: cdktf.stringToHclTerraform(struct.restoreTime), isBlock: false, type: "simple", storageClassType: "string", }, source_db_instance_automated_backups_arn: { value: cdktf.stringToHclTerraform(struct.sourceDbInstanceAutomatedBackupsArn), isBlock: false, type: "simple", storageClassType: "string", }, source_db_instance_identifier: { value: cdktf.stringToHclTerraform(struct.sourceDbInstanceIdentifier), isBlock: false, type: "simple", storageClassType: "string", }, source_dbi_resource_id: { value: cdktf.stringToHclTerraform(struct.sourceDbiResourceId), isBlock: false, type: "simple", storageClassType: "string", }, use_latest_restorable_time: { value: cdktf.booleanToHclTerraform(struct.useLatestRestorableTime), isBlock: false, type: "simple", storageClassType: "boolean", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DbInstanceRestoreToPointInTimeOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._restoreTime !== undefined) { hasAnyValues = true; internalValueResult.restoreTime = this._restoreTime; } if (this._sourceDbInstanceAutomatedBackupsArn !== undefined) { hasAnyValues = true; internalValueResult.sourceDbInstanceAutomatedBackupsArn = this._sourceDbInstanceAutomatedBackupsArn; } if (this._sourceDbInstanceIdentifier !== undefined) { hasAnyValues = true; internalValueResult.sourceDbInstanceIdentifier = this._sourceDbInstanceIdentifier; } if (this._sourceDbiResourceId !== undefined) { hasAnyValues = true; internalValueResult.sourceDbiResourceId = this._sourceDbiResourceId; } if (this._useLatestRestorableTime !== undefined) { hasAnyValues = true; internalValueResult.useLatestRestorableTime = this._useLatestRestorableTime; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._restoreTime = undefined; this._sourceDbInstanceAutomatedBackupsArn = undefined; this._sourceDbInstanceIdentifier = undefined; this._sourceDbiResourceId = undefined; this._useLatestRestorableTime = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._restoreTime = value.restoreTime; this._sourceDbInstanceAutomatedBackupsArn = value.sourceDbInstanceAutomatedBackupsArn; this._sourceDbInstanceIdentifier = value.sourceDbInstanceIdentifier; this._sourceDbiResourceId = value.sourceDbiResourceId; this._useLatestRestorableTime = value.useLatestRestorableTime; } } get restoreTime() { return this.getStringAttribute('restore_time'); } set restoreTime(value) { this._restoreTime = value; } resetRestoreTime() { this._restoreTime = undefined; } // Temporarily expose input value. Use with caution. get restoreTimeInput() { return this._restoreTime; } get sourceDbInstanceAutomatedBackupsArn() { return this.getStringAttribute('source_db_instance_automated_backups_arn'); } set sourceDbInstanceAutomatedBackupsArn(value) { this._sourceDbInstanceAutomatedBackupsArn = value; } resetSourceDbInstanceAutomatedBackupsArn() { this._sourceDbInstanceAutomatedBackupsArn = undefined; } // Temporarily expose input value. Use with caution. get sourceDbInstanceAutomatedBackupsArnInput() { return this._sourceDbInstanceAutomatedBackupsArn; } get sourceDbInstanceIdentifier() { return this.getStringAttribute('source_db_instance_identifier'); } set sourceDbInstanceIdentifier(value) { this._sourceDbInstanceIdentifier = value; } resetSourceDbInstanceIdentifier() { this._sourceDbInstanceIdentifier = undefined; } // Temporarily expose input value. Use with caution. get sourceDbInstanceIdentifierInput() { return this._sourceDbInstanceIdentifier; } get sourceDbiResourceId() { return this.getStringAttribute('source_dbi_resource_id'); } set sourceDbiResourceId(value) { this._sourceDbiResourceId = value; } resetSourceDbiResourceId() { this._sourceDbiResourceId = undefined; } // Temporarily expose input value. Use with caution. get sourceDbiResourceIdInput() { return this._sourceDbiResourceId; } get useLatestRestorableTime() { return this.getBooleanAttribute('use_latest_restorable_time'); } set useLatestRestorableTime(value) { this._useLatestRestorableTime = value; } resetUseLatestRestorableTime() { this._useLatestRestorableTime = undefined; } // Temporarily expose input value. Use with caution. get useLatestRestorableTimeInput() { return this._useLatestRestorableTime; } } exports.DbInstanceRestoreToPointInTimeOutputReference = DbInstanceRestoreToPointInTimeOutputReference; _f = JSII_RTTI_SYMBOL_1; DbInstanceRestoreToPointInTimeOutputReference[_f] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceRestoreToPointInTimeOutputReference", version: "21.22.1" }; function dbInstanceS3ImportToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return { bucket_name: cdktf.stringToTerraform(struct.bucketName), bucket_prefix: cdktf.stringToTerraform(struct.bucketPrefix), ingestion_role: cdktf.stringToTerraform(struct.ingestionRole), source_engine: cdktf.stringToTerraform(struct.sourceEngine), source_engine_version: cdktf.stringToTerraform(struct.sourceEngineVersion), }; } function dbInstanceS3ImportToHclTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } const attrs = { bucket_name: { value: cdktf.stringToHclTerraform(struct.bucketName), isBlock: false, type: "simple", storageClassType: "string", }, bucket_prefix: { value: cdktf.stringToHclTerraform(struct.bucketPrefix), isBlock: false, type: "simple", storageClassType: "string", }, ingestion_role: { value: cdktf.stringToHclTerraform(struct.ingestionRole), isBlock: false, type: "simple", storageClassType: "string", }, source_engine: { value: cdktf.stringToHclTerraform(struct.sourceEngine), isBlock: false, type: "simple", storageClassType: "string", }, source_engine_version: { value: cdktf.stringToHclTerraform(struct.sourceEngineVersion), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DbInstanceS3ImportOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._bucketName !== undefined) { hasAnyValues = true; internalValueResult.bucketName = this._bucketName; } if (this._bucketPrefix !== undefined) { hasAnyValues = true; internalValueResult.bucketPrefix = this._bucketPrefix; } if (this._ingestionRole !== undefined) { hasAnyValues = true; internalValueResult.ingestionRole = this._ingestionRole; } if (this._sourceEngine !== undefined) { hasAnyValues = true; internalValueResult.sourceEngine = this._sourceEngine; } if (this._sourceEngineVersion !== undefined) { hasAnyValues = true; internalValueResult.sourceEngineVersion = this._sourceEngineVersion; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._bucketName = undefined; this._bucketPrefix = undefined; this._ingestionRole = undefined; this._sourceEngine = undefined; this._sourceEngineVersion = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._bucketName = value.bucketName; this._bucketPrefix = value.bucketPrefix; this._ingestionRole = value.ingestionRole; this._sourceEngine = value.sourceEngine; this._sourceEngineVersion = value.sourceEngineVersion; } } get bucketName() { return this.getStringAttribute('bucket_name'); } set bucketName(value) { this._bucketName = value; } // Temporarily expose input value. Use with caution. get bucketNameInput() { return this._bucketName; } get bucketPrefix() { return this.getStringAttribute('bucket_prefix'); } set bucketPrefix(value) { this._bucketPrefix = value; } resetBucketPrefix() { this._bucketPrefix = undefined; } // Temporarily expose input value. Use with caution. get bucketPrefixInput() { return this._bucketPrefix; } get ingestionRole() { return this.getStringAttribute('ingestion_role'); } set ingestionRole(value) { this._ingestionRole = value; } // Temporarily expose input value. Use with caution. get ingestionRoleInput() { return this._ingestionRole; } get sourceEngine() { return this.getStringAttribute('source_engine'); } set sourceEngine(value) { this._sourceEngine = value; } // Temporarily expose input value. Use with caution. get sourceEngineInput() { return this._sourceEngine; } get sourceEngineVersion() { return this.getStringAttribute('source_engine_version'); } set sourceEngineVersion(value) { this._sourceEngineVersion = value; } // Temporarily expose input value. Use with caution. get sourceEngineVersionInput() { return this._sourceEngineVersion; } } exports.DbInstanceS3ImportOutputReference = DbInstanceS3ImportOutputReference; _g = JSII_RTTI_SYMBOL_1; DbInstanceS3ImportOutputReference[_g] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceS3ImportOutputReference", version: "21.22.1" }; function dbInstanceTimeoutsToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return { create: cdktf.stringToTerraform(struct.create), delete: cdktf.stringToTerraform(struct.delete), update: cdktf.stringToTerraform(struct.update), }; } function dbInstanceTimeoutsToHclTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } const attrs = { create: { value: cdktf.stringToHclTerraform(struct.create), isBlock: false, type: "simple", storageClassType: "string", }, delete: { value: cdktf.stringToHclTerraform(struct.delete), isBlock: false, type: "simple", storageClassType: "string", }, update: { value: cdktf.stringToHclTerraform(struct.update), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DbInstanceTimeoutsOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false); this.isEmptyObject = false; } get internalValue() { if (this.resolvableValue) { return this.resolvableValue; } let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._create !== undefined) { hasAnyValues = true; internalValueResult.create = this._create; } if (this._delete !== undefined) { hasAnyValues = true; internalValueResult.delete = this._delete; } if (this._update !== undefined) { hasAnyValues = true; internalValueResult.update = this._update; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._create = undefined; this._delete = undefined; this._update = undefined; } else if (cdktf.Tokenization.isResolvable(value)) { this.isEmptyObject = false; this.resolvableValue = value; } else { this.isEmptyObject = Object.keys(value).length === 0; this.resolvableValue = undefined; this._create = value.create; this._delete = value.delete; this._update = value.update; } } get create() { return this.getStringAttribute('create'); } set create(value) { this._create = value; } resetCreate() { this._create = undefined; } // Temporarily expose input value. Use with caution. get createInput() { return this._create; } get delete() { return this.getStringAttribute('delete'); } set delete(value) { this._delete = value; } resetDelete() { this._delete = undefined; } // Temporarily expose input value. Use with caution. get deleteInput() { return this._delete; } get update() { return this.getStringAttribute('update'); } set update(value) { this._update = value; } resetUpdate() { this._update = undefined; } // Temporarily expose input value. Use with caution. get updateInput() { return this._update; } } exports.DbInstanceTimeoutsOutputReference = DbInstanceTimeoutsOutputReference; _h = JSII_RTTI_SYMBOL_1; DbInstanceTimeoutsOutputReference[_h] = { fqn: "@cdktf/provider-aws.dbInstance.DbInstanceTimeoutsOutputReference", version: "21.22.1" }; /** * Represents a {@link https://registry.terraform.io/providers/hashicorp/aws/6.25.0/docs/resources/db_instance aws_db_instance} */ class DbInstance extends cdktf.TerraformResource { // ============== // STATIC Methods // ============== /** * Generates CDKTF code for importing a DbInstance resource upon running "cdktf plan <stack-name>" * @param scope The scope in which to define this construct * @param importToId The construct id used in the generated config for the DbInstance to import * @param importFromId The id of the existing DbInstance that should be imported. Refer to the {@link https://registry.terraform.io/providers/hashicorp/aws/6.25.0/docs/resources/db_instance#import import section} in the documentation of this resource for the id to use * @param provider? Optional instance of the provider where the DbInstance to import is found */ static generateConfigForImport(scope, importToId, importFromId, provider) { return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "aws_db_instance", importId: importFromId, provider }); } // =========== // INITIALIZER // =========== /** * Create a new {@link https://registry.terraform.io/providers/hashicorp/aws/6.25.0/docs/resources/db_instance aws_db_instance} Resource * * @param scope The scope in which to define this construct * @param id The scoped construct ID. Must be unique amongst siblings in the same scope * @param options DbInstanceConfig */ constructor(scope, id, config) { super(scope, id, { terraformResourceType: 'aws_db_instance', terraformGeneratorMetadata: { providerName: 'aws', providerVersion: '6.25.0', providerVersionConstraint: '~> 6.0' }, provider: config.provider, dependsOn: config.dependsOn, count: config.count, lifecycle: config.lifecycle, provisioners: config.provisioners, connection: config.connection, forEach: config.forEach }); // listener_endpoint - computed: true, optional: false, required: false this._listenerEndpoint = new DbInstanceListenerEndpointList(this, "listener_endpoint", false); // master_user_secret - computed: true, optional: false, required: false this._masterUserSecret = new DbInstanceMasterUserSecretList(this, "master_user_secret", false); // blue_green_update - computed: false, optional: true, required: false this._blueGreenUpdate = new DbInstanceBlueGreenUpdateOutputReference(this, "blue_green_update"); // restore_to_point_in_time - computed: false, optional: true, required: false this._restoreToPointInTime = new DbInstanceRestoreToPointInTimeOutputReference(this, "restore_to_point_in_time"); // s3_import - computed: false, optional: true, required: false this._s3Import = new DbInstanceS3ImportOutputReference(this, "s3_import"); // timeouts - computed: false, optional: true, required: false this._timeouts = new DbInstanceTimeoutsOutputReference(this, "timeouts"); this._allocatedStorage = config.allocatedStorage; this._allowMajorVersionUpgrade = config.allowMajorVersionUpgrade; this._applyImmediately = config.applyImmediately; this._autoMinorVersionUpgrade = config.autoMinorVersionUpgrade; this._availabilityZone = config.availabilityZone; this._backupRetentionPeriod = config.backupRetentionPeriod; this._backupTarget = config.backupTarget; this._backupWindow = config.backupWindow; this._caCertIdentifier = config.caCertIdentifier; this._characterSetName = config.characterSetName; this._copyTagsToSnapshot = config.copyTagsToSnapshot; this._customIamInstanceProfile = config.customIamInstanceProfile; this._customerOwnedIpEnabled = config.customerOwnedIpEnabled; this._databaseInsightsMode = config.databaseInsightsMode; this._dbName = config.dbName; this._dbSubnetGroupName = config.dbSubnetGroupName; this._dedicatedLogVolume = config.dedicatedLogVolume; this._deleteAutomatedBackups = config.deleteAutomatedBackups; this._deletionProtection = config.deletionProtection; this._domain = config.domain; this._domainAuthSecretArn = config.domainAuthSecretArn; this._domainDnsIps = config.domainDnsIps; this._domainFqdn = config.domainFqdn; this._domainIamRoleName = config.domainIamRoleName; this._domainOu = config.domainOu; this._enabledCloudwatchLogsExports = config.enabledCloudwatchLogsExports; this._engine = config.engine; this._engineLifecycleSupport = config.engineLifecycleSupport; this._engineVersion = config.engineVersion; this._finalSnapshotIdentifier = config.finalSnapshotIdentifier; this._iamDatabaseAuthenticationEnabled = config.iamDatabaseAuthenticationEnabled; this._id = config.id; this._identifier = config.identifier; this._identifierPrefix = config.identifierPrefix; this._instanceClass = config.instanceClass; this._iops = config.iops; this._kmsKeyId = config.kmsKeyId; this._licenseModel = config.licenseModel; this._maintenanceWindow = config.maintenanceWindow; this._manageMasterUserPassword = config.manageMasterUserPassword; this._masterUserSecretKmsKeyId = config.masterUserSecretKmsKeyId; this._maxAllocatedStorage = config.maxAllocatedStorage; this._monitoringInterval = config.monitoringInterval; this._monitoringRoleArn = config.monitoringRoleArn; this._multiAz = config.multiAz; this._ncharCharacterSetName = config.ncharCharacterSetName; this._networkType = config.networkType; this._optionGroupName = config.optionGroupName; this._parameterGroupName = config.parameterGroupName; this._password = config.password; this._passwordWo = config.passwordWo; this._passwordWoVersion = config.passwordWoVersion; this._performanceInsightsEnabled = config.performanceInsightsEnabled; this._performanceInsightsKmsKeyId = config.performanceInsightsKmsKeyId; this._performanceInsightsRetentionPeriod = config.performanceInsightsRetentionPeriod; this._port = config.port; this._publiclyAccessible = config.publiclyAccessible; this._region = config.region; this._replicaMode = config.replicaMode; this._replicateSourceDb = config.replicateSourceDb; this._skipFinalSnapshot = config.skipFinalSnapshot; this._snapshotIdentifier = config.snapshotIdentifier; this._storageEncrypted = config.storageEncrypted; this._storageThroughput = config.storageThroughput; this._storageType = config.storageType; this._tags = config.tags; this._tagsAll = config.tagsAll; this._timezone = config.timezone; this._upgradeStorageConfig = config.upgradeStorageConfig; this._username = config.username; this._vpcSecurityGroupIds = config.vpcSecurityGroupIds; this._blueGreenUpdate.internalValue = config.blueGreenUpdate; this._restoreToPointInTime.internalValue = config.restoreToPointInTime; this._s3Import.internalValue = config.s3Import; this._timeouts.internalValue = config.timeouts; } // ========== // ATTRIBUTES // ========== // address - computed: true, optional: false, required: false get address() { return this.getStringAttribute('address'); } get allocatedStorage() { return this.getNumberAttribute('allocated_storage'); } set allocatedStorage(value) { this._allocatedStorage = value; } resetAllocatedStorage() { this._allocatedStorage = undefined; } // Temporarily expose input value. Use with caution. get allocatedStorageInput() { return this._allocatedStorage; } get allowMajorVersionUpgrade() { return this.getBooleanAttribute('allow_major_version_upgrade'); } set allowMajorVersionUpgrade(value) { this._allowMajorVersionUpgrade = value; } resetAllowMajorVersionUpgrade() { this._allowMajorVersionUpgrade = undefined; } // Temporarily expose input value. Use with caution. get allowMajorVersionUpgradeInput() { return this._allowMajorVersionUpgrade; } get applyImmediately() { return this.getBooleanAttribute('apply_immediately'); } set applyImmediately(value) { this._applyImmediately = value; } resetApplyImmediately() { this._applyImmediately = undefined; } // Temporarily expose input value. Use with caution. get applyImmediatelyInput() { return this._applyImmediately; } // arn - computed: true, optional: false, required: false get arn() { return this.getStringAttribute('arn'); } get autoMinorVersionUpgrade() { return this.getBooleanAttribute('auto_minor_version_upgrade'); } set autoMinorVersionUpgrade(value) { this._autoMinorVersionUpgrade = value; } resetAutoMinorVersionUpgrade() { this._autoMinorVersionUpgrade = undefined; } // Temporarily expose input value. Use with caution. get autoMinorVersionUpgradeInput() { return this._autoMinorVersionUpgrade; } get availabilityZone() { return this.getStringAttribute('availability_zone'); } set availabilityZone(value) { this._availabilityZone = value; } resetAvailabilityZone() { this._availabilityZone = undefined; } // Temporarily expose input value. Use with caution. get availabilityZoneInput() { return this._availabilityZone; } get backupRetentionPeriod() { return this.getNumberAttribute('backup_retention_period'); } set backupRetentionPeriod(value) { this._backupRetentionPeriod = value; } resetBackupRetentionPeriod() { this._backupRetentionPeriod = undefined; } // Temporarily expose input value. Use with caution. get backupRetentionPeriodInput() { return this._backupRetentionPeriod; } get backupTarget() { return this.getStringAttribute('backup_target'); } set backupTarget(value) { this._backupTarget = value; } resetBackupTarget() { this._backupTarget = undefined; } // Temporarily expose input value. Use with caution. get backupTargetInput() { return this._backupTarget; } get backupWindow() { return this.getStringAttribute('backup_window'); } set backupWindow(value) { this._backupWindow = value; } resetBackupWindow() { this._backupWindow = undefined; } // Temporarily expose input value. Use with caution. get backupWindowInput() { return this._backupWindow; } get caCertIdentifier() { return this.getStringAttribute('ca_cert_identifier'); } set caCertIdentifier(value) { this._caCertIdentifier = value; } resetCaCertIdentifier() { this._caCertIdentifier = undefined; } // Temporarily expose input value. Use with caution. get caCertIdentifierInput() { return this._caCertIdentifier; } get characterSetName() { return this.getStringAttribute('character_set_name'); } set characterSetName(value) { this._characterSetName = value; } resetCharacterSetName() { this._characterSetName = undefined; } // Temporarily expose input value. Use with caution. get characterSetNameInput() { return this._characterSetName; } get copyTagsToSnapshot() { return this.getBooleanAttribute('copy_tags_to_snapshot'); } set copyTagsToSnapshot(value) { this._copyTagsToSnapshot = value; } resetCopyTagsToSnapshot() { this._copyTagsToSnapshot = undefined; } // Temporarily expose input value. Use with caution. get copyTagsToSnapshotInput() { return this._copyTagsToSnapshot; } get customIamInstanceProfile() { return this.getStringAttribute('custom_iam_instance_profile'); } set customIamInstanceProfile(value) { this._customIamInstanceProfile = value; } resetCustomIamInstanceProfile() { this._customIamInstanceProfile = undefined; } // Temporarily expose input value. Use with caution. get customIamInstanceProfileInput() { return this._customIamInstanceProfile; } get customerOwnedIpEnabled() { return this.getBooleanAttribute('customer_owned_ip_enabled'); } set customerOwnedIpEnabled(value) { this._customerOwnedIpEnabled = value; } resetCustomerOwnedIpEnabled() { this._customerOwnedIpEnabled = undefined; } // Temporarily expose input value. Use with caution. get customerOwnedIpEnabledInput() { return this._customerOwnedIpEnabled; } get databaseInsightsMode() { return this.getStringAttribute('database_insights_mode'); } set databaseInsightsMode(value) { this._databaseInsightsMode = value; } resetDatabaseInsightsMode() { this._databaseInsightsMode = undefined; } // Temporarily expose input value. Use with caution. get databaseInsightsModeInput() { return this._databaseInsightsMode; } get dbName() { return this.getStringAttribute('db_name'); } set dbName(value) { this._dbName = value; } resetDbName() { this._dbName = undefined; } // Temporarily expose input value. Use with caution. get dbNameInput() { return this._dbName; } get dbSubnetGroupName() { return this.getStringAttribute('db_subnet_group_name'); } set dbSubnetGroupName(value) { this._dbSubnetGroupName = value; } resetDbSubnetGroupName() { this._dbSubnetGroupName = undefined; } // Temporarily expose input value. Use with caution. get dbSubnetGroupNameInput() { return this._dbSubnetGroupName; } get dedicatedLogVolume() { return this.getBooleanAttribute('dedicated_log_volume'); } set dedicatedLogVolume(value) { this._dedicatedLogVolume = value; } resetDedicatedLogVolume() { this._dedicatedLogVolume = undefined; } // Temporarily expose input value. Use with caution. get dedicatedLogVolumeInput() { return this._dedicatedLogVolume; } get deleteAutomatedBackups() { return this.getBooleanAttribute('delete_automated_backups'); } set deleteAutomatedBackups(value) { this._deleteAutomatedBackups = value; } resetDeleteAutomatedBackups() { this._deleteAutomatedBackups = undefined; } // Temporarily expose input value. Use with caution. get deleteAutomatedBackupsInput() { return this._deleteAutomatedBackups; } get deletionProtection() { return this.getBooleanAttribute('deletion_protection'); } set deletionProtection(value) { this._deletionProtection = value; } resetDeletionProtection() { this._deletionProtection = undefined; } // Temporarily expose input value. Use with caution. get deletionProtectionInput() { return this._deletionProtection; } get domain() { return this.getStringAttribute('domain'); } set domain(value) { this._domain = value; } resetDomain() { this._domain = undefined; } // Temporarily expose input value. Use with caution. get domainInput() { return this._domain; } get domainAuthSecretArn() { return this.getStringAttribute('domain_auth_secret_arn'); } set domainAuthSecretArn(value) { this._domainAuthSecretArn = value; } resetDomainAuthSecretArn() { this._domainAuthSecretArn = undefined; } // Temporarily expose input value. Use with caution. get domainAuthSecretArnInput() { return this._domainAuthSecretArn; } get domainDnsIps() { return this.getListAttribute('domain_dns_ips'); } set domainDnsIps(value) { this._domainDnsIps = value; } resetDomainDnsIps() { this._domainDnsIps = undefined; } // Temporarily expose input value. Use with caution. get domainDnsIpsInput() { return this._domainDnsIps; } get domainFqdn() { return this.getStringAttribute('domain_fqdn'); } set domainFqdn(value) { this._domainFqdn = value; } resetDomainFqdn() { this._domainFqdn = undefined; } // Temporarily expose input value. Use with caution. get domainFqdnInput() { return this._domainFqdn; } get domainIamRoleName() { return this.getStringAttribute('domain_iam_role_name'); } set domainIamRoleName(value) { this._domainIamRoleName = value; } resetDomainIamRoleName() { this._domainIamRoleName = undefined; } // Temporarily expose input value. Use with caution. get domainIamRoleNameInput() { return this._domainIamRoleName; } get domainOu() { return this.getStringAttribute('domain_ou'); } set domainOu(value) { this._domainOu = value; } resetDomainOu() { this._domainOu = undefined; } // Temporarily expose input value. Use with caution. get domainOuInput() { return this._domainOu; } get enabledCloudwatchLogsExports() { return cdktf.Fn.tolist(this.getListAttribute('enabled_cloudwatch_logs_exports')); } set enabledCloudwatchLogsExports(value) { this._enabledCloudwatchLogsExports = value; } resetEnabledCloudwatchLogsExports() { this._enabledCloudwatchLogsExports = undefined; } // Temporarily expose input value. Use with caution. get enabledCloudwatchLogsExportsInput() { return this._enabledCloudwatchLogsExports; } // endpoint - computed: true, optional: false, required: false get endpoint() { return this.getStringAttribute('endpoint'); } get engine() { return this.getStringAttribute('engine'); } set engine(value) { this._engine = value; } resetEngine() { this._engine = undefined; } // Temporarily expose input value. Use with caution. get engineInput() { return this._engine; } get engineLifecycleSupport() { return this.getStringAttribute('engine_lifecycle_support'); } set engineLifecycleSupport(value) { this._engineLifecycleSupport = value; } resetEngineLifecycleSupport() { this._engineLifecycleSupport = undefined; } // Temporarily expose input value. Use with caution. get engineLifecycleSupportInput() { return this._engineLifecycleSupport; } get engineVersion() { return this.getStringAttribute('engine_version'); } set engineVersion(value) { this._engineVersion = value; } resetEngineVersion() { this._engineVersion = undefined; } // Temporarily expose input value. Use with caution. get engineVersionInput() { return this._engineVersion; } // engine_version_actual - computed: true, optional: false, required: false get engineVersionActual() { return this.getStringAttribute('engine_version_actual'); } get finalSnapshotIdentifier() { return this.getStringAttribute('final_snapshot_identifier'); } set finalSnapshotIdentifier(value) { this._finalSnapshotIdentifier = value; } resetFinalSnapshotIdentifier() { this._finalSnapshotIdentifier = undefined; } // Temporaril