Change in vdsm[master]: Return deep copy from GuestAgent.getGuestInfo()

fromani at redhat.com fromani at redhat.com
Wed Jan 20 13:38:10 UTC 2016


Francesco Romani has posted comments on this change.

Change subject: Return deep copy from GuestAgent.getGuestInfo()
......................................................................


Patch Set 1: Code-Review-1

(1 comment)

looks ok, but we'll need some data, especially about picklecopy vs deepcopy. -1 for visibility.

https://gerrit.ovirt.org/#/c/52499/1/vdsm/virt/guestagent.py
File vdsm/virt/guestagent.py:

Line 361: 
Line 362:     def getGuestInfo(self):
Line 363:         if self.isResponsive():
Line 364:             # copy.deepcopy() may (or may not) work better than
Line 365:             # utils.picklecopy with large immutable structures such as appsList.
this may be true, and may be fine - here and elsewhere.
But please, either provide a non-hypothetic reason to use deepcopy or picklecopy, as you find most fit, or just do some benchmark and pick the best one accordingly.
Line 366:             return copy.deepcopy(self.guestInfo)
Line 367:         else:
Line 368:             return {
Line 369:                 'username': 'Unknown',


-- 
To view, visit https://gerrit.ovirt.org/52499
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I0c50568604a3b4bdab57ec175687ac4e3a9565b9
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Milan Zamazal <mzamazal at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Vinzenz Feenstra <vfeenstr at redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation at ovirt.org>
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list