See gh-37393
This commit is contained in:
Johnny Lim
2023-09-15 00:50:04 +09:00
committed by Andy Wilkinson
parent 8599f8ecfc
commit 8f4ccb0535
5 changed files with 24 additions and 37 deletions

View File

@@ -36,7 +36,7 @@ Those default settings can be fine-tuned using the `spring.task.execution` names
This changes the thread pool to use a bounded queue so that when the queue is full (100 tasks), the thread pool increases to maximum 16 threads.
Shrinking of the pool is more aggressive as threads are reclaimed when they are idle for 10 seconds (rather than 60 seconds by default).
A scheduler can also be auto-configured if need to be associated to scheduled task execution (using `@EnableScheduling` for instance).
A scheduler can also be auto-configured if it needs to be associated with scheduled task execution (using `@EnableScheduling` for instance).
When virtual threads are enabled (using Java 21+ and configprop:spring.threads.virtual.enabled[] set to `true`) this will be a `SimpleAsyncTaskScheduler` that uses virtual threads.
Otherwise, it will be a `ThreadPoolTaskScheduler` with sensible defaults.