diff --git a/confignode/src/main/java/org/apache/iotdb/confignode/persistence/executor/ConfigPlanExecutor.java b/confignode/src/main/java/org/apache/iotdb/confignode/persistence/executor/ConfigPlanExecutor.java index 3c5e35f655ef51f544daccad09970bf96b2a0bec..70a85fa24e874499958a662a1c2db12fad530e08 100644 --- a/confignode/src/main/java/org/apache/iotdb/confignode/persistence/executor/ConfigPlanExecutor.java +++ b/confignode/src/main/java/org/apache/iotdb/confignode/persistence/executor/ConfigPlanExecutor.java @@ -405,7 +405,7 @@ public class ConfigPlanExecutor { try { takeSnapshotResult = x.processTakeSnapshot(snapshotDir); } catch (TException | IOException e) { - LOGGER.error(e.getMessage()); + LOGGER.error("Take snapshot error: {}", e.getMessage()); takeSnapshotResult = false; } finally { // If any snapshot fails, the whole fails @@ -415,6 +415,9 @@ public class ConfigPlanExecutor { } } }); + if (result.get()) { + LOGGER.info("Task snapshot success, snapshotDir: {}", snapshotDir); + } return result.get(); } @@ -426,6 +429,7 @@ public class ConfigPlanExecutor { return; } + AtomicBoolean result = new AtomicBoolean(true); snapshotProcessorList .parallelStream() .forEach( @@ -433,9 +437,13 @@ public class ConfigPlanExecutor { try { x.processLoadSnapshot(latestSnapshotRootDir); } catch (TException | IOException e) { - LOGGER.error(e.getMessage()); + result.set(false); + LOGGER.error("Load snapshot error: {}", e.getMessage()); } }); + if (result.get()) { + LOGGER.info("Load snapshot success, latestSnapshotRootDir: {}", latestSnapshotRootDir); + } } private DataSet getSchemaNodeManagementPartition(ConfigPhysicalPlan req) {