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

Unified Diff: sync/engine/sync_scheduler_impl.cc

Issue 11314008: sync: Follow-up to conflict resolution refactor (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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
Index: sync/engine/sync_scheduler_impl.cc
diff --git a/sync/engine/sync_scheduler_impl.cc b/sync/engine/sync_scheduler_impl.cc
index b2180fbded8e803e691895fe562d4c82dd5be815..e26c29984ad165d157feb83b8939e351fab7a1ea 100644
--- a/sync/engine/sync_scheduler_impl.cc
+++ b/sync/engine/sync_scheduler_impl.cc
@@ -140,8 +140,6 @@ GetUpdatesCallerInfo::GetUpdatesSource GetUpdatesFromNudgeSource(
return GetUpdatesCallerInfo::NOTIFICATION;
case NUDGE_SOURCE_LOCAL:
return GetUpdatesCallerInfo::LOCAL;
- case NUDGE_SOURCE_CONTINUATION:
- return GetUpdatesCallerInfo::SYNC_CYCLE_CONTINUATION;
case NUDGE_SOURCE_LOCAL_REFRESH:
return GetUpdatesCallerInfo::DATATYPE_REFRESH;
case NUDGE_SOURCE_UNKNOWN:
@@ -782,23 +780,14 @@ void SyncSchedulerImpl::DoSyncSessionJob(const SyncSessionJob& job) {
job.session->RebaseRoutingInfoWithLatest(*session);
}
- SDVLOG(2) << "DoSyncSessionJob with "
- << SyncSessionJob::GetPurposeString(job.purpose) << " job";
-
SyncerStep begin(SYNCER_END);
SyncerStep end(SYNCER_END);
SetSyncerStepsForPurpose(job.purpose, &begin, &end);
- bool has_more_to_sync = true;
- while (ShouldRunJob(job) && has_more_to_sync) {
- SDVLOG(2) << "Calling SyncShare.";
- // Synchronously perform the sync session from this thread.
- syncer_->SyncShare(job.session.get(), begin, end);
- has_more_to_sync = job.session->HasMoreToSync();
- if (has_more_to_sync)
- job.session->PrepareForAnotherSyncCycle();
- }
- SDVLOG(2) << "Done SyncShare looping.";
+ SDVLOG(2) << "Calling SyncShare with "
+ << SyncSessionJob::GetPurposeString(job.purpose) << "job";
+ syncer_->SyncShare(job.session.get(), begin, end);
+ SDVLOG(2) << "Done SyncShare.";
FinishSyncSessionJob(job);
}
@@ -861,8 +850,6 @@ void SyncSchedulerImpl::FinishSyncSessionJob(const SyncSessionJob& job) {
void SyncSchedulerImpl::ScheduleNextSync(const SyncSessionJob& old_job) {
DCHECK_EQ(MessageLoop::current(), sync_loop_);
- DCHECK(!old_job.session->HasMoreToSync());
-
AdjustPolling(&old_job);
if (old_job.session->Succeeded()) {

Powered by Google App Engine
This is Rietveld 408576698