request.startAsync()不支持异步操作

Servlet3.0使用异步处理时,后台报错:

java.lang.IllegalStateException: A filter or servlet of the current chain does not support asynchronous operations.

必须在一个请求所涉及到的Servlet和Filter中声明asyncSupported=true

如果web.xml配置了Servlet和Filter也要添加<async-supported>true</async-supported>。比如web.xml配置了UrlRewriteFilter等

 

posted @ 2015-08-18 00:02  Lorence Zhang  阅读(2261)  评论(0编辑  收藏  举报