Bug 1470283

Summary: zones of sub region show up as zones appliances of a central region can move to
Product: Red Hat CloudForms Management Engine Reporter: Felix Dewaleyne <fdewaley>
Component: UI - OPSAssignee: Robin Knaur <rknaur>
Status: CLOSED CURRENTRELEASE QA Contact: Tasos Papaioannou <tpapaioa>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.7.0CC: fdewaley, hkataria, jhardy, mpovolny, obarenbo, simaishi, tpapaioa
Target Milestone: GAKeywords: TestOnly, ZStream
Target Release: 5.9.0   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: 5.9.0.1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1477723 1479938 (view as bug list) Environment:
Last Closed: 2018-03-06 14:39:43 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1477723, 1479938, 1480288    

Description Felix Dewaleyne 2017-07-12 16:04:59 UTC
Description of problem:
IF you are in a multiple region setup and try to move appliances of the central region to other zones, the menus will list zones that are not of that region

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

How reproducible:
all the time (customer environment)

Steps to Reproduce:
1.configure on appliance with several zones (Default, TestA, TestB)
2.configure another appliance to be he central region with several zones (default, TestA, TestC)
3.migrate the appliance between multiple zones

Actual results:
[----] I, [2017-06-16T06:15:49.870714 #10878:f3f138]  INFO -- : MIQ(MiqQueue#deliver) Message id: [99000000007091], Delivering...
[----] I, [2017-06-16T06:15:49.900300 #10878:f3f138]  INFO -- : MIQ(MiqQueue#delivered) Message id: [99000000007091], State: [ok], Delivered in [0.029563781] seconds
[----] I, [2017-06-16T06:15:55.057031 #11600:1377a0c]  INFO -- : MIQ(AssignedServerRole#deactivate) Deactivating Role <ems_inventory> on Server <inventory-2>
[----] I, [2017-06-16T06:15:55.059723 #11600:1377a0c]  INFO -- : MIQ(AssignedServerRole#deactivate) Deactivating Role <event> on Server <inventory-2>
[----] I, [2017-06-16T06:15:55.294268 #11600:1377a0c]  INFO -- : MIQ(MiqQueue.put) Message id: [99000000007092],  id: [], Zone: [test], Role: [], Server: [c6902a28-51c6-11e7-97ec-fa163eff7dfb], Ident: [miq_server], Target id: [], Instance id: [99000000000002], Task id: [], Command: [MiqServer.reload_settings], Timeout: [600], Priority: [100], State: [ready], Deliver On: [], Data: [], Args: []
[----] I, [2017-06-16T06:15:55.300412 #11600:1377a0c]  INFO -- : MIQ(MiqQueue.put) Message id: [99000000007093],  id: [], Zone: [test], Role: [], Server: [c6902a28-51c6-11e7-97ec-fa163eff7dfb], Ident: [generic], Target id: [], Instance id: [99000000000002], Task id: [], Command: [MiqServer.ntp_reload], Timeout: [600], Priority: [20], State: [ready], Deliver On: [], Data: [], Args: [{:server=>["0.pool.ntp.org", "1.pool.ntp.org", "2.pool.ntp.org"]}]
[----] I, [2017-06-16T06:16:01.065079 #11600:1375450]  INFO -- : MIQ(MiqQueue.put) Message id: [99000000007094],  id: [], Zone: [test], Role: [], Server: [c6902a28-51c6-11e7-97ec-fa163eff7dfb], Ident: [generic], Target id: [], Instance id: [99000000000002], Task id: [], Command: [MiqServer.ntp_reload], Timeout: [600], Priority: [20], State: [ready], Deliver On: [], Data: [], Args: [{:server=>["0.pool.ntp.org", "1.pool.ntp.org", "2.pool.ntp.org"]}]
[----] I, [2017-06-16T06:16:03.239506 #10926:f3f138]  INFO -- : MIQ(MiqScheduleWorker::Runner#do_work) Number of scheduled items to be processed: 0.
[----] I, [2017-06-16T06:16:03.786994 #11600:1377368]  INFO -- : MIQ(MiqQueue.put) Message id: [99000000007095],  id: [], Zone: [test], Role: [], Server: [c6902a28-51c6-11e7-97ec-fa163eff7dfb], Ident: [generic], Target id: [], Instance id: [99000000000002], Task id: [], Command: [MiqServer.ntp_reload], Timeout: [600], Priority: [20], State: [ready], Deliver On: [], Data: [], Args: [{:server=>["0.pool.ntp.org", "1.pool.ntp.org", "2.pool.ntp.org"]}]
[----] I, [2017-06-16T06:16:04.473765 #8915:f3f138]  INFO -- : MIQ(MiqServer#heartbeat) Heartbeat [2017-06-16 06:16:04 UTC]...
[----] I, [2017-06-16T06:16:04.481992 #8915:f3f138]  INFO -- : MIQ(MiqServer#heartbeat) Heartbeat [2017-06-16 06:16:04 UTC]...Complete
[----] E, [2017-06-16T06:16:04.483439 #8915:f3f138] ERROR -- : MIQ(MiqServer#monitor) undefined method `name' for nil:NilClass
[----] E, [2017-06-16T06:16:04.483620 #8915:f3f138] ERROR -- : [NoMethodError]: undefined method `name' for nil:NilClass  Method:[rescue in monitor]
[----] E, [2017-06-16T06:16:04.483721 #8915:f3f138] ERROR -- : /var/www/miq/vmdb/app/models/miq_server.rb:560:in `my_zone'

Expected results:
impossible choises are not listed in the list of available zones to migrate to

Additional info:
database dump available if needed

Comment 7 CFME Bot 2017-07-31 07:03:34 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:
https://github.com/ManageIQ/manageiq-ui-classic/commit/6f8303622ee247b44c269ab63c94d847a0b1d622

commit 6f8303622ee247b44c269ab63c94d847a0b1d622
Author:     PanSpagetka <rknaur>
AuthorDate: Thu Jul 27 11:53:48 2017 +0200
Commit:     PanSpagetka <rknaur>
CommitDate: Thu Jul 27 12:10:50 2017 +0200

    Zone select shows only zones in current region
    https://bugzilla.redhat.com/show_bug.cgi?id=1470283

 app/controllers/ops_controller/settings/common.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 10 Tasos Papaioannou 2017-10-12 18:58:11 UTC
Verified on 5.9.0.2.