_description: "Provides a management API for queues of tasks waiting to be executed by workers deployed anywhere (see Workers Service)."
_definitions {
include "_common.conf"
queue_metrics {
type: object
properties: {
queue: {
type: string
description: "ID of the queue"
}
dates {
type: array
description: "List of timestamps (in seconds from epoch) in the acceding order. The timestamps are separated by the requested interval. Timestamps where no queue status change was recorded are omitted."
items { type: integer }
}
avg_waiting_times {
type: array
description: "List of average waiting times for tasks in the queue. The points correspond to the timestamps in the dates list. If more than one value exists for the given interval then the maximum value is taken."
items { type: number }
}
queue_lengths {
type: array
description: "List of tasks counts in the queue. The points correspond to the timestamps in the dates list. If more than one value exists for the given interval then the count that corresponds to the maximum average value is taken."
items { type: integer }
}
}
}
entry {
type: object
properties: {
task {
description: "Queued task ID"
type: string
}
added {
description: "Time this entry was added to the queue"
type: string
format: "date-time"
}
}
}
queue {
type: object
properties: {
id {
description: "Queue id"
type: string
}
name {
description: "Queue name"
type: string
}
user {
description: "Associated user id"
type: string
}
company {
description: "Company id"
type: string
}
created {
description: "Queue creation time"
type: string
format: "date-time"
}
tags {
description: "User-defined tags"
type: array
items { type: string }
}
system_tags {
description: "System tags. This field is reserved for system use, please don't use it."
description: "Page number, returns a specific page out of the result list of results."
type: integer
minimum: 0
}
page_size {
description: "Page size, specifies the number of results returned in each page (last page may contain fewer results)"
type: integer
minimum: 1
}
order_by {
description: "List of field names to order by. When search_text is used, '@text_score' can be used as a field representing the text score of returned documents. Use '-' prefix to specify descending order. Optional, recommended when using page"
description: "List of document field names (nesting is supported using '.', e.g. execution.model_labels). If provided, this list defines the query's projection (only these fields will be returned for each result entry)"
description: "Returns metrics of the company queues. The metrics are avaraged in the specified interval."
request {
type: object
required: [from_date, to_date, interval]
properties: {
from_date {
description: "Starting time (in seconds from epoch) for collecting metrics"
type: number
}
to_date {
description: "Ending time (in seconds from epoch) for collecting metrics"
type: number
}
interval {
description: "Time interval in seconds for a single metrics point. The minimal value is 1"
type: integer
}
queue_ids {
description: "List of queue ids to collect metrics for. If not provided or empty then all then average metrics across all the company queues will be returned."
description: "List of the requested queues with their metrics. If no queue ids were requested then 'all' queue is returned with the metrics averaged accross all the company queues."