Package org.elasticsearch.action.admin.indices.status

Examples of org.elasticsearch.action.admin.indices.status.ShardStatus.shardId()


        // check the status
        IndicesStatusResponse status = client.client().admin().indices().prepareStatus("test").execute().actionGet();
        for (IndexShardStatus shardStatus : status.index("test")) {
            ShardStatus shard = shardStatus.shards()[0];
            logger.info("shard [{}], docs [{}]", shard.shardId(), shard.getDocs().numDocs());
            for (ShardStatus shardStatu : shardStatus) {
                if (shard.docs().numDocs() != shardStatu.docs().numDocs()) {
                    logger.warn("shard doc number does not match!, got {} and {}", shard.docs().numDocs(), shardStatu.docs().numDocs());
                }
            }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.