Nodes hot threads API
Returns the hot threads on each selected node in the cluster.
Request
GET /_nodes/hot_threads
GET /_nodes/<node_id>/hot_threads
Prerequisites
- If the Elasticsearch security features are enabled, you must have the
monitorormanagecluster privilege to use this API.
Description
This API yields a breakdown of the hot threads on each selected node in the cluster. The output is plain text with a breakdown of each node’s top hot threads.
Path parameters
-
<node_id> - (Optional, string) Comma-separated list of node IDs or names used to limit returned information.
Query parameters
-
ignore_idle_threads - (Optional, Boolean) If true, known idle threads (e.g. waiting in a socket select, or to get a task from an empty queue) are filtered out. Defaults to true.
-
interval - (Optional, time units) The interval to do the second sampling of threads. Defaults to
500ms. -
snapshots - (Optional, integer) Number of samples of thread stacktrace. Defaults to
10. -
threads - (Optional, integer) Specifies the number of hot threads to provide information for. Defaults to
3. If you are using this API for troubleshooting, set this parameter to a large number (e.g.9999) to get information about all the threads in the system. -
master_timeout - (Optional, time units) Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. Defaults to
30s. -
timeout - (Optional, time units) Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. Defaults to
30s. -
type - (Optional, string) The type to sample. Available options are
block,cpu, andwait. Defaults tocpu.
Examples
GET /_nodes/hot_threads GET /_nodes/nodeId1,nodeId2/hot_threads
© 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/7.17/cluster-nodes-hot-threads.html