Skip to content
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

Spring internal configuration classes can no longer use @EventListener [SPR-17160] #19660

Closed
spring-projects-issues opened this issue Aug 10, 2018 · 3 comments
Assignees
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: regression A bug that is also a regression
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

spring-projects-issues commented Aug 10, 2018

Stéphane Nicoll opened SPR-17160 and commented

Due to this optimization, Spring projects can no longer use @EventListener.

Spring Boot does use it in a few places where a single component needs to listener for two event types and avoid being called for every event. We can move to ApplicationListener if necessary but it would be nice to have a strategy to narrow down the event types.


Affects: 5.1 RC2

Issue Links:

Referenced from: commits 1d59e52

@spring-projects-issues
Copy link
Collaborator Author

Stéphane Nicoll commented

For the record, Spring Boot master no longer uses @EventListener

@spring-projects-issues
Copy link
Collaborator Author

Juergen Hoeller commented

It seems that we can proceed with the original change for the time being. We may still re-evaluate towards GA.

@spring-projects-issues
Copy link
Collaborator Author

Juergen Hoeller commented

As reported by John Blum via email, we missed one case: the user class traversal for the generated configuration subclasses. This has been fixed for RC3 now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core Issues in core modules (aop, beans, core, context, expression) type: regression A bug that is also a regression
Projects
None yet
Development

No branches or pull requests

2 participants