lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Smiley (Commented) (JIRA)" <>
Subject [jira] [Commented] (SOLR-435) QParser must validate existance/absense of "q" parameter
Date Wed, 21 Mar 2012 21:00:42 GMT


David Smiley commented on SOLR-435:

I've always thought it was bad that Solr throws an error if 'q' is not specified, and it can
be a "WTF" experience to new users unfamiliar with this.  I am aware that dismax has q.alt
but that's separate.  What's wrong with assuming a match-all docs query of *:*?  It's better
than an error, IMO.

FYI aside from seeing this from time to time in my own Solr work, the Ajax-Solr framework
has a work-around to basically automatically supply q or q.alt with '*:*' in different circumstances,
and it's quite a hack.  You can argue the user should explicitly supply *:* but then if they
forget, they get a Solr error.
> 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
>             Fix For: 3.6, 4.0
> 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