terraform-provider-ec
terraform-provider-ec copied to clipboard
Removing the Coordinator Node from ec_deployment resource does not award back the ingest node role to hot nodes if zone count is not set to zero.
13:35 $ terraform --version
Terraform v1.3.9
+ provider registry.terraform.io/elastic/ec v0.8.0
+ provider registry.terraform.io/elastic/elasticstack v0.7.0
- If I remove the coordinating node (or set it to
0g
) from the Terraform Configuration like so, the Ingest role does not get applied back to the Hot nodes. - If I do this through the Elastic Cloud UI, it does.
I just realized I still have the zone count at 2, so i'll set that to zero first and report back if it's still an issue.
Readiness Checklist
- [X] I am running the latest version (providers, yes. Terraform one version back for other reasons)
- [X] I checked the documentation and found no answer
- [X] I checked to make sure that this issue has not already been filed
- [X] I am reporting the issue to the correct repository (for multi-repository projects)
Expected Behavior
When removing the coordinating node, the Ingest node role should be applied back to the hot nodes.
Current Behavior
When removing the coordinating node, the Ingest node role is not applied
## Terraform definition
coordinating = {
autoscaling = {}
size = "0g"
size_resource = "memory"
zone_count = 2
}
Steps to Reproduce
- See Above
Context
I need to currently use the UI to remove a coordinating node.
Possible Solution
When removing the coordinating nodes, make sure the ingest node.role is applied back to the hot nodes.
Your Environment
- Version used: See above. (Elastic Cloud 8.6.0)
- Running against Elastic Cloud SaaS or Elastic Cloud Enterprise and version: Elastic Cloud
- Environment name and version (e.g. Go 1.9):
- Server type and version:
- Operating System and version:
- Link to your project:
Note: If I put the zone count at zero, the plan applies and the ingest node role gets awarded back to the hot node. However, I go through a fail cycle of this which I know is in other tickets. Additionally, I had to do one Deployment Restart in the Elastic Console UI for this to take effect.
╷
│ Error: Provider produced inconsistent result after apply
│
│ When applying changes to module.customer_env.module.elastic.ec_deployment.customer, provider
│ "provider[\"registry.terraform.io/elastic/ec\"]" produced an unexpected new value:
│ .elasticsearch.coordinating.zone_count: was cty.NumberIntVal(0), but now cty.NumberIntVal(2).
│
│ This is a bug in the provider, which should be reported in the provider's own issue tracker.
╵
When I put the zone count to 1, then the plan applies fine.
I'm happy to have this ticket closed if it's expected behavior - but leaving open in case this is net new.