ShaoHe Feng has posted comments on this change.

Change subject: Add a flag to libvirtvm's status to report watchdog event
......................................................................


Patch Set 2: (4 inline comments)

....................................................
Commit Message
Line 6: 
Line 7: Add a flag to libvirtvm's status to report watchdog event
Line 8: 
Line 9: This flag will be set once watchdog event is triggered.
Line 10: And thie flag will be not cleanup after it is set unless the client
agree
Line 11: restart or shutdown VM. So add a timestamp in the message of this flag.
Line 12: 
Line 13: The timestamp is the time in seconds since the Epoch.
Line 14: 


Line 7: Add a flag to libvirtvm's status to report watchdog event
Line 8: 
Line 9: This flag will be set once watchdog event is triggered.
Line 10: And thie flag will be not cleanup after it is set unless the client
Line 11: restart or shutdown VM. So add a timestamp in the message of this flag.
this flag will be overwrite.
 so the next poll,  it  will be a new watchdog event.
Line 12: 
Line 13: The timestamp is the time in seconds since the Epoch.
Line 14: 
Line 15: When the client poll this flag, it should record and check the 
timestamp


....................................................
File vdsm/libvirtvm.py
Line 2224:                 return actionStrings[action]
Line 2225:             except IndexError:
Line 2226:                 return "Received unknown watchdog action(%s)" % 
action
Line 2227: 
Line 2228:         self.watchdogEvent = {}
just support no more than one watchdog for per VM.
 The original idea for a dynamic watchdogEvent attributes,  It will come up 
when  watchdog device is added and the event was fired. 
 No watchdog device for a VM, no watchdogEvent attributes.

 surely, to avoid run-time surprises,  an initially-empty list of events would 
be good enough.
Line 2229:         self.watchdogEvent["time"] = time.time()
Line 2230:         self.watchdogEvent["action"] = actionToString(action)
Line 2231:         self.log.debug("Watchdog event comes from guest %s. "
Line 2232:                        "Action: %s", self.conf['vmName'],


Line 2227: 
Line 2228:         self.watchdogEvent = {}
Line 2229:         self.watchdogEvent["time"] = time.time()
Line 2230:         self.watchdogEvent["action"] = actionToString(action)
Line 2231:         self.log.debug("Watchdog event comes from guest %s. "
agree.
Line 2232:                        "Action: %s", self.conf['vmName'],
Line 2233:                        actionToString(action))
Line 2234: 
Line 2235:     def changeCD(self, drivespec):


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I7aa676299c748d761e216469569156140a79af65
Gerrit-PatchSet: 2
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: ShaoHe Feng <[email protected]>
Gerrit-Reviewer: Dan Kenigsberg <[email protected]>
Gerrit-Reviewer: Doron Fediuck <[email protected]>
Gerrit-Reviewer: ShaoHe Feng <[email protected]>
Gerrit-Reviewer: oVirt Jenkins CI Server
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to