You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by ramin <do...@gmail.com> on 2012/01/26 20:29:45 UTC

solr shards

Hello,

I've gone through the list and have not found the answer but if it is a
repetitive question, my apologies.

I have a 3x shards solr cluster. If i send a query to each of the shards
individually I get the result with a list of relevant docs. However, if i
send the query to the main solr server (dispatcher) it only returns the
value for numFound but there is no list of docs. Since i seem to be the only
one having this issue, it is probably a misconfiguration for which i
couldn't find an answer in the documentations. Can someone please help?

Also, the sum of all the individual numFound's seems to not match the
numFound I get from the main solr server, given that i do not have any
duplicate on the unique key.

Thanks in advance,
Ramin

--
View this message in context: http://lucene.472066.n3.nabble.com/solr-shards-tp3691370p3691370.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: Strange things happen when I query with many facet.prefixes and fq filters

Posted by Chris Hostetter <ho...@fucit.org>.
: References: <13...@n3.nabble.com>
:  <CA...@mail.gmail.com>
:  <13...@n3.nabble.com>
: Message-ID: <13...@web160304.mail.bf1.yahoo.com>
: Subject: Strange things happen when I query with many facet.prefixes and fq
:  filters

https://people.apache.org/~hossman/#threadhijack
Thread Hijacking on Mailing Lists

When starting a new discussion on a mailing list, please do not reply to 
an existing message, instead start a fresh email.  Even if you change the 
subject line of your email, other mail headers still track which thread 
you replied to and your question is "hidden" in that thread and gets less 
attention.   It makes following discussions in the mailing list archives 
particularly difficult.



-Hoss

Re: SOLVED: Strange things happen when I query with many facet.prefixes and fq filters

Posted by Erick Erickson <er...@gmail.com>.
Ah, thanks for bringing closure. Should have occurred to me
when I saw your query....

On Mon, Jan 30, 2012 at 2:55 PM, Yuhao <nf...@yahoo.com> wrote:
> Good question.  I checked the output sent to Jetty.  In the case where it returns a blank page, nothing at all is sent to Jetty.  This raised my suspicion that Solr never got a chance to process the query.  Sure enough, it led me to the finding that Jetty by default cannot take more than 4 KB of header.  After I increased that limit, everything works.
> Problem solved.
>
>
>
>
> ________________________________
>  From: Erick Erickson <er...@gmail.com>
> To: solr-user@lucene.apache.org; Yuhao <nf...@yahoo.com>
> Sent: Sunday, January 29, 2012 1:05 PM
> Subject: Re: Strange things happen when I query with many facet.prefixes and fq filters
>
> The very first question I have is "what do your Solr logs show"? I suspect
> you'll see something interesting there. Otherwise, there's no way really to
> say what's going on here without reproducing your setup...
>
> Best
> Erick
>
> On Fri, Jan 27, 2012 at 6:48 PM, Yuhao <nf...@yahoo.com> wrote:
>> Hi,
>>
>> I'm having issues when running the following query, which is produced by expanding several hierarchical facets (implemented the facet.prefix way).  I realize it's pretty massive, but I'd like to figure out what exactly is causing the problem.  Is it too many facet.prefix clauses, too many fq filters, the combo of both, or what.  Anyway, here is the URL I start out
>>  with:
>>
>> http://40.163.5.153:920/solr/browse?&fq=Gene_Ontology_Associations%3A%220%2Fbiological_process%28GO%3A0008150%29%22&fq=Gene_Ontology_Associations%3A%221%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%22&fq=Gene_Ontology_Associations%3A%222%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%22&fq=Gene_Ontology_Associations%3A%223%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29%22&fq=Mouse_Phenotype_Associations%3A%220%2Fmammalian+phenotype%28MP%3A0000001%29%22&fq=Mouse_Phenotype_Associations%3A%221%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%22&fq=Mouse_Phenotype_Associations%3A%222%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fme
>> tabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%22&fq=Mouse_Phenotype_Associations%3A%223%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%22&fq=Mouse_Phenotype_Associations%3A%224%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%22&fq=Mouse_Phenotype_Associations%3A%225%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%22&fq=Mouse_Phenotype_Associations%3A%226%2Fm
>> ammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%22&fq=Mouse_Phenotype_Associations%3A%227%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29%22&fq=BKL_Diagnostic_Marker_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=BKL_Molecular_Mechanism_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=
>> BKL_Diagnostic_Marker_Associations%3A%221%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%22&q=&fq=BKL_Diagnostic_Marker_Associations:%222%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%3BAtherosclerosis%28MESH%3AD050197%29%22&f.Gene_Ontology_Associations.facet.prefix=4%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29&f.Mouse_Phenotype_Associations.facet.prefix=8%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29&a
>> mp;f.BKL_Molecular_Mechanism_Associations.facet.prefix=1%2FCardiovascular+Diseases%28MESH%3AD002318%29
>>
>> The above works fine.  It's basically a bunch of fq= and facet.prefix= parameters.  However, if I add another parameter, shown below, then I will instantly get a totally blank page, and I can't get it to load anything no matter what.  (the parameter itself is fine since it works by itself or with fewer parameters)
>>
>> &f.BKL_Diagnostic_Marker_Associations.facet.prefix=3%2FCardiovascular+Diseases(MESH%3AD002318)%3BArteriosclerosis(MESH%3AD001161)%3BAtherosclerosis(MESH%3AD050197)
>>
>> Here's another interesting thing: if I just add the parameter field without any value, as in "&f.BKL_Diagnostic_Marker_Associations.facet.prefix=", then I will get a page of the result, but without any CSS rendering.
>>
>> Please advise what may be going on here.  Is my query simply too big?  Does Solr have a limit?  Did I break the limit?

Re: SOLVED: Strange things happen when I query with many facet.prefixes and fq filters

Posted by Yuhao <nf...@yahoo.com>.
Good question.  I checked the output sent to Jetty.  In the case where it returns a blank page, nothing at all is sent to Jetty.  This raised my suspicion that Solr never got a chance to process the query.  Sure enough, it led me to the finding that Jetty by default cannot take more than 4 KB of header.  After I increased that limit, everything works.
Problem solved.




________________________________
 From: Erick Erickson <er...@gmail.com>
To: solr-user@lucene.apache.org; Yuhao <nf...@yahoo.com> 
Sent: Sunday, January 29, 2012 1:05 PM
Subject: Re: Strange things happen when I query with many facet.prefixes and fq filters
 
The very first question I have is "what do your Solr logs show"? I suspect
you'll see something interesting there. Otherwise, there's no way really to
say what's going on here without reproducing your setup...

Best
Erick

On Fri, Jan 27, 2012 at 6:48 PM, Yuhao <nf...@yahoo.com> wrote:
> Hi,
>
> I'm having issues when running the following query, which is produced by expanding several hierarchical facets (implemented the facet.prefix way).  I realize it's pretty massive, but I'd like to figure out what exactly is causing the problem.  Is it too many facet.prefix clauses, too many fq filters, the combo of both, or what.  Anyway, here is the URL I start out
>  with:
>
> http://40.163.5.153:920/solr/browse?&fq=Gene_Ontology_Associations%3A%220%2Fbiological_process%28GO%3A0008150%29%22&fq=Gene_Ontology_Associations%3A%221%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%22&fq=Gene_Ontology_Associations%3A%222%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%22&fq=Gene_Ontology_Associations%3A%223%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29%22&fq=Mouse_Phenotype_Associations%3A%220%2Fmammalian+phenotype%28MP%3A0000001%29%22&fq=Mouse_Phenotype_Associations%3A%221%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%22&fq=Mouse_Phenotype_Associations%3A%222%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fme
> tabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%22&fq=Mouse_Phenotype_Associations%3A%223%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%22&fq=Mouse_Phenotype_Associations%3A%224%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%22&fq=Mouse_Phenotype_Associations%3A%225%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%22&fq=Mouse_Phenotype_Associations%3A%226%2Fm
> ammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%22&fq=Mouse_Phenotype_Associations%3A%227%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29%22&fq=BKL_Diagnostic_Marker_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=BKL_Molecular_Mechanism_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=
> BKL_Diagnostic_Marker_Associations%3A%221%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%22&q=&fq=BKL_Diagnostic_Marker_Associations:%222%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%3BAtherosclerosis%28MESH%3AD050197%29%22&f.Gene_Ontology_Associations.facet.prefix=4%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29&f.Mouse_Phenotype_Associations.facet.prefix=8%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29&a
> mp;f.BKL_Molecular_Mechanism_Associations.facet.prefix=1%2FCardiovascular+Diseases%28MESH%3AD002318%29
>
> The above works fine.  It's basically a bunch of fq= and facet.prefix= parameters.  However, if I add another parameter, shown below, then I will instantly get a totally blank page, and I can't get it to load anything no matter what.  (the parameter itself is fine since it works by itself or with fewer parameters)
>
> &f.BKL_Diagnostic_Marker_Associations.facet.prefix=3%2FCardiovascular+Diseases(MESH%3AD002318)%3BArteriosclerosis(MESH%3AD001161)%3BAtherosclerosis(MESH%3AD050197)
>
> Here's another interesting thing: if I just add the parameter field without any value, as in "&f.BKL_Diagnostic_Marker_Associations.facet.prefix=", then I will get a page of the result, but without any CSS rendering.
>
> Please advise what may be going on here.  Is my query simply too big?  Does Solr have a limit?  Did I break the limit?

Re: Strange things happen when I query with many facet.prefixes and fq filters

Posted by Erick Erickson <er...@gmail.com>.
The very first question I have is "what do your Solr logs show"? I suspect
you'll see something interesting there. Otherwise, there's no way really to
say what's going on here without reproducing your setup...

Best
Erick

On Fri, Jan 27, 2012 at 6:48 PM, Yuhao <nf...@yahoo.com> wrote:
> Hi,
>
> I'm having issues when running the following query, which is produced by expanding several hierarchical facets (implemented the facet.prefix way).  I realize it's pretty massive, but I'd like to figure out what exactly is causing the problem.  Is it too many facet.prefix clauses, too many fq filters, the combo of both, or what.  Anyway, here is the URL I start out
>  with:
>
> http://40.163.5.153:920/solr/browse?&fq=Gene_Ontology_Associations%3A%220%2Fbiological_process%28GO%3A0008150%29%22&fq=Gene_Ontology_Associations%3A%221%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%22&fq=Gene_Ontology_Associations%3A%222%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%22&fq=Gene_Ontology_Associations%3A%223%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29%22&fq=Mouse_Phenotype_Associations%3A%220%2Fmammalian+phenotype%28MP%3A0000001%29%22&fq=Mouse_Phenotype_Associations%3A%221%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%22&fq=Mouse_Phenotype_Associations%3A%222%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fme
> tabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%22&fq=Mouse_Phenotype_Associations%3A%223%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%22&fq=Mouse_Phenotype_Associations%3A%224%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%22&fq=Mouse_Phenotype_Associations%3A%225%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%22&fq=Mouse_Phenotype_Associations%3A%226%2Fm
> ammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%22&fq=Mouse_Phenotype_Associations%3A%227%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29%22&fq=BKL_Diagnostic_Marker_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=BKL_Molecular_Mechanism_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=
> BKL_Diagnostic_Marker_Associations%3A%221%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%22&q=&fq=BKL_Diagnostic_Marker_Associations:%222%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%3BAtherosclerosis%28MESH%3AD050197%29%22&f.Gene_Ontology_Associations.facet.prefix=4%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29&f.Mouse_Phenotype_Associations.facet.prefix=8%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29&a
> mp;f.BKL_Molecular_Mechanism_Associations.facet.prefix=1%2FCardiovascular+Diseases%28MESH%3AD002318%29
>
> The above works fine.  It's basically a bunch of fq= and facet.prefix= parameters.  However, if I add another parameter, shown below, then I will instantly get a totally blank page, and I can't get it to load anything no matter what.  (the parameter itself is fine since it works by itself or with fewer parameters)
>
> &f.BKL_Diagnostic_Marker_Associations.facet.prefix=3%2FCardiovascular+Diseases(MESH%3AD002318)%3BArteriosclerosis(MESH%3AD001161)%3BAtherosclerosis(MESH%3AD050197)
>
> Here's another interesting thing: if I just add the parameter field without any value, as in "&f.BKL_Diagnostic_Marker_Associations.facet.prefix=", then I will get a page of the result, but without any CSS rendering.
>
> Please advise what may be going on here.  Is my query simply too big?  Does Solr have a limit?  Did I break the limit?

Strange things happen when I query with many facet.prefixes and fq filters

Posted by Yuhao <nf...@yahoo.com>.
Hi,

I'm having issues when running the following query, which is produced by expanding several hierarchical facets (implemented the facet.prefix way).  I realize it's pretty massive, but I'd like to figure out what exactly is causing the problem.  Is it too many facet.prefix clauses, too many fq filters, the combo of both, or what.  Anyway, here is the URL I start out
 with:

http://40.163.5.153:920/solr/browse?&fq=Gene_Ontology_Associations%3A%220%2Fbiological_process%28GO%3A0008150%29%22&fq=Gene_Ontology_Associations%3A%221%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%22&fq=Gene_Ontology_Associations%3A%222%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%22&fq=Gene_Ontology_Associations%3A%223%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29%22&fq=Mouse_Phenotype_Associations%3A%220%2Fmammalian+phenotype%28MP%3A0000001%29%22&fq=Mouse_Phenotype_Associations%3A%221%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%22&fq=Mouse_Phenotype_Associations%3A%222%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fme
tabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%22&fq=Mouse_Phenotype_Associations%3A%223%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%22&fq=Mouse_Phenotype_Associations%3A%224%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%22&fq=Mouse_Phenotype_Associations%3A%225%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%22&fq=Mouse_Phenotype_Associations%3A%226%2Fm
ammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%22&fq=Mouse_Phenotype_Associations%3A%227%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29%22&fq=BKL_Diagnostic_Marker_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=BKL_Molecular_Mechanism_Associations%3A%220%2FCardiovascular+Diseases%28MESH%3AD002318%29%22&fq=
BKL_Diagnostic_Marker_Associations%3A%221%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%22&q=&fq=BKL_Diagnostic_Marker_Associations:%222%2FCardiovascular+Diseases%28MESH%3AD002318%29%3BArteriosclerosis%28MESH%3AD001161%29%3BAtherosclerosis%28MESH%3AD050197%29%22&f.Gene_Ontology_Associations.facet.prefix=4%2Fbiological_process%28GO%3A0008150%29%3Bmetabolic+process%28GO%3A0008152%29%3Bsteroid+metabolic+process%28GO%3A0008202%29%3Bcholesterol+metabolic+process%28GO%3A0008203%29&f.Mouse_Phenotype_Associations.facet.prefix=8%2Fmammalian+phenotype%28MP%3A0000001%29%3Bhomeostasis%2Fmetabolism+phenotype%28MP%3A0005376%29%3Babnormal+homeostasis%28MP%3A0001764%29%3Babnormal+lipid+homeostasis%28MP%3A0002118%29%3Babnormal+cholesterol+homeostasis%28MP%3A0005278%29%3Babnormal+cholesterol+level%28MP%3A0003947%29%3Bdecreased+cholesterol+level%28MP%3A0003983%29%3Bdecreased+liver+cholesterol+level%28MP%3A0010026%29&a
mp;f.BKL_Molecular_Mechanism_Associations.facet.prefix=1%2FCardiovascular+Diseases%28MESH%3AD002318%29

The above works fine.  It's basically a bunch of fq= and facet.prefix= parameters.  However, if I add another parameter, shown below, then I will instantly get a totally blank page, and I can't get it to load anything no matter what.  (the parameter itself is fine since it works by itself or with fewer parameters)

&f.BKL_Diagnostic_Marker_Associations.facet.prefix=3%2FCardiovascular+Diseases(MESH%3AD002318)%3BArteriosclerosis(MESH%3AD001161)%3BAtherosclerosis(MESH%3AD050197)

Here's another interesting thing: if I just add the parameter field without any value, as in "&f.BKL_Diagnostic_Marker_Associations.facet.prefix=", then I will get a page of the result, but without any CSS rendering.

Please advise what may be going on here.  Is my query simply too big?  Does Solr have a limit?  Did I break the limit?

Re: solr shards

Posted by ramin <do...@gmail.com>.
I think you nailed it, Hoss. What I did is I regenerated the indices and made
sure that they were inline with he schema definitions and it works perfectly
now.

One curious thing is that if there was a mismatch with the schema, why would
a direct query to one of the shards work just fine while the distributed
query would have only the document count but no document result set?

--
View this message in context: http://lucene.472066.n3.nabble.com/solr-shards-tp3691370p3707471.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: solr shards

Posted by Chris Hostetter <ho...@fucit.org>.
: Now in my case the indices are being built outside of Solr. So basically I
: create three sets of indices through Lucene API's. And at this point, I
: change the schema.xml and define the fields I have in these new indices. I

do you define a uniqueKey field in your schema.xml?  does that field 
actually exist in all of your documents? is it indexed? is it stored? is 
it actaully unique across all of your documents?

(these are things that Solr would normally take care of checking for you 
when indexing, but since you've bypassed Solr building these indexes you 
have to be more vigilent in checking these things -- you are in 
deep into "unsupported, experts only" territory)


-Hoss

Re: solr shards

Posted by ramin <do...@gmail.com>.
Sure. So it is really simple. Following the Solr example for setting up two
shards and pushing some xml docs to each one and then doing a distributed
query (http://wiki.apache.org/solr/DistributedSearch), it works perfectly.
Now in my case the indices are being built outside of Solr. So basically I
create three sets of indices through Lucene API's. And at this point, I
change the schema.xml and define the fields I have in these new indices. I
launch three Solr apps (say on ports 7573, 7574, 7575) and host these
indices under each of the instances. Now if I do a search on any of the Solr
apps separately:

curl
'http://localhost:757[345]/solr/select/?distrib=true&indent=on&q=content:solar'

I get results:

<lst name="responseHeader">
  <int name="status">0</int>
  <int name="QTime">59</int>
  <lst name="params">
    <str name="indent">on</str>
    <str name="distrib">true</str>
    <str name="q">content:solar</str>
  </lst>
</lst>
<result name="response" numFound="6776" start="0">
  <doc>
   ...
  </doc>
  <doc>
   ...
  </doc>
  ...
</result>
</response>

But when I issue the following GET:

curl
'http://localhost:7575/solr/select/?shards=localhost:7573/solr,localhost:7574/solr,localhost:7575/solr&distrib=true&indent=on&q=content:solar'

This is what I get:

<response>

<lst name="responseHeader">
  <int name="status">0</int>
  <int name="QTime">235</int>
  <lst name="params">
    <str name="q">content:solar</str>
    <str name="indent">on</str>
    <str
name="shards">localhost:7573/solr,localhost:7574/solr,localhost:7575/solr</str>
    <str name="distrib">true</str>
  </lst>
</lst>
<result name="response" numFound="20298" start="0"/>
</response>

As you can see the numFound says that there are documents but the documents
are not part of the response.

Now if I add "group.main=true&group=true&group.field=id" to the query
string, then I get an NPE:

<body>
HTTP ERROR 500

<p>Problem accessing /solr/select/. Reason:
<pre>    null

java.lang.NullPointerException
	at java.io.StringReader.&lt;init&gt;(StringReader.java:44)
	at org.apache.lucene.queryParser.QueryParser.parse(QueryParser.java:203)
	at org.apache.solr.search.LuceneQParser.parse(LuceneQParserPlugin.java:80)
	at org.apache.solr.search.QParser.getQuery(QParser.java:142)
	at
org.apache.solr.handler.component.QueryComponent.prepare(QueryComponent.java:101)
	at
org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:173)
	at
org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:129)
	at org.apache.solr.core.SolrCore.execute(SolrCore.java:1372)
	at
org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:356)
	at
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:252)
	at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
	at
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
	at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
	at
org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
	at
org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
	at org.mortbay.jetty.Server.handle(Server.java:326)
	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
	at
org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:928)
	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:549)
	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
	at
org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228)
	at
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
</pre></p><hr />/<small>Powered by Jetty://</small>/<br/>      

So, the only thing that is different between the Solr sample and mine is
that the indices have not been built through Solr itself but I believe that
is a moot point anyway (I might be wrong here). But the fact that the
individual queries to each instance do return the answer while the query
with shards does not is a mystery to me.

Thanks for the help.
Ramin


--
View this message in context: http://lucene.472066.n3.nabble.com/solr-shards-tp3691370p3694787.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: solr shards

Posted by Erick Erickson <er...@gmail.com>.
You need to provide the relevant bits of your configuration
file for anyone to help I think.... In particular the
sharding-relevant configurations.

Best
Erick

On Thu, Jan 26, 2012 at 11:29 AM, ramin <do...@gmail.com> wrote:
> Hello,
>
> I've gone through the list and have not found the answer but if it is a
> repetitive question, my apologies.
>
> I have a 3x shards solr cluster. If i send a query to each of the shards
> individually I get the result with a list of relevant docs. However, if i
> send the query to the main solr server (dispatcher) it only returns the
> value for numFound but there is no list of docs. Since i seem to be the only
> one having this issue, it is probably a misconfiguration for which i
> couldn't find an answer in the documentations. Can someone please help?
>
> Also, the sum of all the individual numFound's seems to not match the
> numFound I get from the main solr server, given that i do not have any
> duplicate on the unique key.
>
> Thanks in advance,
> Ramin
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/solr-shards-tp3691370p3691370.html
> Sent from the Solr - User mailing list archive at Nabble.com.