-
Notifications
You must be signed in to change notification settings - Fork 467
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Application didn't checkpoint at end of shard #211
Comments
+1 |
1 similar comment
+1 |
I have also encountered this problem. It is annoying, as when it happens the worker cannot progress causing service downtime (it doesn't crash, but it stops working as expected). It may happen when instance of Here is how it is exhibited in logs:
Here is what happened:
It can be worked around by using Correction suggested by @posac will solve the problem. |
Hi,
I have issue with checkpoints and ending shards.
In my processor, after each processRecords call I am calling checkpoint with sequence number. Sequence number is also stored in processor field.
On shutdown I am also calling :
if (shutdownInput.getShutdownReason() == ShutdownReason.TERMINATE) {
checkpoint(shutdownInput.getCheckpointer());
}
But after "Reached end of shard " I got exception:
java.lang.IllegalArgumentException: Application didn't checkpoint at end of shard shardId-00000001505383995695-aa7bbe9c at com.amazonaws.services.kinesis.clientlibrary.lib.worker.ShutdownTask.call(ShutdownTask.java:107) ~[amazon-kinesis-client-1.8.1.jar:?]
I have debug your code and for me there is bug in : RecordProcessorCheckpointer.java in method advancePosition.
I believe that in condition :
if (extendedSequenceNumber != null && !extendedSequenceNumber.equals(lastCheckpointValue)) {
should be :
if (checkpointToRecord != null && !checkpointToRecord.equals(lastCheckpointValue)) {
Otherwise I am not able to store SHARD_END - cause when processRecord calls checkpoint in checkpoint there is no sequenceNumberAtShardEnd yet, It is when it is called from shutdown but then mentioned condition is not satisfy -> lastCheckpointValue is equal to extendedSequenceNumber
The text was updated successfully, but these errors were encountered: