Class AuthenticatedUserConverter

java.lang.Object
org.apache.logging.log4j.core.pattern.AbstractPatternConverter
org.apache.logging.log4j.core.pattern.LogEventPatternConverter
com.flowable.platform.common.logging.log4j2.AuthenticatedUserConverter
All Implemented Interfaces:
org.apache.logging.log4j.core.pattern.PatternConverter

@Plugin(name="AuthenticatedUserConverter", category="Converter") public class AuthenticatedUserConverter extends org.apache.logging.log4j.core.pattern.LogEventPatternConverter
A Log4J 2 converter that can be used to output the currently authenticated user. It can be used by using %authenticatedUser in the log pattern. When used in a pattern the rules that apply to pattern layout as defined in the Log4J 2 Documentation apply to this as well.

When there is no user then <missing> will be used.

Author:
Filip Hrisafov
  • Field Summary

    Fields inherited from class org.apache.logging.log4j.core.pattern.AbstractPatternConverter

    LOGGER

    Fields inherited from interface org.apache.logging.log4j.core.pattern.PatternConverter

    CATEGORY
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    format(org.apache.logging.log4j.core.LogEvent event, StringBuilder toAppendTo)
     
    newInstance(String[] options)
     

    Methods inherited from class org.apache.logging.log4j.core.pattern.LogEventPatternConverter

    format, handlesThrowable, isVariable

    Methods inherited from class org.apache.logging.log4j.core.pattern.AbstractPatternConverter

    getName, getStyleClass

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • newInstance

      public static AuthenticatedUserConverter newInstance(String[] options)
    • format

      public void format(org.apache.logging.log4j.core.LogEvent event, StringBuilder toAppendTo)
      Specified by:
      format in class org.apache.logging.log4j.core.pattern.LogEventPatternConverter