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

Unified Diff: chrome/browser/sync/engine/sync_scheduler.cc

Issue 7655055: [Sync] Make BackendMigrator not wait for full sync cycles (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address more comments Created 9 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/sync/engine/sync_scheduler.h ('k') | chrome/browser/sync/engine/sync_scheduler_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/engine/sync_scheduler.cc
diff --git a/chrome/browser/sync/engine/sync_scheduler.cc b/chrome/browser/sync/engine/sync_scheduler.cc
index 3f860494ef208b77cff425d870b913df08cdf521..3782aff6c45b1689891f868717be2c2074077f37 100644
--- a/chrome/browser/sync/engine/sync_scheduler.cc
+++ b/chrome/browser/sync/engine/sync_scheduler.cc
@@ -445,11 +445,13 @@ void SyncScheduler::ScheduleClearUserData() {
&SyncScheduler::ScheduleClearUserDataImpl));
}
+// TODO(sync): Remove the *Impl methods for the other Schedule*
+// functions, too.
void SyncScheduler::ScheduleCleanupDisabledTypes() {
DCHECK_EQ(MessageLoop::current(), sync_loop_);
- PostTask(FROM_HERE, "ScheduleCleanupDisabledTypes",
- method_factory_.NewRunnableMethod(
- &SyncScheduler::ScheduleCleanupDisabledTypesImpl));
+ ScheduleSyncSessionJob(
+ TimeDelta::FromSeconds(0), SyncSessionJob::CLEANUP_DISABLED_TYPES,
+ CreateSyncSession(SyncSourceInfo()), FROM_HERE);
}
void SyncScheduler::ScheduleNudge(
@@ -496,13 +498,6 @@ void SyncScheduler::ScheduleClearUserDataImpl() {
CreateSyncSession(SyncSourceInfo()), FROM_HERE);
}
-void SyncScheduler::ScheduleCleanupDisabledTypesImpl() {
- DCHECK_EQ(MessageLoop::current(), sync_loop_);
- ScheduleSyncSessionJob(
- TimeDelta::FromSeconds(0), SyncSessionJob::CLEANUP_DISABLED_TYPES,
- CreateSyncSession(SyncSourceInfo()), FROM_HERE);
-}
-
void SyncScheduler::ScheduleNudgeImpl(
const TimeDelta& delay,
GetUpdatesCallerInfo::GetUpdatesSource source,
@@ -1037,6 +1032,8 @@ SyncSession* SyncScheduler::CreateSyncSession(const SyncSourceInfo& source) {
ModelSafeRoutingInfo routes;
std::vector<ModelSafeWorker*> workers;
session_context_->registrar()->GetModelSafeRoutingInfo(&routes);
+ VLOG(2) << "Creating sync session with routes "
+ << ModelSafeRoutingInfoToString(routes);
session_context_->registrar()->GetWorkers(&workers);
SyncSourceInfo info(source);
« no previous file with comments | « chrome/browser/sync/engine/sync_scheduler.h ('k') | chrome/browser/sync/engine/sync_scheduler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698