Skip to content

feat: Add support for availability zone rebalancing (#262) #269

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

Merged
merged 2 commits into from
Mar 21, 2025

Conversation

kskmats
Copy link

@kskmats kskmats commented Mar 20, 2025

Description

This PR aims to add support for availability zone rebalancing in the services.
(This PR is a rework of the following pull request : #263)

References

Motivation and Context

Fixes : #262

Breaking Changes

How Has This Been Tested?

  • I have updated at least one of the examples/* to demonstrate and validate my change(s)
  • I have tested and validated these changes using one or more of the provided examples/* projects
  • I have executed pre-commit run -a on my pull request

main.tf Outdated
@@ -59,6 +59,7 @@ module "service" {
# Service
ignore_task_definition_changes = try(each.value.ignore_task_definition_changes, false)
alarms = try(each.value.alarms, {})
availability_zone_rebalancing = try(each.value.availability_zone_rebalancing, "DISABLED")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
availability_zone_rebalancing = try(each.value.availability_zone_rebalancing, "DISABLED")
availability_zone_rebalancing = try(each.value.availability_zone_rebalancing, null)

Copy link
Author

Choose a reason for hiding this comment

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

OK, I'll fix.

@@ -39,7 +39,7 @@ variable "alarms" {
variable "availability_zone_rebalancing" {
description = " ECS automatically redistributes tasks within a service across Availability Zones (AZs) to mitigate the risk of impaired application availability due to underlying infrastructure failures and task lifecycle activities. The valid values are `ENABLED` and `DISABLED`. Defaults to `DISABLED`"
type = string
default = null
default = "DISABLED"
Copy link
Member

Choose a reason for hiding this comment

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

revert, should be null

Copy link
Author

Choose a reason for hiding this comment

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

OK

@@ -28,7 +28,7 @@ module "wrapper" {
}
})
autoscaling_scheduled_actions = try(each.value.autoscaling_scheduled_actions, var.defaults.autoscaling_scheduled_actions, null)
availability_zone_rebalancing = try(each.value.availability_zone_rebalancing, var.defaults.availability_zone_rebalancing, null)
availability_zone_rebalancing = try(each.value.availability_zone_rebalancing, var.defaults.availability_zone_rebalancing, "DISABLED")
Copy link
Member

Choose a reason for hiding this comment

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

revert

Copy link
Author

Choose a reason for hiding this comment

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

OK

@kskmats
Copy link
Author

kskmats commented Mar 21, 2025

@bryantbiggs
thank you for your review.
I reverted default value of availability zone rebalancing.

@bryantbiggs bryantbiggs merged commit 48c7150 into terraform-aws-modules:wip/v6 Mar 21, 2025
2 checks passed
bryantbiggs pushed a commit that referenced this pull request Apr 1, 2025
* feat: Add support for availability zone rebalancing (#262)

* revert default value of availability zone rebalancing
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 Apr 21, 2025
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