previous next TOC
Log4j vs. JSR47

  • Sun has recently completed a community process, named JSR47, that defines a logging API for Java.
  • The table below compares the two APIs.

    log4j JSR 47 API
    Availability since early 1999 scheduled for 2Q 2001
    Required JDK 1.1 or above 1.4 or above
    Authorship actual users closed committee
    License Apache Public License Sun Community Source License
    configuration order
    order independent order independent
    (as of spec. version 0.75)
    Support for API extensions pervasive none
    Appender inheritance cumulative cumulative (as of spec. version 0.75)
    Support for object rendering yes no
    Configuration file formats XML and key=value formats key=value format only with very limited syntax
    Support for ErrorHandlers yes yes (as of version 0.75)
    Filter logic à la Linux ipchains boolean
    Part of JDK no yes

Log4j is extremely popular and being currently used in thousands of projects worldwide.


For up to date and detailed log4j documentation directly from the developer please consider The complete log4j manual.