Description of problem: [DNS] - Validate empty DNS configuration and mark field in red. It is possible to check the 'DNS Configuration' check box with empty 'DNS Servers' filed and it's possible to press 'OK" to approve operation and we get: Error while executing action: size must be between 1 and 2 Attribute: network.dnsResolverConfiguration.nameServers 2017-05-16 11:14:05,016+03 WARN [org.ovirt.engine.core.bll.network.dc.UpdateNetworkCommand] (default task-11) [84552b7c-1239-4c86-bbad-ac77afd87327] Validation of action 'UpdateNetwork' failed for user admin@internal-authz. Reasons: VAR__TYPE__NETWORK,VAR__ACTION__UPDATE,size must be between 1 and 2,$groups [Ljava.lang.Class;@11c98c2f,$min 1,$message {javax.validation.constraints.Size.message},$payload [Ljava.lang.Class;@158fcaad,$max 2,ACTION_TYPE_FAILED_ATTRIBUTE_PATH,$path network.dnsResolverConfiguration.nameServers,$validatedValue [] Version-Release number of selected component (if applicable): 4.2.0-0.0.master.20170514130938.gitacb8b09.el7.centos DNS rpms on top of the master version. How reproducible: 100 Steps to Reproduce: 1. Check the 'DNS Configuration' checkbox, but don't fill in the name server, and press 'OK" Actual results: Failed with error: Error while executing action: size must be between 1 and 2 Attribute: network.dnsResolverConfiguration.nameServers Expected results: Engine should require to fill a name server if the 'DNS Configuration' checkbox is checked and it should color the 'DNS Servers' field in red, same behaviour we have for other fields in all dialogs.
This is the patch for the DNS rpms - http://jenkins.ovirt.org/job/ovirt-engine_master_build-artifacts-on-demand-el7-x86_64/171/ https://gerrit.ovirt.org/#/c/76497/
Hi Martin, I saw in the patch that you can't mark the unset field in red and you marked the checkbox as invalid(attaching screenshot of how it looks now on master). Can you please make the invalid checkbox mark in red color?
Created attachment 1285205 [details] screenshot
maybe, but I shouldn't. We actually saw that happening with UI guy here in brno. This is how all 'invalid' checkboxes are styled. They have some css class, which is not defined. So from point of view of this patch, it's OK and unrelated, IIUC. We should fill a bug for UI guys, to fix CSS definitions.
Verified on - 4.2.0-0.0.master.20170702100738.git46a9f67.el7.centos
This bugzilla is included in oVirt 4.2.0 release, published on Dec 20th 2017. Since the problem described in this bug report should be resolved in oVirt 4.2.0 release, published on Dec 20th 2017, it has been closed with a resolution of CURRENT RELEASE. If the solution does not work for you, please open a new bug report.