From ed53b8275d27c36abca0300447c2243cc8457838 Mon Sep 17 00:00:00 2001 From: Dave Marion Date: Tue, 24 Oct 2023 12:41:55 +0000 Subject: [PATCH] Deprecate rate limiting properties --- core/src/main/java/org/apache/accumulo/core/conf/Property.java | 3 +++ .../core/util/compaction/CompactionServicesConfig.java | 1 + .../accumulo/test/compaction/CompactionRateLimitingIT.java | 1 + 3 files changed, 5 insertions(+) diff --git a/core/src/main/java/org/apache/accumulo/core/conf/Property.java b/core/src/main/java/org/apache/accumulo/core/conf/Property.java index a4b627068c0..903c5d74431 100644 --- a/core/src/main/java/org/apache/accumulo/core/conf/Property.java +++ b/core/src/main/java/org/apache/accumulo/core/conf/Property.java @@ -573,6 +573,7 @@ public enum Property { TSERV_COMPACTION_SERVICE_ROOT_PLANNER("tserver.compaction.major.service.root.planner", DefaultCompactionPlanner.class.getName(), PropertyType.CLASSNAME, "Compaction planner for root tablet service", "2.1.0"), + @Deprecated(since = "3.1", forRemoval = true) TSERV_COMPACTION_SERVICE_ROOT_RATE_LIMIT("tserver.compaction.major.service.root.rate.limit", "0B", PropertyType.BYTES, "Maximum number of bytes to read or write per second over all major" @@ -591,6 +592,7 @@ public enum Property { TSERV_COMPACTION_SERVICE_META_PLANNER("tserver.compaction.major.service.meta.planner", DefaultCompactionPlanner.class.getName(), PropertyType.CLASSNAME, "Compaction planner for metadata table", "2.1.0"), + @Deprecated(since = "3.1", forRemoval = true) TSERV_COMPACTION_SERVICE_META_RATE_LIMIT("tserver.compaction.major.service.meta.rate.limit", "0B", PropertyType.BYTES, "Maximum number of bytes to read or write per second over all major" @@ -609,6 +611,7 @@ public enum Property { TSERV_COMPACTION_SERVICE_DEFAULT_PLANNER("tserver.compaction.major.service.default.planner", DefaultCompactionPlanner.class.getName(), PropertyType.CLASSNAME, "Planner for default compaction service.", "2.1.0"), + @Deprecated(since = "3.1", forRemoval = true) TSERV_COMPACTION_SERVICE_DEFAULT_RATE_LIMIT("tserver.compaction.major.service.default.rate.limit", "0B", PropertyType.BYTES, "Maximum number of bytes to read or write per second over all major" diff --git a/core/src/main/java/org/apache/accumulo/core/util/compaction/CompactionServicesConfig.java b/core/src/main/java/org/apache/accumulo/core/util/compaction/CompactionServicesConfig.java index c6e1cea55de..b3f911c4673 100644 --- a/core/src/main/java/org/apache/accumulo/core/util/compaction/CompactionServicesConfig.java +++ b/core/src/main/java/org/apache/accumulo/core/util/compaction/CompactionServicesConfig.java @@ -44,6 +44,7 @@ public class CompactionServicesConfig { public static final CompactionServiceId DEFAULT_SERVICE = CompactionServiceId.of("default"); + @SuppressWarnings("removal") private long getDefaultThroughput() { return ConfigurationTypeHelper .getMemoryAsBytes(Property.TSERV_COMPACTION_SERVICE_DEFAULT_RATE_LIMIT.getDefaultValue()); diff --git a/test/src/main/java/org/apache/accumulo/test/compaction/CompactionRateLimitingIT.java b/test/src/main/java/org/apache/accumulo/test/compaction/CompactionRateLimitingIT.java index 0b4280f8d10..46e1060e240 100644 --- a/test/src/main/java/org/apache/accumulo/test/compaction/CompactionRateLimitingIT.java +++ b/test/src/main/java/org/apache/accumulo/test/compaction/CompactionRateLimitingIT.java @@ -39,6 +39,7 @@ public class CompactionRateLimitingIT extends ConfigurableMacBase { public static final long BYTES_TO_WRITE = 10 * 1024 * 1024; public static final long RATE = 1 * 1024 * 1024; + @SuppressWarnings("removal") protected Property getThroughputProp() { return Property.TSERV_COMPACTION_SERVICE_DEFAULT_RATE_LIMIT; }