A Method for Detecting and Measuring Architectural Layering Violations in Source Code

The layered architecture pattern has been widely adopted by the developer community in order to build large software systems. The layered organization of software modules offers a number of benefits such as reusability, changeability and portability to those who are involved in the development and maintenance of such software systems. But in reality as the system evolves over time, rarely does the actual source code of the system conform to the conceptual horizontal layering of modules. This in turn results in a significant degradation of system maintainability. In order to re-factor such a system to improve its maintainability, it is very important to discover, analyze and measure violations of layered architecture pattern. In this paper we propose a technique to discover such violations in the source code and quantitatively measure the amount of non-conformance to the conceptual layering. The proposed approach evaluates the extent to which the module dependencies across layers violate the layered architecture pattern. In order to evaluate the accuracy of our approach, we have applied this technique to discover and analyze such violations to a set of open source applications and a proprietary business application by taking the help of domain experts wherever possible.

[1]  David Garlan,et al.  Documenting software architectures: views and beyond , 2002, 25th International Conference on Software Engineering, 2003. Proceedings..

[2]  D. L. Parnas,et al.  On the criteria to be used in decomposing systems into modules , 1972, Software Pioneers.

[3]  Richard C. Holt,et al.  Completeness of a fact extractor , 2003, 10th Working Conference on Reverse Engineering, 2003. WCRE 2003. Proceedings..

[4]  Paul Clements,et al.  Software architecture in practice , 1999, SEI series in software engineering.

[5]  Susan Elliott Sim,et al.  On using a benchmark to evaluate C++ extractors , 2002, Proceedings 10th International Workshop on Program Comprehension.

[6]  Richard N. Taylor,et al.  An infrastructure for the rapid development of XML-based architecture description languages , 2002, ICSE '02.

[7]  Evans,et al.  Domain-driven design , 2003 .

[8]  David Garlan,et al.  A Formal Approach to Software Architectures , 1992, IFIP Congress.

[9]  Naranker Dulay,et al.  Specifying Distributed Software Architectures , 1995, ESEC.

[10]  Darren C. Atkinson Accurate call graph extraction of programs with function pointers using type signatures , 2004, 11th Asia-Pacific Software Engineering Conference.

[11]  Emden R. Gansner,et al.  A C++ data model supporting reachability analysis and dead code detection , 1997, ESEC '97/FSE-5.

[12]  Edsger W. Dijkstra,et al.  The structure of the “THE”-multiprogramming system , 1968, CACM.

[13]  David Notkin,et al.  An empirical study of static call graph extractors , 1998, TSEM.