mirror of
https://github.com/clearlinux/WALinuxAgent.git
synced 2026-10-03 23:38:24 +00:00
Report the upgradeGuid back to CRP in the status blob
This commit is contained in:
@@ -246,11 +246,13 @@ class ExtHandlerStatus(DataContract):
|
||||
def __init__(self,
|
||||
name=None,
|
||||
version=None,
|
||||
upgradeGuid=None,
|
||||
status=None,
|
||||
code=0,
|
||||
message=None):
|
||||
self.name = name
|
||||
self.version = version
|
||||
self.upgradeGuid = upgradeGuid
|
||||
self.status = status
|
||||
self.code = code
|
||||
self.message = message
|
||||
|
||||
@@ -321,6 +321,9 @@ def ext_handler_status_to_v1(handler_status, ext_statuses, timestamp):
|
||||
"message": handler_status.message
|
||||
}
|
||||
|
||||
if handler_status.upgradeGuid is not None:
|
||||
v1_handler_status["upgradeGuid"] = handler_status.upgradeGuid
|
||||
|
||||
if len(handler_status.extensions) > 0:
|
||||
# Currently, no more than one extension per handler
|
||||
ext_name = handler_status.extensions[0]
|
||||
|
||||
@@ -940,6 +940,7 @@ class ExtHandlerInstance(object):
|
||||
handler_status = ExtHandlerStatus()
|
||||
handler_status.name = self.ext_handler.name
|
||||
handler_status.version = self.ext_handler.properties.version
|
||||
handler_status.upgradeGuid = self.ext_handler.properties.upgradeGuid
|
||||
handler_status.message = message
|
||||
handler_status.code = code
|
||||
handler_status.status = status
|
||||
|
||||
Reference in New Issue
Block a user