本文整理了Java中org.elasticsearch.client.IndicesAdminClient.prepareStatus()
方法的一些代码示例,展示了IndicesAdminClient.prepareStatus()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。IndicesAdminClient.prepareStatus()
方法的具体详情如下:
包路径:org.elasticsearch.client.IndicesAdminClient
类名称:IndicesAdminClient
方法名:prepareStatus
暂无
代码示例来源:origin: ujmp/universal-java-matrix-package
@Override
public synchronized int size() {
IndicesStatusResponse response = client.admin().indices().prepareStatus().execute().actionGet();
return response.getIndices().size();
}
代码示例来源:origin: com.netflix.raigad/raigad
/**
* Following method is isolated so that it helps in Unit Testing for Mocking
* @param esTransportClient
* @return
*/
public IndicesStatusResponse getIndicesStatusResponse(Client esTransportClient)
{
return esTransportClient.admin().indices().prepareStatus().execute().actionGet(config.getAutoCreateIndexTimeout());
}
代码示例来源:origin: ujmp/universal-java-matrix-package
@Override
public synchronized Matrix get(int index) {
IndicesStatusResponse response = client.admin().indices().prepareStatus().execute().actionGet();
Set<String> indexSet = new TreeSet<String>(response.getIndices().keySet());
List<String> indexList = new ArrayList<String>(indexSet);
return Matrix.Factory.linkToValue(indexList.get(index));
}
代码示例来源:origin: mallocator/Elasticsearch-HBase-River
private void waitForESReady() {
if (!this.esClient.admin().indices().prepareExists(this.index).execute().actionGet().exists()) {
return;
}
for (final ShardStatus status : this.esClient.admin().indices().prepareStatus(this.index).execute().actionGet().getShards()) {
if (status.getState() != IndexShardState.STARTED) {
try {
Thread.sleep(1000);
} catch (InterruptedException e) {
this.logger.trace("HBase thread has been interrupted while waiting for the database to be reachable");
}
this.logger.trace("Waiting...");
waitForESReady();
break;
}
}
}
内容来源于网络,如有侵权,请联系作者删除!