Bug 1294451

Summary: v2v: webadmin uncaught exception occurs when trying to import VM without selecting cluster.
Product: [oVirt] ovirt-engine Reporter: Nisim Simsolo <nsimsolo>
Component: BLL.VirtAssignee: jniederm
Status: CLOSED CURRENTRELEASE QA Contact: meital avital <mavital>
Severity: medium Docs Contact:
Priority: high    
Version: 3.6.1CC: bugs, hannsj_uhl, mavital, mgoldboi, nsimsolo, stirabos, tjelinek
Target Milestone: ovirt-3.6.7Flags: rule-engine: ovirt-3.6.z+
mgoldboi: planning_ack+
tjelinek: devel_ack+
mavital: testing_ack+
Target Release: 3.6.7.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Cause: It wasn't checked if there is a cluster with matching architecture for imported VMs. Consequence: There was no cluster in Cluster dropbox on second page of Import VM dialog when VM selected for import had architecture for which there was no corresponding Cluster in selected Data Center Fix: * Split table allowing to select VMs for import shows architecture, format: "vm_name (arch)" * Selection of VMs is validated: * The selection may only contain VMs of one architecture * The selection may only contain VMs of architecture that has at least one architecture corresponding Cluster in selected Data Center Result:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-07-04 12:31:33 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Virt RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1308609, 1359843    

Description Nisim Simsolo 2015-12-28 09:17:13 UTC
Description of problem:
In some cases, such as using PPC, the cluster dropbox in the second import dialog will be empty. clicking "ok" in such case leads to webadmin exception.

Version-Release number of selected component (if applicable):
rhevm-3.6.1.3-0.1.el6

How reproducible:
Consistently.

Steps to Reproduce:
1. Browse webadmin UI and navigate to virtual machines tab > import > set VMware parameters and click "load" > select VM to import > click next.
2. See that second import dialog does not shows cluster in cluster dropbox > click ok
3.

Actual results:
Uncaught exception appears on the top of webadmin: 
Uncaught exception occurred. Please try reloading the page. Details: Exception caught: (TypeError) __gwt$exception:..

Expected results:
Exception should not occur, furthermore, when there is no available cluster to import to (such as PPC which is not supported yet) an appropriate message should appear.

Additional info:
Webadmin web-console log: 
Mon Dec 28 11:02:02 GMT+200 2015 
SEVERE: Uncaught exception: com.google.gwt.event.shared.UmbrellaException: Exception caught: (TypeError) 
 __gwt$exception: <skipped>: zab(...) is null
	at Unknown.ms(Unknown Source)
	at Unknown.us(Unknown Source)
	at Unknown.e3(Unknown Source)
	at Unknown.h3(Unknown Source)
	at Unknown.s2(Unknown Source)
	at Unknown.Im(Unknown Source)
	at Unknown.Sm(Unknown Source)
	at Unknown.g$(Unknown Source)
	at Unknown.Km(Unknown Source)
	at Unknown.v5e(Unknown Source)
	at Unknown.$Ve(Unknown Source)
	at Unknown.$Xe(Unknown Source)
	at Unknown.Yt(Unknown Source)
	at Unknown.au(Unknown Source)
	at Unknown._t/<(Unknown Source)
	at Unknown.ty(Unknown Source)
	at Unknown._4e(Unknown Source)
	at Unknown.eml(Unknown Source)
	at Unknown.v5e(Unknown Source)
	at Unknown.$Ve(Unknown Source)
	at Unknown.ZVe(Unknown Source)
	at Unknown.YXe(Unknown Source)
	at Unknown.Yt(Unknown Source)
	at Unknown.au(Unknown Source)
	at Unknown._t/<(Unknown Source)
	at Unknown.anonymous(Unknown Source)
Caused by: com.google.gwt.core.client.JavaScriptException: (TypeError) 
 __gwt$exception: <skipped>: zab(...) is null
	at Unknown.H2q(Unknown Source)
	at Unknown.N2q(Unknown Source)
	at Unknown.r3q(Unknown Source)
	at Unknown.hrr(Unknown Source)
	at Unknown.qll(Unknown Source)
	at Unknown.tyk(Unknown Source)
	at Unknown.B$(Unknown Source)
	at Unknown.C2(Unknown Source)
	at Unknown.s2(Unknown Source)
	at Unknown.Im(Unknown Source)
	at Unknown.Sm(Unknown Source)
	at Unknown.g$(Unknown Source)
	at Unknown.Km(Unknown Source)
	at Unknown.v5e(Unknown Source)
	at Unknown.$Ve(Unknown Source)
	at Unknown.$Xe(Unknown Source)
	at Unknown.Yt(Unknown Source)
	at Unknown.au(Unknown Source)
	at Unknown._t/<(Unknown Source)
	at Unknown.ty(Unknown Source)
	at Unknown._4e(Unknown Source)
	at Unknown.eml(Unknown Source)
	at Unknown.v5e(Unknown Source)
	at Unknown.$Ve(Unknown Source)
	at Unknown.ZVe(Unknown Source)
	at Unknown.YXe(Unknown Source)
	at Unknown.Yt(Unknown Source)
	at Unknown.au(Unknown Source)
	at Unknown._t/<(Unknown Source)
	at Unknown.anonymous(Unknown Source)
 06550BCB73EB7864DA79284790C1A9ED.cache.html:24013:11922

Comment 1 Nisim Simsolo 2015-12-28 14:51:57 UTC
*** Bug 1294453 has been marked as a duplicate of this bug. ***

Comment 2 Yaniv Kaul 2016-01-03 09:21:25 UTC
Can you follow http://www.ovirt.org/OVirt_Engine_Debug_Obfuscated_UI and get a nicer stack trace?

Comment 3 Nisim Simsolo 2016-01-04 15:48:40 UTC
obfuscated symbol map code:

zab,com.google.gwt.lang.Cast::dynamicCast(Ljava/lang/Object;I)Ljava/lang/Object;,com.google.gwt.lang.Cast,dynamicCast,com/google/gwt/dev/jjs/intrinsic/com/google/gwt/lang/Cast.java,53,0

Comment 4 Martin Betak 2016-02-17 11:55:01 UTC
After some preliminary investigation it seems that we need to filter the list of available data centers in the very first part of the import process to show only those DCs that have hosts capable of V2V. This will prevent getting into further frontend issues in this inconsistent state and among other things would also cover this scenario with PPC only clusters.

Comment 5 meital avital 2016-06-27 14:28:48 UTC
Verified on 3.6.7.4-0.1.el6

When trying to continue to second import dialog, the next "operation canceled" message appears:
"There is no cluster supporting selected VM(s) architecture in selected Data Center"