Uploaded image for project: 'Spigot'
  1. Spigot
  2. SPIGOT-3388

Spigot thread consumes 100% CPU when using log4j2 configuration

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Minor Minor
    • None
    • None

      When invoking spigot using a log4j2 configuration file (-Dlog4j.configurationFile=/path/to/file), one of its threads will always consume 100% CPU, even when the server is idle.

      The contents of the logging configuration file don't seem to matter. This problem occurs using a normal config file with various appenders and loggers as well as an empty config.

      When I remove the log4j property from invocation the problem does not happen.

      The vanilla 1.12 minecraft server is not affected by this problem. Log4j works as expected without consuming extra CPU when using vanilla.

      I am using spigot with all of the default configurations in place and no plugins added.

      It may also be worth noting spigot also goes to 100% on one thread when I use systemd to manage spigot directly (no screen or tmux). If I use both systemd and a log4j2 config file, 2 threads will jump to 100% use. I'm not entirely sure if this is related or not.

            Unassigned Unassigned
            3dB Adam Sebzda
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: