log4j2.properties 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. ################################################################################
  2. # Licensed to the Apache Software Foundation (ASF) under one
  3. # or more contributor license agreements. See the NOTICE file
  4. # distributed with this work for additional information
  5. # regarding copyright ownership. The ASF licenses this file
  6. # to you under the Apache License, Version 2.0 (the
  7. # "License"); you may not use this file except in compliance
  8. # with the License. You may obtain a copy of the License at
  9. #
  10. # http://www.apache.org/licenses/LICENSE-2.0
  11. #
  12. # Unless required by applicable law or agreed to in writing, software
  13. # distributed under the License is distributed on an "AS IS" BASIS,
  14. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  15. # See the License for the specific language governing permissions and
  16. # limitations under the License.
  17. ################################################################################
  18. property.file_path = ${sys:seatunnel.logs.path:-/tmp/seatunnel/logs}
  19. property.file_name = ${sys:seatunnel.logs.file_name:-seatunnel}
  20. property.file_split_size = 100MB
  21. property.file_count = 100
  22. property.file_ttl = 7d
  23. rootLogger.level = INFO
  24. logger.zeta.name=org.apache.seatunnel.engine
  25. logger.zeta.level=INFO
  26. logger.debezium.name=io.debezium.connector
  27. logger.debezium.level=WARN
  28. ############################ log output to console #############################
  29. #rootLogger.appenderRef.consoleStdout.ref = consoleStdoutAppender
  30. #rootLogger.appenderRef.consoleStderr.ref = consoleStderrAppender
  31. ############################ log output to console #############################
  32. ############################ log output to file #############################
  33. rootLogger.appenderRef.file.ref = fileAppender
  34. ############################ log output to file #############################
  35. appender.consoleStdout.name = consoleStdoutAppender
  36. appender.consoleStdout.type = CONSOLE
  37. appender.consoleStdout.target = SYSTEM_OUT
  38. appender.consoleStdout.layout.type = PatternLayout
  39. appender.consoleStdout.layout.pattern = %d{yyyy-MM-dd HH:mm:ss,SSS} %-5p %c - %m%n
  40. appender.consoleStdout.filter.acceptLtWarn.type = ThresholdFilter
  41. appender.consoleStdout.filter.acceptLtWarn.level = WARN
  42. appender.consoleStdout.filter.acceptLtWarn.onMatch = DENY
  43. appender.consoleStdout.filter.acceptLtWarn.onMismatch = ACCEPT
  44. appender.consoleStderr.name = consoleStderrAppender
  45. appender.consoleStderr.type = CONSOLE
  46. appender.consoleStderr.target = SYSTEM_ERR
  47. appender.consoleStderr.layout.type = PatternLayout
  48. appender.consoleStderr.layout.pattern = %d{yyyy-MM-dd HH:mm:ss,SSS} %-5p %c - %m%n
  49. appender.consoleStderr.filter.acceptGteWarn.type = ThresholdFilter
  50. appender.consoleStderr.filter.acceptGteWarn.level = WARN
  51. appender.consoleStderr.filter.acceptGteWarn.onMatch = ACCEPT
  52. appender.consoleStderr.filter.acceptGteWarn.onMismatch = DENY
  53. appender.file.name = fileAppender
  54. appender.file.type = RollingFile
  55. appender.file.fileName = ${file_path}/${file_name}.log
  56. appender.file.filePattern = ${file_path}/${file_name}.log.%d{yyyy-MM-dd}-%i
  57. appender.file.append = true
  58. appender.file.layout.type = PatternLayout
  59. appender.file.layout.pattern = %d{yyyy-MM-dd HH:mm:ss,SSS} %-5p %c - %m%n
  60. appender.file.policies.type = Policies
  61. appender.file.policies.time.type = TimeBasedTriggeringPolicy
  62. appender.file.policies.time.modulate = true
  63. appender.file.policies.size.type = SizeBasedTriggeringPolicy
  64. appender.file.policies.size.size = ${file_split_size}
  65. appender.file.strategy.type = DefaultRolloverStrategy
  66. appender.file.strategy.fileIndex = nomax
  67. appender.file.strategy.action.type = Delete
  68. appender.file.strategy.action.basepath = ${file_path}
  69. appender.file.strategy.action.maxDepth = 1
  70. appender.file.strategy.action.condition.type = IfFileName
  71. appender.file.strategy.action.condition.glob = ${file_name}.log*
  72. appender.file.strategy.action.condition.nested_condition.type = IfAny
  73. appender.file.strategy.action.condition.nested_condition.lastModify.type = IfLastModified
  74. appender.file.strategy.action.condition.nested_condition.lastModify.age = ${file_ttl}
  75. appender.file.strategy.action.condition.nested_condition.fileCount.type = IfAccumulatedFileCount
  76. appender.file.strategy.action.condition.nested_condition.fileCount.exceeds = ${file_count}