I thought someone else might jump in on this, but they didn't, so I guess I have to :)
load time weaving gives you more flexibility than compile time weaving. You can make decisions very late, basically as the JVM comes up, about what aspects you want to be woven into what types. You can even use loadtime configuration through aop.xml to customize abstract aspects (and in AspectJ 1.6.12 build entire aspects) just as the JVM starts. Example: on one run of a product you want logging/tracing/monitoring, so loadtime weave it in. On the next run you don't want it so don't loadtime weave it in - there is no need to go back and do your product build to create either the woven or unwoven variant. The price you pay for the flexibility is slowing down startup time (as weaving isn't free) and slightly increasing runtime footprint (although I do have the latter on my TODO list to sort out). cheers, Andy On 10 December 2011 14:25, Mark <[email protected]> wrote: > The title says it all. > Thanks. > > -- > View this message in context: > http://aspectj.2085585.n4.nabble.com/Why-would-one-ever-want-to-use-Load-Time-Weaving-tp4181328p4181328.html > Sent from the AspectJ - users mailing list archive at Nabble.com. > _______________________________________________ > aspectj-users mailing list > [email protected] > https://dev.eclipse.org/mailman/listinfo/aspectj-users _______________________________________________ aspectj-users mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/aspectj-users
