前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >SpringBoot 2.x中英文配置详解

SpringBoot 2.x中英文配置详解

作者头像
小柒2012
发布2019-12-09 16:32:28
6630
发布2019-12-09 16:32:28
举报
文章被收录于专栏:IT笔记IT笔记IT笔记

此示例文件作为指导提供。请勿将其全部内容复制到您自己的应用程序中。^^^

英文配置

# ===================================================================
# COMMON SPRING BOOT PROPERTIES
#
# This sample file is provided as a guideline. Do NOT copy it in its
# entirety to your own application.               ^^^
# ===================================================================


# ----------------------------------------
# CORE PROPERTIES
# ----------------------------------------
debug=false # Enable debug logs.
trace=false # Enable trace logs.

# LOGGING
logging.config= # Location of the logging configuration file. For instance, `classpath:logback.xml` for Logback.
logging.exception-conversion-word=%wEx # Conversion word used when logging exceptions.
logging.file= # Log file name (for instance, `myapp.log`). Names can be an exact location or relative to the current directory.
logging.file.max-history=0 # Maximum of archive log files to keep. Only supported with the default logback setup.
logging.file.max-size=10MB # Maximum log file size. Only supported with the default logback setup.
logging.level.*= # Log levels severity mapping. For instance, `logging.level.org.springframework=DEBUG`.
logging.path= # Location of the log file. For instance, `/var/log`.
logging.pattern.console= # Appender pattern for output to the console. Supported only with the default Logback setup.
logging.pattern.dateformat=yyyy-MM-dd HH:mm:ss.SSS # Appender pattern for log date format. Supported only with the default Logback setup.
logging.pattern.file= # Appender pattern for output to a file. Supported only with the default Logback setup.
logging.pattern.level=%5p # Appender pattern for log level. Supported only with the default Logback setup.
logging.register-shutdown-hook=false # Register a shutdown hook for the logging system when it is initialized.

中文配置

#================================================= ================== 
#COMMON SPRING BOOT PROPERTIES 

#---------------------------------------- 
#核心属性
#----- ----------------------------------- 
debug = false #启用调试日志。
trace = false #启用跟踪日志。

#LOGGING 
logging.config = #日志配置文件的位置。例如,Logback的`classpath:logback.xml`。
logging.exception-conversion-word =%wEx #记录异常时使用的转换字。
logging.file = #日志文件名(例如`myapp.log`)。名称可以是确切的位置或相对于当前目录。
logging.file.max-history = 0 #要保留的归档日志文件的最大数量。仅支持默认的登录设置。
logging.file.max-size = 10MB #最大日志文件大小。仅支持默认的登录设置。
logging.level。* =#日志级别严重性映射。例如`logging.level.org.springframework = DEBUG`。
logging.path = #日志文件的位置。例如,`/ var / log`。
logging.pattern.console = #输出到控制台的Appender模式。仅使用默认的Logback设置支持。
logging.pattern.dateformat = yyyy-MM-dd HH:mm:ss.SSS #日志格式的Appender模式。仅使用默认的Logback设置支持。
logging.pattern.file = #输出到文件的Appender模式。仅使用默认的Logback设置支持。
logging.pattern.level =%5p #日志级别的Appender模式。仅使用默认的Logback设置支持。
logging.register-shutdown-hook = false #为日志记录系统初始化时注册一个关闭钩子。

附件下载:SpringBoot 2.x中英文配置详解.zip

本文参与 腾讯云自媒体分享计划,分享自作者个人站点/博客。
原始发表:2018-04-11,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体分享计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • 英文配置
  • 中文配置
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档