Menu

#101 Use SLF4J for logging.

SMC 7.3.0
closed
logging (1)
5
2021-11-11
2017-01-24
No

Hello,
This is an idea for a feature: logging through SFL4J (https://www.slf4j.org/) instead of sysout/syserr. This is the standard logging facade that many open source libraries rely onto and would enable to debug the programm in non-trivial use case. For example, I run my app somewhere I don't have access to syserr/sysout and rely on a real logger. When I need to debug machine specific problems, I'm stuck.
As a bonus, you could remove the ctx.setDebugFlag methods and rely on the logger's configuration.

By the way, is there any plan to use and deploy smc to Maven central ? I may help if there is any interest doing so.

Discussion

  • Charles Rapp

    Charles Rapp - 2017-02-22

    I agree with this idea for the statemap.jar code. But instead of SLF4J, I suggest that java.util.logging be used since that come is part of the JVM and can be integrated with SLF4J. My reason is that I do not want developers to be forced into using a 3rd party API in order to use SMC.

     
  • Francois MAROT

    Francois MAROT - 2017-02-22

    You're totally right: java.util.logging (JUL) should be enough and I understand the need to avoid 3rd party dependencies.

     
  • Charles Rapp

    Charles Rapp - 2021-09-30
    • summary: Use SLF4J for login --> Use SLF4J for logging.
    • status: open --> accepted
    • assigned_to: Charles Rapp
    • Group: -->
     
  • Charles Rapp

    Charles Rapp - 2021-09-30
    • Group: --> SMC 7.3.0
     
  • Charles Rapp

    Charles Rapp - 2021-11-11
    • status: accepted --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB