Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1599997 - [RFE] Update WeightedUpdateStatus to handle task cancellation and cleanup
Summary: [RFE] Update WeightedUpdateStatus to handle task cancellation and cleanup
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Automate
Version: 5.9.0
Hardware: Unspecified
OS: Unspecified
high
low
Target Milestone: GA
: 5.10.0
Assignee: Fabien Dupont
QA Contact: Kedar Kulkarni
URL:
Whiteboard:
Depends On: 1564257
Blocks: 1564236 1608758 1610533
TreeView+ depends on / blocked
 
Reported: 2018-07-11 07:40 UTC by Fabien Dupont
Modified: 2019-02-07 23:03 UTC (History)
9 users (show)

Fixed In Version: 5.10.0.11
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1608758 (view as bug list)
Environment:
Last Closed: 2019-02-07 23:03:14 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Github ManageIQ manageiq-content pull 357 None None None 2018-07-11 07:39:59 UTC
Red Hat Product Errata RHSA-2019:0212 None None None 2019-02-07 23:03:25 UTC

Description Fabien Dupont 2018-07-11 07:40:00 UTC
Description of problem:
We need to implement task cancellation and cleanup. @bzwei has started implementing task cancellation on the backend: https://github.com/ManageIQ/manageiq/pull/17687/files. It adds an entry in task options hash called cancel_requested with value true. So we check if this entry exists and if yes we trigger the cleanup state machine and raise to abort the current state machine.

The method should trigger the cleanup state machine when the migration is failed, i.e. the state exits on_error. The cleanup state machine is the same for failure and cancellation, as cancellation can be seen as a manual failure.

Comment 2 Brett Thurber 2018-07-17 05:02:14 UTC
@Fabien, is this required for 5.9.4 IMS GA or 5.10.0, 1.1?

Comment 3 Fabien Dupont 2018-07-20 11:05:54 UTC
@Brett, yes it's required for 5.9.4 IMS GA, because cancellation is part of the GA features.

Comment 4 Brett Thurber 2018-07-23 15:04:48 UTC
PR is merged.  Moving to Post.

Comment 6 Fabien Dupont 2018-07-27 21:51:30 UTC
Extra PR (bug fix):
https://github.com/ManageIQ/manageiq-content/pull/377

Comment 7 Fabien Dupont 2018-07-28 21:51:11 UTC
Extra PR - Add default cleanup state machine for VM transformation:
https://github.com/ManageIQ/manageiq-content/pull/378

Maybe this BZ should be renamed to reflect all the associated changes. It doesn't only update a method to trigger cleanup. It also adds the default cleanup state machine. @simaishi, what do you think ?

Comment 8 Kedar Kulkarni 2018-07-30 18:14:35 UTC
In 5.10.0.6, there could be backend changes in automate, I cannot validate those unless I have some UI. Please bring this back on_qa for appropriate build with UI changes as well.

Comment 10 Fabien Dupont 2018-08-02 07:39:03 UTC
All PRs merged. Moving to POST.

Comment 11 Fabien Dupont 2018-08-03 09:41:57 UTC
Identified a bug and provided a fix:
https://github.com/ManageIQ/manageiq-content/pull/392

Moving back to ON_DEV.

Comment 12 Kedar Kulkarni 2018-08-23 20:27:35 UTC
On 5.10.0.12 I could cancel in progress migration and it did cleanup the RHV disk as well.

Comment 13 errata-xmlrpc 2019-02-07 23:03:14 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2019:0212


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