title: Bean starts with the application server, and run method every 10 seconds
body: <p>I need to create a bean that allows to clean a database. So that it runs at server startup and every 10 seconds (for example).</p>
  
  <p>How can I handle it?</p>
  
  <p>EDIT:</p>
  
  <p>I've tried with @Startup, @Singleton and @Schedule annotation but it doesn't start.</p>