Tag Archives: aspects

Why use an AOP language when other languages can now do Aspects?

Interesting research,  JOT: Journal of Object Technology – How AspectJ is Used: An Analysis of Eleven AspectJ Programs: Sven Apel, on how an AOP language, specifically AspectJ, is used in a few sample projects.  Was it useful, required?  The jury is out.

Interestingly the author correctly mentions that some languages now have rudimentary support for handling of basic crosscutting concerns.   And, since the analyzed projects did not really need advanced AOP techniques,

“numbers indicate that languages that provide only basic crosscutting mechanisms are appropriate to implement a large extent of the analyzed programs.”  

Note that the study does not apply to container based AOP as used in frameworks such as JBossAOP and SpringAOP.  Several Dynamic Languages use a Metaobject Protocol.

I used AspectJ for some utility and diagnostic help.  The language is fine and the concepts are approachable.  It’s the configuration, tools, and environment hassles that put a damper on things.   That’s why frameworks and tool support like that found in Eclipse are critical.

Updates
9/11/2010:
Adding Logging around all of the Methods of a Class with Groovy“, Ted Naleid. http://naleid.com/blog/2010/09/11/adding-logging-around-all-of-the-methods-of-a-class-with-groovy/

Further Reading

JOT: Journal of Object Technology – How AspectJ is Used: An Analysis of Eleven AspectJ Programs, Sven Apel

McClean, John, “Painless AOP with Groovy“, http://www.infoq.com/articles/aop-with-groovy

Meta-object Protocol, http://en.wikipedia.org/wiki/Meta-object_protocol

Dynamic Programming Language, http://en.wikipedia.org/wiki/Dynamic_language

AspectJ, http://www.eclipse.org/aspectj/

AJDT, http://www.eclipse.org/ajdt/

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License.