Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-2719

REGRESSION ReturnFields incorrect parse fields with hyphen - breaks existing "fl=my-field-name" type usecases

    XMLWordPrintableJSON

Details

    Description

      fl=my-hyphen-field in query params parsed as "my" instead of "my-hyphen-field".

      OAS.search.ReturnFields use method getId() from OAS.search.QueryParsing
      in which check chars "if (!Character.isJavaIdentifierPart(ch) && ch != '.')"
      Hyphen is not JavaIdentifierPart and this check break when first "-" is found.

      This problem solve by passing '-' to check:
      if (!Character.isJavaIdentifierPart(ch) && ch != '.' && ch != '-') break;

      But I don't know how it can affect on whole project.

      Attachments

        1. SOLR-2719.patch
          10 kB
          Luca Cavanna
        2. SOLR-2719.patch
          12 kB
          Luca Cavanna
        3. SOLR-2719.patch
          1 kB
          Yonik Seeley

        Issue Links

          Activity

            People

              yseeley@gmail.com Yonik Seeley
              sharky Nik V. Babichev
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: