You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
AsyncAnnotationBeanPostProcessor could find TaskExecutor by type/name [SPR-13248] #17839
Along the lines of #17827, AsyncAnnotationBeanPostProcessor could find a TaskExecutor bean by type and/or name in the context, avoiding the need to implement AsyncConfigurer for that purpose.
This turns out to be easy enough, so I've rolled it in for 4.2 GA still.
Note that we search for a TaskExecutor bean... not a plain Executor since that would match with ScheduledExecutorService as well, which is unusable for our purposes here. TaskExecutor is more clearly designed for it and clearly differentiated from scheduler types. And we fall back to a bean named "taskExecutor", if any, along the lines of #17827.
Activity
spring-projects-issues commentedon Jul 17, 2015
Juergen Hoeller commented
This turns out to be easy enough, so I've rolled it in for 4.2 GA still.
Note that we search for a
TaskExecutorbean... not a plainExecutorsince that would match withScheduledExecutorService as well, which is unusable for our purposes here.TaskExecutoris more clearly designed for it and clearly differentiated from scheduler types. And we fall back to a bean named "taskExecutor", if any, along the lines of #17827.Juergen