[jira] [Updated] (SOLR-435) QParser must validate existence/absence of "q" parameter

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[jira] [Updated] (SOLR-435) QParser must validate existence/absence of "q" parameter

Sebastian Nagel (Jira)

     [ https://issues.apache.org/jira/browse/SOLR-435?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

David Smiley updated SOLR-435:

    Attachment: SOLR-2001_3x_backport_with_empty_string_check_and_test.patch

Attached is my 3x port of SOLR-2001.  Modifications:
* I added your test Hoss
* Added empty string check
* Added a Javadoc on QParser.parse() to indicate null may be returned
* Added support for DisMaxQParser

I'd like to commit this tonight to 3x, and commit the differences it has with trunk to trunk.

Is a CHANGES.txt necessary?

> QParser must validate existence/absence of "q" parameter
> --------------------------------------------------------
>                 Key: SOLR-435
>                 URL: https://issues.apache.org/jira/browse/SOLR-435
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 1.3
>            Reporter: Ryan McKinley
>            Assignee: David Smiley
>             Fix For: 3.6, 4.0
>         Attachments: SOLR-2001_3x_backport_with_empty_string_check_and_test.patch, SOLR-435.patch, SOLR-435_3x_consistent_errors.patch, SOLR-435_q_defaults_to_all-docs.patch
> Each QParser should check if "q" exists or not.  For some it will be required others not.
> currently it throws a null pointer:
> {code}
> java.lang.NullPointerException
> at org.apache.solr.common.util.StrUtils.splitSmart(StrUtils.java:36)
> at org.apache.solr.search.OldLuceneQParser.parse(LuceneQParserPlugin.java:104)
> at org.apache.solr.search.QParser.getQuery(QParser.java:80)
> at org.apache.solr.handler.component.QueryComponent.prepare(QueryComponent.java:67)
> at org.apache.solr.handler.SearchHandler.handleRequestBody(SearchHandler.java:150)
>         ...
> {code}
> see:
> http://www.nabble.com/query-parsing-error-to14124285.html#a14140108

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]