You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/12/14 05:14:04 UTC
[GitHub] [iotdb] SzyWilliam commented on a diff in pull request #8447: [IOTDB-5061] Add initialize state check when create snapshot
SzyWilliam commented on code in PR #8447:
URL: https://github.com/apache/iotdb/pull/8447#discussion_r1048023830
##########
server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionMemoryImpl.java:
##########
@@ -437,6 +437,12 @@ public synchronized void deleteSchemaRegion() throws MetadataException {
// currently, this method is only used for cluster-ratis mode
@Override
public synchronized boolean createSnapshot(File snapshotDir) {
+ if (!initialized) {
+ logger.warn(
+ "Failed to create snapshot of schemaRegion {}, because thi schemaRegion has not been initialized.",
Review Comment:
thi
##########
server/src/main/java/org/apache/iotdb/db/metadata/schemaregion/SchemaRegionSchemaFileImpl.java:
##########
@@ -424,6 +424,12 @@ public synchronized void deleteSchemaRegion() throws MetadataException {
@Override
public boolean createSnapshot(File snapshotDir) {
+ if (!initialized) {
+ logger.warn(
+ "Failed to create snapshot of schemaRegion {}, because thi schemaRegion has not been initialized.",
Review Comment:
thi
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org