Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(rds): trigger subsequent instance update operation for PITR case masterUserPassword #35589

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 7 additions & 2 deletions internal/service/rds/instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -642,8 +642,8 @@ func resourceInstanceCreate(ctx context.Context, d *schema.ResourceData, meta in
var diags diag.Diagnostics
conn := meta.(*conns.AWSClient).RDSConn(ctx)

// Some API calls (e.g. CreateDBInstanceReadReplica and
// RestoreDBInstanceFromDBSnapshot do not support all parameters to
// Some API calls (e.g. CreateDBInstanceReadReplica, RestoreDBInstanceFromDBSnapshot
// RestoreDBInstanceToPointInTime do not support all parameters to
// correctly apply all settings in one pass. For missing parameters or
// unsupported configurations, we may need to call ModifyDBInstance
// afterwards to prevent Terraform operators from API errors or needing
Expand Down Expand Up @@ -1348,6 +1348,11 @@ func resourceInstanceCreate(ctx context.Context, d *schema.ResourceData, meta in
requiresModifyDbInstance = true
}

if v, ok := d.GetOk("password"); ok {
modifyDbInstanceInput.MasterUserPassword = aws.String(v.(string))
requiresModifyDbInstance = true
}

if v, ok := d.GetOk("monitoring_interval"); ok {
modifyDbInstanceInput.MonitoringInterval = aws.Int64(int64(v.(int)))
requiresModifyDbInstance = true
Expand Down