Skip to content
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

ec2_ami - allow ImageAvailable waiter to retry when the image can't be found #1321

Conversation

tremble
Copy link
Contributor

@tremble tremble commented Jan 5, 2023

SUMMARY

When using the image_available waiter shortly after triggering the creation of an AMI this can fail (Amazon sometimes return from creation calls, with an ID, before the APIs recognise that the resource exists)

Additionally splits up the AMI tests, it's sporadically timing out. (taking a snapshot of a running instance is slow)

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

ec2_ami

ADDITIONAL INFORMATION

https://e7359f847acd480e3075-df27b72133198827a14e5ee13616eeff.ssl.cf1.rackcdn.com/periodic/github.com/ansible-collections/amazon.aws/main/integration-amazon.aws-target-ec2_ami/adb87fd/job-output.txt

@ansibullbot
Copy link

@ansibullbot ansibullbot added bug This issue/PR relates to a bug community_review integration tests/integration module_utils module_utils needs_triage plugins plugin (any type) tests tests labels Jan 5, 2023
@tremble tremble marked this pull request as ready for review January 5, 2023 16:45
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded.

✔️ ansible-galaxy-importer SUCCESS in 4m 09s
✔️ build-ansible-collection SUCCESS in 5m 07s
✔️ ansible-test-sanity-aws-ansible-python38 SUCCESS in 8m 46s (non-voting)
✔️ ansible-test-sanity-aws-ansible-2.12-python38 SUCCESS in 9m 22s
✔️ ansible-test-sanity-aws-ansible-2.13-python38 SUCCESS in 9m 41s
✔️ ansible-test-sanity-aws-ansible-2.14 SUCCESS in 10m 08s
✔️ ansible-test-units-amazon-aws-python36 SUCCESS in 9m 04s
✔️ ansible-test-units-amazon-aws-python38 SUCCESS in 9m 32s
✔️ ansible-test-units-amazon-aws-python39 SUCCESS in 9m 37s
✔️ ansible-test-units-amazon-aws-python310 SUCCESS in 11m 31s
✔️ cloud-tox-py3 SUCCESS in 4m 58s
✔️ ansible-test-changelog SUCCESS in 2m 11s
✔️ ansible-test-splitter SUCCESS in 2m 57s
✔️ integration-amazon.aws-1 SUCCESS in 11m 18s
✔️ integration-amazon.aws-2 SUCCESS in 59m 46s
✔️ integration-amazon.aws-3 SUCCESS in 36m 12s
✔️ integration-amazon.aws-4 SUCCESS in 31m 02s
✔️ integration-amazon.aws-5 SUCCESS in 11m 56s
⚠️ integration-amazon.aws-6 SKIPPED
⚠️ integration-amazon.aws-7 SKIPPED
⚠️ integration-amazon.aws-8 SKIPPED
⚠️ integration-amazon.aws-9 SKIPPED
⚠️ integration-amazon.aws-10 SKIPPED
⚠️ integration-amazon.aws-11 SKIPPED
⚠️ integration-amazon.aws-12 SKIPPED
⚠️ integration-amazon.aws-13 SKIPPED
⚠️ integration-amazon.aws-14 SKIPPED
⚠️ integration-amazon.aws-15 SKIPPED
⚠️ integration-amazon.aws-16 SKIPPED
⚠️ integration-amazon.aws-17 SKIPPED
⚠️ integration-amazon.aws-18 SKIPPED
⚠️ integration-amazon.aws-19 SKIPPED
⚠️ integration-amazon.aws-20 SKIPPED
⚠️ integration-amazon.aws-21 SKIPPED
⚠️ integration-amazon.aws-22 SKIPPED
✔️ integration-community.aws-1 SUCCESS in 29m 51s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED
⚠️ integration-community.aws-14 SKIPPED
⚠️ integration-community.aws-15 SKIPPED
⚠️ integration-community.aws-16 SKIPPED
⚠️ integration-community.aws-17 SKIPPED
⚠️ integration-community.aws-18 SKIPPED
⚠️ integration-community.aws-19 SKIPPED
⚠️ integration-community.aws-20 SKIPPED
⚠️ integration-community.aws-21 SKIPPED
⚠️ integration-community.aws-22 SKIPPED

@tremble tremble added backport-4 PR should be backported to the stable-4 branch backport-5 PR should be backported to the stable-5 branch labels Jan 9, 2023
@tremble tremble added the mergeit Merge the PR (SoftwareFactory) label Jan 9, 2023
@softwarefactory-project-zuul
Copy link
Contributor

Build succeeded (gate pipeline).

✔️ ansible-galaxy-importer SUCCESS in 4m 11s
✔️ build-ansible-collection SUCCESS in 5m 54s
✔️ ansible-test-splitter SUCCESS in 2m 58s
✔️ integration-amazon.aws-1 SUCCESS in 15m 01s
✔️ integration-amazon.aws-2 SUCCESS in 40m 36s
✔️ integration-amazon.aws-3 SUCCESS in 40m 38s
✔️ integration-amazon.aws-4 SUCCESS in 25m 20s
✔️ integration-amazon.aws-5 SUCCESS in 33m 48s
✔️ integration-amazon.aws-6 SUCCESS in 32m 17s
✔️ integration-amazon.aws-7 SUCCESS in 34m 01s
⚠️ integration-amazon.aws-8 SKIPPED
⚠️ integration-amazon.aws-9 SKIPPED
⚠️ integration-amazon.aws-10 SKIPPED
⚠️ integration-amazon.aws-11 SKIPPED
⚠️ integration-amazon.aws-12 SKIPPED
⚠️ integration-amazon.aws-13 SKIPPED
⚠️ integration-amazon.aws-14 SKIPPED
⚠️ integration-amazon.aws-15 SKIPPED
⚠️ integration-amazon.aws-16 SKIPPED
⚠️ integration-amazon.aws-17 SKIPPED
⚠️ integration-amazon.aws-18 SKIPPED
⚠️ integration-amazon.aws-19 SKIPPED
⚠️ integration-amazon.aws-20 SKIPPED
⚠️ integration-amazon.aws-21 SKIPPED
⚠️ integration-amazon.aws-22 SKIPPED
✔️ integration-community.aws-1 SUCCESS in 33m 54s
⚠️ integration-community.aws-2 SKIPPED
⚠️ integration-community.aws-3 SKIPPED
⚠️ integration-community.aws-4 SKIPPED
⚠️ integration-community.aws-5 SKIPPED
⚠️ integration-community.aws-6 SKIPPED
⚠️ integration-community.aws-7 SKIPPED
⚠️ integration-community.aws-8 SKIPPED
⚠️ integration-community.aws-9 SKIPPED
⚠️ integration-community.aws-10 SKIPPED
⚠️ integration-community.aws-11 SKIPPED
⚠️ integration-community.aws-12 SKIPPED
⚠️ integration-community.aws-13 SKIPPED
⚠️ integration-community.aws-14 SKIPPED
⚠️ integration-community.aws-15 SKIPPED
⚠️ integration-community.aws-16 SKIPPED
⚠️ integration-community.aws-17 SKIPPED
⚠️ integration-community.aws-18 SKIPPED
⚠️ integration-community.aws-19 SKIPPED
⚠️ integration-community.aws-20 SKIPPED
⚠️ integration-community.aws-21 SKIPPED
⚠️ integration-community.aws-22 SKIPPED

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit 6da1aaa into ansible-collections:main Jan 9, 2023
@patchback
Copy link

patchback bot commented Jan 9, 2023

Backport to stable-4: 💔 cherry-picking failed — conflicts found

❌ Failed to cleanly apply 6da1aaa on top of patchback/backports/stable-4/6da1aaa700e1c6f4b2b8c5e0f1af19394c536301/pr-1321

Backporting merged PR #1321 into main

  1. Ensure you have a local repo clone of your fork. Unless you cloned it
    from the upstream, this would be your origin remote.
  2. Make sure you have an upstream repo added as a remote too. In these
    instructions you'll refer to it by the name upstream. If you don't
    have it, here's how you can add it:
    $ git remote add upstream https://github.com/ansible-collections/amazon.aws.git
  3. Ensure you have the latest copy of upstream and prepare a branch
    that will hold the backported code:
    $ git fetch upstream
    $ git checkout -b patchback/backports/stable-4/6da1aaa700e1c6f4b2b8c5e0f1af19394c536301/pr-1321 upstream/stable-4
  4. Now, cherry-pick PR ec2_ami - allow ImageAvailable waiter to retry when the image can't be found #1321 contents into that branch:
    $ git cherry-pick -x 6da1aaa700e1c6f4b2b8c5e0f1af19394c536301
    If it'll yell at you with something like fatal: Commit 6da1aaa700e1c6f4b2b8c5e0f1af19394c536301 is a merge but no -m option was given., add -m 1 as follows intead:
    $ git cherry-pick -m1 -x 6da1aaa700e1c6f4b2b8c5e0f1af19394c536301
  5. At this point, you'll probably encounter some merge conflicts. You must
    resolve them in to preserve the patch from PR ec2_ami - allow ImageAvailable waiter to retry when the image can't be found #1321 as close to the
    original as possible.
  6. Push this branch to your fork on GitHub:
    $ git push origin patchback/backports/stable-4/6da1aaa700e1c6f4b2b8c5e0f1af19394c536301/pr-1321
  7. Create a PR, ensure that the CI is green. If it's not — update it so that
    the tests and any other checks pass. This is it!
    Now relax and wait for the maintainers to process your pull request
    when they have some cycles to do reviews. Don't worry — they'll tell you if
    any improvements are necessary when the time comes!

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

@patchback
Copy link

patchback bot commented Jan 9, 2023

Backport to stable-5: 💔 cherry-picking failed — conflicts found

❌ Failed to cleanly apply 6da1aaa on top of patchback/backports/stable-5/6da1aaa700e1c6f4b2b8c5e0f1af19394c536301/pr-1321

Backporting merged PR #1321 into main

  1. Ensure you have a local repo clone of your fork. Unless you cloned it
    from the upstream, this would be your origin remote.
  2. Make sure you have an upstream repo added as a remote too. In these
    instructions you'll refer to it by the name upstream. If you don't
    have it, here's how you can add it:
    $ git remote add upstream https://github.com/ansible-collections/amazon.aws.git
  3. Ensure you have the latest copy of upstream and prepare a branch
    that will hold the backported code:
    $ git fetch upstream
    $ git checkout -b patchback/backports/stable-5/6da1aaa700e1c6f4b2b8c5e0f1af19394c536301/pr-1321 upstream/stable-5
  4. Now, cherry-pick PR ec2_ami - allow ImageAvailable waiter to retry when the image can't be found #1321 contents into that branch:
    $ git cherry-pick -x 6da1aaa700e1c6f4b2b8c5e0f1af19394c536301
    If it'll yell at you with something like fatal: Commit 6da1aaa700e1c6f4b2b8c5e0f1af19394c536301 is a merge but no -m option was given., add -m 1 as follows intead:
    $ git cherry-pick -m1 -x 6da1aaa700e1c6f4b2b8c5e0f1af19394c536301
  5. At this point, you'll probably encounter some merge conflicts. You must
    resolve them in to preserve the patch from PR ec2_ami - allow ImageAvailable waiter to retry when the image can't be found #1321 as close to the
    original as possible.
  6. Push this branch to your fork on GitHub:
    $ git push origin patchback/backports/stable-5/6da1aaa700e1c6f4b2b8c5e0f1af19394c536301/pr-1321
  7. Create a PR, ensure that the CI is green. If it's not — update it so that
    the tests and any other checks pass. This is it!
    Now relax and wait for the maintainers to process your pull request
    when they have some cycles to do reviews. Don't worry — they'll tell you if
    any improvements are necessary when the time comes!

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

@github-actions
Copy link

github-actions bot commented Jan 9, 2023

Docs Build 📝

Thank you for contribution!✨

This PR has been merged and your docs changes will be incorporated when they are next published.

softwarefactory-project-zuul bot pushed a commit that referenced this pull request Jan 9, 2023
Bulk update imports after reshuffle

Depends-On: #1323
Depends-On: #1322
Depends-On: #1321
SUMMARY
module_utils code got split up.  Bulk update the imports to reflect this
ISSUE TYPE

Feature Pull Request

COMPONENT NAME
various
ADDITIONAL INFORMATION

Reviewed-by: Alina Buzachis <None>
@tremble tremble deleted the tests/stability/ec2_ami branch February 15, 2023 09:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-4 PR should be backported to the stable-4 branch backport-5 PR should be backported to the stable-5 branch bug This issue/PR relates to a bug community_review integration tests/integration mergeit Merge the PR (SoftwareFactory) module_utils module_utils needs_triage plugins plugin (any type) tests tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants