Skip to content
Advertisement

Tag: scheduled-tasks

Do I need synchronize method Scheduled method?

I have a Spring schedulled tasks which calls the same private method. Do I need to sync this method? Will I have the problem if shedulled tasks runned in the same time? Or will be better to extract it to the prototype component or separate schedulled classes or something else? Answer The default ThreadPoolTaskScheduler used by the @Scheduled annotation is,

Advertisement