Trailblazer: a tool for automated annotation refactoring

  • Authors:
  • Myoungkyu Song;Eli Tilevich;Wesley Tansey

  • Affiliations:
  • Virginia Tech, Blacksburg, VA, USA;Virginia Tech, Blacksburg, VA, USA;Lincoln Vale LLC, Lincoln, MA, USA

  • Venue:
  • Proceedings of the 24th ACM SIGPLAN conference companion on Object oriented programming systems languages and applications
  • Year:
  • 2009

Quantified Score

Hi-index 0.00

Visualization

Abstract

Since annotations were added to the Java language, many enterprise frameworks have been transitioning to using annotated Plain Old Java Objects (POJOs) in their latest releases. Our automated refactoring tool, Trailblazer, alleviates the maintenance burden of such annotation refactoring tasks. The tool implements a novel approach that leverages a machine learning algorithm to infer semantics-preserving rules that are then used to automatically transform legacy Java classes. Using Trailblazer involves two phases. First, given an XML-based framework application, a programmer creates an annotation-based version of the application by hand, with Trailblazer recording the programmer's actions. Trailblazer then uses inductive learning to infer generalized upgrade rules. In the second phase, other programmers can apply the inferred general transformation rules to upgrade any other application that uses the same framework. Thus, once one developer has trailblazed through the hurdles of manually upgrading for a given framework, other developers can automatically follow along the beaten path. In this demonstration, we will use transparent persistence as our example domain to show how Trailblazer can infer generalized rules and then automatically upgrade a legacy enterprise application that uses EJB 2.0 XML configuration files, to use EJB 3.0 annotations.