-
Notifications
You must be signed in to change notification settings - Fork 45
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
Adding and Removing Services Causing Re-creation of all the resource #43
Comments
Hello @Sanyambansal76, thanks for reaching out. Please, could you provide the version you're using and steps to reproduce? What do you mean by "Re-creation of all the resource"? |
I experience similar inconsistencies and an exhaustive re-creation of resources if I change anything inside a service. For me, this leads to unnecessary downtimes of the application when I upgrade the fargate declaration. Maybe too many resources depend on something that is defined in a service, and thus it triggers recreation of those resources. |
For example: Adding an Plan: 22 to add, 1 to change, 21 to destroy.
------------------------------------------------------------------------ It event recreates the ECR repository, leading to the CodePipeline to fail, leading to new pushes being ignored, leading to a complete standstill. |
@jlsan92 Sorry I was on vacation for last few days, I think it is happening because the resource and their state are uniquely identified by the index, not by their name, so if we change something in the order, hash calculated again and resources mismatched with hash index values and lead to the re-creation of resources. Following are the use-cases when hash recalculated for index *We can add new rules only at the end of the hash. Terraform Version - 0.12.12 |
I had re-written the whole module for my use-case if you want i can send a PR request next week. |
@jlsan92 any update? |
@Sanyambansal76 could you share this code in your own fork online so we can all benefit? |
Hi,
Thanks for building this module, I am facing a similar issue described in the following link hashicorp/terraform#17179
I think we should modify the existing code to use
for_each
The text was updated successfully, but these errors were encountered: