Usage
  • 228 views
  • 558 downloads

An Empirical Investigation of Software Merging Challenges

  • Author / Creator
    Mehran Mahmoudi
  • With the rise of distributed and global software development, branching has become a popular approach that facilitates collaboration between software developers. Similarly, forking, the practice of cloning an entire repository and creating an independently modified variant of it, is also common. One of the biggest challenges that developers face when employing these practices is dealing with integration problems such as merge conflicts. Conflicts occur when inconsistent changes happen to the code. Resolving these conflicts can be a cumbersome task as it requires prior knowledge about the changes in each of the versions that are going to be merged.In this thesis, we investigate merge conflicts in different integration contexts to understand what causes them, and we identify possible directions to help developers in the integration process. We perform two empirical studies, each with a different focus.In our first empirical study, we focus on understanding the integration challenges and improvement opportunities in independently modified variants of a repository. As a case study, we investigate the Android operating system and a community-based variant of it, LineageOS. We analyze changes made in LineageOS versus changes made in the original development of Android. By investigating the overlap of different changes, we also determine the possibility of having automated support for merging them. Our findings show that 83% of subsystems modified by LineageOS are also modified in the next release of Android. By taking the nature of overlapping changes into account, we assess the feasibility of having automated tool support to help phone vendors with the Android update problem. Our results show that 56% of the changes in LineageOS have the potential to be safely automated.In our second empirical study, we focus on the relationship between refactoring changes and conflicts. Previous studies have proposed techniques for facilitating conflict resolution in the presence of refactorings. However, the magnitude of the impact that refactorings have on merge conflicts has never been empirically evaluated. We study almost 3,000 well-engineered open-source Java software repositories and investigate the relation between merge conflicts and 15 popular refactoring types. Our results show that refactoring operations are involved in 22% of merge conflicts, which is remarkable taking into account that we investigated a relatively small subset of all possible refactoring types. Furthermore, certain refactoring types, such as Extract Method, tend to be more problematic for merge conflicts. Our results also suggest that conflicts that involve refactored code are usually more complex, compared to conflicts with no refactoring changes.

  • Subjects / Keywords
  • Graduation date
    Spring 2019
  • Type of Item
    Thesis
  • Degree
    Master of Science
  • DOI
    https://doi.org/10.7939/r3-smzy-dg62
  • License
    Permission is hereby granted to the University of Alberta Libraries to reproduce single copies of this thesis and to lend or sell such copies for private, scholarly or scientific research purposes only. Where the thesis is converted to, or otherwise made available in digital form, the University of Alberta will advise potential users of the thesis of these terms. The author reserves all other publication and other rights in association with the copyright in the thesis and, except as herein before provided, neither the thesis nor any substantial portion thereof may be printed or otherwise reproduced in any material form whatsoever without the author's prior written permission.