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

java.time.ZoneId.systemDefault() should be faster

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 9
    • Component/s: core-libs
    • Labels:
    • Subcomponent:
    • Introduced In Version:
      8
    • Resolved In Build:
      b66

      Backports

        Description

        Obtaining default system ZoneId is a frequent call. It should have as little overhead as possible. This call is implemented as: TimeZone.getDefault().toZoneId(), so the opportunity is to cache the instance inside default TimeZone instance.

          Issue Links

            Activity

            plevart Peter Levart created issue -
            Show
            plevart Peter Levart added a comment - This is a proposed patch: http://cr.openjdk.java.net/~plevart/jdk9-dev/ZoneId.systemDefault/webrev.03/
            dfuchs Daniel Fuchs made changes -
            Field Original Value New Value
            Link This issue relates to JDK-8074023 [ JDK-8074023 ]
            hgupdate HG Updates made changes -
            Status New [ 10000 ] Open [ 1 ]
            Hide
            hgupdate HG Updates added a comment -
            URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/fafc39e9a46a
            User: plevart
            Date: 2015-05-17 17:20:33 +0000
            Show
            hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/dev/jdk/rev/fafc39e9a46a User: plevart Date: 2015-05-17 17:20:33 +0000
            hgupdate HG Updates made changes -
            Status Open [ 1 ] Resolved [ 5 ]
            Resolved In Build team [ 17324 ]
            Fix Version/s 9 [ 14949 ]
            Resolution Fixed [ 1 ]
            rriggs Roger Riggs made changes -
            Labels noreg-sqe
            Hide
            hgupdate HG Updates added a comment -
            URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/fafc39e9a46a
            User: lana
            Date: 2015-05-27 18:31:20 +0000
            Show
            hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/fafc39e9a46a User: lana Date: 2015-05-27 18:31:20 +0000
            hgupdate HG Updates made changes -
            Resolved In Build team [ 17324 ] master [ 18256 ]
            hgupdate HG Updates made changes -
            Resolved In Build master [ 18256 ] b66 [ 17580 ]
            hgupdate HG Updates made changes -
            Link This issue backported by JDK-8084932 [ JDK-8084932 ]

              People

              • Assignee:
                plevart Peter Levart
                Reporter:
                plevart Peter Levart
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: