1u0 commented on a change in pull request #9727: [FLINK-14145] Fix 
getLatestCheckpoint(true) returns wrong checkpoint
URL: https://github.com/apache/flink/pull/9727#discussion_r326561669
 
 

 ##########
 File path: 
flink-runtime/src/test/java/org/apache/flink/runtime/checkpoint/StandaloneCompletedCheckpointStoreTest.java
 ##########
 @@ -116,4 +120,35 @@ public void testAddCheckpointWithFailedRemove() throws 
Exception {
                        }
                }
        }
+
+       @Test
+       public void preferCheckpointForRecoveryWithSavepoint() throws Exception 
{
+               StandaloneCompletedCheckpointStore store = new 
StandaloneCompletedCheckpointStore(5);
+               JobID jobId = new JobID();
+               store.addCheckpoint(checkpoint(jobId, 1L));
+               store.addCheckpoint(checkpoint(jobId, 2L));
+               store.addCheckpoint(checkpoint(jobId, 3L));
 
 Review comment:
   The `savepoint` method is not used so far. Maybe it should be used by an 
additional test like:
   ```
   checkpoint 1, checkpoint 2, savepoint 3 -> returns checkpoint 2
   ``` 

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to