lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Male (Commented) (JIRA)" <>
Subject [jira] [Commented] (SOLR-435) QParser must validate existance/absense of "q" parameter
Date Sat, 24 Mar 2012 04:33:23 GMT


Chris Male commented on SOLR-435:

You're absolutely right.  

I can see the advantages of having QParser's accept a generic String that they need to parse,
whether it be the main query string or a filter query.  But in that case I don't think QParser's
should also be trying to find the query string themselves in certain cases (such as ExtendedDisMaxQParser
trying q.alt as an alternative source of a query string).  QParsers are not required to respect
what the QueryComponent gives them, so you can specify whatever you like in 'q' or 'fq' and
QParser can totally ignore it.

It just feels a little messy and confusing because wherever the query string identification
occurs is where the validation should occur too, right?

> QParser must validate existance/absense of "q" parameter
> --------------------------------------------------------
>                 Key: SOLR-435
>                 URL:
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.3
>            Reporter: Ryan McKinley
>            Assignee: Ryan McKinley
>             Fix For: 3.6, 4.0
>         Attachments: SOLR-435_q_defaults_to_all-docs.patch
> Each QParser should check if "q" exists or not.  For some it will be required others
> currently it throws a null pointer:
> {code}
> java.lang.NullPointerException
> 	at org.apache.solr.common.util.StrUtils.splitSmart(
> 	at
> 	at
> 	at org.apache.solr.handler.component.QueryComponent.prepare(
> 	at org.apache.solr.handler.SearchHandler.handleRequestBody(
>         ...
> {code}
> see:

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message