Commons Logging
  1. Commons Logging
  2. LOGGING-83

[logging] Enhance error message for " org.apache.commons.logging.impl.Log4JLogger does not implement Log"

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0.3
    • Fix Version/s: 1.0.4
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

      Description

      After moving from struts1.0 to struts1.1 I got the same error message as in the
      above mailing list discussion thread.

      Couldn't the error message contain the names of the two jar files?
      Even better if it hinted on what to do or provided a link to an explanation page!

      http://jakarta.apache.org/commons/logging/userguide.html#Configuring%20the%20Logger%20Implementation
      didn't really provide any help?

      So shall I remove the
      -rwxr-xr-x 1 root root 218864 Dec 2 15:37 WEB-INF/lib/log4j.jar
      or the
      rw-rr- 1 root root 31605 Dec 2 16:05
      WEB-INF/lib/commons-logging.jar

      Since all went well with log4j so far and the file is bigger, I am inclined to
      dump commons-logging.jar.
      On the other hand, since I am a new user of commons-dbcp-1.1.jar, that one may
      rely on its own logger - so perhaps I will run into trouble due to that?
      Anyway, help would be highly appreciated!

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Resolved Resolved Closed Closed
        1490d 14h 51m 1 Henri Yandell 02/Jan/08 07:48
        Dennis Lundberg made changes -
        Fix Version/s 1.0.4 [ 12311713 ]
        Henri Yandell made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Dennis Lundberg made changes -
        Affects Version/s 1.0 Beta 1 [ 12311817 ]
        Bugzilla Id 25156
        Affects Version/s 1.0.3 [ 12311839 ]
        Henri Yandell made changes -
        Affects Version/s 1.0 Beta 1 [ 12311817 ]
        Henri Yandell made changes -
        Affects Version/s 1.0 Beta 1 [ 12311649 ]
        Key COM-984 LOGGING-83
        Assignee Jakarta Commons Developers Mailing List [ commons-dev@jakarta.apache.org ]
        Project Commons [ 12310458 ] Commons Logging [ 12310484 ]
        Component/s Logging [ 12311124 ]
        Henri Yandell made changes -
        Field Original Value New Value
        issue.field.bugzillaimportkey 25156 12341135
        Hide
        Craig McClanahan added a comment -

        I've improved the error message in the (fairly common) case where the user has
        org.apache.commons.logging.Log available more than once in the class loading
        hierarchy.

        For the expected configuration when using commons logging inside Tomcat, you
        should consult the Tomcat documentation, but I've had no problems with the
        standard way that Tomcat packages things (commons-logging-api.jar in common/lib,
        no logging libraries in my webapp, put log4j.jar in commons/lib if I want to use
        it).

        Show
        Craig McClanahan added a comment - I've improved the error message in the (fairly common) case where the user has org.apache.commons.logging.Log available more than once in the class loading hierarchy. For the expected configuration when using commons logging inside Tomcat, you should consult the Tomcat documentation, but I've had no problems with the standard way that Tomcat packages things (commons-logging-api.jar in common/lib, no logging libraries in my webapp, put log4j.jar in commons/lib if I want to use it).
        Hide
        Ralf Hauser added a comment -

        removed commons-logging.jar, left tomcat1.27/commons/lib/commons-logging-api.jar

        and now it works again - no clue whether this is a recommendable setup or not???

        Show
        Ralf Hauser added a comment - removed commons-logging.jar, left tomcat1.27/commons/lib/commons-logging-api.jar and now it works again - no clue whether this is a recommendable setup or not???
        Ralf Hauser created issue -

          People

          • Assignee:
            Unassigned
            Reporter:
            Ralf Hauser
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development