Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
8136db69
Commit
8136db69
authored
Jan 07, 2019
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '2.1.x'
parents
5e736c0d
d4992777
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
1 deletion
+14
-1
spring-boot-features.adoc
...ing-boot-docs/src/main/asciidoc/spring-boot-features.adoc
+14
-1
No files found.
spring-boot-project/spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc
View file @
8136db69
...
@@ -6361,11 +6361,24 @@ in a similar manner, as shown in the following example:
...
@@ -6361,11 +6361,24 @@ in a similar manner, as shown in the following example:
[[boot-features-task-execution-scheduling]]
[[boot-features-task-execution-scheduling]]
== Task Execution and Scheduling
== Task Execution and Scheduling
In the absence of a
`Task
Executor` bean in the context, Spring Boot auto-configures a
In the absence of a
n `
Executor` bean in the context, Spring Boot auto-configures a
`ThreadPoolTaskExecutor` with sensible defaults that can be automatically associated to
`ThreadPoolTaskExecutor` with sensible defaults that can be automatically associated to
asynchronous task execution (`@EnableAsync`) and Spring MVC asynchronous request
asynchronous task execution (`@EnableAsync`) and Spring MVC asynchronous request
processing.
processing.
[TIP]
====
If you have defined a custom `Executor` in the context, regular task execution (i.e.
`@EnableAsync`) will use it transparently but the Spring MVC support will not be
configured as it requires an `AsyncTaskExecutor` implementation (named
`applicationTaskExecutor`). Depending on your target arrangement, you could change your
`Executor` into a `ThreadPoolTaskExecutor` or define both a `ThreadPoolTaskExecutor` and
an `AsyncConfigurer` wrapping your custom `Executor`.
The auto-configured `TaskExecutorBuilder` allows you to easily create instances that
reproduces what the auto-configuration does by default.
====
The thread pool uses 8 core threads that can grow and shrink according to the load. Those
The thread pool uses 8 core threads that can grow and shrink according to the load. Those
default settings can be fine-tuned using the `spring.task.execution` namespace as shown in
default settings can be fine-tuned using the `spring.task.execution` namespace as shown in
the following example:
the following example:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment