You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Response Ops][Task Manager] Setting background task utilization window based on poll interval (#203481)
## Summary
Setting a desired window length (15 seconds) for the background task
utilization window running average and calcuating the number of entries
to average based on the poll interval. Updating config to be optional so
this value can still be configured but if not configured will be
calculated.
## To Verify
- Add a console log to log the window size
```
--- a/x-pack/platform/plugins/shared/task_manager/server/monitoring/background_task_utilization_statistics.ts
+++ b/x-pack/platform/plugins/shared/task_manager/server/monitoring/background_task_utilization_statistics.ts
@@ -59,6 +59,7 @@ export function createBackgroundTaskUtilizationAggregator(
workerUtilizationRunningAverageWindowSize ??
WORKER_UTILIZATION_RUNNING_AVERAGE_WINDOW_SIZE_MS / pollInterval;
+ console.log(`workerUtilizationWindowSize ${workerUtilizationWindowSize}`);
const taskRunEventToAdhocStat = createTaskRunEventToAdhocStat();
const taskRunAdhocEvents$: Observable<Pick<BackgroundTaskUtilizationStat, 'adhoc'>> =
```
- Start Kibana with `mget` claim strategy. The window size should be 30
- Start Kibana with `update_by_query` claim strategy. The window size
should be 5
- Set `xpack.task_manager.worker_utilization_running_average_window: 22`
in your Kibana config and start Kibana. The window size should be 22
(takes the configured window size if it's passed in).
Co-authored-by: Elastic Machine <[email protected]>
Copy file name to clipboardExpand all lines: x-pack/platform/plugins/shared/task_manager/server/monitoring/background_task_utilization_statistics.test.ts
+35-6Lines changed: 35 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -425,7 +425,10 @@ describe('Task Run Statistics', () => {
0 commit comments