Skip to content

Task Manager health API - workload.value.average_interval_ms #96893

Open

Description

Problem

Currently, the Task Manager health API returns statistics about Task Manager's configuration, workload, and runtime performance. The workload.value.schedule currently returns the 10 most frequent intervals for the scheduled tasks, but it does not return the intervals for all scheduled tasks, as this would be infeasible to return a "bucket" for every single interval:

Screen Shot 2021-04-12 at 1 56 20 PM

As part of the autoscaling Kibana project, we would like to scale Kibana based on the task-capacity vs the scheduled task-load. One of the missing data-points for performing this calculation is the average interval for all scheduled tasks and this can't be inferred from the workload.value.schedule field.

Solution

The task-manager health API should be updated to return the workload.value.average_interval_ms to support this autoscaling calculation.

Currently, each task document has a task.schedule.interval field; however, this is a keyword field and stores the intervals using Elasticsearch's date interval syntax: 10m for 10 minutes, 100ms for 10 milliseconds. As a result, it's not possible to use the Elasticsearch avg aggregation on the task.schedule.interval field. Instead, a task.schedule.interval_ms field should be added so that the Elasticsearch avg aggregation can efficiently run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Feature:Task ManagerProject:AutoscalingKibanaAutoscaling Kibana in CloudTeam:ResponseOpsLabel for the ResponseOps team (formerly the Cases and Alerting teams)enhancementNew value added to drive a business resultestimate:smallSmall Estimated Level of EffortinsightIssues related to user insight into platform operations and resilienceresilienceIssues related to Platform resilience in terms of scale, performance & backwards compatibility

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions