springboot配置文件Tomcat和mvc详细配置

tomcat相关配置参数 (ServerProperties)

server.port=8080

server.address= # bind to a specific NIC

server.session-timeout= # session timeout in seconds

server.context-path= # the context path, defaults to '/'

server.servlet-path= # the servlet path, defaults to '/'

server.tomcat.access-log-pattern= # log pattern of the access log

server.tomcat.access-log-enabled=false # is access logging enabled

server.tomcat.protocol-header=x-forwarded-proto # ssl forward headers

server.tomcat.remote-ip-header=x-forwarded-for

server.tomcat.basedir=/tmp # base dir (usually not needed, defaults to tmp)

server.tomcat.background-processor-delay=30; # in seconds

server.tomcat.max-threads = 0 # number of threads in protocol handler

server.tomcat.uri-encoding = UTF-8 # character encoding to use for URL decoding

springmvc相关配置参数 (HttpMapperProperties)

http.mappers.json-pretty-print=false # pretty print JSON

http.mappers.json-sort-keys=false # sort keys

spring.mvc.locale= # set fixed locale, e.g. en_UK

spring.mvc.date-format= # set fixed date format, e.g. dd/MM/yyyy

spring.mvc.message-codes-resolver-format= # PREFIX_ERROR_CODE / POSTFIX_ERROR_CODE

spring.view.prefix= # MVC view prefix

spring.view.suffix= # ... and suffix

spring.resources.cache-period= # cache timeouts in headers sent to browser

spring.resources.add-mappings=true # if default mappings should be added

相关推荐
狂团商城小师妹14 分钟前
JAVA国际版同城打车源码同城服务线下结账系统源码适配PAD支持Android+IOS+H5
android·java·ios·小程序·交友
m0_7369270418 分钟前
Java面试场景题及答案总结(2025版持续更新)
java·开发语言·后端·职场和发展
何中应22 分钟前
IDEA实用快捷键
java·ide·intellij-idea
lkbhua莱克瓦241 小时前
Java练习——正则表达式2
java·开发语言·笔记·正则表达式·github·学习方法
鬼火儿1 小时前
MySQL系列之数据类型(String)
java·后端
江湖人称小鱼哥1 小时前
Jenkins 在构建 Java 项目并操作 Docker 时 CPU 会突然飙高
java·docker·jenkins
Violet_YSWY1 小时前
Iterable<Result<Item>>讲一下
java
懒羊羊不懒@1 小时前
JavaSe—List集合系列
java·开发语言·数据结构·人工智能·windows
蓝-萧1 小时前
【Java】如何使用jdbc连接并操作MySQL,一文读
java·后端
qianbailiulimeng1 小时前
【MySQL】mysqldump使用方法
java·后端