title: @RestController with StreamingResponseBody async.request-timeout not working
body: <p>I'm trying to get a StreamingResponseBody from a @RestController on a long running job.  It times out after 30 seconds, no matter what configuration I try.</p>
  
  <p>This is in Spring Boot 2.0.3.
  I've used the below test which shows the same behavior to try and get the configuration correct.</p>
  
  <pre><code>@RestController
  public class TestController {
  
      @RequestMapping("/streamtest")
      public StreamingResponseBody handleRequest () {
          return new StreamingResponseBody() {
              @Override
              public void writeTo (OutputStream out) throws IOException {
                  for (int i = 0; i &lt; 100000; i++) {
                      out.write((Integer.toString(i) + " - ").getBytes());
                      out.flush();
                      try {
                          Thread.sleep(500);
                      } catch (InterruptedException e) {
                          e.printStackTrace();
                      }
                  }
              }
         };
     }
  }
  </code></pre>
  
  <p>I've tried the async.request-timeout setting defined here;
  <a href="https://stackoverflow.com/questions/42877498/async-timeout-downloading-a-large-file-using-streamingresponsebody-on-spring-boo#comment92771233_43496244">Async timeout downloading a large file using StreamingResponseBody on Spring Boot</a></p>
  
  <p>I've tried overriding WebMvcConfig to set the timeout.  This method is never called.</p>
  
  <pre><code>@EnableWebMvc
  @Configuration
  public class WebMvcConfig implements WebMvcConfigurer {
  
      @Override
      public void configureAsyncSupport(AsyncSupportConfigurer configurer) {
          configurer.setDefaultTimeout(3600000);
          WebMvcConfigurer.super.configureAsyncSupport(configurer);
      }
  }
  </code></pre>
  
  <p>I've tried defining the ThreadPoolTaskExecutor:</p>
  
  <pre><code>@Configuration
  @EnableAsync
  @EnableScheduling
  public class AsyncConfig implements AsyncConfigurer {
  
      @Override
      public Executor getAsyncExecutor() {
          return new ThreadPoolTaskExecutor();
      }
  }
  </code></pre>
  
  <p>It always times out after 30 seconds with a log;</p>
  
  <pre><code>12:14:28.028 [http-nio-8080-exec-2] DEBUG c.b.b.bof_static.config.BofStaticExceptionHandler - Async timeout for GET [/streamtest]
  12:14:28.028 [http-nio-8080-exec-2] DEBUG org.springframework.web.servlet.DispatcherServlet - Null ModelAndView returned to DispatcherServlet with name 'dispatcherServlet': assuming HandlerAdapter completed request handling
  12:14:28.028 [http-nio-8080-exec-2] DEBUG org.springframework.web.servlet.DispatcherServlet - Successfully completed request
  12:14:28.030 [http-nio-8080-exec-2] DEBUG o.s.security.web.access.ExceptionTranslationFilter - Chain processed normally
  </code></pre>
  
  <p>I'm unable to find any other solutions.  Can anyone point out what's missing?</p>