Abstract

Software refactoring is to restructure the internal structure of object-oriented software to improve software quality, especially maintainability, extensibility and reusability while preserving its external behaviours. According to predefined refactoring rules, we may find many places in the software where refactorings can be applied. Applying each refactoring, we may achieve some effect (quality improvement). If we can apply all of the available refactorings, we can achieve the greatest effect. However, the conflicts among refactorings usually make it impossible. The application of a refactoring may change or delete elements necessary for other refactorings, and thus disables these refactorings. As a result, the application order (schedule) of the available refactorings determines which refactorings will be applied, and thus determines the total effect achieved by the refactoring activity. Consequently, conflicting refactorings had better be scheduled rationally so as to promote the total effect of refactoring activities. However, how to schedule conflicting refactorings is rarely discussed.In this paper, a conflict-aware scheduling approach is proposed. It schedules refactorings according to the conflict matrix of refactorings and effects of each individual refactoring. The scheduling model is a multi-objective optimisation model. We propose a heuristic algorithm to solve the scheduling model. We also evaluate the proposed scheduling approach in non-trivial projects. Evaluation results suggest that refactoring activities with the scheduling approach lead to greater effect (quality improvement) than refactoring activities without explicit scheduling.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call