Bug 1522988

Summary: Please expose generic objects to the services service model
Product: Red Hat CloudForms Management Engine Reporter: Kevin Morey <kmorey>
Component: AutomateAssignee: Lucy Fu <lufu>
Status: CLOSED CURRENTRELEASE QA Contact: Dave Johnson <dajohnso>
Severity: high Docs Contact:
Priority: high    
Version: 5.9.0CC: bascar, cpelland, jhardy, kmorey, mkanoor, obarenbo, tfitzger
Target Milestone: GAKeywords: FutureFeature, TestOnly
Target Release: 5.10.0   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: 5.10.0.0 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1524611 (view as bug list) Environment:
Last Closed: 2018-06-21 20:24:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1524611    

Description Kevin Morey 2017-12-06 22:01:32 UTC
Description of problem:
IN PR https://github.com/ManageIQ/manageiq/pull/15490 we are missing generic_objects association from services.

Version-Release number of selected component (if applicable):
5.0.9.11

Steps to Reproduce:
service = $evm.vmdb(:service).find_by_name('my-service')

service.associations
=> ["all_service_children", "direct_service_children", "direct_vms", "indirect_service_children", "indirect_vms", "parent_service", "root_service", "service_resources", "service_template", "tenant", "vms"]

The workaround is currently this:
service.service_resources.detect {|sr| sr.resource_type == "GenericObject"}.resource



Additional info:

Comment 2 Greg McCullough 2017-12-07 15:42:08 UTC
Changed from an RFE, this should be included in the release build.

Lucy - I believe we just need to expose the "generic_objects" association from the service model for Service.

Comment 4 CFME Bot 2017-12-07 16:40:29 UTC
New commit detected on ManageIQ/manageiq-automation_engine/master:
https://github.com/ManageIQ/manageiq-automation_engine/commit/2766f6b04abac52d51338f3fbc1aa32c8ef01f65

commit 2766f6b04abac52d51338f3fbc1aa32c8ef01f65
Author:     Lucy Fu <lufu>
AuthorDate: Thu Dec 7 11:02:26 2017 -0500
Commit:     Lucy Fu <lufu>
CommitDate: Thu Dec 7 11:02:26 2017 -0500

    Expose generic objects to the services service model.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1522988

 lib/miq_automation_engine/service_models/miq_ae_service_service.rb | 1 +
 1 file changed, 1 insertion(+)