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:9723 google_sql_user - "Root resource was present, but now absent" #9848

Merged
merged 3 commits into from
Aug 19, 2021

Conversation

jangolano
Copy link
Contributor

No description provided.

Copy link
Contributor

@megan07 megan07 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this fix! Per the comment, we're going to need to GET the associated databaseInstance in order to check what version it is. Thanks!

google/resource_sql_user.go Show resolved Hide resolved
@@ -186,9 +186,15 @@ func resourceSqlUserRead(d *schema.ResourceData, meta interface{}) error {
}

var user *sqladmin.User
for _, currentUser := range users.Items {
databaseInstance, err := config.NewSqlAdminClient(userAgent).Instances.Get(project, instance).Do()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, great! Testing now and if it passes I'll approve and get this in. Thanks!

Copy link
Contributor

@megan07 megan07 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks so much!

@megan07 megan07 merged commit e02dbe2 into hashicorp:master Aug 19, 2021
@jangolano jangolano deleted the fix9723 branch August 19, 2021 18:48
@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants