Pou*_*leh 2 java http http-protocols spring-boot
我将在我的 Spring Boot 应用程序中以 json 格式发送大约 500 万条记录的数组。有没有办法增加http请求超时以防止连接超时?
对于“默认容器”,这将是:
server.tomcat.connection-timeout
弹簧靴属性。
在本例中(JSON 主体),还:
server.tomcat.max-swallow-size
听起来很重要。
还相关:
server.tomcat.keep-alive-timeout
// Time to wait for another HTTP request before the connection is closed. When not set the connectionTimeout is used. When set to -1 there will be no timeout.
Run Code Online (Sandbox Code Playgroud)
有可能:
server.tomcat.max-connections
Run Code Online (Sandbox Code Playgroud)
和:
server.tomcat.max-keep-alive-requests
Run Code Online (Sandbox Code Playgroud)
对于其他/反应式容器最好:在链接站点中搜索“超时”:)