Bug 1449092 - Host targeted refresh fails when using sdk (v4)
Summary: Host targeted refresh fails when using sdk (v4)
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Providers
Version: 5.8.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: GA
: 5.9.0
Assignee: Moti Asayag
QA Contact: Ilanit Stein
URL:
Whiteboard: rhev
Depends On:
Blocks: 1458951
TreeView+ depends on / blocked
 
Reported: 2017-05-09 08:28 UTC by Moti Asayag
Modified: 2018-03-06 14:43 UTC (History)
4 users (show)

Fixed In Version: 5.9.0.1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1458951 (view as bug list)
Environment:
Last Closed: 2018-03-06 14:43:23 UTC
Category: Bug
Cloudforms Team: RHEVM
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Moti Asayag 2017-05-09 08:28:21 UTC
Description of problem:
When setting manageiq to work with ovirt-engine-sdk [1], and performing a targeted refresh for a host, the action fails.

Version-Release number of selected component (if applicable):
master, based on commit 

How reproducible:
always

Steps to Reproduce:
1. Follow [1] and set manageiq to work with the ovirt-engine-sdk
2. Select a specific host and click on 'Refresh Relationships and Power State'

Actual results:
Action fails and the evm.log contains:
[----] E, [2017-05-09T10:27:57.235798 #18731:1097120] ERROR -- : [NoMethodError]: undefined method `detect' for nil:NilClass  Method:[rescue in block in refresh]
[----] E, [2017-05-09T10:27:57.236071 #18731:1097120] ERROR -- : /home/masayag/work/manageiq-master/plugins/manageiq-providers-ovirt/app/models/manageiq/providers/redha
t/infra_manager/refresh/parse/strategies/host_inventory.rb:139:in `block in host_inv_to_switch_hashes'
/home/masayag/work/manageiq-master/plugins/manageiq-providers-ovirt/app/models/manageiq/providers/redhat/infra_manager/refresh/parse/strategies/host_inventory.rb:135:in
 `each'
/home/masayag/work/manageiq-master/plugins/manageiq-providers-ovirt/app/models/manageiq/providers/redhat/infra_manager/refresh/parse/strategies/host_inventory.rb:135:in
 `host_inv_to_switch_hashes'
/home/masayag/work/manageiq-master/plugins/manageiq-providers-ovirt/app/models/manageiq/providers/redhat/infra_manager/refresh/parse/strategies/host_inventory.rb:44:in 
`block in host_inv_to_hashes'


Expected results:
Refresh should completed successfully. 

Additional info:
[1] Set ':use_ovirt_engine_sdk' to true in config/settings.yml

The action fails since collecting data for host in v4 doesn't retrieve the entire list of networks. Therefore when trying to find a network which is reported by the host's nic as configured on the host - no network is found.
This leads to the exception above.

Comment 4 Ilanit Stein 2017-11-09 18:22:39 UTC
Verified on 5.9.0.4/RHV-4.1.7

Host's 'Refresh Relationships and Power State' ends up with a successful refresh.


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