Commons Logging
  1. Commons Logging
  2. LOGGING-10

SimpleLog uses getSystemResourceAsStream to load props

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0
    • Fix Version/s: 1.0.1
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

      Description

      The Log implementation, SimpleLog, uses getSystemResourceAsStream() to load the
      simplelog.properties file. Using getSystemResourceAsStream(), instead of something like
      this.getClass().getClassLoader().getResourceAsStream(), or even better,
      Thread.currentThread().getContextClassLoader().getResourceAsStream(), prevents the
      properties file from being deployed with an application. This forces the developer to put the
      properties file on the system classpath.

      Why was the decision made to only look on at the
      system classloader? The LogFactory does a nice job of finding it's properties with
      findClassLoader(). A similar implementation for SimpleLog would be great.

        Activity

          People

          • Assignee:
            Unassigned
            Reporter:
            John Rousseau
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development