Unplugging Components using Aspects

Sergei Kojarski, Northeastern University
David H. Lorenz, Northeastern University

Normally, Aspect-Oriented Programming (AOP) is used for plugging and not for unplugging. Aspects (concerns) are weaved into a system, thus providing a modularized way to add crosscutting features to a base program. For example, given a base program without logging and given a logging aspect, the AOP weaver produces from the untangled code an executable with the desired crosscutting logging behaviors. The benefit is that the logging code is modularized, e.g., you can easily activate or deactivate logging. However, what if a legacy system written without AOP technology already contains logging functionality hard-coded in the base program? How do you deactivate logging then? In this paper, we explore the use of AOP for writing aspects that transform exiting hard-coded calls into plugs that can be used to retarget the client to use other subcomponents. Applying AOP for unplugging has potential usage in connection with components. You are given a monolithic system. You apply AOP to non-intrusively decouple the system's components. You may then replace some of the legacy components with alternative third-party components.

In Proceedings of the ECOOP 2003 Eighth International Workshop on Component-Oriented Programming. Darmstadt, Germany, July 21, 2003.


main.ps.gz (36k)

main.pdf (120k)


@InProceedings{Kojarski:2003:UCA,
 Author = "Sergei Kojarski and David~H. Lorenz",
 Title = "Unplugging Components using Aspects",
 Year = 2003,
 Booktitle = "ECOOP 2003 Eighth International Workshop on Component-Oriented Programming",
 Editor = "Jan Bosch and Clemens Szyperski and Wolfgang Weck",
 URL = "\url{http://www.ccs.neu.edu/home/lorenz/papers/wcop03/}",
}