You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2023/03/07 19:40:00 UTC

[jira] [Commented] (MNG-7724) Slf4jConfigurationFactory should use info level when there is no exception and the logger type is unknown

    [ https://issues.apache.org/jira/browse/MNG-7724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17697610#comment-17697610 ] 

ASF GitHub Bot commented on MNG-7724:
-------------------------------------

rmannibucau opened a new pull request, #1041:
URL: https://github.com/apache/maven/pull/1041

   Following this checklist to help us incorporate your
   contribution quickly and easily:
   
    - [X] Make sure there is a [JIRA issue](https://issues.apache.org/jira/browse/MNG) filed
          for the change (usually before you start working on it).  Trivial changes like typos do not
          require a JIRA issue. Your pull request should address just this issue, without
          pulling in other changes.
    - [X] Each commit in the pull request should have a meaningful subject line and body.
    - [X] Format the pull request title like `[MNG-XXX] SUMMARY`,
          where you replace `MNG-XXX` and `SUMMARY` with the appropriate JIRA issue.
    - [X] Also format the first line of the commit message like `[MNG-XXX] SUMMARY`.
          Best practice is to use the JIRA issue title in both the pull request title and in the first line of the commit message.
    - [X] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
    - [X] Run `mvn clean verify` to make sure basic checks pass. A more thorough check will
          be performed on your pull request automatically.
    - [ ] You have run the [Core IT][core-its] successfully.
   
   [core-its]: https://maven.apache.org/core-its/core-it-suite/
   
   
   The issue with current code is that using a SLF4J binding which is not known by maven will lead to WARNINGs.
   There are several builds which intend to run without warning or consider warnings as error and therefore fail - not using maven CLI options but other mecanism - either log analyzis on CI, the old way with appenders/handlers or stdout/stderr check if the handlers support the redirection properly.
   This behavior defeats a bit using a logger abstraction since the support is pretty limited.
   The idea is to keep the message - we can refine it later if relevant - but log it at info level to not make the build failling when there is no issue loading the impl maven should use and keep warning when a loading failed (we can evaluate the move to error later too for this case).




> Slf4jConfigurationFactory should use info level when there is no exception and the logger type is unknown
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-7724
>                 URL: https://issues.apache.org/jira/browse/MNG-7724
>             Project: Maven
>          Issue Type: Improvement
>    Affects Versions: 4.0.0-alpha-4
>            Reporter: Romain Manni-Bucau
>            Priority: Minor
>
> As of now if we change the SLF4J bindings maven will issue warnings because a few features are disabled but due to the nature of switching these bindings it is highly likely it is intended and therefore the warning are misleading more than helping.
> The solution can be to log a warning if a configured factory fails to load but just log info when it succeeds.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)