June 2018
Intermediate to advanced
408 pages
11h 23m
English
We can enable asynchronous processing by simply adding @EnableAsync to a configuration class, as follows:
@Configuration@EnableAsyncpublic class AppConfig { @Bean public AsyncTask asyncTask() { return new AsyncTask(); }}
In the previous code, we have not provided TaskExecutor as a bean, so Spring will use a default SimpleAsyncTaskExecutor implicitly.
Read now
Unlock full access