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

Fixing service bundle resource linking #18250

Closed

Conversation

d-m-u
Copy link
Contributor

@d-m-u d-m-u commented Nov 29, 2018

This fixes an issue with the provisioning of bundled services that was introduced in https://github.com/ManageIQ/manageiq/pull/16799/files#diff-9257fff45a7d1258305c9a6b7d15e322R198, a pr which changed service_template.rb to use the block form of create. The issue with this is that when we get to the "add_resource" call the child service isn't saved yet and does not have an ID which causes the service resource to be saved with a resource_type but without a resource_id.

The second commit puts back the original direct_service_retirement call taken out here: https://github.com/ManageIQ/manageiq/pull/17881/files#diff-610ed908579256e82c76ec0910169142L10. The fact that things were being provisioned without the link in the first commit meant that the children of a bundle weren't being retired. This fixes that and adds an additional check to make sure that we're not doubly retiring anything.

This will in some form need to go back to Fine, though the call for the double service retirement was removed entirely from gaprindashvili.

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1653648

@d-m-u
Copy link
Contributor Author

d-m-u commented Nov 29, 2018

@miq-bot add_label bug
@miq-bot assign @gmcculloug
@miq-bot add_reviewer @tinaafitz

@miq-bot miq-bot added the bug label Nov 29, 2018
@miq-bot miq-bot requested a review from tinaafitz November 29, 2018 20:00
@d-m-u d-m-u force-pushed the fixing_service_bundle_resource_linking branch from 667091a to 4eefd80 Compare November 29, 2018 20:16
@d-m-u d-m-u force-pushed the fixing_service_bundle_resource_linking branch from 4eefd80 to e4cd2d7 Compare November 29, 2018 20:31
@miq-bot
Copy link
Member

miq-bot commented Nov 29, 2018

Checked commits d-m-u/manageiq@6e65b7d~...e4cd2d7 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
4 files checked, 0 offenses detected
Everything looks fine. 🏆

@d-m-u d-m-u closed this Nov 29, 2018
@d-m-u d-m-u deleted the fixing_service_bundle_resource_linking branch November 29, 2018 21:36
@d-m-u
Copy link
Contributor Author

d-m-u commented Nov 29, 2018

Closed in favor of #18251 and #18252

#18251 is relevant on all four branches, #18252 is only relevant on g.

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