Skip to content

Commit

Permalink
HBASE-27762 Include EventType and ProcedureV2 pid in logging via MDC …
Browse files Browse the repository at this point in the history
…(addendum)

Make use of `%notEmpty` pattern with MDC logging. Will function as expected once we upgrade to
Log4J 2.21.0+.
  • Loading branch information
ndimiduk committed May 1, 2023
1 parent da81079 commit b776c12
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion conf/log4j2.properties
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ appender.console.type = Console
appender.console.target = SYSTEM_ERR
appender.console.name = console
appender.console.layout.type = PatternLayout
appender.console.layout.pattern = %d{ISO8601} %-5p [%t (%X)] %c{2}: %.1000m%n
appender.console.layout.pattern = %d{ISO8601} %-5p [%t%notEmpty{ %X}] %c{2}: %.1000m%n

# Daily Rolling File Appender
appender.DRFA.type = RollingFile
Expand Down
2 changes: 1 addition & 1 deletion hbase-logging/src/test/resources/log4j2.properties
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ appender.console.target = SYSTEM_ERR
appender.console.name = Console
appender.console.maxSize = 1G
appender.console.layout.type = PatternLayout
appender.console.layout.pattern = %d{ISO8601} %-5p [%t (%X)] %C{2}(%L): %m%n
appender.console.layout.pattern = %d{ISO8601} %-5p [%t%notEmpty{ %X}] %C{2}(%L): %m%n

rootLogger = INFO,Console

Expand Down

0 comments on commit b776c12

Please sign in to comment.