DBAtlas · Database operations atlas

task_cancelled_exception: task_cancelled_exception: Task was cancelled / TaskCancelledException

Elasticsearch

What does it mean?

A running task (search, _reindex, _update_by_query, etc.) was cancelled. Cancellation can happen by a user request to _tasks/_cancel, by the client closing the HTTP connection (client timeout/abort; Elasticsearch cancels the associated search automatically), or by cancellation of a parent task or an expired async search.

Why does it happen?

The user cancelled the task with POST _tasks/<task_id>/_cancel (X-Opaque-Id only identifies and helps find the task; it does not cancel it), a client timeout dropped the connection, long-running expensive queries, or adaptive resource management stopped a heavy task.

How to fix it

If the task was cancelled unexpectedly, review client timeout and connection settings; optimize the heavy query (less data, more specific filters). For long operations, run _reindex/_update_by_query asynchronously (wait_for_completion=false) and monitor with GET _tasks. View active tasks: GET _tasks?detailed=true. If needed, split expensive queries or use scroll/PIT.

Open in DBAtlas →

More from this engine