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

Logger.inferCaller() should use Throwable.getStackTrace()

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P3 P3
    • None
    • 1.4.0
    • core-libs
    • None
    • generic
    • generic

      It appears that Logger.inferCaller should be able to use Throwable.getStackTrace
      to infer caller stack information. There is a comment in the code which says:

              // This is an initial implementation.
              // We may get VM support later.

      It seems that Throwable.getStackTrace is the VM support for which this code was
      waiting.

      Using getStackTrace should be more robust and efficient than printing stack
      trace ouput to a byte array output stream.

            ghamiltosunw Graham Hamilton (Inactive)
            ldorninsunw Laird Dornin (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: