Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8245302 Upgrade LogRecord to support long thread ids and remove its usage of ThreadLocal
  3. JDK-8247877

Release Note: java.util.logging.LogRecord Updated to Support Long Thread IDs

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Delivered
    • Icon: P3 P3
    • 16
    • 16
    • core-libs

      In this release, `java.util.logging.LogRecord` has been updated to support long thread ids.

      `LogRecord::getThreadID` and `LogRecord::setThreadID` are deprecated. New accessors, `LogRecord::getLongThreadID` and `LogRecord::setLongThreadID`, are provided and should be used instead.

      The serial field `threadID` has been deprecated and a new serial field `longThreadID` that can support long values has been introduced. The deprecated `threadID` field is kept in the serial form for backward compatibility. Long thread ids that are less than `Integer.MAX_VALUE` are directly mapped to `threadID` and `longThreadID` has the same value. For `longThreadID` greater than Integer.MAX_VALUE, a new negative value for the `int` `threadID` is synthesized by using a deterministic algorithm based on the `longThreadID` hash. The resulting value is guaranteed to be a negative value.

            ryadav Rahul Yadav
            ryadav Rahul Yadav
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: