summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--common/resourceaccess.cpp2
-rw-r--r--common/resourcecontrol.cpp4
-rw-r--r--common/store.cpp16
-rw-r--r--common/synchronizer.cpp4
4 files changed, 13 insertions, 13 deletions
diff --git a/common/resourceaccess.cpp b/common/resourceaccess.cpp
index 50845ac..4831c72 100644
--- a/common/resourceaccess.cpp
+++ b/common/resourceaccess.cpp
@@ -614,7 +614,7 @@ bool ResourceAccess::processMessageBuffer()
614 [[clang::fallthrough]]; 614 [[clang::fallthrough]];
615 case Sink::Notification::Progress: { 615 case Sink::Notification::Progress: {
616 auto n = getNotification(buffer); 616 auto n = getNotification(buffer);
617 SinkTrace() << "Received notification: " << n.type; 617 SinkTrace() << "Received notification: Type:" << n.type << "Message: " << n.message << "Code: " << n.code;
618 emit notification(n); 618 emit notification(n);
619 } break; 619 } break;
620 case Sink::Notification::RevisionUpdate: 620 case Sink::Notification::RevisionUpdate:
diff --git a/common/resourcecontrol.cpp b/common/resourcecontrol.cpp
index 1f61a1c..70a3f7d 100644
--- a/common/resourcecontrol.cpp
+++ b/common/resourcecontrol.cpp
@@ -100,9 +100,9 @@ KAsync::Job<void> ResourceControl::flush(Flush::FlushType type, const QByteArray
100 auto notifier = QSharedPointer<Sink::Notifier>::create(resourceAccess); 100 auto notifier = QSharedPointer<Sink::Notifier>::create(resourceAccess);
101 auto id = QUuid::createUuid().toByteArray(); 101 auto id = QUuid::createUuid().toByteArray();
102 return KAsync::start<void>([=](KAsync::Future<void> &future) { 102 return KAsync::start<void>([=](KAsync::Future<void> &future) {
103 SinkTrace() << "Waiting for notification notification " << id; 103 SinkTrace() << "Waiting for flush completion notification " << id;
104 notifier->registerHandler([&future, id](const Notification &notification) { 104 notifier->registerHandler([&future, id](const Notification &notification) {
105 SinkTrace() << "Received notification " << notification.type << notification.id; 105 SinkTrace() << "Received notification: " << notification.type << notification.id;
106 if (notification.id == id) { 106 if (notification.id == id) {
107 SinkTrace() << "FlushComplete"; 107 SinkTrace() << "FlushComplete";
108 if (notification.code) { 108 if (notification.code) {
diff --git a/common/store.cpp b/common/store.cpp
index 1c8620b..727f4cc 100644
--- a/common/store.cpp
+++ b/common/store.cpp
@@ -281,14 +281,14 @@ static KAsync::Job<void> synchronize(const QByteArray &resource, const Sink::Syn
281 auto resourceAccess = ResourceAccessFactory::instance().getAccess(resource, ResourceConfig::getResourceType(resource)); 281 auto resourceAccess = ResourceAccessFactory::instance().getAccess(resource, ResourceConfig::getResourceType(resource));
282 return resourceAccess->synchronizeResource(scope) 282 return resourceAccess->synchronizeResource(scope)
283 .addToContext(resourceAccess) 283 .addToContext(resourceAccess)
284 .then<void>([](const KAsync::Error &error) { 284 .then([=](const KAsync::Error &error) {
285 if (error) { 285 if (error) {
286 SinkWarning() << "Error during sync."; 286 SinkWarning() << "Error during sync.";
287 return KAsync::error<void>(error); 287 return KAsync::error(error);
288 } 288 }
289 SinkTrace() << "synced."; 289 SinkTrace() << "Synchronization of resource " << resource << " complete.";
290 return KAsync::null<void>(); 290 return KAsync::null();
291 }); 291 });
292} 292}
293 293
294KAsync::Job<void> Store::synchronize(const Sink::Query &query) 294KAsync::Job<void> Store::synchronize(const Sink::Query &query)
diff --git a/common/synchronizer.cpp b/common/synchronizer.cpp
index e722f57..c7c0af5 100644
--- a/common/synchronizer.cpp
+++ b/common/synchronizer.cpp
@@ -353,7 +353,7 @@ KAsync::Job<void> Synchronizer::processRequest(const SyncRequest &request)
353 Q_ASSERT(!request.requestId.isEmpty()); 353 Q_ASSERT(!request.requestId.isEmpty());
354 //FIXME it looks like this is emitted before the replay actually finishes 354 //FIXME it looks like this is emitted before the replay actually finishes
355 if (request.flushType == Flush::FlushReplayQueue) { 355 if (request.flushType == Flush::FlushReplayQueue) {
356 SinkTraceCtx(mLogCtx) << "Emitting flush completion."; 356 SinkTraceCtx(mLogCtx) << "Emitting flush completion: " << request.requestId;
357 Sink::Notification n; 357 Sink::Notification n;
358 n.type = Sink::Notification::FlushCompletion; 358 n.type = Sink::Notification::FlushCompletion;
359 n.id = request.requestId; 359 n.id = request.requestId;
@@ -410,7 +410,7 @@ KAsync::Job<void> Synchronizer::processSyncQueue()
410 emit changesReplayed(); 410 emit changesReplayed();
411 } 411 }
412 if (error) { 412 if (error) {
413 SinkWarningCtx(mLogCtx) << "Error during sync: " << error.errorMessage; 413 SinkWarningCtx(mLogCtx) << "Error during sync: " << error;
414 } 414 }
415 //In case we got more requests meanwhile. 415 //In case we got more requests meanwhile.
416 return processSyncQueue(); 416 return processSyncQueue();