I would like to use @Scheduled to perform some initialization tasks in background.
The syntax is inspired by @reboot in crontab.
21557
WDYT?
Comment From: simonbasle
This PR has been around for a long time, sorry for coming back to it only now.
We think that the application event listeners feature makes more sense than @Scheduled here, especially given the fact that @start is a new concept (not a standard cron expression) that is "made up" to shoehorn that usecase into @Scheduled.
@EventListener with the @Async annotation would be a good candidate, with the ContextRefreshedEvent event.
In Spring Boot, you also have the ApplicationStartupEvent special application event.