Spec-Zone.ru › Elasticsearch 8
›Elasticsearch Guide [8.17] ›REST APIs ›SQL APIs

Get async SQL search status API

New API reference

For the most up-to-date API details, refer to SQL APIs.

Returns the current status of an async SQL search or a stored synchronous SQL search.

resp = client.sql.get_async_status(
    id="FmdMX2pIang3UWhLRU5QS0lqdlppYncaMUpYQ05oSkpTc3kwZ21EdC1tbFJXQToxOTI=",
    format="json",
)
print(resp)
response = client.sql.get_async_status(
  id: 'FmdMX2pIang3UWhLRU5QS0lqdlppYncaMUpYQ05oSkpTc3kwZ21EdC1tbFJXQToxOTI=',
  format: 'json'
)
puts response
const response = await client.sql.getAsyncStatus({
  id: "FmdMX2pIang3UWhLRU5QS0lqdlppYncaMUpYQ05oSkpTc3kwZ21EdC1tbFJXQToxOTI=",
  format: "json",
});
console.log(response);
GET _sql/async/status/FmdMX2pIang3UWhLRU5QS0lqdlppYncaMUpYQ05oSkpTc3kwZ21EdC1tbFJXQToxOTI=?format=json

Request

GET _sql/async/status/<search_id>

Prerequisites

  • If the Elasticsearch security features are enabled, you must have the monitor cluster privilege to use this API.

Limitations

See SQL Limitations.

Path parameters

<search_id>
(Required, string) Identifier for the search.

Response body

id
(string) Identifier for the search.
is_running
(Boolean) If true, the search is still running. If false, the search has finished.
is_partial
(Boolean) If true, the response does not contain complete search results. If is_partial is true and is_running is true, the search is still running. If is_partial is true but is_running is false, the results are partial due to a failure or timeout.
start_time_in_millis
(integer) Timestamp, in milliseconds since the Unix epoch, when the search started. The API only returns this property for running searches.
expiration_time_in_millis
(integer) Timestamp, in milliseconds since the Unix epoch, when Elasticsearch will delete the search and its results, even if the search is still running.
completion_status
(integer) HTTP status code for the search. The API only returns this property for completed searches.

© 2023-2025 Elasticsearch
As of September 2024, Elasticsearch is available under a choice of three licenses: the Server Side Public License (SSPL), the Elastic License, or the AGPLv3 (OSI approved).
Elasticsearch and the Elasticsearch logo are trademarks of Elasticsearch B.V., registered in the U.S. and in other countries.
https://www.elastic.co/guide/en/elasticsearch/reference/8.17/get-async-sql-search-status-api.html

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API