Solr
  1. Solr
  2. SOLR-6267

Let user override Interval Faceting key with LocalParams

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.10
    • Component/s: None
    • Labels:
      None

      Description

      This issue is related to Interval Faceting, being worked at SOLR-6216. Right now they key of each interval is the string of the interval as entered in the request. For example:

      [*,20)
      [20,40)
      [40,*]
      

      would output something like

      "facet_intervals":{
            "size":{
              "[*,20)":3,
              "[20,40)":4,
              "[40,*]":9}}
      

      It would be good to be able to override the "key" per interval using local params, for example:

      {!key='small'}[*,20)
      {!key='medium'}[20,40)
      {!key='large'}[40,*]
      

      Would output:

      "facet_intervals":{
            "size":{
              "small":3,
              "medium":4,
              "large":9}}
      
      1. SOLR-6267.patch
        15 kB
        Tomás Fernández Löbbe

        Issue Links

          Activity

          Transition Time In Source Status Execution Times Last Executer Last Execution Date
          Open Open Resolved Resolved
          2d 5h 51m 1 Erick Erickson 25/Jul/14 00:51
          Tomás Fernández Löbbe made changes -
          Description This issue is related to Interval Faceting, being worked at SOLR-6216. Right now they key of each interval is the string of the interval as entered in the request. For example:
          {noformat}
          [*,20)
          [20,40)
          [40,*]
          {noformat}
          would output something like
          {noformat}
          "facet_intervals":{
                "size":{
                  "[*,20)":3,
                  "[20,40)":4,
                  "[40,*]":9}}
          {noformat}
          It would be good to be able to override the "key" per interval using local params, for example:
          {noformat}
          {!key='small'}[,20)
          {!key='medium'}[20,40)
          {!key='large'}[40,]
          {noformat}
          Would output:
          {noformat}
          "facet_intervals":{
                "size":{
                  "small":3,
                  "medium":4,
                  "large":9}}
          {noformat}
          This issue is related to Interval Faceting, being worked at SOLR-6216. Right now they key of each interval is the string of the interval as entered in the request. For example:
          {noformat}
          [*,20)
          [20,40)
          [40,*]
          {noformat}
          would output something like
          {noformat}
          "facet_intervals":{
                "size":{
                  "[*,20)":3,
                  "[20,40)":4,
                  "[40,*]":9}}
          {noformat}
          It would be good to be able to override the "key" per interval using local params, for example:
          {noformat}
          {!key='small'}[*,20)
          {!key='medium'}[20,40)
          {!key='large'}[40,*]
          {noformat}
          Would output:
          {noformat}
          "facet_intervals":{
                "size":{
                  "small":3,
                  "medium":4,
                  "large":9}}
          {noformat}
          Erick Erickson made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Fix Version/s 4.10 [ 12327122 ]
          Resolution Fixed [ 1 ]
          Hide
          Erick Erickson added a comment -

          Thanks Tomás!

          Show
          Erick Erickson added a comment - Thanks Tomás!
          Hide
          ASF subversion and git services added a comment -

          Commit 1613333 from Erick Erickson in branch 'dev/branches/branch_4x'
          [ https://svn.apache.org/r1613333 ]

          SOLR-6267: Let user override Interval Faceting key with LocalParams. Thanks Tomas

          Show
          ASF subversion and git services added a comment - Commit 1613333 from Erick Erickson in branch 'dev/branches/branch_4x' [ https://svn.apache.org/r1613333 ] SOLR-6267 : Let user override Interval Faceting key with LocalParams. Thanks Tomas
          Hide
          ASF subversion and git services added a comment -

          Commit 1613308 from Erick Erickson in branch 'dev/trunk'
          [ https://svn.apache.org/r1613308 ]

          SOLR-6267: Let user override Interval Faceting key with LocalParams. Thanks Tomas

          Show
          ASF subversion and git services added a comment - Commit 1613308 from Erick Erickson in branch 'dev/trunk' [ https://svn.apache.org/r1613308 ] SOLR-6267 : Let user override Interval Faceting key with LocalParams. Thanks Tomas
          Erick Erickson made changes -
          Assignee Erick Erickson [ erickerickson ]
          Tomás Fernández Löbbe made changes -
          Attachment SOLR-6267.patch [ 12657282 ]
          Hide
          Tomás Fernández Löbbe added a comment - - edited

          Added LocalParam parsing and some tests. This patch assumes the patch in SOLR-6216 committed to trunk.

          Show
          Tomás Fernández Löbbe added a comment - - edited Added LocalParam parsing and some tests. This patch assumes the patch in SOLR-6216 committed to trunk.
          Tomás Fernández Löbbe made changes -
          Field Original Value New Value
          Link This issue depends upon SOLR-6216 [ SOLR-6216 ]
          Tomás Fernández Löbbe created issue -

            People

            • Assignee:
              Erick Erickson
              Reporter:
              Tomás Fernández Löbbe
            • Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development