Content-Length: 275647 | pFad | http://github.com/lowcoder-org/lowcoder/commit/4ced9eed58c0be474e68cfaae9526f538606c641

CB Fix migration of snapshot history · lowcoder-org/lowcoder@4ced9ee · GitHub
Skip to content

Commit 4ced9ee

Browse files
dragonpooludomikula
authored andcommitted
Fix migration of snapshot history
1 parent d43d0aa commit 4ced9ee

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

server/api-service/lowcoder-server/src/main/java/org/lowcoder/runner/migrations/DatabaseChangelog.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ public void addTimeSeriesSnapshotHistory(MongockTemplate mongoTemplate, CommonCo
359359
}
360360

361361
// Delete the migrated records
362-
Query deleteQuery = new Query(Criteria.where("createdAt").gte(thresholdDate));
362+
Query deleteQuery = new Query(Criteria.where("createdAt").lte(thresholdDate));
363363
DeleteResult deleteResult = mongoTemplate.remove(deleteQuery, ApplicationHistorySnapshot.class);
364364

365365
log.info("Deleted {} records from the source collection.", deleteResult.getDeletedCount());
@@ -390,7 +390,7 @@ public void addTimeSeriesSnapshotHistory(MongockTemplate mongoTemplate, CommonCo
390390
.toCollection();
391391

392392
// Delete the migrated records
393-
Query deleteQuery = new Query(Criteria.where("createdAt").gte(thresholdDate));
393+
Query deleteQuery = new Query(Criteria.where("createdAt").lte(thresholdDate));
394394
DeleteResult deleteResult = mongoTemplate.remove(deleteQuery, ApplicationHistorySnapshot.class);
395395

396396
log.info("Deleted {} records from the source collection.", deleteResult.getDeletedCount());

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/lowcoder-org/lowcoder/commit/4ced9eed58c0be474e68cfaae9526f538606c641

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy