We use the Bean Import functionality in to allow injection of beans from various (internal) libraries which don't depend on Micronaut (and thus do not have generated bean definition classes).
Since the imports are handled by an annotation processor which doesn't have access to the list of available packages each package has to be defined in the @Import annotation. This is however error prone as it is easy to forget to add a package when a new package is introduced in the library.
The Micronaut Import Maven Plugin was created to overcome this issue, it allows you to generate factory classes annotated with @Import for the matching packages from the dependencies. It would however be great to see this functionality in the Micronaut Maven (and Gradle) plugin.
Would you consider integrating such functionality in the Micronaut plugin?
We use the Bean Import functionality in to allow injection of beans from various (internal) libraries which don't depend on Micronaut (and thus do not have generated bean definition classes).
Since the imports are handled by an annotation processor which doesn't have access to the list of available packages each package has to be defined in the
@Import
annotation. This is however error prone as it is easy to forget to add a package when a new package is introduced in the library.The Micronaut Import Maven Plugin was created to overcome this issue, it allows you to generate factory classes annotated with
@Import
for the matching packages from the dependencies. It would however be great to see this functionality in the Micronaut Maven (and Gradle) plugin.Would you consider integrating such functionality in the Micronaut plugin?