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

Only run preprocess_targets_manager_refresh when doing graph refresh and add specs #18513

Merged

Conversation

agrare
Copy link
Member

@agrare agrare commented Mar 4, 2019

If we run preprocess_targets_manager_refresh on an EMS that isn't using graph refresh then we accidentally disable targeted refresh due to the ems.allow_targeted_refresh? check which was a setting that was never added to classic refresh.

Introduced by refactoring in #18312. This would have been a bug if we had turned off graph refresh for any provider inheriting from that class also, but now it used by everyone.

If we run preprocess_targets_manager_refresh on an EMS that isn't using
graph refresh then we accidentally disable targeted refresh due to the
ems.allow_targeted_refresh? check which was a setting that was never
added to classic refresh.
@miq-bot
Copy link
Member

miq-bot commented Mar 4, 2019

Checked commits agrare/manageiq@932fb53~...e8ee67a with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
2 files checked, 0 offenses detected
Everything looks fine. 🏆

if targets.any? { |t| t.kind_of?(ExtManagementSystem) }
targets_for_log = targets.map { |t| "#{t.class} [#{t.name}] id [#{t.id}] " }
_log.info("Defaulting to full refresh for EMS: [#{ems.name}], id: [#{ems.id}], from targets: #{targets_for_log}") if targets.length > 1
end
Copy link
Member Author

Choose a reason for hiding this comment

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

This logic is handled down here

_log.info("Defaulting to full refresh for EMS: [#{ems.name}], id: [#{ems.id}].") if targets.length > 1
so this isn't needed anymore

@gtanzillo gtanzillo added this to the Sprint 106 Ending Mar 4, 2019 milestone Mar 4, 2019
@gtanzillo gtanzillo merged commit 71524f8 into ManageIQ:master Mar 4, 2019
@agrare agrare deleted the fix_base_refresher_targeted_refresh branch March 4, 2019 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants