MCPcopy Create free account
hub / github.com/apache/solr / getSegmentCount

Method getSegmentCount

solr/core/src/java/org/apache/solr/core/SolrCore.java:521–528  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

519 return calculateIndexSize();
520 }
521 }
522
523 private String cachedIndexSizeKeyName() {
524 // avoid collision when we put index sizes for multiple cores in the same metrics request
525 return "indexSize_" + getName();
526 }
527
528 public int getSegmentCount() {
529 try {
530 return withSearcher(
531 solrIndexSearcher -> solrIndexSearcher.getRawReader().getIndexCommit().getSegmentCount());

Callers 4

initializeMetricsMethod · 0.95
updateCommitsMethod · 0.45
informMethod · 0.45

Calls 2

withSearcherMethod · 0.95
getRawReaderMethod · 0.80

Tested by 1