Hi, is it possible to handle multiple requests at the same time?
If I execute the following example I see that the requests are queued and not processed in parallel.
Code:@Controller @RequestMapping("/foo") public class TestController { @RequestMapping(value = "/bar", method = RequestMethod.GET) public void test() throws Exception { Syso("Sync"); Thread.sleep(60 * 1000); } }How to make it async?Code:<?xml version="1.0" encoding="UTF-8"?> <web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" version="3.0"> <servlet> <servlet-name>springapp</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>springapp</servlet-name> <url-pattern>/*</url-pattern> </servlet-mapping> </web-app>
Requerements:
* Spring 3.2 is ok
* Tomcat 7 is ok
Best Regards,
Christian.


Reply With Quote
