commit | eb39fc23e374dcf484109315255be983592a1acd | [log] [tgz] |
---|---|---|
author | Mugdha Lakhani <[email protected]> | Thu Nov 14 14:54:25 2019 |
committer | Commit Bot <[email protected]> | Thu Nov 14 14:54:25 2019 |
tree | cae1f8145df94fb369e42f0dac6738787becfb0e | |
parent | 7a18f0ba75a32b1dbf8b493d936c49aa1eedafcb [diff] |
[Background Sync] Move browser wakeup to scheduler. Before this chance, we were calculating the soonest wakeup_delta across all storage partitions every time there was a change in state of any storage partition, to schedule a wakeup task with this delta. This change builds on the fact that we have running timers representing delays for each of the storage partitions with active registrations in the scheduler. I've changed scheduling the wakeup task to a push system. Each storage partition informs the scheduler of its soonest delay after there's any change in state. If this requested delay is the smallest of all the current delays of the timers the scheduler has, it schedules a wakeup task. Canceling delayed scheduling causes cancellation of the wakeup task if none of the storage partitions need it. The change also removes now unnecessary code. Unit tests are also added, and integration tests updated. Bug: 996166 Change-Id: I1e6216ecc7085535a8e0ca0075ddad05085df763 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1834086 Commit-Queue: Mugdha Lakhani <[email protected]> Reviewed-by: David Trainor <[email protected]> Reviewed-by: Avi Drissman <[email protected]> Reviewed-by: Rayan Kanso <[email protected]> Auto-Submit: Mugdha Lakhani <[email protected]> Cr-Commit-Position: refs/heads/master@{#715262}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .