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

new field type - EnumField

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 4.6, 6.0
    • None
    • None

    Description

      We have encountered a use case in our system where we have a few fields (Severity. Risk etc) with a closed set of values, where the sort order for these values is pre-determined but not lexicographic (Critical is higher than High). Generically this is very close to how enums work.

      To implement, I have prototyped a new type of field: EnumField where the inputs are a closed predefined set of strings in a special configuration file (similar to currency.xml).

      The code is based on 4.2.1.

      Attachments

        1. enumsConfig.xml
          0.5 kB
          Elran Dvir
        2. schema_example.xml
          52 kB
          Elran Dvir
        3. Solr-5084.patch
          43 kB
          Elran Dvir
        4. Solr-5084.patch
          35 kB
          Elran Dvir
        5. Solr-5084.patch
          42 kB
          Elran Dvir
        6. Solr-5084.patch
          101 kB
          Elran Dvir
        7. Solr-5084.trunk.patch
          49 kB
          Erick Erickson
        8. Solr-5084.trunk.patch
          49 kB
          Erick Erickson
        9. Solr-5084.trunk.patch
          44 kB
          Elran Dvir
        10. Solr-5084.trunk.patch
          43 kB
          Erick Erickson
        11. Solr-5084.trunk.patch
          43 kB
          Elran Dvir
        12. Solr-5084.trunk.patch
          40 kB
          Erick Erickson
        13. Solr-5084.trunk.patch
          40 kB
          Elran Dvir
        14. Solr-5084.trunk.patch
          40 kB
          Elran Dvir
        15. Solr-5084.trunk.patch
          42 kB
          Elran Dvir

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            erickerickson Erick Erickson
            elrand Elran Dvir
            Votes:
            1 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment