Aspects for trace monitoring

  • Authors:
  • Pavel Avgustinov;Eric Bodden;Elnar Hajiyev;Laurie Hendren;Ondřej Lhoták;Oege de Moor;Neil Ongkingco;Damien Sereni;Ganesh Sittampalam;Julian Tibble;Mathieu Verbaere

  • Affiliations:
  • Programming Tools Group, Oxford University, United Kingdom;Sable Research Group, McGill University, Montréal, Canada;Programming Tools Group, Oxford University, United Kingdom;Sable Research Group, McGill University, Montréal, Canada;Programming Languages Group, University of Waterloo, Waterloo, Canada;Programming Tools Group, Oxford University, United Kingdom;Programming Tools Group, Oxford University, United Kingdom;Programming Tools Group, Oxford University, United Kingdom;Programming Tools Group, Oxford University, United Kingdom;Programming Tools Group, Oxford University, United Kingdom;Programming Tools Group, Oxford University, United Kingdom

  • Venue:
  • FATES'06/RV'06 Proceedings of the First combined international conference on Formal Approaches to Software Testing and Runtime Verification
  • Year:
  • 2006

Quantified Score

Hi-index 0.00

Visualization

Abstract

A trace monitor observes the sequence of events in a system, and takes appropriate action when a given pattern occurs in that sequence. Aspect-oriented programming provides a convenient framework for writing such trace monitors. We provide a brief introduction to aspect-oriented programming in AspectJ. AspectJ only provides support for triggering extra code with single events, and we present a new language feature (named tracematches) that allows one to directly express patterns that range over the whole current trace. Implementing this feature efficiently is challenging, and we report on our work towards that goal. Another drawback of AspectJ is the highly syntactic nature of the event patterns, often requiring the programmer to list all methods that have a certain property, rather than specifying that property itself. We argue that Datalog provides an appropriate notation for describing such properties. Furthermore, all of the existing patterns in AspectJ can be reduced to Datalog via simple rewrite rules. This research is carried out with abc, an extensible optimising compiler for AspectJ, which is freely available for download.