{"record":{"id":"8269d11923a7ba72","repo":"apache/iceberg","slug":"unknown-starting-strategy","errorCode":null,"errorMessage":"Unknown starting strategy: ","messagePattern":"Unknown starting strategy: ","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"flink/v1.20/flink/src/main/java/org/apache/iceberg/flink/source/enumerator/ContinuousSplitPlannerImpl.java","lineNumber":244,"sourceCode":"      case INCREMENTAL_FROM_LATEST_SNAPSHOT_EXCLUSIVE:\n        return Optional.ofNullable(table.currentSnapshot());\n      case INCREMENTAL_FROM_EARLIEST_SNAPSHOT:\n        return Optional.ofNullable(SnapshotUtil.oldestAncestor(table));\n      case INCREMENTAL_FROM_SNAPSHOT_ID:\n        Snapshot matchedSnapshotById = table.snapshot(scanContext.startSnapshotId());\n        Preconditions.checkArgument(\n            matchedSnapshotById != null,\n            \"Start snapshot id not found in history: \" + scanContext.startSnapshotId());\n        return Optional.of(matchedSnapshotById);\n      case INCREMENTAL_FROM_SNAPSHOT_TIMESTAMP:\n        Snapshot matchedSnapshotByTimestamp =\n            SnapshotUtil.oldestAncestorAfter(table, scanContext.startSnapshotTimestamp());\n        Preconditions.checkArgument(\n            matchedSnapshotByTimestamp != null,\n            \"Cannot find a snapshot after: \" + scanContext.startSnapshotTimestamp());\n        return Optional.of(matchedSnapshotByTimestamp);\n      default:\n        throw new IllegalArgumentException(\n            \"Unknown starting strategy: \" + scanContext.streamingStartingStrategy());\n    }\n  }\n}\n","sourceCodeStart":226,"sourceCodeEnd":249,"githubUrl":"https://github.com/apache/iceberg/blob/86d9c8fc543e7c56c9f624eb725f76c9baff9570/flink/v1.20/flink/src/main/java/org/apache/iceberg/flink/source/enumerator/ContinuousSplitPlannerImpl.java#L226-L249","documentation":"ContinuousSplitPlannerImpl.startSnapshot switches over the StreamingStartingStrategy and has no handling for the given strategy, throwing IllegalArgumentException. The strategy value is un recognized by this connector version.","triggerScenarios":"Resuming a streaming scan whose saved state (IcebergEnumeratorPosition) or table property (streaming-starting-strategy) contains a strategy value not in the switch (TABLE_SCAN_THEN_INCREMENTAL, INCREMENTAL_FROM_SNAPSHOT_ID, INCREMENTAL_FROM_SNAPSHOT_TIMESTAMP, INCREMENTAL_FROM_LATEST_SNAPSHOT).","commonSituations":"Restoring a checkpoint/savepoint produced by a different connector version with a new strategy; manually setting an invalid streaming-starting-strategy property value.","solutions":["Check the streaming-starting-strategy property value and set a valid one (e.g., INCREMENTAL_FROM_LATEST_SNAPSHOT).","Restore checkpoints/savepoints with the same connector version that produced them, or upgrade both together.","Upgrade the Iceberg Flink connector if the strategy was introduced in a newer version."],"exampleFix":"// before\n.env(\"streaming-starting-strategy\", \"INCREMENTAL_FROM_EARLIEST\") // invalid\n// after\n.env(\"streaming-starting-strategy\", \"INCREMENTAL_FROM_LATEST_SNAPSHOT\")","handlingStrategy":"validation","validationCode":"String strategy = table.properties().getOrDefault(\"streaming-starting-strategy\", \"TABLE_SCAN_THEN_INCREMENTAL\");\njava.util.Set<String> valid = java.util.Set.of(\"TABLE_SCAN_THEN_INCREMENTAL\", \"INCREMENTAL_FROM_SNAPSHOT_ID\", \"INCREMENTAL_FROM_SNAPSHOT_TIMESTAMP\", \"INCREMENTAL_FROM_LATEST_SNAPSHOT\");\nif (!valid.contains(strategy)) throw new IllegalArgumentException(\"Invalid streaming-starting-strategy: \" + strategy);","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Set streaming-starting-strategy only to documented enum names","Restore checkpoints/savepoints with the connector version that wrote them","Upgrade (never downgrade) connectors when strategy state was written by newer code"],"tags":["flink","streaming","enum","starting-strategy"],"backgroundTag":"invalid-enum-value","analyzedSha":"86d9c8fc543e7c56c9f624eb725f76c9baff9570","analyzedAt":"2026-09-12T00:46:39.097Z","contentChangedAt":"2026-09-12T00:46:39.097Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}