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

Refactor ec2_transit_gateway_* modules #2158

Conversation

mandar242
Copy link
Contributor

@mandar242 mandar242 commented Sep 25, 2024

SUMMARY

Refactor ec2_transit_gateway and ec2_transit_gateway_info modules

common code moved to module_utils ansible-collections/amazon.aws#2325

ISSUE TYPE
  • Bugfix Pull Request
  • Docs Pull Request
  • Feature Pull Request
  • New Module Pull Request
COMPONENT NAME

ec2_transit_gateway
ec2_transit_gateway_info

ADDITIONAL INFORMATION

Copy link

github-actions bot commented Sep 25, 2024

Docs Build 📝

Thank you for contribution!✨

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

This comment was marked as outdated.

@mandar242 mandar242 changed the title Refactor ec2_transit_gateway_info module Refactor ec2_transit_gateway_* modules Sep 27, 2024

This comment was marked as outdated.

This comment was marked as outdated.

Copy link
Collaborator

@GomathiselviS GomathiselviS left a comment

Choose a reason for hiding this comment

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

The imports should be from amazon.aws. This module may require further refactoring to align with the format we use in the a.aws module plugins—please use the shared code from a.aws/module_utils/ec2 wherever possible.

@mandar242
Copy link
Contributor Author

mandar242 commented Oct 2, 2024

The imports should be from amazon.aws. This module may require further refactoring to align with the format we use in the a.aws module plugins—please use the shared code from a.aws/module_utils/ec2 wherever possible.

Hi @GomathiselviS could you please provide more details on what changes should be done, I am not sure.

The imports should be from amazon.aws

Will be updating imports in migration PR, for refactoring c.aws seems fine.

@GomathiselviS
Copy link
Collaborator

The imports should be from amazon.aws. This module may require further refactoring to align with the format we use in the a.aws module plugins—please use the shared code from a.aws/module_utils/ec2 wherever possible.

Hi @GomathiselviS could you please provide more details on what changes should be done, I am not sure.

The imports should be from amazon.aws

Will be updating imports in migration PR, for refactoring c.aws seems fine.

You can refer to one of the closed refactoring PRs from @abikouo or @alinabuzachis (https://github.com/ansible-collections/community.aws/pull/2152/files)

This comment was marked as outdated.

@mandar242
Copy link
Contributor Author

recheck

This comment was marked as outdated.

@mandar242
Copy link
Contributor Author

recheck

This comment was marked as outdated.

@mandar242
Copy link
Contributor Author

recheck

This comment was marked as outdated.

Copy link
Contributor

@alinabuzachis alinabuzachis left a comment

Choose a reason for hiding this comment

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

Can you please follow the pattern for refactoring we have adopted in the other PRs (see for example #2152 and ansible-collections/amazon.aws#2302)? We would like to maintain consistency.

This comment was marked as outdated.

This comment was marked as outdated.

This comment was marked as outdated.

plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway_info.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway_info.py Outdated Show resolved Hide resolved
@mandar242 mandar242 force-pushed the refactor_ec2_transit_gateway_info branch from 3786cc5 to 7012f35 Compare October 10, 2024 18:07
Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/7d52555c956245af931ad4a63cea3d11

ansible-galaxy-importer FAILURE in 4m 43s (non-voting)
✔️ build-ansible-collection SUCCESS in 12m 17s
✔️ ansible-test-splitter SUCCESS in 4m 44s
integration-community.aws-1 FAILURE in 4m 41s
integration-community.aws-2 FAILURE in 5m 55s
integration-community.aws-3 FAILURE in 9m 42s
Skipped 19 jobs

Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/fde184ee7e5b442d97fc9c1601884f3f

ansible-galaxy-importer FAILURE in 4m 23s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 35s
✔️ ansible-test-splitter SUCCESS in 4m 22s
integration-community.aws-1 FAILURE in 7m 10s
integration-community.aws-2 FAILURE in 5m 31s
integration-community.aws-3 FAILURE in 8m 42s
Skipped 19 jobs

@mandar242 mandar242 force-pushed the refactor_ec2_transit_gateway_info branch from 80dd53c to 27275f4 Compare October 16, 2024 01:19
@alinabuzachis
Copy link
Contributor

recheck

Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/db1b29d7ba2b40ee98a2a0e2da9bcbb4

ansible-galaxy-importer FAILURE in 5m 22s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 53s
✔️ ansible-test-splitter SUCCESS in 4m 40s
✔️ integration-community.aws-1 SUCCESS in 29m 28s
✔️ integration-community.aws-2 SUCCESS in 26m 39s
integration-community.aws-3 FAILURE in 29m 00s
✔️ integration-community.aws-4 SUCCESS in 15m 52s
✔️ integration-community.aws-5 SUCCESS in 9m 10s
✔️ integration-community.aws-6 SUCCESS in 8m 17s
✔️ integration-community.aws-7 SUCCESS in 6m 36s
✔️ integration-community.aws-8 SUCCESS in 13m 02s
✔️ integration-community.aws-9 SUCCESS in 23m 12s
✔️ integration-community.aws-10 SUCCESS in 11m 52s
Skipped 12 jobs

Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/2b72a04519434c2ba7183698144482d0

ansible-galaxy-importer FAILURE in 4m 02s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 37s
✔️ ansible-test-splitter SUCCESS in 4m 23s
integration-community.aws-1 TIMED_OUT in 1h 00m 21s
✔️ integration-community.aws-2 SUCCESS in 24m 42s
✔️ integration-community.aws-3 SUCCESS in 34m 11s
✔️ integration-community.aws-4 SUCCESS in 15m 57s
✔️ integration-community.aws-5 SUCCESS in 6m 59s
✔️ integration-community.aws-6 SUCCESS in 9m 48s
✔️ integration-community.aws-7 SUCCESS in 7m 49s
✔️ integration-community.aws-8 SUCCESS in 14m 05s
✔️ integration-community.aws-9 SUCCESS in 23m 01s
integration-community.aws-10 FAILURE in 15m 48s
Skipped 12 jobs

softwarefactory-project-zuul bot pushed a commit to ansible-collections/amazon.aws that referenced this pull request Oct 23, 2024
SUMMARY

Added api calls used by ec2_transit_gateway and ec2_transit_gateway_info to ec2 module_utils

Required for ansible-collections/community.aws#2158
ISSUE TYPE


Feature Pull Request

COMPONENT NAME

module_utils/ec2
ADDITIONAL INFORMATION

Reviewed-by: Alina Buzachis
Reviewed-by: Bikouo Aubin
Reviewed-by: GomathiselviS <[email protected]>
@alinabuzachis
Copy link
Contributor

recheck

Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/f3f4a4a4a6b049938a94e8e36da17f8d

ansible-galaxy-importer FAILURE in 5m 04s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 46s
✔️ ansible-test-splitter SUCCESS in 3m 59s
integration-community.aws-1 FAILURE in 22m 02s
✔️ integration-community.aws-2 SUCCESS in 10m 12s
Skipped 20 jobs

@alinabuzachis
Copy link
Contributor

recheck

Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/d897d0b3f75c416999f638ade3deae14

ansible-galaxy-importer FAILURE in 4m 55s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 25s
ansible-test-splitter FAILURE in 3m 39s
⚠️ integration-community.aws-1 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-2 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-3 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-4 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-5 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-6 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-7 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-8 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-9 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-10 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-11 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-12 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-13 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-14 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-15 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-16 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-17 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-18 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-19 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-20 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-21 SKIPPED Skipped due to failed job ansible-test-splitter
⚠️ integration-community.aws-22 SKIPPED Skipped due to failed job ansible-test-splitter

@alinabuzachis
Copy link
Contributor

recheck

Copy link
Contributor

Build failed.
https://ansible.softwarefactory-project.io/zuul/buildset/06b2e172cf404ec989fd44ef9228d60d

⚠️ ansible-galaxy-importer SKIPPED Skipped due to failed job build-ansible-collection (non-voting)
build-ansible-collection POST_FAILURE in 10m 03s
✔️ ansible-test-splitter SUCCESS in 4m 31s
⚠️ integration-community.aws-1 SKIPPED Skipped due to failed job build-ansible-collection
⚠️ integration-community.aws-2 SKIPPED Skipped due to failed job build-ansible-collection
Skipped 20 jobs

@alinabuzachis
Copy link
Contributor

recheck

Copy link
Collaborator

@GomathiselviS GomathiselviS left a comment

Choose a reason for hiding this comment

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

LGTM ! Suggested few changes.

plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
plugins/modules/ec2_transit_gateway.py Outdated Show resolved Hide resolved
Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/af0d76ce64714d66b064e0d4437a9fe3

ansible-galaxy-importer FAILURE in 4m 32s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 58s
✔️ ansible-test-splitter SUCCESS in 4m 00s
✔️ integration-community.aws-1 SUCCESS in 28m 07s
✔️ integration-community.aws-2 SUCCESS in 10m 42s
Skipped 20 jobs

@alinabuzachis alinabuzachis added the mergeit Merge the PR (SoftwareFactory) label Oct 23, 2024
@GomathiselviS GomathiselviS added mergeit Merge the PR (SoftwareFactory) and removed mergeit Merge the PR (SoftwareFactory) labels Oct 23, 2024
@mandar242 mandar242 dismissed abikouo’s stale review October 23, 2024 16:49

comments addressed

Copy link
Contributor

Build succeeded.
https://ansible.softwarefactory-project.io/zuul/buildset/1f160ccf74ea4694882d33f578917fc8

ansible-galaxy-importer FAILURE in 5m 11s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 39s
✔️ ansible-test-splitter SUCCESS in 4m 06s
✔️ integration-community.aws-1 SUCCESS in 25m 14s
✔️ integration-community.aws-2 SUCCESS in 11m 33s
Skipped 20 jobs

Copy link
Contributor

Build succeeded (gate pipeline).
https://ansible.softwarefactory-project.io/zuul/buildset/51e9f622e23240dead38b4a8766aa564

ansible-galaxy-importer FAILURE in 4m 42s (non-voting)
✔️ build-ansible-collection SUCCESS in 10m 36s
✔️ ansible-test-splitter SUCCESS in 4m 06s
✔️ integration-community.aws-1 SUCCESS in 24m 11s
✔️ integration-community.aws-2 SUCCESS in 13m 20s
Skipped 20 jobs

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit fc782d2 into ansible-collections:main Oct 23, 2024
66 of 96 checks passed
@mandar242 mandar242 deleted the refactor_ec2_transit_gateway_info branch October 23, 2024 19:17
@mandar242 mandar242 restored the refactor_ec2_transit_gateway_info branch October 23, 2024 19:17
alinabuzachis pushed a commit to abikouo/community.aws that referenced this pull request Oct 24, 2024
SUMMARY

Refactor ec2_transit_gateway and ec2_transit_gateway_info modules

common code moved to module_utils ansible-collections/amazon.aws#2325
ISSUE TYPE


Bugfix Pull Request
Docs Pull Request
Feature Pull Request
New Module Pull Request

COMPONENT NAME
 
ec2_transit_gateway
ec2_transit_gateway_info
ADDITIONAL INFORMATION

Reviewed-by: GomathiselviS <[email protected]>
Reviewed-by: Alina Buzachis
Reviewed-by: Mandar Kulkarni <[email protected]>
Reviewed-by: Bikouo Aubin
alinabuzachis pushed a commit to mandar242/community.aws that referenced this pull request Oct 25, 2024
SUMMARY

Refactor ec2_transit_gateway and ec2_transit_gateway_info modules

common code moved to module_utils ansible-collections/amazon.aws#2325
ISSUE TYPE


Bugfix Pull Request
Docs Pull Request
Feature Pull Request
New Module Pull Request

COMPONENT NAME
 
ec2_transit_gateway
ec2_transit_gateway_info
ADDITIONAL INFORMATION

Reviewed-by: GomathiselviS <[email protected]>
Reviewed-by: Alina Buzachis
Reviewed-by: Mandar Kulkarni <[email protected]>
Reviewed-by: Bikouo Aubin
alinabuzachis pushed a commit to GomathiselviS/community.aws that referenced this pull request Oct 25, 2024
SUMMARY

Refactor ec2_transit_gateway and ec2_transit_gateway_info modules

common code moved to module_utils ansible-collections/amazon.aws#2325
ISSUE TYPE


Bugfix Pull Request
Docs Pull Request
Feature Pull Request
New Module Pull Request

COMPONENT NAME
 
ec2_transit_gateway
ec2_transit_gateway_info
ADDITIONAL INFORMATION

Reviewed-by: GomathiselviS <[email protected]>
Reviewed-by: Alina Buzachis
Reviewed-by: Mandar Kulkarni <[email protected]>
Reviewed-by: Bikouo Aubin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mergeit Merge the PR (SoftwareFactory)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants