@ -5861,6 +5861,54 @@ metadata is provided per-instance rather than per-class.
@@ -5861,6 +5861,54 @@ metadata is provided per-instance rather than per-class.
[[beans-scanning-index]]
=== Generating a index of candidate components
Rather than scanning the classpath to find components, it is also possible to generate an
index at compilation time. When the `ApplicationContext` detects such index it will
automatically use it rather than scanning the classpath. This can reduce the time required
to refresh the `ApplicationContext` as scanning large applications can take a significant
amount of time.
To generate the index, simply add an additional dependency to each module that contains
components that are target for component scan directives: