Skip to content

build: remove logback.xml from release jar #82

@theborakompanioni

Description

@theborakompanioni

The current jar includes a logback configuration file.

If a downstream consumer also defines a logback.xml, logback will complain about it on stdout, which makes cln killing the plugin. This happens even with <root level="OFF"> and no console appender defined.

11:19:14,443 |-INFO in LoggerContext[default] - Found resource [logback.xml] at [file:/home/user/workspace/tapplication/build/resources/main/logback.xml]
11:19:14,443 |-WARN in LoggerContext[default] - Resource [logback.xml] occurs multiple times on the classpath.
11:19:14,444 |-WARN in LoggerContext[default] - Resource [logback.xml] occurs at [jar:file:/home/user/workspace/application/libs/jrpclightning-0.2.4-SNAPSHOT.jar!/logback.xml]
11:19:14,444 |-WARN in LoggerContext[default] - Resource [logback.xml] occurs at [file:/home/user/workspace/application/build/resources/main/logback.xml]

Context: https://stackoverflow.com/questions/3401051/suppress-all-logback-output-to-console
Also: https://mailman.qos.ch/pipermail/logback-user/2010-August/001717.html

Logback only outputs its status messages when there is a warning or error - in this case Logback thinks that you have two logback.xml files on the classpath.

An additional side effect is that a clightning4j dir is created in the users home directory.
Would it be possible to exclude the logback.xml file in the release builds?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions