Generate org.springframework.boot.autoconfigure.AutoConfiguration.imports file automatically
This one isn't a big issue anyway but I feel like @AutoConfiguration annotation should be enough to indicate the intention of the developer to create an autoconfiguration that should be automatically registered.
Personally, I feel META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports might be redundant, though I might be missing some use cases the team has previously thought of. Even if the idea is for this not to happen automatically for some "user-protection" reasons, I believe it would be nice to offer a parameter on the annotation to opt-in. Something like register(boolean register) that can default to false.
Thanks for raising this @rubasace. We've been thinking about extending our annotation processor, or create a dedicated one that would create this file automatically.
Using the annotation processor to generate the AutoConfiguration.imports file was causing problems with incremental compilation for Eclipse users, so we've reverted the changes. We'll look into this again after the 3.0.0 release.
The commits to re-apply for this enhancement and #32222, in order, are:
- https://github.com/spring-projects/spring-boot/commit/da4de7d67d442771704fba268f33fbc90aaaf1aa
- https://github.com/spring-projects/spring-boot/commit/6b3b0dd3a6ac4818388e97e121de69a91e21657d
- https://github.com/spring-projects/spring-boot/commit/95e62b7ff822d0179850b3eb9baf6f0e0d89eb2e
- https://github.com/spring-projects/spring-boot/commit/9fe24fe6929099243ab8aecceeed88ed48b24860
When reinstating this support, we need to consider the Eclipse problems described in https://github.com/spring-projects/spring-boot/issues/32404.
Any recent update? This would really help with maintenance of auto-configuration modules 🚀
No update, the Eclipse issue was a blocker for us and we've had higher priority issues to work on.
META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
Every time I try to write a sdk for springboot3, I need to copy this file name. I really hate it.
@nan-www if you have something constructive to say then we're more than happy to hear it. Otherwise, please vent elsewhere.
@nan-www if you have something constructive to say then we're more than happy to hear it. Otherwise, please vent elsewhere.
Got it. I'm sorry for the previous complaint. One more question: where can I subscribe to the progress of this issue?
By commenting on this issue GitHub should have automatically subscribed you to it already.