Solr
  1. Solr
  2. SOLR-749

QParser and ValueSourceParser init bug

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.3
    • Fix Version/s: 1.3
    • Component/s: search
    • Labels:
      None

      Description

      As noticed by Maximilian Hütter in this email thread...

      http://www.nabble.com/SOLR-218-problem-to19266169.html#a19266169

      ...when a person tries to register a QParser (or ValueSourceParser) with the same name as a "standard" implementation it gets blown away by the initialization code for the standard impls.

      we need to allow people to override these standard names the same way they can with responseWriters, etc...

      1. SOLR-749.patch
        22 kB
        Grant Ingersoll
      2. SOLR-749.patch
        2 kB
        Hoss Man

        Activity

        Hide
        Hoss Man added a comment -

        To clarify: I think this a bug based on a quick skim of the code (i only caught the ValueSourceParser part because i greped for init(null)) but i'm not 100% certain. I'd appreciate some verification from someone else.

        Assuming i'm right, here's a quick patch (untested)

        Show
        Hoss Man added a comment - To clarify: I think this a bug based on a quick skim of the code (i only caught the ValueSourceParser part because i greped for init(null)) but i'm not 100% certain. I'd appreciate some verification from someone else. Assuming i'm right, here's a quick patch (untested)
        Hide
        Yonik Seeley added a comment -

        So... standard plugins are only created/registered if it's name doesn't already exist. The logic seems fine, but I haven't tested it either

        Show
        Yonik Seeley added a comment - So... standard plugins are only created/registered if it's name doesn't already exist. The logic seems fine, but I haven't tested it either
        Hide
        Grant Ingersoll added a comment -

        I think we need a test case for this.

        Show
        Grant Ingersoll added a comment - I think we need a test case for this.
        Hide
        Grant Ingersoll added a comment -

        Hoss's patch plus unit tests

        Show
        Grant Ingersoll added a comment - Hoss's patch plus unit tests
        Hide
        Grant Ingersoll added a comment -

        Committed on trunk and on branch-1.3

        Show
        Grant Ingersoll added a comment - Committed on trunk and on branch-1.3

          People

          • Assignee:
            Grant Ingersoll
            Reporter:
            Hoss Man
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development