Ori Liel has posted comments on this change.

Change subject: restapi: backward compatibility for cluster's scheduling policy
......................................................................


Patch Set 8: (1 inline comment)

....................................................
File 
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/ClusterMapper.java
Line 148:             }
Line 149:         }
Line 150:         if (model.isSetThresholds()) {
Line 151:             SchedulingPolicyThresholds thresholds = 
model.getThresholds();
Line 152:             entity.setClusterPolicyProperties(new 
LinkedHashMap<String, String>());
Can the user update a scheduling policy? If so, using this mapping in the 
context of update will result in a bug: the properties map is re-created from 
scratch and old values will disappear.
Line 153:             if (thresholds.getLow() != null) {
Line 154:                 
entity.getClusterPolicyProperties().put(LOW_UTILIZATION, 
thresholds.getLow().toString());
Line 155:             }
Line 156:             if (thresholds.getHigh() != null) {


-- 
To view, visit http://gerrit.ovirt.org/16607
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I4edd7313401670ca225b32d19dd7ad961ccd1b6a
Gerrit-PatchSet: 8
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Gilad Chaplik <gchap...@redhat.com>
Gerrit-Reviewer: Doron Fediuck <dfedi...@redhat.com>
Gerrit-Reviewer: Laszlo Hornyak <lhorn...@redhat.com>
Gerrit-Reviewer: Michael Pasternak <mpast...@redhat.com>
Gerrit-Reviewer: Ori Liel <ol...@redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to