From ed17c92c9f3be95e9b280f2abc67f1c0ba48e8c4 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Fri, 22 Jun 2018 17:46:57 +0200 Subject: Try harder to avoid storing a revision that is too high in the result set. We might miss some updates. This should not normally ever happen if we assume that we have a transaction from start to finish of the query (the maxRevision() call should be equivalent. We do have some cornercases in our lmdb implementation that breaks transactions when new databases are opened, so we try to be extra safe this way.... Let's see if it works. --- common/datastorequery.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'common/datastorequery.cpp') diff --git a/common/datastorequery.cpp b/common/datastorequery.cpp index 0195cfc..fd910f8 100644 --- a/common/datastorequery.cpp +++ b/common/datastorequery.cpp @@ -665,7 +665,7 @@ QVector DataStoreQuery::loadIncrementalResultSet(qint64 baseRevision ResultSet DataStoreQuery::update(qint64 baseRevision) { - SinkTraceCtx(mLogCtx) << "Executing query update from revision " << baseRevision; + SinkTraceCtx(mLogCtx) << "Executing query update from revision " << baseRevision << " to revision " << mStore.maxRevision(); auto incrementalResultSet = loadIncrementalResultSet(baseRevision); SinkTraceCtx(mLogCtx) << "Incremental changes: " << incrementalResultSet; mSource->add(incrementalResultSet); -- cgit v1.2.3