LinMingQiang commented on code in PR #4145:
URL: https://github.com/apache/paimon/pull/4145#discussion_r1749211626
##########
paimon-core/src/main/java/org/apache/paimon/table/system/ManifestsTable.java:
##########
@@ -195,7 +195,16 @@ private static List<ManifestFileMeta>
allManifests(FileStoreTable dataTable) {
SnapshotManager snapshotManager = dataTable.snapshotManager();
Long snapshotId = coreOptions.scanSnapshotId();
Snapshot snapshot = null;
- if (snapshotId != null && snapshotManager.snapshotExists(snapshotId)) {
+ if (snapshotId != null) {
+ // reminder user with snapshot id range
+ if (!snapshotManager.snapshotExists(snapshotId)) {
+ Long earliestSnapshotId = snapshotManager.earliestSnapshotId();
+ Long latestSnapshotId = snapshotManager.latestSnapshotId();
+ throw new RuntimeException(
+ String.format(
+ "Specified scan.snapshot-id %s is not exist,
you can set it in range from %s to %s",
+ snapshotId, earliestSnapshotId,
latestSnapshotId));
+ }
Review Comment:
SnapshotNotExistException
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]