Uploaded image for project: 'Phoenix'
  1. Phoenix
  2. PHOENIX-6792

FastDateFormat cannot parse greater than milisecond precision.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 5.2.0
    • None
    • core
    • None

    Description

      While working on PHOENIX-5066, I found that FastDateFormat is incapable of handling greater than milisecond precision.

      We're using the format string: "yyyy-MM-dd HH:mm:ss.SSS", but we want to parse nanosecond resolution timestamp strings like "2020-01-01 13:30:00.123456789"

      Strictly speaking FastDateFormat works as documented, as it interprets 123456789 as miliseconds, and sets miliseconds to "789", and adds "123456" seconds to the date.

      However, this is clearly not the intended behaviour.

      We either need to add some format-dependent heuristics, or drop FastDateFormat usage.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              stoty Istvan Toth
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: