title: Spring Async ThreadPoolTaskScheduler not initialized
body: <p>I'm trying to use Async annotation in Spring but I'm getting </p>
  
  <pre><code>java.lang.IllegalStateException: ThreadPoolTaskScheduler not initialized
  </code></pre>
  
  <p>error, when I try to run the method marked as Async. The following is the configuration for Async:</p>
  
  <pre><code>@EnableScheduling
  @EnableAsync
  @Configuration 
  public class SchedulingConfiguration implements AsyncConfigurer{
  
      @Override
      public Executor getAsyncExecutor() {
          ThreadPoolTaskScheduler scheduler = new ThreadPoolTaskScheduler();
          scheduler.setPoolSize(10);
          return scheduler;
      }
  
  }
  </code></pre>
  
  <p>and the following is the declaration of async method.</p>
  
  <pre><code>@Async
  @Transactional(value = "baseTransactionManager", isolation = Isolation.READ_COMMITTED)
  public void foo(Bar bar) {// some code here}
  </code></pre>
  
  <p>What am I missing in here?</p>
  
  <p>Thanks in advance.</p>