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

logging: inferring caller information should be done lazily

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P3 P3
    • 1.4.0
    • 1.4.0
    • core-libs
    • None
    • beta3
    • x86
    • windows_nt
    • Verified

      This RFE is based on beta feedback.

      Right now in JSR-047, if a logging methods is not given
      an explicit source method name and class name as arguments,
      then after passing its initial level based filter tests,
      the Logger "eagerly" locates the caller method and class by
      walking over the call stack.

      However, in many cases the information may not be used, so
      this is potentially a significant unnecessary cost.

      Instead, the stack walk should be done lazily, when someone
      first asks for the value. Thus if no one downstream from the
      Logger wants to use the methodname/classname, you don't pay
      the cost of the stack walk.


      graham.hamilton@Eng 2001-08-01

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

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: