Closed
Description
Silvio Assunção Junior opened SPR-17587 and commented
The issue #17470 was not resolved, the problem continue
I checked the code of ScheduledAnnotationBeanPostProcessor and the tasks will registered on method postProcessAfterInitialization, but lazy Beans it is not created or initialized, than Beans with @Scheduled
and @Lazy
does not work correctly
The Schedule will be registered only if I will use the Bean (Force a creation)
Other guys with the same problem https://stackoverflow.com/questions/47585846/why-spring-schedule-do-not-work-with-lazy
Affects: 4.3.18
Reference URL: #17470
Issue Links:
- @Scheduled methods in @Lazy beans are not scheduled [SPR-12872] #17470
@Scheduled
methods in@Lazy
beans are not scheduled