-
Notifications
You must be signed in to change notification settings - Fork 41.1k
Support multiple TaskDecorator beans #45295
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Not sure if this is an enhancement or a bug. |
#43190 was specifically about scheduled tasks 😃
This logic has existed from the very beginning: #1563
I believe composition is a good idea. The
I think this is an enhancement |
Oh, sorry @nosan I mixed things up. Thanks for digging. |
Could you kindly assign this one to me, please? |
Closing in favor of PR 45302 |
In #43190 (landed in 3.5.0-M1), support for
TaskDecorator
has been added. If a bean is in the context, it's automatically applied toSimpleAsyncTaskExecutorBuilder
andThreadPoolTaskExecutorBuilder
.However, if there are multiple
TaskDecorator
beans are in the context, none is applied. That's because we use.getIfUnique
.I think that's somewhat confusing. It would be better to fail if there is more than one bean, or even better, support multiple
TaskDecorator
s (maybe using composition?).The text was updated successfully, but these errors were encountered: