-
Notifications
You must be signed in to change notification settings - Fork 619
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
engine: don't stop container when applied status is running #1446
Conversation
b03164f
to
2ba3355
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you manually reproduce this issue and verify this actually fix the issue?
@richardpen Yes, I used the following task definition and script: Task definition:
Test script:
The first time I run the above script with the unfixed Agent, I got similar logs that indicate there are redundant container changes from
And when I run
You can see there are two containers that are still running. But when I run the above script with the fixed Agent for multiple times, I cannot find any redundant container changes from Part of the logs:
You can see all the containers are stopped. |
@haikuoliu Great, can you resolve the conflicts? |
2ba3355
to
35dbaf4
Compare
@richardpen Conflicts are resolved now. |
35dbaf4
to
0325cce
Compare
Summary
This PR aims to fix this issue.
Implementation details
Do not mark container as stopped when its applied status is running.
Testing
make release
)go build -out amazon-ecs-agent.exe ./agent
)make test
) passgo test -timeout=25s ./agent/...
) passmake run-integ-tests
) pass.\scripts\run-integ-tests.ps1
) passmake run-functional-tests
) pass.\scripts\run-functional-tests.ps1
) passNew tests cover the changes: yes
Description for the changelog
Bug - Fixed a bug where container marked as stopped comes back with a running status
Licensing
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.