public interface Savepoint
In order to allow changes to the savepoint format between Flink versions, we allow different savepoint implementations (see subclasses of this interface).
Savepoints are serialized via a SavepointSerializer
and stored
via a SavepointStore
.
Modifier and Type | Method and Description |
---|---|
void |
dispose(ClassLoader classLoader)
Disposes the savepoint.
|
long |
getCheckpointId()
Returns the checkpoint ID of the savepoint.
|
Collection<TaskState> |
getTaskStates()
Returns the snapshotted task states.
|
int |
getVersion()
Returns the savepoint version.
|
int getVersion()
This version is independent of the Flink version, e.g. multiple Flink versions can work the same savepoint version.
long getCheckpointId()
Savepoints use the same mechanisms as regular checkpoints and are
identified by a unique ID. This ID is used to reset the CheckpointIDCounter
when restoring from a savepoint.
Collection<TaskState> getTaskStates()
These are used to restore the snapshot state.
void dispose(ClassLoader classLoader) throws Exception
The class loader is needed, because savepoints can currently point to
arbitrary snapshot StateHandle
instances, which need the user code class loader for deserialization.
classLoader
- Class loader for disposalException
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.