summaryrefslogtreecommitdiff
path: root/scripts/update_payload/format_utils.py
diff options
context:
space:
mode:
authorSaurabh Nijhara <snijhara@google.com>2020-11-25 11:59:09 +0100
committerCommit Bot <commit-bot@chromium.org>2020-12-01 17:16:28 +0000
commit76b3a64c54ac819c87eb0a4e5f7d2bf2987f0bbe (patch)
tree725694e45f29b07d8b7f3338970db89a5e95ec57 /scripts/update_payload/format_utils.py
parent043355bd0870d407b62b100ab04dc6912402720f (diff)
update_engine: Add restricted intervals monitor
This CL introduces class UpdateTimeRestrictionsMonitor responsible for tracking the restricted time intervals from DeviceAutoUpdateTimeRestrictions policy during which update download is not allowed. It reads the policy, chooses the next interval according to current time and notifies the delegate when it starts. UpdateTimeRestrictionsMonitor is also able to detect and handle changes in restricted intervals during its lifetime. This monitor would be used in a follow up CL to cancel the download process during a restricted interval. This class would be short lived with its lifetime restricted to during the DownloadAction so that it can notify the delegate when restricted interval starts which would then cancel the update process. Resuming the update process when interval ends would be handled by the next auto update after interval end as update engine checkpoints the download progress. BUG=chromium:1117450 TEST=FEATURES=test emerge-${BOARD} update_engine Change-Id: Ia7190a488efecf1de53c6396ff67a2b7ef10aa57 Reviewed-on: https://chromium-review.googlesource.com/c/aosp/platform/system/update_engine/+/2560619 Tested-by: Saurabh Nijhara <snijhara@google.com> Reviewed-by: Amin Hassani <ahassani@chromium.org> Reviewed-by: Jae Hoon Kim <kimjae@chromium.org> Commit-Queue: Saurabh Nijhara <snijhara@google.com>
Diffstat (limited to 'scripts/update_payload/format_utils.py')
0 files changed, 0 insertions, 0 deletions