Skip to content

Commit

Permalink
[hotfix] [rocksdb] Only log snapshot restore message when state is ac…
Browse files Browse the repository at this point in the history
…tually restored
  • Loading branch information
tzulitai committed Jan 8, 2019
1 parent 7a1147b commit ef08a86
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -517,10 +517,6 @@ public void restore(Collection<KeyedStateHandle> restoreState) throws Exception

LOG.info("Initializing RocksDB keyed state backend.");

if (LOG.isDebugEnabled()) {
LOG.debug("Restoring snapshot from state handles: {}, will use {} thread(s) to download files from DFS.", restoreState, restoringThreadNum);
}

// clear all meta data
kvStateInformation.clear();

Expand All @@ -529,6 +525,10 @@ public void restore(Collection<KeyedStateHandle> restoreState) throws Exception
if (restoreState == null || restoreState.isEmpty()) {
createDB();
} else {
if (LOG.isDebugEnabled()) {
LOG.debug("Restoring snapshot from state handles: {}, will use {} thread(s) to download files from DFS.", restoreState, restoringThreadNum);
}

KeyedStateHandle firstStateHandle = restoreState.iterator().next();
if (firstStateHandle instanceof IncrementalKeyedStateHandle
|| firstStateHandle instanceof IncrementalLocalKeyedStateHandle) {
Expand Down

0 comments on commit ef08a86

Please sign in to comment.