You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "WantingDU (via GitHub)" <gi...@apache.org> on 2025/07/14 09:53:17 UTC
[I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
WantingDU opened a new issue, #13552:
URL: https://github.com/apache/iceberg/issues/13552
### Apache Iceberg version
1.9.1 (latest release)
### Query engine
Flink
### Please describe the bug 🐞
We are using Apache Iceberg with Flink 1.20.1, and we have observed that jobs cannot restore properly from checkpoints due to a missing fileSequenceNumber. The Preconditions.checkNotNull at SplitComparator#fileSequenceNumber always fails during the restoration process.
We are using Apache Iceberg with Flink in V2 format. We have verified that the sequence-number field is correctly present inside our metadata.json snapshots.
However, we always encounter the following exception during job restoration:
```
Caused by: java.lang.NullPointerException: Invalid file sequence number: null. Doesn't support splits written with V1 format: IcebergSourceSplit{files=[SplitScanTask{file=<xxx>.parquet, start=4, length=4416967}], fileOffset=0, recordOffset=0}
at org.apache.iceberg.relocated.com.google.common.base.Preconditions.checkNotNull(Preconditions.java:1008)
at org.apache.iceberg.flink.source.split.SplitComparators.lambda$fileSequenceNumber$96288a6c$1(SplitComparators.java:45)
at java.base/java.util.PriorityQueue.siftUpUsingComparator(Unknown Source)
at java.base/java.util.PriorityQueue.siftUp(Unknown Source)
at java.base/java.util.PriorityQueue.offer(Unknown Source)
at java.base/java.util.PriorityQueue.add(Unknown Source)
at org.apache.iceberg.flink.source.assigner.DefaultSplitAssigner.lambda$new$0(DefaultSplitAssigner.java:54)
at java.base/java.util.ArrayList.forEach(Unknown Source)
at org.apache.iceberg.flink.source.assigner.DefaultSplitAssigner.<init>(DefaultSplitAssigner.java:54)
at org.apache.iceberg.flink.source.assigner.OrderedSplitAssignerFactory.createAssigner(OrderedSplitAssignerFactory.java:44)
at org.apache.iceberg.flink.source.IcebergSource.createEnumerator(IcebergSource.java:217)
at org.apache.iceberg.flink.source.IcebergSource.restoreEnumerator(IcebergSource.java:193)
at org.apache.iceberg.flink.source.IcebergSource.restoreEnumerator(IcebergSource.java:88)
at org.apache.flink.runtime.source.coordinator.SourceCoordinator.resetToCheckpoint(SourceCoordinator.java:511)
at org.apache.flink.runtime.operators.coordination.RecreateOnResetOperatorCoordinator$DeferrableCoordinator.resetAndStart(RecreateOnResetOperatorCoordinator.java:429)
```
We suspect the issue arises because the fileSequenceNumber field is lost during the serialization and deserialization phase handled by FileScanTaskParser.
This issue might be relevant to [GitHub Issue #13320](https://github.com/apache/iceberg/issues/13320)
### Willingness to contribute
- [ ] I can contribute a fix for this bug independently
- [x] I would be willing to contribute a fix for this bug with guidance from the Iceberg community
- [ ] I cannot contribute a fix for this bug at this time
--
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: issues-unsubscribe@iceberg.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #13552: Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber
URL: https://github.com/apache/iceberg/issues/13552
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
Posted by "mxm (via GitHub)" <gi...@apache.org>.
mxm commented on issue #13552:
URL: https://github.com/apache/iceberg/issues/13552#issuecomment-3817367641
It looks like the fileSequenceNumber are indeed not properly serialized in the tasks json. FWIW, this particular split assigner isn't used anymore.
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
Posted by "WantingDU (via GitHub)" <gi...@apache.org>.
WantingDU commented on issue #13552:
URL: https://github.com/apache/iceberg/issues/13552#issuecomment-3089444328
Hello @mxm. Thanks for replying!
Unfortunately, I don't think it's because of the missing sequence number. We've checked the Iceberg metadata files and confirmed that all snapshots have a sequence number. Also, when we start a Flink job without restoring the state from a serialized checkpoint, there's never a missing sequence number issue, and the SplitComparator works as expected.
We're currently using the latest version, 1.9.1. Are you certain this code is no longer used?
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #13552:
URL: https://github.com/apache/iceberg/issues/13552#issuecomment-3752292453
This issue has been automatically marked as stale because it has been open for 180 days with no activity. It will be closed in next 14 days if no further activity occurs. To permanently prevent this issue from being considered stale, add the label 'not-stale', but commenting on the issue is preferred when possible.
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
Posted by "mxm (via GitHub)" <gi...@apache.org>.
mxm commented on issue #13552:
URL: https://github.com/apache/iceberg/issues/13552#issuecomment-3088582798
It appears the sequence number is missing from at least some data files. We could probably find another way to compare files instead of using the sequence number.
Which Iceberg version are you using? I don't see this code being used anymore in the latest versions.
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] Checkpoint Restore Failure in Flink Due to Missing FileSequenceNumber [iceberg]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #13552:
URL: https://github.com/apache/iceberg/issues/13552#issuecomment-3814631648
This issue has been closed because it has not received any activity in the last 14 days since being marked as 'stale'
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org