morningman commented on a change in pull request #4550:
URL: https://github.com/apache/incubator-doris/pull/4550#discussion_r486360186
##########
File path: fe/fe-core/src/main/java/org/apache/doris/catalog/Database.java
##########
@@ -483,7 +483,7 @@ public void readFields(DataInput in) throws IOException {
if (Catalog.getCurrentCatalogJournalVersion() >=
FeMetaVersion.VERSION_81) {
replicaQuotaSize = in.readLong();
} else {
- replicaQuotaSize = FeConstants.default_db_replica_quota_size;
+ replicaQuotaSize = Config.default_db_replica_quota_bytes;
Review comment:
If change this to Config, different FE may has different configuration.
So this will result in inconsistency of meta data.
This is just a default value filled in for compatibility with old data. I
suggest to leave it as `FeConstants.default_db_replica_quota_size`
##########
File path: fe/fe-core/src/main/java/org/apache/doris/common/Config.java
##########
@@ -1250,4 +1250,16 @@
*/
@ConfField(mutable = true, masterOnly = true)
public static boolean enable_batch_delete_by_default = false;
+
+ /**
+ * Used to set default db data quota bytes.
+ */
+ @ConfField(mutable = true, masterOnly = false)
+ public static long default_db_data_quota_bytes = 1024 * 1024 * 1024 *
1024L; // 1TB
+
+ /**
+ * Used to set default db replica quota bytes.
+ */
+ @ConfField(mutable = true, masterOnly = false)
+ public static long default_db_replica_quota_bytes = 1024 * 1024 * 1024;
Review comment:
The unit is wrong. This is not a "byte size", but a "number of" replicas.
##########
File path: fe/fe-core/src/main/java/org/apache/doris/common/Config.java
##########
@@ -1250,4 +1250,16 @@
*/
@ConfField(mutable = true, masterOnly = true)
public static boolean enable_batch_delete_by_default = false;
+
+ /**
+ * Used to set default db data quota bytes.
+ */
+ @ConfField(mutable = true, masterOnly = false)
+ public static long default_db_data_quota_bytes = 1024 * 1024 * 1024 *
1024L; // 1TB
Review comment:
Both config should be `masterOnly = true`
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]