Skip to content

Commit f7617d3

Browse files
authored
Increase the number of buckets in the queue latency histogram (#137596)
1 parent 4bd894d commit f7617d3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

server/src/main/java/org/elasticsearch/common/util/concurrent/TaskExecutionTimeTrackingEsThreadPoolExecutor.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@
3939
* An extension to thread pool executor, which tracks statistics for the task execution time.
4040
*/
4141
public final class TaskExecutionTimeTrackingEsThreadPoolExecutor extends EsThreadPoolExecutor {
42-
public static final int QUEUE_LATENCY_HISTOGRAM_BUCKETS = 18;
42+
// 20 buckets means the upper bound on the largest bound bucket will be 2^18 ms (~= 4 minutes 20 seconds)
43+
public static final int QUEUE_LATENCY_HISTOGRAM_BUCKETS = 20;
4344
private static final int[] LATENCY_PERCENTILES_TO_REPORT = { 50, 90, 99 };
4445

4546
private final Function<Runnable, WrappedRunnable> runnableWrapper;

0 commit comments

Comments
 (0)