Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-2249

The module-info of org.apache.logging.log4j miss some directive 'uses'

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Duplicate
    • Affects Version/s: 2.10.0
    • Fix Version/s: 2.11.0
    • Component/s: None
    • Labels:
      None

      Description

      Hi !
      using Log4J with no configuration file doesn't work in a full module environment,
      i get the following stacktrace because the module-info.java does not contain the directive  `uses org.apache.logging.log4j.util.PropertySource`.

      This is a showstopper for us

      java.util.ServiceConfigurationError: org.apache.logging.log4j.util.PropertySource: module org.apache.logging.log4j does not declare `uses`
          at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:588)
          at java.base/java.util.ServiceLoader.checkCaller(ServiceLoader.java:574)
          at java.base/java.util.ServiceLoader.<init>(ServiceLoader.java:503)
          at java.base/java.util.ServiceLoader.load(ServiceLoader.java:1684)
          at org.apache.logging.log4j/org.apache.logging.log4j.util.PropertiesUtil$Environment.<init>(PropertiesUtil.java:319)
          at org.apache.logging.log4j/org.apache.logging.log4j.util.PropertiesUtil$Environment.<init>(PropertiesUtil.java:310)
          at org.apache.logging.log4j/org.apache.logging.log4j.util.PropertiesUtil.<init>(PropertiesUtil.java:69)
          at org.apache.logging.log4j/org.apache.logging.log4j.util.PropertiesUtil.<clinit>(PropertiesUtil.java:49)
          at com.github.forax.beautifullogger/com.github.forax.beautifullogger.Log4JTests.<clinit>(Log4JTests.java:15)

      regards,
      Rémi

       

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                rgoers Ralph Goers
                Reporter:
                forax remi forax
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: