Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8180428

Clarify implementation note in Clock.java to match implementation changes made by JDK-8068730

    Details

    • Subcomponent:
    • Resolved In Build:
      b172
    • Verification:
      Not verified

      Backports

        Description

        In JDK 9, the implementation of Clock has been improved to be better
        than millisecond in most cases. However, the Javadoc of the "Implementation Note" is now wrong. It says:

        "The clock implementation provided here is based on
        System.currentTimeMillis(). That method provides little to no
        guarantee about the accuracy of the clock. Applications requiring a
        more accurate clock must implement this abstract class themselves
        using a different external clock, such as an NTP server."

        This needs to be updated to match the changes to the implementation.
        Suggested replacement text:

        "The clock implementation provided here is based on the same
        underlying clock as System.currentTimeMillis(), but may have a
        precision finer than milliseconds if available. However, little to no
        guarantee is provided about the accuracy of the underlying clock.
        Applications requiring a more accurate clock must implement this
        abstract class themselves using a different external clock, such
         as an NTP server."

          Issue Links

            Activity

            Show
            dfuchs Daniel Fuchs added a comment - See also: http://mail.openjdk.java.net/pipermail/core-libs-dev/2017-May/047671.html
            Hide
            hgupdate HG Updates added a comment -
            URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/82ab8dec02ae
            User: dfuchs
            Date: 2017-05-23 10:37:29 +0000
            Show
            hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/82ab8dec02ae User: dfuchs Date: 2017-05-23 10:37:29 +0000
            Hide
            hgupdate HG Updates added a comment -
            URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/82ab8dec02ae
            User: lana
            Date: 2017-05-31 20:16:38 +0000
            Show
            hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/82ab8dec02ae User: lana Date: 2017-05-31 20:16:38 +0000

              People

              • Assignee:
                dfuchs Daniel Fuchs
                Reporter:
                dfuchs Daniel Fuchs
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: