summaryrefslogtreecommitdiffstats
path: root/common/synchronizer.cpp
diff options
context:
space:
mode:
authorChristian Mollekopf <chrigi_1@fastmail.fm>2017-02-20 13:11:23 +0100
committerChristian Mollekopf <chrigi_1@fastmail.fm>2017-02-20 13:11:23 +0100
commit267813e1d71fe053742dbee11c30ea5004e2102b (patch)
tree7737cccfc23dc056134e84fe28f51c9b5374dba4 /common/synchronizer.cpp
parent129443ac808e69d5a61755451301633d2e07a3a6 (diff)
downloadsink-267813e1d71fe053742dbee11c30ea5004e2102b.tar.gz
sink-267813e1d71fe053742dbee11c30ea5004e2102b.zip
Debug output
Diffstat (limited to 'common/synchronizer.cpp')
-rw-r--r--common/synchronizer.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/common/synchronizer.cpp b/common/synchronizer.cpp
index a8af114..57c5d90 100644
--- a/common/synchronizer.cpp
+++ b/common/synchronizer.cpp
@@ -371,8 +371,12 @@ KAsync::Job<void> Synchronizer::processRequest(const SyncRequest &request)
371 371
372KAsync::Job<void> Synchronizer::processSyncQueue() 372KAsync::Job<void> Synchronizer::processSyncQueue()
373{ 373{
374 if (mSyncRequestQueue.isEmpty() || mSyncInProgress) { 374 if (mSyncRequestQueue.isEmpty()) {
375 SinkTraceCtx(mLogCtx) << "Sync still in progress or nothing to do."; 375 SinkLogCtx(mLogCtx) << "All requests processed.";
376 return KAsync::null<void>();
377 }
378 if (mSyncInProgress) {
379 SinkTraceCtx(mLogCtx) << "Sync still in progress.";
376 return KAsync::null<void>(); 380 return KAsync::null<void>();
377 } 381 }
378 //Don't process any new requests until we're done with the pending ones. 382 //Don't process any new requests until we're done with the pending ones.
@@ -485,7 +489,7 @@ KAsync::Job<void> Synchronizer::replay(const QByteArray &type, const QByteArray
485 oldRemoteId = syncStore().resolveLocalId(type, uid); 489 oldRemoteId = syncStore().resolveLocalId(type, uid);
486 //oldRemoteId can be empty if the resource implementation didn't return a remoteid 490 //oldRemoteId can be empty if the resource implementation didn't return a remoteid
487 } 491 }
488 SinkTraceCtx(mLogCtx) << "Replaying " << key << type << uid << oldRemoteId; 492 SinkLogCtx(mLogCtx) << "Replaying: " << key << "Type: " << type << "Uid: " << uid << "Rid: " << oldRemoteId << "Revision: " << metadataBuffer->revision();
489 493
490 KAsync::Job<QByteArray> job = KAsync::null<QByteArray>(); 494 KAsync::Job<QByteArray> job = KAsync::null<QByteArray>();
491 //TODO This requires supporting every domain type here as well. Can we solve this better so we can do the dispatch somewhere centrally? 495 //TODO This requires supporting every domain type here as well. Can we solve this better so we can do the dispatch somewhere centrally?