elasticsearch-java-restful-api常見問題

1、java-restful-api查詢所有索引名(_cat/index?v)

ClusterHealthRequest request = new ClusterHealthRequest();
ClusterHealthResponse response = myRestClient.cluster().health(request, RequestOptions.DEFAULT);
Set<String> indices = response.getIndices().keySet();
System.out.println(indices.toString());
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章