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

[WIP]Reuse get_collector_names method for network facts gathering #58817

Open
wants to merge 1 commit into
base: devel
Choose a base branch
from

Conversation

@trishnaguha
Copy link
Member

@trishnaguha trishnaguha commented Jul 8, 2019

Signed-off-by: Trishna Guha trishnaguha17@gmail.com

SUMMARY

Reuse get_collector_names method for network facts gathering

COMPONENT NAME

module_utils/network/common/facts/facts.py

@trishnaguha trishnaguha requested a review from ganeshrn Jul 8, 2019
@ansibot
Copy link
Contributor

@ansibot ansibot commented Jul 8, 2019

Loading

restorun_subsets = self.gen_runable(resource_facts_type, frozenset(net_res_choices))
valid_subsets = net_res_choices
gather_subset = resource_facts_type
restorun_subsets = get_collector_names(valid_subsets, gather_subset=gather_subset)
Copy link
Member

@ganeshrn ganeshrn Jul 8, 2019

Choose a reason for hiding this comment

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

net_res_choices and resource_facts_type can be passed directly get_collector_names instead of seperately crearting those two varaible or instead net_res_choices can be renamed as valid_subsets and resource_facts_type to gather_subset

Loading

runable_subsets.add('default')
valid_subsets = frozenset(fact_legacy_obj_map.keys())
minimal_gather_subset = frozenset(['default'])
gather_subset = legacy_facts_type
Copy link
Member

@ganeshrn ganeshrn Jul 8, 2019

Choose a reason for hiding this comment

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

Same as above

Loading

@trishnaguha trishnaguha force-pushed the reuse_get_collector_names_method branch from e4cacd4 to 2b1448e Jul 8, 2019
Copy link
Member

@ganeshrn ganeshrn left a comment

Thank you!

Loading

@ansible-zuul
Copy link

@ansible-zuul ansible-zuul bot commented Jul 8, 2019

Build failed (third-party-check pipeline) integration testing with
Ansible.

Loading

Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
@trishnaguha trishnaguha force-pushed the reuse_get_collector_names_method branch from 2b1448e to 605f26f Jul 9, 2019
@ansible-zuul
Copy link

@ansible-zuul ansible-zuul bot commented Jul 9, 2019

Build failed (third-party-check pipeline) integration testing with
Ansible.

Loading

@@ -93,7 +48,8 @@ def get_network_resources_facts(self, net_res_choices, facts_resource_obj_map, r
if not resource_facts_type:
resource_facts_type = self._gather_network_resources

restorun_subsets = self.gen_runable(resource_facts_type, frozenset(net_res_choices))
restorun_subsets = get_collector_names(valid_subsets=net_res_choices,
Copy link
Member

@ganeshrn ganeshrn Jul 9, 2019

Choose a reason for hiding this comment

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

This should be frozenset(net_res_choices)

Loading

@trishnaguha trishnaguha changed the title Reuse get_collector_names method for network facts gathering [WIP]Reuse get_collector_names method for network facts gathering Jul 9, 2019
@ansibot ansibot added the WIP label Jul 9, 2019
@ansibot ansibot added pre_azp and removed stale_ci labels Dec 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants