Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use local clusterState call during healthchecks #8187

Merged
merged 4 commits into from
Sep 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions changelogs/fragments/8187.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
feat:
- Making local cluster state calls during health checks to avoid stressing cluster manager node ([#8187](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/8187))
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,12 @@ export const getNodeId = async (
}

/*
* Using _cluster/state/nodes to retrieve the cluster_id of each node from cluster manager node which
* is considered to be a lightweight operation to aggegrate different cluster_ids from the OpenSearch nodes.
* Using _cluster/state/nodes to retrieve the cluster_id of each node from local cluster state of the node
* which would be be a lightweight operation to aggegrate different cluster_ids from the OpenSearch nodes.
*/
const state = (await internalClient.cluster.state({
metric: 'nodes',
local: true,
gargharsh3134 marked this conversation as resolved.
Show resolved Hide resolved
filter_path: [path],
})) as ApiResponse;

Expand Down
Loading