Skip to main content

A Feature Model Based Framework for Refactoring Software Product Line Architecture

Abstract

Software product line (SPL) is an approach used to develop a range of software products with a high degree of similarity. In this approach, a feature model is usually used to keep track of similarities and differences. Over time, as modifications are made to the SPL, inconsistencies with the feature model could arise. The first approach to dealing with these inconsistencies is refactoring. Refactoring consists of small steps which, when accumulated, may lead to large-scale changes in the SPL, resulting in features being added to or eliminated from the SPL. In this paper, we propose a framework for refactoring SPLs, which helps keep SPLs consistent with the feature model. After some introductory remarks, we describe a formal model for representing the feature model. We express various refactoring patterns applicable to the feature model and the SPL formally, and then introduce an algorithm for finding them in the SPL. In the end, we use a real-world case study of an SPL to illustrate the applicability of the framework introduced in the paper.

This is a preview of subscription content, access via your institution.

References

  1. Tseng M M, Hu S J. Mass customization. In CIRP Encyclopedia of Production Engineering, Laperrière L, Reinhart G (eds.), Springer Berlin Heidelberg, 2014, pp.836-843.

  2. van der Linden F J, Schmid K, Rommes E. Software Product Lines in Action. Springer-Verlag Berlin Heidelberg, 2007.

  3. Clements P C, Northrop L. Software Product Lines: Practices and Patterns (3rd edition). Addison-Wesley Professional, 2001.

  4. Schulze S, Thüm T, Kuhlemann M, Saake G. Variantpreserving refactoring in feature-oriented software product lines. In Proc. the 6th Int. Workshop on Variability Modeling of Software-Intensive Systems, Jan. 2012, pp.73-81.

  5. Fowler M, Brant J, Opdyke W et al. Refactoring: Improving the Design of Existing Code. Pearson Education India, 2009.

  6. Alves V, Gheyi R, Massoni T, Kulesza U, Borba P, Lucena C. Refactoring product lines. In Proc. the 5th Int. Conf. Generative Programming and Component Engineering, Oct. 2006, pp.201-210.

  7. Zimmermann O. Architectural refactoring: A task-centric view on software evolution. IEEE Software, 2015, 32(2): 26-29.

    Article  Google Scholar 

  8. Krueger C. Easing the transition to software mass customization. In Lecture Notes in Computer Science 2290, van der Linden F (ed.), Springer Berlin Heidelberg, 2002, pp.282-293.

  9. Pohl K, Böckle G, van der Linden F. Software Product Line Engineering. Springer-Verlag Berlin Heidelberg, 2005.

    Book  MATH  Google Scholar 

  10. Batory D. Feature models, grammars, and propositional formulas. In Proc. the 9th SPLC, Sept. 2005, pp.7-20.

  11. Pohl K, Böckle G, Linden F J. Software Product Line Engineering: Foundations, Principles and Techniques. Springer Science & Business Media, 2005.

  12. Coleman D, Ash D, Lowther B, Oman P. Using metrics to evaluate software system maintainability. Computer, 1994, 27(8): 44-49.

    Article  Google Scholar 

  13. Guimaraes T. Managing application program maintenance expenditures. Communications of the ACM, 1983, 26(10): 739-746.

    Article  Google Scholar 

  14. Borba P. An introduction to software product line refactoring. In Lecture Notes in Computer Science 6491, Fernandes J M, Lammel R, Visser J, Saraiva J (eds.), Springer Berlin Heidelberg, 2011, pp.1-6.

  15. Gheyi R, Massoni T, Borba P. Automatically checking feature model refactorings. J. UCS, 2011, 17(5): 684-711.

    MATH  Google Scholar 

  16. Fenske W, Thüm T, Saake G. A taxonomy of software product line reengineering. In Proc. the 8th Int. Workshop on Variability Modelling of Software-Intensive Systems, Jan. 2014, Article No. 4.

  17. Hemakumar A. Finding contradictions in feature models. In Proc. the 12th Int. Software Product Line Conf. (SPLC), Sept. 2008, pp.183-190.

  18. Kang K C, Cohen S G, Hess J A, Novak W E, Peterson A S. Feature-oriented domain analysis (FODA) feasibility study. Technical Report CMU/SEI-90-TR-21, Software Engineering Institute, Carnegie Mellon University, Nov. 1990.

  19. Lopez-Herrejon R E, Batory D. A standard problem for evaluating product-line methodologies. In Proc. the Int. Conf. Generative and Component-Based Software Engineering, Sept. 2001, pp.10-24.

  20. Schobbens P, Heymans P, Trigaux J C. Feature diagrams: A survey and a formal semantics. In Proc. the 14th IEEE Int. Conf. Requirements Engineering, Sept. 2006, pp.139-148.

  21. Thüm T, Kästner C, Erdweg S, Siegmund N. Abstract features in feature modeling. In Proc. the 15th Int. Software Product Line Conf. (SPLC), Aug. 2011, pp.191-200.

  22. Batory D, Benavides D, Ruiz-Cortes A. Automated analysis of feature models: Challenges ahead. Communications of the ACM, 2006, 49(12): 45-47.

    Article  Google Scholar 

  23. In H P, Baik J, Kim S, Yang Y, Boehm B. A quality-based cost estimation model for the product line life cycle. Communications of the ACM, 2006, 49(12): 85-88.

    Article  Google Scholar 

  24. Mendonça M, Cowan D, Malyk W, Oliveira T. Collaborative product configuration: Formalization and efficient algorithms for dependency analysis. Journal of Software, 2008, 3(2): 69-82.

    Article  Google Scholar 

  25. Knoop J, Rüthing O, Steffen B. Partial dead code elimination. SIGPLAN Not., 1994, 29(6): 147-158.

    Article  Google Scholar 

  26. Kruchten P, Nord R L, Ozkaya I. Technical debt: From metaphor to theory and practice. IEEE Software, 2012, 29(6): 18-21.

    Article  Google Scholar 

  27. Dubinsky Y, Rubin J, Berger T, Duszynski S, Becker M, Czarnecki K. An exploratory study of cloning in industrial software product lines. In Proc. the 17th European Conf. Software Maintenance and Reengineering (CSMR), Mar. 2013, pp.25-34.

  28. Benavides D, Segura S, Trinidad P, Ruiz-Cortés A. FAMA: Tooling a framework for the automated analysis of feature models. In Proc. the 1st Int. Workshop on Variability Modelling of Software Intensive Systems, Jan. 2007.

  29. Mendonça M, Branco M, Cowan D. SPLOT: Software product lines online tools. In Proc. the 24th ACM SIGPLAN Conf. Companion on Object Oriented Programming Systems Languages and Applications, Oct. 2009, pp.761-762.

  30. Easterbrook S, Singer J, Storey M A, Damian D. Selecting empirical methods for software engineering research. In Guide to Advanced Empirical Software Engineering, Shull F, Singer J, Siøberg D (eds.), Springer London, 2008, pp.285-311.

  31. Yin R. Case Study Research: Design and Methods. SAGE Publications, 2009.

  32. Batory D. A tutorial on feature oriented programming and the ahead tool suite. In Lecture Notes in Computer Science 4143, Lämmel R, Saraiva J, Visser J (eds.), Springer Berlin Heidelberg, 2006, pp.3-5.

  33. Benavides D, Segura S, Trinidad P, Ruiz-Cortès A. A first step towards a framework for the automated analysis of feature models. In Proc. Managing Variability for Software Product Lines: Working With Variability Mechanisms, Aug. 2006, pp.39-47.

  34. Segura S. Automated analysis of feature models using atomic sets. In Proc. the 12th Int. Software Product Line Conf. (SPLC), Sept. 2008, pp.201-207.

  35. Thüm T, Batory D, Kastner C. Reasoning about edits to feature models. In Proc. the 31st IEEE Int. Conf. Software Engineering (ICSE), May 2009, pp.254-264.

  36. Mendonça M, Wasowski A, Czarnecki K. SATbased analysis of feature models is easy. In Proc. the 13th Int. Software Product Line Conf. (SPLC), Aug. 2009, pp.231-240.

  37. Czarnecki K, Wasowski A. Feature diagrams and logics: There and back again. In Proc. the 11th Int. Conf. Software Product Line Conf. (SPLC), Sept. 2007, pp.23-34.

  38. Fontoura M, Sadanandan S, Shanmugasundaram J, Vassilvitskii S, Vee E, Venkatesan S, Zien J. Efficiently evaluating complex Boolean expressions. In Proc. the 2010 ACM SIGMOD Int. Conf. Management of Data, Jun. 2010, pp.3-14.

  39. Kang K C, Kim S, Lee J, Kim K, Shin E, Huh M. FORM: A feature-oriented reuse method with domain-specific reference architectures. Annals of Software Engineering, 1998, 5(1): 143-168.

    Article  Google Scholar 

  40. Griss M L, Favaro J, d’Alessandro M. Integrating feature modeling with the RSEB. In Proc. the 5th Int. Conf. Software Reuse, Jun. 1998, pp.76-85.

  41. Eriksson M, Börstler J, Borg K. The PLUSS approachdomain modeling with features, use cases and use case realizations. In Lecture Notes in Computer Science 3714, Obbink H, Pohl K (eds.), Springer Berlin Heidelberg, 2005, pp.33-44.

  42. Peña J, Hinchey M G, Ruiz-Cortés A, Trinidad P. Building the core architecture of a NASA multiagent system product line. In Lecture Notes in Computer Science 4405, Padgham L, Iambonell F (eds.), Springer Berlin Heidelberg, 2006, pp.208-224.

  43. Czarnecki K, Kim C H P. Cardinality-based feature modeling and constraints: A progress report. In Proc. Int. Workshop on Software Factories, Oct. 2005, pp.16-20.

  44. Trinidad P, Benavides D, Durán A, Ruiz-Cortés A, Toro M. Automated error analysis for the agilization of feature modeling. Journal of Systems and Software, 2008, 81(6): 883-896.

    Article  Google Scholar 

  45. Von Der Maβen T, Lichter H. Deficiencies in feature models. In Proc. the Workshop on Software Variability Management for Product Derivation — Towards Tool Support, Aug. 30-Sept. 2, 2004, pp.59-62.

  46. Heidenreich F, Kopcsek J, Wende C. FeatureMapper: Mapping features to models. In Proc. the 30th Int. Conf. Software Engineering, May 2008, pp.943-944.

  47. Seidl C, Heidenreich F, Aβmann U. Co-evolution of models and feature mapping in software product lines. In Proc. the 16th Int. Conf. Software Product Line Conf. (SPLC), Sept. 2012, pp.76-85.

  48. Schulze S, Richers O, Schaefer I. Refactoring deltaoriented software product lines. In Proc. the 12th Annual Int. Conf. Aspect-Oriented Software Development, Mar. 2013, pp.73-84.

  49. Borba P, Teixeira L, Gheyi R. A theory of software product line refinement. Theoretical Computer Science, 2012, 455: 2-30.

    MathSciNet  Article  MATH  Google Scholar 

  50. Wimmer M, Perez S M, Jouault F, Cabot J. A catalogue of refactorings for model-to-model transformations. Journal of Object Technology, 2012, 11(2): 2:1-2:40.

  51. Aspvall B, Plass M F, Tarjan R E. A linear-time algorithm for testing the truth of certain quantified Boolean formulas. Information Processing Letters, 1979, 8(3): 121-123.

    MathSciNet  Article  MATH  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Jafar Habibi.

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Tanhaei, M., Habibi, J. & Mirian-Hosseinabadi, SH. A Feature Model Based Framework for Refactoring Software Product Line Architecture. J. Comput. Sci. Technol. 31, 951–986 (2016). https://doi.org/10.1007/s11390-016-1674-y

Download citation

  • Received:

  • Revised:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11390-016-1674-y

Keywords

  • software product line
  • feature model
  • refactoring
  • software architecture