'if we cancel the job with savepoint, job got cancelled and savepoint was failure how to restore this job now

I have deployed flink job in application mode using native kubernetes deployment and stopping job along with savepoint (I'm using rest api command for that) but if it fails to complete savepoint is it possible to take savepoint for that job as it was cancelled already?

1) success:

{
  "status":{"id":"COMPLETED"},
  "operation":{
    "location":"file:/savepoints-dir/savepoint-ad4025-dd46c1bd1c80"
  }
}
2) failure:

{
  "status":{"id":"COMPLETED"},
  "operation":{
    "failure-cause":{
      "class": "java.util.concurrent.CompletionException",
      "stack-trace": "..."
    }
  }
}


Solution 1:[1]

If you still have a checkpoint, you can restart from it: https://nightlies.apache.org/flink/flink-docs-release-1.13/docs/ops/state/checkpoints/#resuming-from-a-retained-checkpoint

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Gerard Garcia