Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(101)

Issue 1132013004: [Sync] Refactoring polling to be reliable. (Closed)

Created:
5 years, 7 months ago by Nicolas Zea
Modified:
5 years, 7 months ago
Reviewers:
pavely
CC:
chromium-reviews, tim+watch_chromium.org, zea+watch_chromium.org, maxbogue+watch_chromium.org, pvalenzuela+watch_chromium.org, plaree+watch_chromium.org, maniscalco+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Sync] Refactoring polling to be reliable. Polling is now an important component of sync health, as it can sometimes be the only time we'll query for certain datatypes. As such, the following has changed: - Polls that fail will be retried (with backoff). - As such, the logic to force a poll after an auth error isn't needed anymore - The last successful poll time will be persisted in the sync prefs. - On startup, schedule the first poll for last_poll_time + poll_interval (or Now(), whichever is latest). - Receiving a new poll interval from the server will update the poll timer - The poll timer is now a one shot timer, and only restarts on success - Some code cleanup to make the above more straightforward BUG=482154 Committed: https://crrev.com/3777d8727d7b4caedfb72bfdcbe2fea1f1d1d594 Cr-Commit-Position: refs/heads/master@{#329669}

Patch Set 1 #

Patch Set 2 : Self review #

Patch Set 3 : Bring back backoff on no-attempt #

Patch Set 4 : Fix SyncClient #

Total comments: 2

Patch Set 5 : Address comments #

Patch Set 6 : Diff from previous #

Patch Set 7 : Full patch #

Unified diffs Side-by-side diffs Delta from patch set Stats (+640 lines, -475 lines) Patch
M chrome/browser/sync/glue/sync_backend_host_core.h View 6 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/sync/glue/sync_backend_host_core.cc View 6 1 chunk +3 lines, -2 lines 0 comments Download
M chrome/browser/sync/glue/sync_backend_host_impl.cc View 6 2 chunks +4 lines, -1 line 0 comments Download
M components/sync_driver/pref_names.h View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M components/sync_driver/pref_names.cc View 1 2 3 4 5 6 1 chunk +3 lines, -0 lines 0 comments Download
M components/sync_driver/sync_prefs.h View 1 2 3 4 5 6 1 chunk +3 lines, -0 lines 0 comments Download
M components/sync_driver/sync_prefs.cc View 1 2 3 4 5 6 3 chunks +13 lines, -0 lines 0 comments Download
M sync/engine/sync_scheduler.h View 6 1 chunk +3 lines, -2 lines 0 comments Download
M sync/engine/sync_scheduler_impl.h View 6 4 chunks +9 lines, -13 lines 0 comments Download
M sync/engine/sync_scheduler_impl.cc View 1 2 3 4 5 6 17 chunks +110 lines, -91 lines 0 comments Download
M sync/engine/sync_scheduler_unittest.cc View 6 56 chunks +172 lines, -111 lines 0 comments Download
M sync/engine/syncer.h View 1 2 3 4 6 4 chunks +34 lines, -21 lines 0 comments Download
M sync/engine/syncer.cc View 6 6 chunks +16 lines, -2 lines 0 comments Download
M sync/engine/syncer_unittest.cc View 6 174 chunks +210 lines, -209 lines 0 comments Download
M sync/internal_api/js_sync_manager_observer_unittest.cc View 6 1 chunk +1 line, -0 lines 0 comments Download
M sync/internal_api/public/sessions/sync_session_snapshot.h View 6 3 chunks +3 lines, -0 lines 0 comments Download
M sync/internal_api/public/sessions/sync_session_snapshot.cc View 6 3 chunks +6 lines, -0 lines 0 comments Download
M sync/internal_api/public/sessions/sync_session_snapshot_unittest.cc View 6 1 chunk +1 line, -0 lines 0 comments Download
M sync/internal_api/public/sync_manager.h View 6 1 chunk +2 lines, -1 line 0 comments Download
M sync/internal_api/public/test/fake_sync_manager.h View 6 1 chunk +2 lines, -1 line 0 comments Download
M sync/internal_api/sync_manager_impl.h View 6 1 chunk +2 lines, -1 line 0 comments Download
M sync/internal_api/sync_manager_impl.cc View 6 4 chunks +6 lines, -4 lines 0 comments Download
M sync/internal_api/sync_manager_impl_unittest.cc View 6 4 chunks +4 lines, -4 lines 0 comments Download
M sync/internal_api/sync_rollback_manager.h View 6 1 chunk +2 lines, -1 line 0 comments Download
M sync/internal_api/sync_rollback_manager.cc View 6 1 chunk +1 line, -1 line 0 comments Download
M sync/internal_api/sync_rollback_manager_base.h View 6 1 chunk +2 lines, -1 line 0 comments Download
M sync/internal_api/sync_rollback_manager_base.cc View 6 1 chunk +1 line, -1 line 0 comments Download
M sync/internal_api/sync_rollback_manager_unittest.cc View 6 2 chunks +2 lines, -2 lines 0 comments Download
M sync/internal_api/test/fake_sync_manager.cc View 6 1 chunk +1 line, -1 line 0 comments Download
M sync/sessions/status_controller.h View 6 2 chunks +13 lines, -1 line 0 comments Download
M sync/sessions/status_controller.cc View 6 1 chunk +4 lines, -0 lines 0 comments Download
M sync/sessions/sync_session.cc View 6 1 chunk +1 line, -0 lines 0 comments Download
M sync/test/engine/fake_sync_scheduler.h View 6 1 chunk +1 line, -1 line 0 comments Download
M sync/test/engine/fake_sync_scheduler.cc View 6 1 chunk +1 line, -1 line 0 comments Download
M sync/tools/sync_client.cc View 1 2 3 6 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 15 (5 generated)
Nicolas Zea
+Pavel, PTAL Sorry for the size of the CL but nearly everything outside of the ...
5 years, 7 months ago (2015-05-07 23:50:12 UTC) #2
pavely
lstm with minor comments. https://codereview.chromium.org/1132013004/diff/60001/sync/engine/sync_scheduler_impl.cc File sync/engine/sync_scheduler_impl.cc (right): https://codereview.chromium.org/1132013004/diff/60001/sync/engine/sync_scheduler_impl.cc#newcode10 sync/engine/sync_scheduler_impl.cc:10: #include "base/auto_reset.h" I think auto_reset.h ...
5 years, 7 months ago (2015-05-08 23:04:13 UTC) #3
pavely
On 2015/05/08 23:04:13, pavely wrote: > lstm with minor comments. > > https://codereview.chromium.org/1132013004/diff/60001/sync/engine/sync_scheduler_impl.cc > File ...
5 years, 7 months ago (2015-05-08 23:05:07 UTC) #4
Nicolas Zea
Thanks for the quick review! Comments addressed.
5 years, 7 months ago (2015-05-09 17:23:59 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1132013004/80001
5 years, 7 months ago (2015-05-09 17:26:46 UTC) #8
commit-bot: I haz the power
Try jobs failed on following builders: android_chromium_gn_compile_dbg on tryserver.chromium.linux (JOB_TIMED_OUT, no build URL) android_chromium_gn_compile_rel on ...
5 years, 7 months ago (2015-05-09 21:31:00 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1132013004/80001
5 years, 7 months ago (2015-05-13 16:45:10 UTC) #12
commit-bot: I haz the power
Committed patchset #5 (id:80001)
5 years, 7 months ago (2015-05-13 17:43:13 UTC) #13
commit-bot: I haz the power
Patchset 5 (id:??) landed as https://crrev.com/3777d8727d7b4caedfb72bfdcbe2fea1f1d1d594 Cr-Commit-Position: refs/heads/master@{#329669}
5 years, 7 months ago (2015-05-13 17:44:13 UTC) #14
Nicolas Zea
5 years, 7 months ago (2015-05-13 18:44:07 UTC) #15
Message was sent while issue was closed.
A revert of this CL (patchset #5 id:80001) has been created in
https://codereview.chromium.org/1144443004/ by zea@chromium.org.

The reason for reverting is: Failing on valgrind bots.

Powered by Google App Engine
This is Rietveld 408576698