Studying the Evolution of Library Utilization in Maven Projects: A Metric-Based Approach
摘要
In modern software development, usually, reuse takes place by invoking in the codebase, methods that are deployed and imported into projects as 3rd party libraries. The ease with which one can take benefit of reuse of libraries has been simplified lately, by platforms such as Maven, Gradle, etc. However, this convenient choice in many cases leads to an overwhelming number of libraries being packed in the final executable, even when not needed (e.g., the code that uses originally invoked a library is removed, or it is dead). In this paper, we propose five novel metrics that capture the extent to which each library is utilized in the codebase, providing information to the software engineers on the actual utility of the library in the final product. To automate the calculation of these metrics we have developed a corresponding tool that can be used for quality monitoring purposes. Finally, we have used the tools and metrics to study the evolution of library utilization in several Maven open-source software projects.