Solr
  1. Solr
  2. SOLR-2690

Date Math should allow clients to override timezone used for rounding (faceting & queries)

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0-ALPHA
    • Component/s: None
    • Labels:
      None

      Description

      Timezone needs to be taken into account when doing date math. Currently it isn't. DateMathParser instances created are always being constructed with UTC. This is a huge issue when it comes to faceting. Depending on your timezone day-light-savings changes the length of a month. A facet gap of +1MONTH is different depending on the timezone and the time of the year.

      I believe the issue is very simple to fix. There are three places in the code DateMathParser is created. All three are configured with the timezone being UTC. If a user could specify the TimeZone to pass into DateMathParser this faceting issue would be resolved.

      1. SOLR-2690.patch
        25 kB
        Hoss Man
      2. SOLR-2690.patch
        16 kB
        Hoss Man
      3. SOLR-2690.patch
        7 kB
        Hoss Man
      4. add-tz-parameter.patch
        10 kB
        David Schlotfeldt
      5. add-tz-parameter.patch
        10 kB
        David Schlotfeldt
      6. timezone-facet-component.tgz
        13 kB
        Shotaro Kamio

        Issue Links

          Activity

            People

            • Assignee:
              Hoss Man
              Reporter:
              David Schlotfeldt
            • Votes:
              3 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 3h
                3h
                Remaining:
                Remaining Estimate - 3h
                3h
                Logged:
                Time Spent - Not Specified
                Not Specified

                  Development