/
clusterInstance.go
771 lines (691 loc) · 49.4 KB
/
clusterInstance.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package rds
import (
"context"
"reflect"
"errors"
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Provides an RDS Cluster Instance Resource. A Cluster Instance Resource defines
// attributes that are specific to a single instance in a RDS Cluster,
// specifically running Amazon Aurora.
//
// Unlike other RDS resources that support replication, with Amazon Aurora you do
// not designate a primary and subsequent replicas. Instead, you simply add RDS
// Instances and Aurora manages the replication. You can use the [count][5]
// meta-parameter to make multiple instances and join them all to the same RDS
// Cluster, or you may specify different Cluster Instance resources with various
// `instanceClass` sizes.
//
// For more information on Amazon Aurora, see [Aurora on Amazon RDS](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Aurora.html) in the Amazon RDS User Guide.
//
// > **NOTE:** Deletion Protection from the RDS service can only be enabled at the cluster level, not for individual cluster instances. You can still add the [`protect` CustomResourceOption](https://www.pulumi.com/docs/intro/concepts/programming-model/#protect) to this resource configuration if you desire protection from accidental deletion.
//
// > **NOTE:** `aurora` is no longer a valid `engine` because of [Amazon Aurora's MySQL-Compatible Edition version 1 end of life](https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/Aurora.MySQL56.EOL.html).
//
// ## Example Usage
//
// <!--Start PulumiCodeChooser -->
// ```go
// package main
//
// import (
//
// "fmt"
//
// "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/rds"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := rds.NewCluster(ctx, "default", &rds.ClusterArgs{
// ClusterIdentifier: pulumi.String("aurora-cluster-demo"),
// AvailabilityZones: pulumi.StringArray{
// pulumi.String("us-west-2a"),
// pulumi.String("us-west-2b"),
// pulumi.String("us-west-2c"),
// },
// DatabaseName: pulumi.String("mydb"),
// MasterUsername: pulumi.String("foo"),
// MasterPassword: pulumi.String("barbut8chars"),
// })
// if err != nil {
// return err
// }
// var clusterInstances []*rds.ClusterInstance
// for index := 0; index < 2; index++ {
// key0 := index
// val0 := index
// __res, err := rds.NewClusterInstance(ctx, fmt.Sprintf("cluster_instances-%v", key0), &rds.ClusterInstanceArgs{
// Identifier: pulumi.String(fmt.Sprintf("aurora-cluster-demo-%v", val0)),
// ClusterIdentifier: _default.ID(),
// InstanceClass: pulumi.String(rds.InstanceType_R4_Large),
// Engine: _default.Engine,
// EngineVersion: _default.EngineVersion,
// })
// if err != nil {
// return err
// }
// clusterInstances = append(clusterInstances, __res)
// }
// return nil
// })
// }
//
// ```
// <!--End PulumiCodeChooser -->
//
// ## Import
//
// Using `pulumi import`, import RDS Cluster Instances using the `identifier`. For example:
//
// ```sh
// $ pulumi import aws:rds/clusterInstance:ClusterInstance prod_instance_1 aurora-cluster-instance-1
// ```
type ClusterInstance struct {
pulumi.CustomResourceState
// Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default is`false`.
ApplyImmediately pulumi.BoolOutput `pulumi:"applyImmediately"`
// Amazon Resource Name (ARN) of cluster instance
Arn pulumi.StringOutput `pulumi:"arn"`
// Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
AutoMinorVersionUpgrade pulumi.BoolPtrOutput `pulumi:"autoMinorVersionUpgrade"`
// EC2 Availability Zone that the DB instance is created in. See [docs](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) about the details.
AvailabilityZone pulumi.StringOutput `pulumi:"availabilityZone"`
// Identifier of the CA certificate for the DB instance.
CaCertIdentifier pulumi.StringOutput `pulumi:"caCertIdentifier"`
// Identifier of the `rds.Cluster` in which to launch this instance.
ClusterIdentifier pulumi.StringOutput `pulumi:"clusterIdentifier"`
// Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
CopyTagsToSnapshot pulumi.BoolPtrOutput `pulumi:"copyTagsToSnapshot"`
// Instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.
CustomIamInstanceProfile pulumi.StringPtrOutput `pulumi:"customIamInstanceProfile"`
// Name of the DB parameter group to associate with this instance.
DbParameterGroupName pulumi.StringOutput `pulumi:"dbParameterGroupName"`
// DB subnet group to associate with this DB instance. **NOTE:** This must match the `dbSubnetGroupName` of the attached `rds.Cluster`.
DbSubnetGroupName pulumi.StringOutput `pulumi:"dbSubnetGroupName"`
// Region-unique, immutable identifier for the DB instance.
DbiResourceId pulumi.StringOutput `pulumi:"dbiResourceId"`
// DNS address for this instance. May not be writable
Endpoint pulumi.StringOutput `pulumi:"endpoint"`
// Name of the database engine to be used for the RDS cluster instance.
// Valid Values: `aurora-mysql`, `aurora-postgresql`, `mysql`, `postgres`.(Note that `mysql` and `postgres` are Multi-AZ RDS clusters).
Engine pulumi.StringOutput `pulumi:"engine"`
// Database engine version. Please note that to upgrade the `engineVersion` of the instance, it must be done on the `rds.Cluster` `engineVersion`. Trying to upgrade in `awsClusterInstance` will not update the `engineVersion`.
EngineVersion pulumi.StringOutput `pulumi:"engineVersion"`
// Database engine version
EngineVersionActual pulumi.StringOutput `pulumi:"engineVersionActual"`
// Identifier for the RDS instance, if omitted, Pulumi will assign a random, unique identifier.
Identifier pulumi.StringOutput `pulumi:"identifier"`
// Creates a unique identifier beginning with the specified prefix. Conflicts with `identifier`.
IdentifierPrefix pulumi.StringOutput `pulumi:"identifierPrefix"`
// Instance class to use. For details on CPU and memory, see [Scaling Aurora DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Managing.html). Aurora uses `db.*` instance classes/types. Please see [AWS Documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html) for currently available instance classes and complete details.
InstanceClass pulumi.StringOutput `pulumi:"instanceClass"`
// ARN for the KMS encryption key if one is set to the cluster.
KmsKeyId pulumi.StringOutput `pulumi:"kmsKeyId"`
// Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.
MonitoringInterval pulumi.IntPtrOutput `pulumi:"monitoringInterval"`
// ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the [AWS Documentation](http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.html) what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
MonitoringRoleArn pulumi.StringOutput `pulumi:"monitoringRoleArn"`
// Network type of the DB instance.
NetworkType pulumi.StringOutput `pulumi:"networkType"`
// Specifies whether Performance Insights is enabled or not.
PerformanceInsightsEnabled pulumi.BoolOutput `pulumi:"performanceInsightsEnabled"`
// ARN for the KMS key to encrypt Performance Insights data. When specifying `performanceInsightsKmsKeyId`, `performanceInsightsEnabled` needs to be set to true.
PerformanceInsightsKmsKeyId pulumi.StringOutput `pulumi:"performanceInsightsKmsKeyId"`
// Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performanceInsightsRetentionPeriod`, `performanceInsightsEnabled` needs to be set to true. Defaults to '7'.
PerformanceInsightsRetentionPeriod pulumi.IntOutput `pulumi:"performanceInsightsRetentionPeriod"`
// Database port
Port pulumi.IntOutput `pulumi:"port"`
// Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". **NOTE:** If `preferredBackupWindow` is set at the cluster level, this argument **must** be omitted.
PreferredBackupWindow pulumi.StringOutput `pulumi:"preferredBackupWindow"`
// Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00".
PreferredMaintenanceWindow pulumi.StringOutput `pulumi:"preferredMaintenanceWindow"`
// Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer.
PromotionTier pulumi.IntPtrOutput `pulumi:"promotionTier"`
// Bool to control if instance is publicly accessible. Default `false`. See the documentation on [Creating DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) for more details on controlling this property.
PubliclyAccessible pulumi.BoolOutput `pulumi:"publiclyAccessible"`
// Specifies whether the DB cluster is encrypted.
StorageEncrypted pulumi.BoolOutput `pulumi:"storageEncrypted"`
// Map of tags to assign to the instance. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapOutput `pulumi:"tags"`
// Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
//
// Deprecated: Please use `tags` instead.
TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"`
// Boolean indicating if this instance is writable. `False` indicates this instance is a read replica.
Writer pulumi.BoolOutput `pulumi:"writer"`
}
// NewClusterInstance registers a new resource with the given unique name, arguments, and options.
func NewClusterInstance(ctx *pulumi.Context,
name string, args *ClusterInstanceArgs, opts ...pulumi.ResourceOption) (*ClusterInstance, error) {
if args == nil {
return nil, errors.New("missing one or more required arguments")
}
if args.ClusterIdentifier == nil {
return nil, errors.New("invalid value for required argument 'ClusterIdentifier'")
}
if args.Engine == nil {
return nil, errors.New("invalid value for required argument 'Engine'")
}
if args.InstanceClass == nil {
return nil, errors.New("invalid value for required argument 'InstanceClass'")
}
opts = internal.PkgResourceDefaultOpts(opts)
var resource ClusterInstance
err := ctx.RegisterResource("aws:rds/clusterInstance:ClusterInstance", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetClusterInstance gets an existing ClusterInstance resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetClusterInstance(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *ClusterInstanceState, opts ...pulumi.ResourceOption) (*ClusterInstance, error) {
var resource ClusterInstance
err := ctx.ReadResource("aws:rds/clusterInstance:ClusterInstance", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering ClusterInstance resources.
type clusterInstanceState struct {
// Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default is`false`.
ApplyImmediately *bool `pulumi:"applyImmediately"`
// Amazon Resource Name (ARN) of cluster instance
Arn *string `pulumi:"arn"`
// Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
AutoMinorVersionUpgrade *bool `pulumi:"autoMinorVersionUpgrade"`
// EC2 Availability Zone that the DB instance is created in. See [docs](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) about the details.
AvailabilityZone *string `pulumi:"availabilityZone"`
// Identifier of the CA certificate for the DB instance.
CaCertIdentifier *string `pulumi:"caCertIdentifier"`
// Identifier of the `rds.Cluster` in which to launch this instance.
ClusterIdentifier *string `pulumi:"clusterIdentifier"`
// Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
CopyTagsToSnapshot *bool `pulumi:"copyTagsToSnapshot"`
// Instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.
CustomIamInstanceProfile *string `pulumi:"customIamInstanceProfile"`
// Name of the DB parameter group to associate with this instance.
DbParameterGroupName *string `pulumi:"dbParameterGroupName"`
// DB subnet group to associate with this DB instance. **NOTE:** This must match the `dbSubnetGroupName` of the attached `rds.Cluster`.
DbSubnetGroupName *string `pulumi:"dbSubnetGroupName"`
// Region-unique, immutable identifier for the DB instance.
DbiResourceId *string `pulumi:"dbiResourceId"`
// DNS address for this instance. May not be writable
Endpoint *string `pulumi:"endpoint"`
// Name of the database engine to be used for the RDS cluster instance.
// Valid Values: `aurora-mysql`, `aurora-postgresql`, `mysql`, `postgres`.(Note that `mysql` and `postgres` are Multi-AZ RDS clusters).
Engine *string `pulumi:"engine"`
// Database engine version. Please note that to upgrade the `engineVersion` of the instance, it must be done on the `rds.Cluster` `engineVersion`. Trying to upgrade in `awsClusterInstance` will not update the `engineVersion`.
EngineVersion *string `pulumi:"engineVersion"`
// Database engine version
EngineVersionActual *string `pulumi:"engineVersionActual"`
// Identifier for the RDS instance, if omitted, Pulumi will assign a random, unique identifier.
Identifier *string `pulumi:"identifier"`
// Creates a unique identifier beginning with the specified prefix. Conflicts with `identifier`.
IdentifierPrefix *string `pulumi:"identifierPrefix"`
// Instance class to use. For details on CPU and memory, see [Scaling Aurora DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Managing.html). Aurora uses `db.*` instance classes/types. Please see [AWS Documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html) for currently available instance classes and complete details.
InstanceClass *string `pulumi:"instanceClass"`
// ARN for the KMS encryption key if one is set to the cluster.
KmsKeyId *string `pulumi:"kmsKeyId"`
// Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.
MonitoringInterval *int `pulumi:"monitoringInterval"`
// ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the [AWS Documentation](http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.html) what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
MonitoringRoleArn *string `pulumi:"monitoringRoleArn"`
// Network type of the DB instance.
NetworkType *string `pulumi:"networkType"`
// Specifies whether Performance Insights is enabled or not.
PerformanceInsightsEnabled *bool `pulumi:"performanceInsightsEnabled"`
// ARN for the KMS key to encrypt Performance Insights data. When specifying `performanceInsightsKmsKeyId`, `performanceInsightsEnabled` needs to be set to true.
PerformanceInsightsKmsKeyId *string `pulumi:"performanceInsightsKmsKeyId"`
// Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performanceInsightsRetentionPeriod`, `performanceInsightsEnabled` needs to be set to true. Defaults to '7'.
PerformanceInsightsRetentionPeriod *int `pulumi:"performanceInsightsRetentionPeriod"`
// Database port
Port *int `pulumi:"port"`
// Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". **NOTE:** If `preferredBackupWindow` is set at the cluster level, this argument **must** be omitted.
PreferredBackupWindow *string `pulumi:"preferredBackupWindow"`
// Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00".
PreferredMaintenanceWindow *string `pulumi:"preferredMaintenanceWindow"`
// Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer.
PromotionTier *int `pulumi:"promotionTier"`
// Bool to control if instance is publicly accessible. Default `false`. See the documentation on [Creating DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) for more details on controlling this property.
PubliclyAccessible *bool `pulumi:"publiclyAccessible"`
// Specifies whether the DB cluster is encrypted.
StorageEncrypted *bool `pulumi:"storageEncrypted"`
// Map of tags to assign to the instance. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags map[string]string `pulumi:"tags"`
// Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
//
// Deprecated: Please use `tags` instead.
TagsAll map[string]string `pulumi:"tagsAll"`
// Boolean indicating if this instance is writable. `False` indicates this instance is a read replica.
Writer *bool `pulumi:"writer"`
}
type ClusterInstanceState struct {
// Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default is`false`.
ApplyImmediately pulumi.BoolPtrInput
// Amazon Resource Name (ARN) of cluster instance
Arn pulumi.StringPtrInput
// Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
AutoMinorVersionUpgrade pulumi.BoolPtrInput
// EC2 Availability Zone that the DB instance is created in. See [docs](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) about the details.
AvailabilityZone pulumi.StringPtrInput
// Identifier of the CA certificate for the DB instance.
CaCertIdentifier pulumi.StringPtrInput
// Identifier of the `rds.Cluster` in which to launch this instance.
ClusterIdentifier pulumi.StringPtrInput
// Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
CopyTagsToSnapshot pulumi.BoolPtrInput
// Instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.
CustomIamInstanceProfile pulumi.StringPtrInput
// Name of the DB parameter group to associate with this instance.
DbParameterGroupName pulumi.StringPtrInput
// DB subnet group to associate with this DB instance. **NOTE:** This must match the `dbSubnetGroupName` of the attached `rds.Cluster`.
DbSubnetGroupName pulumi.StringPtrInput
// Region-unique, immutable identifier for the DB instance.
DbiResourceId pulumi.StringPtrInput
// DNS address for this instance. May not be writable
Endpoint pulumi.StringPtrInput
// Name of the database engine to be used for the RDS cluster instance.
// Valid Values: `aurora-mysql`, `aurora-postgresql`, `mysql`, `postgres`.(Note that `mysql` and `postgres` are Multi-AZ RDS clusters).
Engine pulumi.StringPtrInput
// Database engine version. Please note that to upgrade the `engineVersion` of the instance, it must be done on the `rds.Cluster` `engineVersion`. Trying to upgrade in `awsClusterInstance` will not update the `engineVersion`.
EngineVersion pulumi.StringPtrInput
// Database engine version
EngineVersionActual pulumi.StringPtrInput
// Identifier for the RDS instance, if omitted, Pulumi will assign a random, unique identifier.
Identifier pulumi.StringPtrInput
// Creates a unique identifier beginning with the specified prefix. Conflicts with `identifier`.
IdentifierPrefix pulumi.StringPtrInput
// Instance class to use. For details on CPU and memory, see [Scaling Aurora DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Managing.html). Aurora uses `db.*` instance classes/types. Please see [AWS Documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html) for currently available instance classes and complete details.
InstanceClass pulumi.StringPtrInput
// ARN for the KMS encryption key if one is set to the cluster.
KmsKeyId pulumi.StringPtrInput
// Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.
MonitoringInterval pulumi.IntPtrInput
// ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the [AWS Documentation](http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.html) what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
MonitoringRoleArn pulumi.StringPtrInput
// Network type of the DB instance.
NetworkType pulumi.StringPtrInput
// Specifies whether Performance Insights is enabled or not.
PerformanceInsightsEnabled pulumi.BoolPtrInput
// ARN for the KMS key to encrypt Performance Insights data. When specifying `performanceInsightsKmsKeyId`, `performanceInsightsEnabled` needs to be set to true.
PerformanceInsightsKmsKeyId pulumi.StringPtrInput
// Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performanceInsightsRetentionPeriod`, `performanceInsightsEnabled` needs to be set to true. Defaults to '7'.
PerformanceInsightsRetentionPeriod pulumi.IntPtrInput
// Database port
Port pulumi.IntPtrInput
// Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". **NOTE:** If `preferredBackupWindow` is set at the cluster level, this argument **must** be omitted.
PreferredBackupWindow pulumi.StringPtrInput
// Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00".
PreferredMaintenanceWindow pulumi.StringPtrInput
// Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer.
PromotionTier pulumi.IntPtrInput
// Bool to control if instance is publicly accessible. Default `false`. See the documentation on [Creating DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) for more details on controlling this property.
PubliclyAccessible pulumi.BoolPtrInput
// Specifies whether the DB cluster is encrypted.
StorageEncrypted pulumi.BoolPtrInput
// Map of tags to assign to the instance. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapInput
// Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
//
// Deprecated: Please use `tags` instead.
TagsAll pulumi.StringMapInput
// Boolean indicating if this instance is writable. `False` indicates this instance is a read replica.
Writer pulumi.BoolPtrInput
}
func (ClusterInstanceState) ElementType() reflect.Type {
return reflect.TypeOf((*clusterInstanceState)(nil)).Elem()
}
type clusterInstanceArgs struct {
// Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default is`false`.
ApplyImmediately *bool `pulumi:"applyImmediately"`
// Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
AutoMinorVersionUpgrade *bool `pulumi:"autoMinorVersionUpgrade"`
// EC2 Availability Zone that the DB instance is created in. See [docs](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) about the details.
AvailabilityZone *string `pulumi:"availabilityZone"`
// Identifier of the CA certificate for the DB instance.
CaCertIdentifier *string `pulumi:"caCertIdentifier"`
// Identifier of the `rds.Cluster` in which to launch this instance.
ClusterIdentifier string `pulumi:"clusterIdentifier"`
// Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
CopyTagsToSnapshot *bool `pulumi:"copyTagsToSnapshot"`
// Instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.
CustomIamInstanceProfile *string `pulumi:"customIamInstanceProfile"`
// Name of the DB parameter group to associate with this instance.
DbParameterGroupName *string `pulumi:"dbParameterGroupName"`
// DB subnet group to associate with this DB instance. **NOTE:** This must match the `dbSubnetGroupName` of the attached `rds.Cluster`.
DbSubnetGroupName *string `pulumi:"dbSubnetGroupName"`
// Name of the database engine to be used for the RDS cluster instance.
// Valid Values: `aurora-mysql`, `aurora-postgresql`, `mysql`, `postgres`.(Note that `mysql` and `postgres` are Multi-AZ RDS clusters).
Engine string `pulumi:"engine"`
// Database engine version. Please note that to upgrade the `engineVersion` of the instance, it must be done on the `rds.Cluster` `engineVersion`. Trying to upgrade in `awsClusterInstance` will not update the `engineVersion`.
EngineVersion *string `pulumi:"engineVersion"`
// Identifier for the RDS instance, if omitted, Pulumi will assign a random, unique identifier.
Identifier *string `pulumi:"identifier"`
// Creates a unique identifier beginning with the specified prefix. Conflicts with `identifier`.
IdentifierPrefix *string `pulumi:"identifierPrefix"`
// Instance class to use. For details on CPU and memory, see [Scaling Aurora DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Managing.html). Aurora uses `db.*` instance classes/types. Please see [AWS Documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html) for currently available instance classes and complete details.
InstanceClass string `pulumi:"instanceClass"`
// Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.
MonitoringInterval *int `pulumi:"monitoringInterval"`
// ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the [AWS Documentation](http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.html) what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
MonitoringRoleArn *string `pulumi:"monitoringRoleArn"`
// Specifies whether Performance Insights is enabled or not.
PerformanceInsightsEnabled *bool `pulumi:"performanceInsightsEnabled"`
// ARN for the KMS key to encrypt Performance Insights data. When specifying `performanceInsightsKmsKeyId`, `performanceInsightsEnabled` needs to be set to true.
PerformanceInsightsKmsKeyId *string `pulumi:"performanceInsightsKmsKeyId"`
// Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performanceInsightsRetentionPeriod`, `performanceInsightsEnabled` needs to be set to true. Defaults to '7'.
PerformanceInsightsRetentionPeriod *int `pulumi:"performanceInsightsRetentionPeriod"`
// Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". **NOTE:** If `preferredBackupWindow` is set at the cluster level, this argument **must** be omitted.
PreferredBackupWindow *string `pulumi:"preferredBackupWindow"`
// Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00".
PreferredMaintenanceWindow *string `pulumi:"preferredMaintenanceWindow"`
// Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer.
PromotionTier *int `pulumi:"promotionTier"`
// Bool to control if instance is publicly accessible. Default `false`. See the documentation on [Creating DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) for more details on controlling this property.
PubliclyAccessible *bool `pulumi:"publiclyAccessible"`
// Map of tags to assign to the instance. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags map[string]string `pulumi:"tags"`
}
// The set of arguments for constructing a ClusterInstance resource.
type ClusterInstanceArgs struct {
// Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default is`false`.
ApplyImmediately pulumi.BoolPtrInput
// Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
AutoMinorVersionUpgrade pulumi.BoolPtrInput
// EC2 Availability Zone that the DB instance is created in. See [docs](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) about the details.
AvailabilityZone pulumi.StringPtrInput
// Identifier of the CA certificate for the DB instance.
CaCertIdentifier pulumi.StringPtrInput
// Identifier of the `rds.Cluster` in which to launch this instance.
ClusterIdentifier pulumi.StringInput
// Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
CopyTagsToSnapshot pulumi.BoolPtrInput
// Instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.
CustomIamInstanceProfile pulumi.StringPtrInput
// Name of the DB parameter group to associate with this instance.
DbParameterGroupName pulumi.StringPtrInput
// DB subnet group to associate with this DB instance. **NOTE:** This must match the `dbSubnetGroupName` of the attached `rds.Cluster`.
DbSubnetGroupName pulumi.StringPtrInput
// Name of the database engine to be used for the RDS cluster instance.
// Valid Values: `aurora-mysql`, `aurora-postgresql`, `mysql`, `postgres`.(Note that `mysql` and `postgres` are Multi-AZ RDS clusters).
Engine pulumi.StringInput
// Database engine version. Please note that to upgrade the `engineVersion` of the instance, it must be done on the `rds.Cluster` `engineVersion`. Trying to upgrade in `awsClusterInstance` will not update the `engineVersion`.
EngineVersion pulumi.StringPtrInput
// Identifier for the RDS instance, if omitted, Pulumi will assign a random, unique identifier.
Identifier pulumi.StringPtrInput
// Creates a unique identifier beginning with the specified prefix. Conflicts with `identifier`.
IdentifierPrefix pulumi.StringPtrInput
// Instance class to use. For details on CPU and memory, see [Scaling Aurora DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Managing.html). Aurora uses `db.*` instance classes/types. Please see [AWS Documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html) for currently available instance classes and complete details.
InstanceClass pulumi.StringInput
// Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.
MonitoringInterval pulumi.IntPtrInput
// ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the [AWS Documentation](http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.html) what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
MonitoringRoleArn pulumi.StringPtrInput
// Specifies whether Performance Insights is enabled or not.
PerformanceInsightsEnabled pulumi.BoolPtrInput
// ARN for the KMS key to encrypt Performance Insights data. When specifying `performanceInsightsKmsKeyId`, `performanceInsightsEnabled` needs to be set to true.
PerformanceInsightsKmsKeyId pulumi.StringPtrInput
// Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performanceInsightsRetentionPeriod`, `performanceInsightsEnabled` needs to be set to true. Defaults to '7'.
PerformanceInsightsRetentionPeriod pulumi.IntPtrInput
// Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". **NOTE:** If `preferredBackupWindow` is set at the cluster level, this argument **must** be omitted.
PreferredBackupWindow pulumi.StringPtrInput
// Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00".
PreferredMaintenanceWindow pulumi.StringPtrInput
// Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer.
PromotionTier pulumi.IntPtrInput
// Bool to control if instance is publicly accessible. Default `false`. See the documentation on [Creating DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) for more details on controlling this property.
PubliclyAccessible pulumi.BoolPtrInput
// Map of tags to assign to the instance. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
Tags pulumi.StringMapInput
}
func (ClusterInstanceArgs) ElementType() reflect.Type {
return reflect.TypeOf((*clusterInstanceArgs)(nil)).Elem()
}
type ClusterInstanceInput interface {
pulumi.Input
ToClusterInstanceOutput() ClusterInstanceOutput
ToClusterInstanceOutputWithContext(ctx context.Context) ClusterInstanceOutput
}
func (*ClusterInstance) ElementType() reflect.Type {
return reflect.TypeOf((**ClusterInstance)(nil)).Elem()
}
func (i *ClusterInstance) ToClusterInstanceOutput() ClusterInstanceOutput {
return i.ToClusterInstanceOutputWithContext(context.Background())
}
func (i *ClusterInstance) ToClusterInstanceOutputWithContext(ctx context.Context) ClusterInstanceOutput {
return pulumi.ToOutputWithContext(ctx, i).(ClusterInstanceOutput)
}
// ClusterInstanceArrayInput is an input type that accepts ClusterInstanceArray and ClusterInstanceArrayOutput values.
// You can construct a concrete instance of `ClusterInstanceArrayInput` via:
//
// ClusterInstanceArray{ ClusterInstanceArgs{...} }
type ClusterInstanceArrayInput interface {
pulumi.Input
ToClusterInstanceArrayOutput() ClusterInstanceArrayOutput
ToClusterInstanceArrayOutputWithContext(context.Context) ClusterInstanceArrayOutput
}
type ClusterInstanceArray []ClusterInstanceInput
func (ClusterInstanceArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*ClusterInstance)(nil)).Elem()
}
func (i ClusterInstanceArray) ToClusterInstanceArrayOutput() ClusterInstanceArrayOutput {
return i.ToClusterInstanceArrayOutputWithContext(context.Background())
}
func (i ClusterInstanceArray) ToClusterInstanceArrayOutputWithContext(ctx context.Context) ClusterInstanceArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(ClusterInstanceArrayOutput)
}
// ClusterInstanceMapInput is an input type that accepts ClusterInstanceMap and ClusterInstanceMapOutput values.
// You can construct a concrete instance of `ClusterInstanceMapInput` via:
//
// ClusterInstanceMap{ "key": ClusterInstanceArgs{...} }
type ClusterInstanceMapInput interface {
pulumi.Input
ToClusterInstanceMapOutput() ClusterInstanceMapOutput
ToClusterInstanceMapOutputWithContext(context.Context) ClusterInstanceMapOutput
}
type ClusterInstanceMap map[string]ClusterInstanceInput
func (ClusterInstanceMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*ClusterInstance)(nil)).Elem()
}
func (i ClusterInstanceMap) ToClusterInstanceMapOutput() ClusterInstanceMapOutput {
return i.ToClusterInstanceMapOutputWithContext(context.Background())
}
func (i ClusterInstanceMap) ToClusterInstanceMapOutputWithContext(ctx context.Context) ClusterInstanceMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(ClusterInstanceMapOutput)
}
type ClusterInstanceOutput struct{ *pulumi.OutputState }
func (ClusterInstanceOutput) ElementType() reflect.Type {
return reflect.TypeOf((**ClusterInstance)(nil)).Elem()
}
func (o ClusterInstanceOutput) ToClusterInstanceOutput() ClusterInstanceOutput {
return o
}
func (o ClusterInstanceOutput) ToClusterInstanceOutputWithContext(ctx context.Context) ClusterInstanceOutput {
return o
}
// Specifies whether any database modifications are applied immediately, or during the next maintenance window. Default is`false`.
func (o ClusterInstanceOutput) ApplyImmediately() pulumi.BoolOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolOutput { return v.ApplyImmediately }).(pulumi.BoolOutput)
}
// Amazon Resource Name (ARN) of cluster instance
func (o ClusterInstanceOutput) Arn() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput)
}
// Indicates that minor engine upgrades will be applied automatically to the DB instance during the maintenance window. Default `true`.
func (o ClusterInstanceOutput) AutoMinorVersionUpgrade() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolPtrOutput { return v.AutoMinorVersionUpgrade }).(pulumi.BoolPtrOutput)
}
// EC2 Availability Zone that the DB instance is created in. See [docs](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) about the details.
func (o ClusterInstanceOutput) AvailabilityZone() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.AvailabilityZone }).(pulumi.StringOutput)
}
// Identifier of the CA certificate for the DB instance.
func (o ClusterInstanceOutput) CaCertIdentifier() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.CaCertIdentifier }).(pulumi.StringOutput)
}
// Identifier of the `rds.Cluster` in which to launch this instance.
func (o ClusterInstanceOutput) ClusterIdentifier() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.ClusterIdentifier }).(pulumi.StringOutput)
}
// Indicates whether to copy all of the user-defined tags from the DB instance to snapshots of the DB instance. Default `false`.
func (o ClusterInstanceOutput) CopyTagsToSnapshot() pulumi.BoolPtrOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolPtrOutput { return v.CopyTagsToSnapshot }).(pulumi.BoolPtrOutput)
}
// Instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.
func (o ClusterInstanceOutput) CustomIamInstanceProfile() pulumi.StringPtrOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringPtrOutput { return v.CustomIamInstanceProfile }).(pulumi.StringPtrOutput)
}
// Name of the DB parameter group to associate with this instance.
func (o ClusterInstanceOutput) DbParameterGroupName() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.DbParameterGroupName }).(pulumi.StringOutput)
}
// DB subnet group to associate with this DB instance. **NOTE:** This must match the `dbSubnetGroupName` of the attached `rds.Cluster`.
func (o ClusterInstanceOutput) DbSubnetGroupName() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.DbSubnetGroupName }).(pulumi.StringOutput)
}
// Region-unique, immutable identifier for the DB instance.
func (o ClusterInstanceOutput) DbiResourceId() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.DbiResourceId }).(pulumi.StringOutput)
}
// DNS address for this instance. May not be writable
func (o ClusterInstanceOutput) Endpoint() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.Endpoint }).(pulumi.StringOutput)
}
// Name of the database engine to be used for the RDS cluster instance.
// Valid Values: `aurora-mysql`, `aurora-postgresql`, `mysql`, `postgres`.(Note that `mysql` and `postgres` are Multi-AZ RDS clusters).
func (o ClusterInstanceOutput) Engine() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.Engine }).(pulumi.StringOutput)
}
// Database engine version. Please note that to upgrade the `engineVersion` of the instance, it must be done on the `rds.Cluster` `engineVersion`. Trying to upgrade in `awsClusterInstance` will not update the `engineVersion`.
func (o ClusterInstanceOutput) EngineVersion() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.EngineVersion }).(pulumi.StringOutput)
}
// Database engine version
func (o ClusterInstanceOutput) EngineVersionActual() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.EngineVersionActual }).(pulumi.StringOutput)
}
// Identifier for the RDS instance, if omitted, Pulumi will assign a random, unique identifier.
func (o ClusterInstanceOutput) Identifier() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.Identifier }).(pulumi.StringOutput)
}
// Creates a unique identifier beginning with the specified prefix. Conflicts with `identifier`.
func (o ClusterInstanceOutput) IdentifierPrefix() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.IdentifierPrefix }).(pulumi.StringOutput)
}
// Instance class to use. For details on CPU and memory, see [Scaling Aurora DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Aurora.Managing.html). Aurora uses `db.*` instance classes/types. Please see [AWS Documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html) for currently available instance classes and complete details.
func (o ClusterInstanceOutput) InstanceClass() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.InstanceClass }).(pulumi.StringOutput)
}
// ARN for the KMS encryption key if one is set to the cluster.
func (o ClusterInstanceOutput) KmsKeyId() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.KmsKeyId }).(pulumi.StringOutput)
}
// Interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. Valid Values: 0, 1, 5, 10, 15, 30, 60.
func (o ClusterInstanceOutput) MonitoringInterval() pulumi.IntPtrOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.IntPtrOutput { return v.MonitoringInterval }).(pulumi.IntPtrOutput)
}
// ARN for the IAM role that permits RDS to send enhanced monitoring metrics to CloudWatch Logs. You can find more information on the [AWS Documentation](http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.html) what IAM permissions are needed to allow Enhanced Monitoring for RDS Instances.
func (o ClusterInstanceOutput) MonitoringRoleArn() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.MonitoringRoleArn }).(pulumi.StringOutput)
}
// Network type of the DB instance.
func (o ClusterInstanceOutput) NetworkType() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.NetworkType }).(pulumi.StringOutput)
}
// Specifies whether Performance Insights is enabled or not.
func (o ClusterInstanceOutput) PerformanceInsightsEnabled() pulumi.BoolOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolOutput { return v.PerformanceInsightsEnabled }).(pulumi.BoolOutput)
}
// ARN for the KMS key to encrypt Performance Insights data. When specifying `performanceInsightsKmsKeyId`, `performanceInsightsEnabled` needs to be set to true.
func (o ClusterInstanceOutput) PerformanceInsightsKmsKeyId() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.PerformanceInsightsKmsKeyId }).(pulumi.StringOutput)
}
// Amount of time in days to retain Performance Insights data. Valid values are `7`, `731` (2 years) or a multiple of `31`. When specifying `performanceInsightsRetentionPeriod`, `performanceInsightsEnabled` needs to be set to true. Defaults to '7'.
func (o ClusterInstanceOutput) PerformanceInsightsRetentionPeriod() pulumi.IntOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.IntOutput { return v.PerformanceInsightsRetentionPeriod }).(pulumi.IntOutput)
}
// Database port
func (o ClusterInstanceOutput) Port() pulumi.IntOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.IntOutput { return v.Port }).(pulumi.IntOutput)
}
// Daily time range during which automated backups are created if automated backups are enabled. Eg: "04:00-09:00". **NOTE:** If `preferredBackupWindow` is set at the cluster level, this argument **must** be omitted.
func (o ClusterInstanceOutput) PreferredBackupWindow() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.PreferredBackupWindow }).(pulumi.StringOutput)
}
// Window to perform maintenance in. Syntax: "ddd:hh24:mi-ddd:hh24:mi". Eg: "Mon:00:00-Mon:03:00".
func (o ClusterInstanceOutput) PreferredMaintenanceWindow() pulumi.StringOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringOutput { return v.PreferredMaintenanceWindow }).(pulumi.StringOutput)
}
// Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoted to writer.
func (o ClusterInstanceOutput) PromotionTier() pulumi.IntPtrOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.IntPtrOutput { return v.PromotionTier }).(pulumi.IntPtrOutput)
}
// Bool to control if instance is publicly accessible. Default `false`. See the documentation on [Creating DB Instances](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html) for more details on controlling this property.
func (o ClusterInstanceOutput) PubliclyAccessible() pulumi.BoolOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolOutput { return v.PubliclyAccessible }).(pulumi.BoolOutput)
}
// Specifies whether the DB cluster is encrypted.
func (o ClusterInstanceOutput) StorageEncrypted() pulumi.BoolOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolOutput { return v.StorageEncrypted }).(pulumi.BoolOutput)
}
// Map of tags to assign to the instance. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
func (o ClusterInstanceOutput) Tags() pulumi.StringMapOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput)
}
// Map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
//
// Deprecated: Please use `tags` instead.
func (o ClusterInstanceOutput) TagsAll() pulumi.StringMapOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput)
}
// Boolean indicating if this instance is writable. `False` indicates this instance is a read replica.
func (o ClusterInstanceOutput) Writer() pulumi.BoolOutput {
return o.ApplyT(func(v *ClusterInstance) pulumi.BoolOutput { return v.Writer }).(pulumi.BoolOutput)
}
type ClusterInstanceArrayOutput struct{ *pulumi.OutputState }
func (ClusterInstanceArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*ClusterInstance)(nil)).Elem()
}
func (o ClusterInstanceArrayOutput) ToClusterInstanceArrayOutput() ClusterInstanceArrayOutput {
return o
}
func (o ClusterInstanceArrayOutput) ToClusterInstanceArrayOutputWithContext(ctx context.Context) ClusterInstanceArrayOutput {
return o
}
func (o ClusterInstanceArrayOutput) Index(i pulumi.IntInput) ClusterInstanceOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *ClusterInstance {
return vs[0].([]*ClusterInstance)[vs[1].(int)]
}).(ClusterInstanceOutput)
}
type ClusterInstanceMapOutput struct{ *pulumi.OutputState }
func (ClusterInstanceMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*ClusterInstance)(nil)).Elem()
}
func (o ClusterInstanceMapOutput) ToClusterInstanceMapOutput() ClusterInstanceMapOutput {
return o
}
func (o ClusterInstanceMapOutput) ToClusterInstanceMapOutputWithContext(ctx context.Context) ClusterInstanceMapOutput {
return o
}
func (o ClusterInstanceMapOutput) MapIndex(k pulumi.StringInput) ClusterInstanceOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *ClusterInstance {
return vs[0].(map[string]*ClusterInstance)[vs[1].(string)]
}).(ClusterInstanceOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*ClusterInstanceInput)(nil)).Elem(), &ClusterInstance{})
pulumi.RegisterInputType(reflect.TypeOf((*ClusterInstanceArrayInput)(nil)).Elem(), ClusterInstanceArray{})
pulumi.RegisterInputType(reflect.TypeOf((*ClusterInstanceMapInput)(nil)).Elem(), ClusterInstanceMap{})
pulumi.RegisterOutputType(ClusterInstanceOutput{})
pulumi.RegisterOutputType(ClusterInstanceArrayOutput{})
pulumi.RegisterOutputType(ClusterInstanceMapOutput{})
}