Skip to content

Mask one single field and select/unselect the other fields #639

Answered by philsttr
cleverton-heusner asked this question in Q&A
Discussion options

You must be logged in to vote

You can use MaskingJsonGeneratorDecorator with LoggingEventCompositeJsonEncoder...

<springProfile name="prod">
    <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
        <encoder class="net.logstash.logback.encoder.LoggingEventCompositeJsonEncoder">
            <providers>
                <version/>
                <logLevel/>
                <loggerName/>
                <pattern>
                    <pattern>
                        {
                            "timestamp": "%d{yyyy-MM-dd'T'HH:mm:ss.SSSZZ}",
                            "appName": "${appName}"
                        }
                    </pattern>
                </pattern>
                <threa…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by philsttr
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
type/question a question (should be converted to discussion)
2 participants
Converted from issue

This discussion was converted from issue #628 on September 09, 2021 02:11.