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

Check for project deletion when refreshing/deleting project_service. #2090

Merged
merged 1 commit into from
Sep 26, 2018

Conversation

paddycarver
Copy link
Contributor

When reading or deleting the google_project_service resource, first
retrieve the project. If it's not found, or if it's pending deletion,
remove the service, as it's functionally disabled.

Also, add a test to confirm the behaviour.

This should resolve #1292.

When reading or deleting the google_project_service resource, first
retrieve the project. If it's not found, or if it's pending deletion,
remove the service, as it's functionally disabled.

Also, add a test to confirm the behaviour.

This should resolve #1292.
Copy link
Contributor

@chrisst chrisst left a comment

Choose a reason for hiding this comment

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

I tried to convince myself that removing it from the read was the right choice, and I had 1 scenario that I was curious about.

I created a project with an IAM service enabled. When I deleted a project, then decided to 'recover' it through the UI I noticed the IAM service was still enabled. When I re-imported the project terraform then tried to re-create the service. However to my surprise the call to create the service didn't fail. So I feel like that's an acceptable outcome for the user.

@paddycarver paddycarver merged commit a395142 into master Sep 26, 2018
@paultyng paultyng deleted the paddy_1292 branch October 29, 2018 19:27
@ghost
Copy link

ghost commented Nov 16, 2018

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Nov 16, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deleting activated services on a project fails
2 participants