Bug 1653648 - Catalog bundle resources not retiring
Summary: Catalog bundle resources not retiring
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Automate
Version: 5.9.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: GA
: 5.10.0
Assignee: Tina Fitzgerald
QA Contact: Niyaz Akhtar Ansari
Red Hat CloudForms Documentation
Depends On:
Blocks: 1655081 1660601
TreeView+ depends on / blocked
Reported: 2018-11-27 10:54 UTC by Gellert Kis
Modified: 2019-02-26 06:57 UTC (History)
14 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1655081 1660601 (view as bug list)
Last Closed: 2019-02-12 16:53:14 UTC
Category: Bug
Cloudforms Team: CFME Core
Target Upstream Version:

Attachments (Terms of Use)

Comment 5 Tina Fitzgerald 2018-11-27 19:16:48 UTC
Hi Yoder,

We've been looking at the Services on the reproducer appliance, and we know why retirement is not retiring the sub service.  

The top level service(Service bundle) has a service_resource for the sub service. The sub service, service_resource is supposed to have a resource for the service, and it doesn't on this specific version. 

We're in the process of figuring out why the service_resource,resource doesn't exist.  

I'll have an update later today.


Comment 6 Tina Fitzgerald 2018-11-27 22:30:06 UTC
Hi Yoder,

As we discussed, can you ask the customer if they would be willing to try a one line code change? They would have to restart the appliance and turn off the Automate role on the other appliances.

The code change is here:

To test the code change: 
1. Navigate to the vmdb/app/models/service folder.
2. Copy the retirement_management.rb to retirement_management.rb.original
   (cp -p retirement_management.rb retirement_management.rb.orig)
3. Edit retirement_management.rb, adding this line:
immediately after this line: def retire_service_resources
4. restart the appliance
5. Retire Service Bundle

Let me know if you have any questions.


Comment 9 Tina Fitzgerald 2018-11-28 18:43:11 UTC
Hi Gellert,

1. Can you ask the customer for the entry point of the Service Bundle and of each service item?

I see this in the new automation.log
retirement_entrypoint: /Cloud/Orchestration/Retirement/StateMachines/StackRetirement/Default
This should be a service entry point.

The customer stated: "But on the other hand, I've created a catalog bundle that contains only the azure orchestration catalog item (this is temporally, the intention is to also add ansible towers items). It creates the service correctly, but the problem is when I try to retire it, the service is successfully retired, but resources created with the azure orchestration aren't deleted."

2. Did the customer try to retire the Service Bundle as described above? If not, can you ask them to retire it? (With a single item) 

3. Does the Service show as retired?

4. It looks like custom code is in use in retirement. Can the customer disable the custom domains before retiring the service?

Let me know if you have any questions.


Comment 13 Tina Fitzgerald 2018-11-29 20:31:40 UTC
Hi Gellert,

I'm glad to hear the customer was able to successfully retire the Service.
Although the problem shows up in retirement, the root cause is a provision issue which we've identified and for which we are currently testing a fix.

I'll send an update once we have more information.


Comment 15 Satoe Imaishi 2018-11-30 14:30:11 UTC

Comment 16 Tina Fitzgerald 2018-11-30 14:35:28 UTC
Although this reported as a retirement issue, the root cause is a service linking issue which is resolved with the PR referenced in comment 15.

Comment 17 CFME Bot 2018-11-30 15:31:05 UTC
New commit detected on ManageIQ/manageiq/hammer:

commit b14870058edc22e3e60f26064a928c11cb5a9240
Author:     Greg McCullough <gmccullo@redhat.com>
AuthorDate: Thu Nov 29 18:48:45 2018 -0500
Commit:     Greg McCullough <gmccullo@redhat.com>
CommitDate: Thu Nov 29 18:48:45 2018 -0500

    Merge pull request #18251 from d-m-u/fixing_service_bundle_resource_linking

    Link service resources of bundled service correctly

    (cherry picked from commit 4cdafdbf809ecf69b80b210abfcd5c7f28629259)


 app/models/service_template.rb | 4 +-
 spec/models/service_template_spec.rb | 42 +-
 2 files changed, 35 insertions(+), 11 deletions(-)

Comment 18 Tina Fitzgerald 2018-11-30 15:33:39 UTC
clearing needinfo

Comment 19 Tina Fitzgerald 2018-12-17 20:22:29 UTC
Adding 5.8.z flag per conversation with Dennis.

Comment 22 Tina Fitzgerald 2018-12-21 23:54:09 UTC
Hi Nandini,

Can you retire a Service bundle containing only service items, not bundles?


Comment 23 Tina Fitzgerald 2018-12-22 14:28:48 UTC
Hi Nandini,

Can you provide the reproducer IP address?


Comment 24 Tina Fitzgerald 2019-01-03 14:31:50 UTC
Hi Nandini,

This is a blocker bug, and the build is next week.
Can you provide a reproducer environment?


Comment 26 drew uhlmann 2019-01-04 15:35:08 UTC
We expect this is fixed in the as-yet-unmerged https://github.com/ManageIQ/manageiq/pull/18283

Comment 27 Tina Fitzgerald 2019-01-09 15:06:48 UTC
Hi Niyaz,

We're still testing our changes on the reproducer environment.
Can we continue to use this appliance for at least the next week, or until we have the new 5.10 build?


Comment 28 Niyaz Akhtar Ansari 2019-01-09 15:57:53 UTC
Hi Tina, sure you can use this appliance.

Comment 29 Niyaz Akhtar Ansari 2019-01-14 16:04:07 UTC
Catalog bundle resources now retiring 
Verified in Version

Note You need to log in before you can comment on or make changes to this bug.