Change in vdsm[master]: Introduce API setBalloonTarget

agl at us.ibm.com agl at us.ibm.com
Fri Apr 27 12:32:45 UTC 2012


Adam Litke has posted comments on this change.

Change subject: Introduce API setBalloonTarget
......................................................................


Patch Set 5: I would prefer that you didn't submit this

(2 inline comments)

Just some suggestions about using a hard-coded default memory value.

....................................................
File vdsm/libvirtvm.py
Line 2102:                 max_mem = self.conf.get('memSize', 256) * 1024
Why are you allowing a default value (256) here?  How do you know that it would be correct?  Would it be better to raise an error if you are unable to access self.conf['memSize'] ?

....................................................
File vdsm/vm.py
Line 405:                 dev['target'] = int(self.conf.get('memSize', 256)) * 1024
I see.  This might be a problem.  What is someone wants to change the default memory from 256M to 512M?  Now they will have to remember two places to change it.  I think the default amount of memory should be defined as a single constant that can be used in multiple places.

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

Gerrit-MessageType: comment
Gerrit-Change-Id: I36b1211dbce28bb5bb5926f2db7e2e42a698efc9
Gerrit-PatchSet: 5
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Mark Wu <wudxw at linux.vnet.ibm.com>
Gerrit-Reviewer: Adam Litke <agl at us.ibm.com>
Gerrit-Reviewer: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Mark Wu <wudxw at linux.vnet.ibm.com>


More information about the vdsm-patches mailing list