My belief is that the Spring bootstraps
- ContextLoaderListener
- DispatcherServlet
due to the instruction
<context:component-scan base-package=" ..... " />
would perform component scans at app startup (or whenever instructed to) during run-time.
Is there a way to instruct the compiler (perhaps thro a maven build plugin) to perform a one time static scan of annotated spring components during build/compile time, so that the bootstrap component scan is not performed, WITHOUT abandoning the use of component annotation?
As a way to reduce startup load and latency.