Saturday, November 14, 2009

Spring AOP: Excessive startup time for "perTarget" advice

Well over 300,000 Class.forName calls during context-initialisation were the result of setting up a simple "perTarget" advice for a 400-something beans application. With the standard "per class" instantiation model, the overhead went back to "normal", returning the Hibernate SessionFactory to the top of the list of startup resource-consumers. From a quick look at the profiler output, AspectJ's Type-Worlds are re-built over and over again while evaluating pointcuts - funny.

No comments: