Details

    • Type: New Feature New Feature
    • Status: Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 4.9, master
    • Component/s: Schema and Analysis
    • Labels:
      None

      Description

      There is some use cases that require to extend SchemaField objects with "attributes" or "properties".
      For example, I would like to be able to assign a specific "term mapping file" for each of my field. Each field name will have a "mapping file" associated that I can access at query time using the IndexSchema object.

      The FieldType object already enables the addition of attributes. However, these attributes are "local" to a field type, not a field definition. Multiple fields can have the same field types, which is not suitable for our use cases.
      One possible solution will be to create one field type per field definition, but this is more a dirty hack: it means duplicating field types, making them more difficult to maintain.

      References to mailing list discussion:
      http://www.mail-archive.com/solr-user@lucene.apache.org/msg40436.html
      http://www.mail-archive.com/solr-user@lucene.apache.org/msg40585.html

        Issue Links

          Activity

          Renaud Delbru created issue -
          Hide
          Hoss Man added a comment -

          Note: the crux of the issue isn't particularly that "SchemaField" needs to be extensible in a java sense – it's primarily that FieldType subclasses should be able to declare properties that can be specified in the corresponding <field /> declarations by some means.

          As i mentioned on the mailing list...

          > something that is intended to be customized -- while FieldType
          > objects are constructed once at startup, SchemaField obejcts are
          > frequently created on the fly when dealing with dynamicFields, so
          > initialization complexity is kept to a minimum.
          > 
          > That said -- this definitely seems like that type of usecase that we
          > should try to find *some* solution for -- even if it just means having
          > Solr automaticly create hidden FieldType instances for you on startup
          > based on attributes specified in the<field />  that the corrisponding
          > FieldType class understands.
          
          Show
          Hoss Man added a comment - Note: the crux of the issue isn't particularly that "SchemaField" needs to be extensible in a java sense – it's primarily that FieldType subclasses should be able to declare properties that can be specified in the corresponding <field /> declarations by some means. As i mentioned on the mailing list... > something that is intended to be customized -- while FieldType > objects are constructed once at startup, SchemaField obejcts are > frequently created on the fly when dealing with dynamicFields, so > initialization complexity is kept to a minimum. > > That said -- this definitely seems like that type of usecase that we > should try to find *some* solution for -- even if it just means having > Solr automaticly create hidden FieldType instances for you on startup > based on attributes specified in the<field /> that the corrisponding > FieldType class understands.
          Mark Miller made changes -
          Field Original Value New Value
          Fix Version/s 4.0 [ 12314992 ]
          Fix Version/s 3.1 [ 12314371 ]
          Hoss Man made changes -
          Link This issue relates to SOLR-1664 [ SOLR-1664 ]
          Robert Muir made changes -
          Fix Version/s 4.1 [ 12321141 ]
          Fix Version/s 4.0 [ 12314992 ]
          Mark Miller made changes -
          Fix Version/s 4.2 [ 12323893 ]
          Fix Version/s 5.0 [ 12321664 ]
          Fix Version/s 4.1 [ 12321141 ]
          Robert Muir made changes -
          Fix Version/s 4.3 [ 12324128 ]
          Fix Version/s 5.0 [ 12321664 ]
          Fix Version/s 4.2 [ 12323893 ]
          Uwe Schindler made changes -
          Fix Version/s 4.4 [ 12324324 ]
          Fix Version/s 4.3 [ 12324128 ]
          Hide
          Steve Rowe added a comment -

          Bulk move 4.4 issues to 4.5 and 5.0

          Show
          Steve Rowe added a comment - Bulk move 4.4 issues to 4.5 and 5.0
          Steve Rowe made changes -
          Fix Version/s 5.0 [ 12321664 ]
          Fix Version/s 4.5 [ 12324743 ]
          Fix Version/s 4.4 [ 12324324 ]
          Adrien Grand made changes -
          Fix Version/s 4.6 [ 12325000 ]
          Fix Version/s 5.0 [ 12321664 ]
          Fix Version/s 4.5 [ 12324743 ]
          Uwe Schindler made changes -
          Fix Version/s 4.7 [ 12325573 ]
          Fix Version/s 4.6 [ 12325000 ]
          David Smiley made changes -
          Fix Version/s 4.8 [ 12326254 ]
          Fix Version/s 4.7 [ 12325573 ]
          Hide
          Uwe Schindler added a comment -

          Move issue to Solr 4.9.

          Show
          Uwe Schindler added a comment - Move issue to Solr 4.9.
          Uwe Schindler made changes -
          Fix Version/s 4.9 [ 12326731 ]
          Fix Version/s 5.0 [ 12321664 ]
          Fix Version/s 4.8 [ 12326254 ]

            People

            • Assignee:
              Unassigned
              Reporter:
              Renaud Delbru
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Development