feat: add option to wait for ECS deployment success status#104
Draft
ToshihitoKon wants to merge 6 commits intomasterfrom
Draft
feat: add option to wait for ECS deployment success status#104ToshihitoKon wants to merge 6 commits intomasterfrom
ToshihitoKon wants to merge 6 commits intomasterfrom
Conversation
Add new method to wait for ECS service deployments to reach SUCCESSFUL status instead of just waiting for running_count to match desired_count. - Add wait_all_deployment_successful class method - Add deployment_successful? private helper method - Method waits for deployment status to be SUCCESSFUL and running_count to match desired_count 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Add new configuration option to control whether to wait for deployment success status or just running count matching desired count. - Add ecs_wait_for_deployment_success attribute - Default value is false to maintain backward compatibility 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Update deploy and rollback tasks to use new wait_all_deployment_successful method when ecs_wait_for_deployment_success is enabled. - Add ecs_wait_for_deployment_success configuration reading - Conditionally use wait_all_deployment_successful or wait_all_running - Apply to both deploy and rollback tasks - Maintain backward compatibility with default behavior 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Add comprehensive test cases for the new deployment_successful? private method to ensure correct behavior in various scenarios: - Single successful deployment with matching counts - Non-successful deployment status - Multiple deployments (should return false) - Mismatched running/desired counts 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
…ployments API Replace basic deployment status check with comprehensive ServiceDeployments API usage: - Use ListServiceDeployments to get latest deployment ARNs - Use DescribeServiceDeployments to monitor deployment status - Check for SUCCESSFUL/ROLLBACK_SUCCESSFUL status instead of just running_count - Handle deployment failure states (STOPPED, ROLLBACK_FAILED, STOP_REQUESTED) - Maintain parallel processing with Thread + each_slice pattern - Add proper error handling and logging for edge cases This provides more accurate deployment completion detection compared to just checking running_count == desired_count. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
wait_all_deployment_successfulmethod to wait for ECS service deployments to reach SUCCESSFUL statusecs_wait_for_deployment_successconfiguration option to control wait behaviorBackground
Currently,
wait_all_runningmethod considers deployment complete whenrunning_countmatchesdesired_count. However, this doesn't guarantee that the ECS service deployment has actually completed successfully. This PR adds an option to wait for the deployment status to become SUCCESSFUL instead.Changes
wait_all_deployment_successful- waits for deployment status to be SUCCESSFUL and running_count to match desired_countecs_wait_for_deployment_successoption (default: false for backward compatibility)Usage
🤖 Generated with Claude Code