Solr
  1. Solr
  2. SOLR-5905

CollapsingQParserPlugin throws a NPE if required 'field' param is missing

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 4.7, 6.0
    • Fix Version/s: 4.7.1, 6.0
    • Component/s: query parsers
    • Labels:
      None

      Description

      A NullPointerException is thrown if the required 'field' param is missing (in the hashCode method). This might confuse the users if they forget or misspell it.

      1. SOLR-5905.patch
        2 kB
        Spyros Kapnissis

        Activity

        Hide
        Spyros Kapnissis added a comment -

        A simple patch to handle this case.

        Show
        Spyros Kapnissis added a comment - A simple patch to handle this case.
        Hide
        ASF subversion and git services added a comment -

        Commit 1581234 from shalin@apache.org in branch 'dev/trunk'
        [ https://svn.apache.org/r1581234 ]

        SOLR-5905: CollapsingQParserPlugin throws a NPE if required 'field' param is missing

        Show
        ASF subversion and git services added a comment - Commit 1581234 from shalin@apache.org in branch 'dev/trunk' [ https://svn.apache.org/r1581234 ] SOLR-5905 : CollapsingQParserPlugin throws a NPE if required 'field' param is missing
        Hide
        ASF subversion and git services added a comment -

        Commit 1581236 from shalin@apache.org in branch 'dev/trunk'
        [ https://svn.apache.org/r1581236 ]

        SOLR-5905: Changed IllegalStateException to a SolrException

        Show
        ASF subversion and git services added a comment - Commit 1581236 from shalin@apache.org in branch 'dev/trunk' [ https://svn.apache.org/r1581236 ] SOLR-5905 : Changed IllegalStateException to a SolrException
        Hide
        ASF subversion and git services added a comment -

        Commit 1581237 from shalin@apache.org in branch 'dev/branches/branch_4x'
        [ https://svn.apache.org/r1581237 ]

        SOLR-5905: CollapsingQParserPlugin throws a NPE if required 'field' param is missing

        Show
        ASF subversion and git services added a comment - Commit 1581237 from shalin@apache.org in branch 'dev/branches/branch_4x' [ https://svn.apache.org/r1581237 ] SOLR-5905 : CollapsingQParserPlugin throws a NPE if required 'field' param is missing
        Hide
        ASF subversion and git services added a comment -

        Commit 1581238 from shalin@apache.org in branch 'dev/branches/lucene_solr_4_7'
        [ https://svn.apache.org/r1581238 ]

        SOLR-5905: CollapsingQParserPlugin throws a NPE if required 'field' param is missing

        Show
        ASF subversion and git services added a comment - Commit 1581238 from shalin@apache.org in branch 'dev/branches/lucene_solr_4_7' [ https://svn.apache.org/r1581238 ] SOLR-5905 : CollapsingQParserPlugin throws a NPE if required 'field' param is missing
        Hide
        Shalin Shekhar Mangar added a comment -

        I changed the IllegalStateException to a SolrException with a bad request status to be in line with what we do in other places.

        This fix will be available in 4.7.1. Thanks Spyros!

        Show
        Shalin Shekhar Mangar added a comment - I changed the IllegalStateException to a SolrException with a bad request status to be in line with what we do in other places. This fix will be available in 4.7.1. Thanks Spyros!
        Hide
        Steve Rowe added a comment -

        Bulk close 4.7.1 issues

        Show
        Steve Rowe added a comment - Bulk close 4.7.1 issues

          People

          • Assignee:
            Shalin Shekhar Mangar
            Reporter:
            Spyros Kapnissis
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development