Github user tillrohrmann commented on a diff in the pull request:
https://github.com/apache/flink/pull/5239#discussion_r169724637
--- Diff:
flink-contrib/flink-statebackend-rocksdb/src/main/java/org/apache/flink/contrib/streaming/state/RocksDBKeyedStateBackend.java
---
@@ -2123,9 +2162,21 @@ void takeSnapshot() throws Exception {
checkpointId,
sstFiles,
miscFiles,
- metaStateHandle);
+ metaStateHandle.getJobManagerOwnedSnapshot());
+
+ DirectoryStateHandle directoryStateHandle =
localBackupDirectory.completeSnapshotAndGetHandle();
+ StreamStateHandle taskLocalSnapshotMetaDataStateHandle
= metaStateHandle.getTaskLocalSnapshot();
+ IncrementalLocalKeyedStateHandle
directoryKeyedStateHandle =
+ directoryStateHandle != null &&
taskLocalSnapshotMetaDataStateHandle != null ?
+ new IncrementalLocalKeyedStateHandle(
+ stateBackend.backendUID,
+ checkpointId,
+ directoryStateHandle,
+ stateBackend.keyGroupRange,
+
taskLocalSnapshotMetaDataStateHandle) :
+ null;
- return new
SnapshotResult<>(incrementalKeyedStateHandle, null);
+ return new
SnapshotResult<>(incrementalKeyedStateHandle, directoryKeyedStateHandle);
--- End diff --
I guess you changed the creation of the `SnapshotResult` in a fixup commit
in your local branch, right? Otherwise we might refactor this in order to get
rid of the many `nulls` in the lines above.
---