I am coming from a Spring background. Recently we started using micronaut for our project. I understand that it uses compile time DI. How does it improve the overall memory footprint of the container ?
I took a look at the Application.class generated in the target folder. When I follow the trail, it seems like the one shown below -
run => Micronaut.run(Application.class, args); => applicationContext.findBean(EmbeddedApplication.class);
At this step it will scan for the beans and add them to the array Class[] and call the .start() on each embeddedApplication.
The beans are generated at compile-time -
When all the wiring is complete, shouldn't spring and micronaut consume the same amount of memory within the jvm ?

Long story short. From the Micronaut documentation.
As mentioned in the documentation the reduced memory consumption is achieved by not using any reflection and runtime proxies. This is a massive improvement, especially when it comes to larger applications, since there are now proxy and reflection object needed that blow up your heap.