From 510f2d6b5c0b48d9e4f2cc4a0e541a96d0aecc3d Mon Sep 17 00:00:00 2001 From: Kaushal Kumar Date: Fri, 8 Dec 2023 12:05:01 -0800 Subject: [PATCH] address comments Signed-off-by: Kaushal Kumar --- config/rca.conf | 4 ++-- config/rca_cluster_manager.conf | 4 ++-- .../rca/configs/SearchBackPressureRcaConfig.java | 9 ++++++++- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/config/rca.conf b/config/rca.conf index e3e1dac0d..11c18b5f0 100644 --- a/config/rca.conf +++ b/config/rca.conf @@ -66,10 +66,10 @@ "shard-request-cache-threshold" : 0.9 }, "search-back-pressure-rca": { - "max-heap-usage-increase": 70, + "max-heap-usage-increase": 80, "max-shard-heap-cancellation-percentage": 5, "max-task-heap-cancellation-percentage": 5, - "max-heap-usage-decrease": 80, + "max-heap-usage-decrease": 90, "min-shard-heap-cancellation-percentage": 3, "min-task-heap-cancellation-percentage": 3 }, diff --git a/config/rca_cluster_manager.conf b/config/rca_cluster_manager.conf index 5efb97b1e..d42ebe818 100644 --- a/config/rca_cluster_manager.conf +++ b/config/rca_cluster_manager.conf @@ -75,10 +75,10 @@ "shard-request-cache-threshold" : 0.9 }, "search-back-pressure-rca": { - "max-heap-usage-increase": 70, + "max-heap-usage-increase": 80, "max-shard-heap-cancellation-percentage": 5, "max-task-heap-cancellation-percentage": 5, - "max-heap-usage-decrease": 80, + "max-heap-usage-decrease": 90, "min-shard-heap-cancellation-percentage": 3, "min-task-heap-cancellation-percentage": 3 } diff --git a/src/main/java/org/opensearch/performanceanalyzer/rca/configs/SearchBackPressureRcaConfig.java b/src/main/java/org/opensearch/performanceanalyzer/rca/configs/SearchBackPressureRcaConfig.java index 785af4d86..9182724ca 100644 --- a/src/main/java/org/opensearch/performanceanalyzer/rca/configs/SearchBackPressureRcaConfig.java +++ b/src/main/java/org/opensearch/performanceanalyzer/rca/configs/SearchBackPressureRcaConfig.java @@ -28,14 +28,17 @@ public class SearchBackPressureRcaConfig { public static final int DEFAULT_MAX_HEAP_INCREASE_THRESHOLD = 70; private Integer maxHeapIncreasePercentageThreshold; - // cancellation percent due to heap is more than 3% of all task completions in shard level + // cancellation percent due to heap is more than 5% of all task completions at shard level // (Taking 3 because we don't cancel more than 10% of all completions at any time) + // Basically this threshold tell that we are overcancelling the shard level tasks given max heap from last rca eval period is still + // below or equal to DEFAULT_MAX_HEAP_INCREASE_THRESHOLD public static final int DEFAULT_SHARD_MAX_HEAP_CANCELLATION_THRESHOLD = 5; private Integer maxShardHeapCancellationPercentageThreshold; // cancellation percent due to heap is more than 5% of all task completions in // SearchTask(co-ordinator) level (Taking 3 because we don't cancel more than 10% of all // completions at any time) + // Basically this threshold tell that we are overcancelling the co-ordinator level tasks public static final int DEFAULT_TASK_MAX_HEAP_CANCELLATION_THRESHOLD = 5; private Integer maxTaskHeapCancellationPercentageThreshold; @@ -45,10 +48,14 @@ public class SearchBackPressureRcaConfig { private Integer minHeapDecreasePercentageThreshold; // cancellationCount due to heap is less than 3% of all task completions in shard level + // Basically this threshold tell that we are under cancelling the shard level tasks given min heap from last rca eval period is still + // above or equal to DEFAULT_MIN_HEAP_DECREASE_THRESHOLD public static final int DEFAULT_SHARD_MIN_HEAP_CANCELLATION_THRESHOLD = 3; private Integer minShardHeapCancellationPercentageThreshold; // cancellationCount due to heap is less than 3% of all task completions in task level + // Basically this threshold tell that we are under cancelling the coordinator level tasks given min heap from last rca eval period is still + // above or equal to DEFAULT_MIN_HEAP_DECREASE_THRESHOLD public static final int DEFAULT_TASK_MIN_HEAP_CANCELLATION_THRESHOLD = 3; private Integer minTaskHeapCancellationPercentageThreshold;