Re: get a total count

2012-05-03 Thread Shawn Heisey

On 5/1/2012 8:57 AM, Rahul R wrote:

Hello,
A related question on this topic. How do I programmatically find the total
number of documents across many shards ? For EmbeddedSolrServer, I use the
following command to get the total count :
solrSearcher.getStatistics().get(numDocs)

With distributed search, how do i get the count of all records in all
shards. Apart from doing a *:* query, is there a way to get the total count
? I am not able to use the same command above because, I am not able to get
a handle to the SolrIndexSearcher object with distributed search. The conf
and data directories of my index reside directly under a folder called solr
(no core) under the weblogic domain directly. I dont have a SolrCore
object. With EmbeddedSolrServer, I used to get the SolrIndexSearcher object
using the following call :
solrSearcher = (SolrIndexSearcher)SolrCoreObject.getSearcher().get();


A *:* query with rows=0 is how I get a total document count.  The 
program that does this most often is Perl using LWP, but I'm pretty sure 
I could do the same thing with the Commons server in SolrJ.  I've never 
used the embedded server.  I do not specify the shards parameter on my 
requests, I query a special core that has the shards parameter in 
solrconfig.xml.


Thanks,
Shawn



Re: get a total count

2012-05-01 Thread Rahul R
Hello,
A related question on this topic. How do I programmatically find the total
number of documents across many shards ? For EmbeddedSolrServer, I use the
following command to get the total count :
solrSearcher.getStatistics().get(numDocs)

With distributed search, how do i get the count of all records in all
shards. Apart from doing a *:* query, is there a way to get the total count
? I am not able to use the same command above because, I am not able to get
a handle to the SolrIndexSearcher object with distributed search. The conf
and data directories of my index reside directly under a folder called solr
(no core) under the weblogic domain directly. I dont have a SolrCore
object. With EmbeddedSolrServer, I used to get the SolrIndexSearcher object
using the following call :
solrSearcher = (SolrIndexSearcher)SolrCoreObject.getSearcher().get();

Stack Information :
OS : Solaris
jdk : 1.5.0_14 32 bit
Solr : 1.3
App Server : Weblogic 10MP1

Thank you.

- Rahul

On Tue, Nov 15, 2011 at 10:49 PM, Otis Gospodnetic 
otis_gospodne...@yahoo.com wrote:

 I'm assuming the question was about how MANY documents have been indexed
 across all shards.

 Answer #1:
 Look at the Solr Admin Stats page on each of your Solr instances and add
 up the numDocs numbers you see there

 Answer #2:
 Use Sematext's free Performance Monitoring tool for Solr
 On Index report choose all, sum in the Solr Host selector and that will
 show you the total # of docs across the cluster, total # of deleted docs,
 total segments, total size on disk, etc.
 URL: http://www.sematext.com/spm/solr-performance-monitoring/index.html

 Otis
 

 Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
 Lucene ecosystem search :: http://search-lucene.com/


 
 From: U Anonym uano...@gmail.com
 To: solr-user@lucene.apache.org
 Sent: Monday, November 14, 2011 11:50 AM
 Subject: get a total count
 
 Hello everyone,
 
 A newbie question:  how do I find out how documents have been indexed
 across all shards?
 
 Thanks much!
 
 
 



Re: get a total count

2011-11-15 Thread Erick Erickson
Not sure I understand the question. You have to specifically address the docs
to a particular shard when indexing, so you should know already. Solr
automagically distributes *queries* across shards (if you've configured
your installation for it), but not docs during indexing.

If that makes no sense, could you add some details to your question?

On Mon, Nov 14, 2011 at 11:50 AM, U Anonym uano...@gmail.com wrote:
 Hello everyone,

 A newbie question:  how do I find out how documents have been indexed
 across all shards?

 Thanks much!



Re: get a total count

2011-11-15 Thread Otis Gospodnetic
I'm assuming the question was about how MANY documents have been indexed across 
all shards.

Answer #1:
Look at the Solr Admin Stats page on each of your Solr instances and add up the 
numDocs numbers you see there

Answer #2:
Use Sematext's free Performance Monitoring tool for Solr
On Index report choose all, sum in the Solr Host selector and that will show 
you the total # of docs across the cluster, total # of deleted docs, total 
segments, total size on disk, etc.
URL: http://www.sematext.com/spm/solr-performance-monitoring/index.html

Otis


Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
Lucene ecosystem search :: http://search-lucene.com/



From: U Anonym uano...@gmail.com
To: solr-user@lucene.apache.org
Sent: Monday, November 14, 2011 11:50 AM
Subject: get a total count

Hello everyone,

A newbie question:  how do I find out how documents have been indexed
across all shards?

Thanks much!




get a total count

2011-11-14 Thread U Anonym
Hello everyone,

A newbie question:  how do I find out how documents have been indexed
across all shards?

Thanks much!