Exceptions and aspects: the devil is in the details

  • Authors:
  • Fernando Castor Filho;Nelio Cacho;Eduardo Figueiredo;Raquel Maranhão;Alessandro Garcia;Cecília Mary F. Rubira

  • Affiliations:
  • State University of Campinas, Campinas, SP, Brazil;Lancaster University, Lancaster, UK;Pontifical Catholic University of Rio de Janeiro, Rio de Janeiro, RJ, Brazil;State University of Campinas, Campinas, SP, Brazil;Lancaster University, Lancaster, UK;State University of Campinas, Campinas, SP, Brazil1 State University of Campinas, Campinas, SP, Brazil

  • Venue:
  • Proceedings of the 14th ACM SIGSOFT international symposium on Foundations of software engineering
  • Year:
  • 2006

Quantified Score

Hi-index 0.01

Visualization

Abstract

It is usually assumed that the implementation of exception handling can be better modularized by the use of aspect-oriented programming (AOP). However, the trade-offs involved in using AOP with this goal are not well-understood. This paper presents an in-depth study of the adequacy of the AspectJ language for modularizing exception handling code. The study consisted in refactoring existing applications so that the code responsible for implementing heterogeneous error handling strategies was moved to separate aspects. We have performed quantitative assessments of four systems - three object-oriented and one aspect-oriented - based on four quality attributes, namely separation of concerns, coupling, cohesion, and conciseness. Our investigation also included a multi-perspective analysis of the refactored systems, including (i) the reusability of the aspectized error handling code, (ii) the beneficial and harmful aspectization scenarios, and (iii) the scalability of AOP to aspectize exception handling in the presence of other crosscutting concerns.