Coder Social home page Coder Social logo

Comments (3)

enapps-enorman avatar enapps-enorman commented on August 26, 2024

Hi @ceki

Checking back in again since we haven't gotten any feedback on the PR since it was proposed 4 months ago.

We would appreciate a review of this proposal if you (or someone else) has the time. Knowing if this proposal will be accepted or not will help us decide how to move forward.

Thanks

from logback.

ceki avatar ceki commented on August 26, 2024

Hi @enapps-enorman,

Thank you for this PR. I imagine that the suppliers would need to be created by the OSGi platform or the application itself.
How/when will these suppliers be created?

How do you intend to inject the suppliers into logback? You would need hooks in logback itself but these seem to be missing in the PR.

from logback.

enapps-enorman avatar enapps-enorman commented on August 26, 2024

Hi @ceki

Thanks for your response. This proposal was to resolve a problem discovered during work to migrate existing code from older slf4j(1.x)+logback(1.2.x) versions to the latest releases and the refactoring needed to deal with everything that had changed. For your reference, that pending PR remains at: apache/sling-org-apache-sling-commons-log#18

Thank you for this PR. I imagine that the suppliers would need to be created by the OSGi platform or the application itself. How/when will these suppliers be created?

Yes, our use case does involve some significant customization of the logback init logic for modularization. This was to support supplying the log config more dynamically based on which OSGi configuration+bundles are active in the application runtime.

For your reference, those logback integration customization details are described briefly in the documentation at: https://sling.apache.org/documentation/development/logging.html#logback-integration

How do you intend to inject the suppliers into logback? You would need hooks in logback itself but these seem to be missing in the PR.

The custom logging init code basically has a custom factory for various PatternLayout objects that programmatically populates the instance converter supplier map with the supplier lambda expressions. This output "masking" code was written by someone else and I believe the purpose was to mask certain characters in the output for https://issues.apache.org/jira/browse/SLING-11393

For your reference, the following is the method (from a pending PR) that customizes the PatternLayout with the suppliers:
https://github.com/enapps-enorman/sling-org-apache-sling-commons-log/blob/issue/SLING-11906/src/main/java/org/apache/sling/commons/log/logback/internal/MaskingMessageUtil.java#L53

Does that make sense?

from logback.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.