ACM Home Page
Please provide us with feedback. Feedback
Annotation refactoring: inferring upgrade transformations for legacy applications
Full text PdfPdf (311 KB)
Source
Conference on Object Oriented Programming Systems Languages and Applications archive
Proceedings of the 23rd ACM SIGPLAN conference on Object-oriented programming systems languages and applications table of contents
Nashville, TN, USA
SESSION: Refactoring table of contents
Pages 295-312  
Year of Publication: 2008
ISBN:978-1-60558-215-3
Also published in ...
Authors
Wesley Tansey  Virginia Tech, Blacksburg, VA, USA
Eli Tilevich  Virginia Tech, Blacksburg, VA, USA
Sponsors
SIGPLAN: ACM Special Interest Group on Programming Languages
ACM: Association for Computing Machinery
Publisher
ACM  New York, NY, USA
Bibliometrics
Downloads (6 Weeks): 16,   Downloads (12 Months): 192,   Citation Count: 0
Additional Information:

abstract   references   index terms   collaborative colleagues  

Tools and Actions: Request Permissions Request Permissions    Review this Article  
DOI Bookmark: Use this link to bookmark this Article: http://doi.acm.org/10.1145/1449764.1449788
What is a DOI?

ABSTRACT

Since annotations were added to the Java language, many frameworks have moved to using annotated Plain Old Java Objects (POJOs) in their newest releases. Legacy applications are thus forced to undergo extensive restructuring in order to migrate from old framework versions to new versions based on annotations (Version Lock-in). Additionally, because annotations are embedded in the application code, changing between framework vendors may also entail largescale manual changes (Vendor Lock-in).

This paper presents a novel refactoring approach that effectively solves these two problems. Our approach infers a concise set of semantics-preserving transformation rules from two versions of a single class. Unlike prior approaches that detect only simple structural refactorings, our algorithm can infer general composite refactorings and is more than 97% accurate on average. We demonstrate the effectiveness of our approach by automatically upgrading more than 80K lines of the unit testing code of four open-source Java applications to use the latest version of the popular JUnit testing framework.


REFERENCES

Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.

 
1
 
2
 
3
K. Beck and E. Gamma. Test Infected: Programmers love writing tests. Java Report, 3(7):37--50, 1998.
 
4
5
 
6
 
7
F. Castor and P. Borba. A language for specifying Java transformations. In V Brazilian Symposium on Programming Languages, pages 236--251, 2001.
8
 
9
 
10
11
 
12
M. Cortés, M. Fontoura, and C. Lucena. A Rule-based Approach to Framework Evolution. Journal of Object Technology (JOT), 5(1), jan-feb 2006.
13
14
 
15
L. DeMichiel and M. Keith. JSR 220: Enterprise JavaBeans 3.0, 2008. http://jcp.org/aboutJava/communityprocess/final/jsr220/index.html.
 
16
D. Dig, C. Comertoglu, D. Marinov, and R. Johnson. Automated detection of refactorings in evolving components. In ECOOP, pages 404--428, 2006.
 
17
18
19
 
20
Eclipse Foundation. Eclipse Java development tools, March 2008. http://www.eclipse.org/jdt.
 
21
 
22
T. Genssler and V. Kuttruff. Source-to-source transformation in the large. In Modular Programming Languages, pages 254--265. Springer-Verlag, 2003.
23
 
24
 
25
H. Lieberman. Your Wish is My Command: Programming By Example. Morgan Kaufmann, 2001.
 
26
Y. Lin, J. Gray, and F. Jouault. DSMDiff: A differentiation tool for domain-specific models. European Journal of Information Systems, 16:349--361, 2007.
 
27
D. Panda, D. Clarke, and M. Schincariol. EJB 3.0 migration. Technical report, Oracle, October 2005.
 
28
R. Pawlak, C. Noguera, and N. Petitprez. Spoon: Program analysis and transformation in Java. Technical report, INRIA Research Report, 2006.
29
 
30
M. Proctor, M. Neale, P. Lin, and M. Frandsen. Drools Documentation. Technical report, JBoss Inc., 2006.
31
 
32
D. Roberts and J. Brant. Tools for making impossible changes - experiences with a tool for transforming large Smalltalk programs. Software, IEE Proceedings-, 151(2):49--56, 2004. 1462--5970.
 
33
S. Roock and A. Havenstein. Refactoring tags for automatic refactoring of framework dependent applications. In Proc. Int'l Conf. eXtreme Programming and Flexible Processes in Software Engineering (XP), 2002.
 
34
C. Russell. Java Data Objects 2.1, June 2007. http://db.apache.org/jdo/specifications.html.
35
 
36
R. Stuckert. JUnit reloaded, December 2006. http://today.java.net/pub/a/today/2006/12/07/junit-reloaded.html.
37
 
38
W. Tansey and E. Tilevich. Refactoring object-oriented applications for metadata-based frameworks. Technical report, Virginia Tech, January 2008.
 
39
 
40
D. Vines and K. Sutter. Migrating legacy Hibernate applications to OpenJPA and EJB 3.0, August 2007. http://www.ibm.com/developerworks/websphere/techjournal/0708_vines/0708_vines.html.
 
41
E. Visser. A survey of strategies in program transformation systems. Electronic Notes in Theoretical Computer Science, 57, 2001.
 
42
E. Visser. Program transformation with Stratego/XT: Rules, strategies, tools, and systems in StrategoXT-0.9. In Domain-Specific Program Generation, volume 3016 of Lecture Notes in Computer Science, pages 216--238. Spinger-Verlag, June 2004.
43
 
44
 
45

Collaborative Colleagues:
Wesley Tansey: colleagues
Eli Tilevich: colleagues