shuwenwei commented on code in PR #14477:
URL: https://github.com/apache/iotdb/pull/14477#discussion_r1889744519
##########
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/conf/IoTDBConfig.java:
##########
@@ -2478,7 +2478,19 @@ public int getDefaultStorageGroupLevel() {
return defaultStorageGroupLevel;
}
- void setDefaultStorageGroupLevel(int defaultStorageGroupLevel) {
+ void setDefaultStorageGroupLevel(int defaultStorageGroupLevel, boolean
startUp) {
+ if (defaultStorageGroupLevel < 1) {
+ if (startUp) {
+ logger.warn(
+ "Illegal defaultStorageGroupLevel: {}, should >= 1, use default
value 1",
+ defaultStorageGroupLevel);
+ defaultStorageGroupLevel = 1;
+ } else {
+ throw new IllegalArgumentException(
Review Comment:
If the configuration file contains an value less than 1, it is allowed at
startup, but it may cause failure during hot loading. Why not handle it the
same way during hot loading as startup?
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]