diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-05-18 10:44:55 +0200 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2018-05-18 10:44:55 +0200 |
commit | 4aba3f019e888ce3272f361565329b7da712ce68 (patch) | |
tree | c10489add247ae30a0778270272db444803e5f1e /common | |
parent | 112a80652de31b763d0cf4087b2bba84e3eacf31 (diff) | |
download | sink-4aba3f019e888ce3272f361565329b7da712ce68.tar.gz sink-4aba3f019e888ce3272f361565329b7da712ce68.zip |
Improved error messages
Diffstat (limited to 'common')
-rw-r--r-- | common/storage/entitystore.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/common/storage/entitystore.cpp b/common/storage/entitystore.cpp index 6a71c39..230dbc7 100644 --- a/common/storage/entitystore.cpp +++ b/common/storage/entitystore.cpp | |||
@@ -437,7 +437,7 @@ QVector<QByteArray> EntityStore::fullScan(const QByteArray &type) | |||
437 | keys << uid; | 437 | keys << uid; |
438 | return true; | 438 | return true; |
439 | }, | 439 | }, |
440 | [&](const DataStore::Error &error) { SinkWarningCtx(d->logCtx) << "Error during query: " << error.message; }); | 440 | [&](const DataStore::Error &error) { SinkWarningCtx(d->logCtx) << "Error during fullScan query: " << error.message; }); |
441 | 441 | ||
442 | SinkTraceCtx(d->logCtx) << "Full scan retrieved " << keys.size() << " results."; | 442 | SinkTraceCtx(d->logCtx) << "Full scan retrieved " << keys.size() << " results."; |
443 | return keys.toList().toVector(); | 443 | return keys.toList().toVector(); |
@@ -489,7 +489,7 @@ void EntityStore::readLatest(const QByteArray &type, const QByteArray &uid, cons | |||
489 | [=](const QByteArray &key, const QByteArray &value) { | 489 | [=](const QByteArray &key, const QByteArray &value) { |
490 | callback(DataStore::uidFromKey(key), Sink::EntityBuffer(value.data(), value.size())); | 490 | callback(DataStore::uidFromKey(key), Sink::EntityBuffer(value.data(), value.size())); |
491 | }, | 491 | }, |
492 | [&](const DataStore::Error &error) { SinkWarningCtx(d->logCtx) << "Error during query: " << error.message << uid; }); | 492 | [&](const DataStore::Error &error) { SinkWarningCtx(d->logCtx) << "Error during readLatest query: " << error.message << uid; }); |
493 | } | 493 | } |
494 | 494 | ||
495 | void EntityStore::readLatest(const QByteArray &type, const QByteArray &uid, const std::function<void(const ApplicationDomainType &)> callback) | 495 | void EntityStore::readLatest(const QByteArray &type, const QByteArray &uid, const std::function<void(const ApplicationDomainType &)> callback) |
@@ -525,7 +525,7 @@ void EntityStore::readEntity(const QByteArray &type, const QByteArray &key, cons | |||
525 | callback(DataStore::uidFromKey(key), Sink::EntityBuffer(value.data(), value.size())); | 525 | callback(DataStore::uidFromKey(key), Sink::EntityBuffer(value.data(), value.size())); |
526 | return false; | 526 | return false; |
527 | }, | 527 | }, |
528 | [&](const DataStore::Error &error) { SinkWarningCtx(d->logCtx) << "Error during query: " << error.message << key; }); | 528 | [&](const DataStore::Error &error) { SinkWarningCtx(d->logCtx) << "Error during readEntity query: " << error.message << key; }); |
529 | } | 529 | } |
530 | 530 | ||
531 | void EntityStore::readEntity(const QByteArray &type, const QByteArray &uid, const std::function<void(const ApplicationDomainType &)> callback) | 531 | void EntityStore::readEntity(const QByteArray &type, const QByteArray &uid, const std::function<void(const ApplicationDomainType &)> callback) |