解决方法:
spring:
mvc:
async:
request-timeout: 3600000
主要原因:
响应太慢。
Exception to be thrown when an async request times out. Alternatively an applications can register a
DeferredResultProcessingInterceptor
or aCallableProcessingInterceptor
to handle the timeout through the MVC Java config or the MVC XML namespace or directly through properties of theRequestMappingHandlerAdapter
.By default the exception will be handled as a 503 error.
参考:Class AsyncRequestTimeoutException
spring.mvc.async.request-timeout
Amount of time before asynchronous request handling times out. If this value is not set, the default timeout of the underlying implementation is used.
参考:spring.mvc.async.request-timeout
设定async请求的超时时间,以毫秒为单位,如果没有设置的话,以具体实现的超时时间为准,比如tomcat的servlet3的话是10秒.