title: SpringBoot @Scheduled doesn't work
body: <p>I have a very simple web application for testing the @Scheduled annotation.
  The method <strong>read()</strong> in the class RetrievePrices  is annotated with @Scheduled . After deploying the war on Tomcat, I was expecting that the read method should be executed every 5 seconds, but nothing is displayed in the Tomcat console.</p>
  
  <p>The Main SpringBoot class</p>
  
  <pre><code>package com.aaaa.main;
  
  import org.springframework.batch.core.configuration.annotation.EnableBatchProcessing;
  import org.springframework.boot.SpringApplication;
  import org.springframework.boot.autoconfigure.SpringBootApplication;
  import org.springframework.scheduling.annotation.EnableScheduling;
  
  @SpringBootApplication
  public class BatchMain {
  
      public static void main(String[] args) {
  
          SpringApplication.run(BatchMain.class, args);
      }
  
  }
  </code></pre>
  
  <p>The Class whith a method annotated with @Scheduled</p>
  
  <pre><code>package com.aaaa.schedule;
  
  import org.springframework.scheduling.annotation.Scheduled;
  
  public class RetrievePrices {
  
      @Scheduled(fixedRate = 5000)
      public void read() {
  
          System.out.println(" *************  Scheduled(fixedRate = 5000) ");
  }
  </code></pre>
  
  <p>A very simple Spring Configuration Class</p>
  
  <pre><code>package com.aaaa.config;
  
  @Configuration
  @ComponentScan("com.aaaa")
  @EnableScheduling
  public class MyConfiguration {
  }
  </code></pre>
  
  <p>The POM</p>
  
  <pre><code>&lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
      &lt;parent&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
          &lt;version&gt;1.5.10.RELEASE&lt;/version&gt;
      &lt;/parent&gt;
      &lt;artifactId&gt;batch&lt;/artifactId&gt;
      &lt;name&gt;Batch processes&lt;/name&gt;
      &lt;packaging&gt;war&lt;/packaging&gt;
  
      &lt;properties&gt;
          &lt;java.version&gt;1.8&lt;/java.version&gt;
          &lt;Postgres.version&gt;9.4-1200-jdbc41&lt;/Postgres.version&gt;
      &lt;/properties&gt;
  
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
              &lt;scope&gt;provided&lt;/scope&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-batch&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-devtools&lt;/artifactId&gt;
              &lt;optional&gt;true&lt;/optional&gt;
          &lt;/dependency&gt;
  
      &lt;/dependencies&gt;
  
      &lt;build&gt;
          &lt;plugins&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
                  &lt;artifactId&gt;spring-boot-maven-plugin&lt;/artifactId&gt;
              &lt;/plugin&gt;
          &lt;/plugins&gt;
      &lt;/build&gt;    
  &lt;/project&gt;
  </code></pre>
  
  <p>The updated class RetrievePrices </p>
  
  <pre><code>package com.aaaa.schedule;
  
  import javax.annotation.PostConstruct;
  
  import org.springframework.scheduling.annotation.Scheduled;
  import org.springframework.stereotype.Component;
  
  @Component
  public class RetrievePrices {
  
      @Scheduled(fixedRate = 5000)
      public void read() {
  
          System.out.println(" *************  into @Scheduled(fixedRate = 5000) ");
      }
  
      @PostConstruct
      public void postConstruct() {
          System.out.println(" *************  postConstruct ************** ");
      }
  }
  </code></pre>