skip to main content
10.1145/1621607.1621615acmconferencesArticle/Chapter ViewAbstractPublication PagesgpceConference Proceedingsconference-collections
research-article

Transactional pointcuts: designation reification and advice of interrelated join points

Published:04 October 2009Publication History

ABSTRACT

Aspect-oriented mechanisms are characterized by their join point models. A join point model has three components: join points, which are elements of language semantics; "a means of identifying join points"; and "a means of affecting the behaviour at those join points." A pointcut-advice model is a dynamic join point model in which join points are points in program execution. Pointcuts select a set of join points, and advice affects the behaviour of the selected join points. In this model, join points are typically selected and advised independently of each other. That is, the relationships between join points are not taken into account in join point selection and advice. In practice, join points are often not independent. Instead, they form part of a higher-level operation that implements the intent of the developer (e.g. managing a resource). There are natural situations in which join points should be selected only if they play a specific role in that operation.

We propose a new join point model that takes join point interrelationships into account and allows the designation of more complex computations as join points. Based on the new model, we have designed an aspect-oriented construct called a transactional pointcut (transcut). Transcuts select sets of interrelated join points and reify them into higher-level join points that can be advised. They share much of the machinery and intuition of pointcuts, and can be viewed as their natural extension. We have implemented a transcuts prototype as an extension to the AspectJ language and integrated it into the abc compiler. We present an example where a transcut is applied to implement recommended resource handling practices in the presence of exceptions within method boundaries.

References

  1. Alfred V. Aho, Ravi Sethi, Jeffrey D. Ullman, and Monica S. Lam. Compilers: Principles, Techniques, and Tools. Pearson Education, Inc, second edition, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Chris Allan, Pavel Avgustinov, Aske Simon Christensen, Laurie Hendren, Sascha Kuzins, Ondrej Lhotak, Oege de Moor, Damien Sereni, Ganesh Sittampalam, and Julian Tibble. Adding trace matching with free variables to aspectj. SIGPLAN Not., 40(10): 345--364, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Pavel Avgustinov, Aske Simon Christensen, Laurie Hendren, Sascha Kuzins, Jennifer Lhotak, Ondrej Lhotak, Oege de Moor, Damien Sereni, Ganesh Sittampalam, and Julian Tibble. abc: an extensible aspectj compiler. In AOSD '05: Proceedings of the 4th international conference on Aspect-oriented software development, pages 87--98, New York, NY, USA, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Thomas Ball. What's in a region? or computing control dependence regions in near-linear time for reducible control flow. ACM Lett. Program. Lang. Syst., 2(1-4):1--16, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Tal Cohen, Joseph Gil, and Itay Maman. JTL - the java tools language. In OOPSLA'06 International Conference on Object-Oriented Programming, Systems, Languages, and Applications, pages 89--108, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Remi Douence and Luc Teboul. A pointcut language for control-flow. In 3rd ACM SIGPLAN/SIGSOFT Conference on Generative Programming and Component Engineering, pages 95--114. Springer, 2004.Google ScholarGoogle ScholarCross RefCross Ref
  7. Remi Douence, Pascal Fradet, and Mario Sudholt. Trace-based aspects. Aspect-Oriented Software Development, pages 201--217, 2005.Google ScholarGoogle Scholar
  8. Christopher Dutchyn. Dynamic Join Points: Model and Interactions. PhD thesis, University of British Columbia, November 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Torbjorn Ekman and Gorel Hedin. The jastadd extensible java compiler. In OOPSLA '07: Proceedings of the 22nd annual ACM SIGPLAN conference on Object-oriented programming systems and applications, pages 1--18, New York, NY, USA, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Jeanne Ferrante, Karl J. Ottenstein, and Joe D. Warren. The program dependence graph and its use in optimization. ACM Trans. Program. Lang. Syst., 9(3):319--349, 1987. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Bruno Harbulot and John R. Gurd. A join point for loops in aspectj. In AOSD '06: Proceedings of the 5th international conference on Aspect-oriented software development, pages 63--74, New York, NY, USA, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Erik Hilsdale and Jim Hugunin. Advice weaving in aspectj. In AOSD '04: Proceedings of the 3rd international conference on Aspect-oriented software development, pages 26--35, New York, NY, USA, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. G. Kiczales, J. Lamping, A. Mendhekar, C. Maeda, C. Lopes, J. M. Loingtier, and J. Irwin. Aspect-oriented programming. In European Conference on Object-Oriented Programming (ECOOP), pages 220--242, June 1997.Google ScholarGoogle ScholarCross RefCross Ref
  14. Martin Lippert and Cristina V. Lopes. A study on exception detection and handling using aspect-oriented programming. Technical Report CSL-99-1, 1999.Google ScholarGoogle Scholar
  15. Michael Martin, Benjamin Livshits, and Monica S. Lam. Finding application errors and security flaws using PQL: a program query language. SIGPLAN Not., 40(10):365--383, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Hidehiko Masuhara and Kazunori Kawauchi. Dataflow pointcut in aspect-oriented programming. In 1st Asian Symposium on Programming Languages and Systems, pages 105--121. Springer, 2003.Google ScholarGoogle ScholarCross RefCross Ref
  17. Hidehiko Masuhara, Gregor Kiczales, and Chris Dutchyn. Compilation semantics of aspect-oriented programs. In G. T. Leavens and R. Cytron, editors, FOAL'02 Foundations of Aspect-Oriented Languages Workshop at AOSD'02, 2002.Google ScholarGoogle Scholar
  18. Flemming Nielson, Hanne Riis Nielson, and Chris Hankin. Principles of Program Analysis. Springer, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. Andy Podgurski. Forward control dependence, chain equivalence, and their preservation by reordering transformations. Technical Report CES-91-18, Case Western Reserve University, August 1991.Google ScholarGoogle Scholar
  20. Hridesh Rajan and Gary Leavens. Ptolemy: A language with quantified, typed events. ECOOP 2008 -- Object-Oriented Programming, pages 155--179, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Tobias Rho, Gunter Kniesel, and Malte Appeltauer. Fine-grained generic aspects. In (FOAL'06) Foundations of Aspect-Oriented Languages, 2006.Google ScholarGoogle Scholar
  22. Hossein Sadat-Mohtasham. Arbitrary non-contiguous pieces of computation: a new join point model for aspect-oriented programming. In OOPSLA Companion '08: Companion to the 23rd ACM SIGPLAN conference on Object-oriented programming systems languages and applications, pages 757--758, New York, NY, USA, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Raja Vallee-Rai and Laurie J. Hendren. Jimple: Simplifying java bytecode for analyses and transformations. Technical report, Sable Research Group, McGill University, 1998.Google ScholarGoogle Scholar
  24. Raja Vallee-Rai, Laurie Hendren, Vijay Sundaresan, Patrick Lam, Etienne Gagnon, and Phong Co. Soot - a Java optimization framework. In Proceedings of CASCON 1999, pages 125--135, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. Robert J. Walker and Kevin Viggers. Implementing protocols via declarative event patterns. In SIGSOFT '04/FSE-12: Proceedings of the 12th ACM SIGSOFT twelfth international symposium on Foundations of software engineering, pages 159--169, New York, NY, USA, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. Mitchell Wand, Gregor Kiczales, and Christopher Dutchyn. A semantics for advice and dynamic join points in aspect-oriented programming. ACM Trans. Program. Lang. Syst., 26(5):890--910, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  27. Westley Weimer and George C. Necula. Finding and preventing run-time error handling mistakes. In OOPSLA '04: Proceedings of the 19th annual ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications, pages 419--431, New York, NY, USA, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. Curtis Clifton, Gary Leavens, and James Noble. MAO: Ownership and effects for more effective reasoning about aspects. ECOOP 2007 -- Object-Oriented Programming, pages 451--475, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Transactional pointcuts: designation reification and advice of interrelated join points

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in
    • Published in

      cover image ACM Conferences
      GPCE '09: Proceedings of the eighth international conference on Generative programming and component engineering
      October 2009
      194 pages
      ISBN:9781605584942
      DOI:10.1145/1621607
      • General Chair:
      • Jeremy Siek,
      • Program Chair:
      • Bernd Fischer
      • cover image ACM SIGPLAN Notices
        ACM SIGPLAN Notices  Volume 45, Issue 2
        GPCE '09
        February 2010
        182 pages
        ISSN:0362-1340
        EISSN:1558-1160
        DOI:10.1145/1837852
        Issue’s Table of Contents

      Copyright © 2009 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 4 October 2009

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • research-article

      Acceptance Rates

      GPCE '09 Paper Acceptance Rate18of62submissions,29%Overall Acceptance Rate56of180submissions,31%

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader