Description of problem:
When removing a VM snapshot from RHV side, on CFME, RHV refresh fail
with Last message "Couldn't find Snapshot with 'id'=204"
(In RHv provider summary page)
Version-Release number of selected component (if applicable):
CFME-184.108.40.206 (Graph refresh=ON)
Not on CFME-220.127.116.11 (Graph refresh=OFF)
RHV refresh fail on snapshot not found.
RHV refresh should not fail on snapshot found, CFME just need to get updated with the snapshot removal.
This is probably related to having the Graph refresh activated, since on CFME-18.104.22.168 this same flow, do not fail the provider refresh.
Created attachment 1426044 [details]
Created attachment 1426045 [details]
Created attachment 1426046 [details]
New commit detected on ManageIQ/manageiq/master:
Author: Ladislav Smola <email@example.com>
AuthorDate: Tue May 22 02:51:16 2018 -0400
Commit: Ladislav Smola <firstname.lastname@example.org>
CommitDate: Tue May 22 02:51:16 2018 -0400
Do not delete children snapshots as part of parent
Do not delete children snapshots as part of parent. The default
relation :children, added by acts_as_tree, has :dependent => :destroy.
So deleting parent, will delete all it's children. This is not behavior
we want in refresh. In old refresh, we were bypassing this by:
So first, we deleted the tree relations, then we did create/update/delete
of the nodes, then we updated the tree connections again. All of that should
not be needed, if we will just use :dependent => :nullify
app/models/snapshot.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commit detected on ManageIQ/manageiq-providers-ovirt/master:
Author: Boris Odnopozov <email@example.com>
AuthorDate: Thu May 17 04:58:26 2018 -0400
Commit: Boris Odnopozov <firstname.lastname@example.org>
CommitDate: Thu May 17 04:58:26 2018 -0400
Fix refreshing targeted vm after snapshot removal
Avoid refreshing the vm a second time if snapshot was removed.
app/models/manageiq/providers/redhat/inventory/collector/target_collection.rb | 14 +-
spec/models/manageiq/providers/redhat/infra_manager/refresh/refresher_graph_target_vm_spec.rb | 14 +-
spec/vcr_cassettes/manageiq/providers/redhat/infra_manager/refresh/ovirt_sdk_refresh_graph_target_vm_deleted_snapshot.yml | 2452 +
3 files changed, 2469 insertions(+), 11 deletions(-)
1. Have a CFME with RHV provider and some VM
2. Go to CFME UI and find your VM's detail page and go to Snapshots.
3. Create a new snapshot.
4. Go to the provider's summary page.
5. Now switch to RHV UI and locate you VM's snapshots and delete the one you just created.
6. Wait until RHV reports that the deletion is complete.
7. Go back to CFME UI and verify there are no error on Provider's summary page or on VM's detail page.
8. Verify there are no errors in evm.log.