ABSTRACT
Software branching and merging allows collaborative development and creating software variants, commonly referred to as clone & own. While simple and cheap, a trade-off is the need to merge code and to resolve merge conflicts, which frequently occur in practice. When resolving conflicts, a key challenge for developer is to understand the changes that led to the conflict. While merge conflicts and their characteristics are reasonably well understood, that is not the case for the actual changes that cause them.
We present a case study of the changes---on the code and on the project-level (e.g., feature addition, refactoring, feature improvement)---that lead to conflicts. We analyzed the development history of ElasticSearch, a large open-source project that heavily relies on branching (forking) and merging. We inspected 40 merge conflicts in detail, sampled from 534 conflicts not resolvable by a semi-structured merge tool. On a code (structural) level, we classified the semantics of changes made. On a project-level, we categorized the decisions that motivated these changes. We contribute a categorization of code- and project-level changes and a detailed dataset of 40 conflict resolutions with a description of both levels of changes. Similar to prior studies, most of our conflicts are also small; while our categorization of code-level changes surprisingly differs from that of prior work. Refactoring, feature additions and feature enhancements are the most common causes of merge conflicts, most of which could potentially be avoided with better development tooling.
- [n.d.]. Online Appendix. https://bitbucket.org/easelab/elasticsearchstudy.Google Scholar
- Hadil Abukwaik, Andreas Burger, Berima Andam, and Thorsten Berger. 2018. Semi-automated feature traceability with embedded annotations. In ICSME.Google Scholar
- Paola Accioly, Paulo Borba, and Guilherme Cavalcanti. 2018. Understanding semi-structured merge conflict characteristics in open-source java projects. Empirical Software Engineering 23, 4 (2018), 2051--2085.Google ScholarDigital Library
- Berima Andam, Andreas Burger, Thorsten Berger, and Michel Chaudron. 2017. FLOrIDA: Feature LOcatIon DAshboard for Extracting and Visualizing Feature Traces. In VaMoS.Google Scholar
- Sven Apel, Don Batory, Christian Kästner, and Gunter Saake. 2013. Feature-Oriented Software Product Lines. Springer.Google ScholarDigital Library
- Sven Apel, Jörg Liebig, Benjamin Brandl, Christian Lengauer, and Christian Kästner. 2011. Semistructured Merge: Rethinking Merge in Revision Control Systems. In ESEC/FSE. ACM, 190--200.Google ScholarDigital Library
- Wesley K. G. Assunção, Roberto E. Lopez-Herrejon, Lukas Linsbauer, Silvia R. Vergilio, and Alexander Egyed. 2017. Reengineering Legacy Applications into Software Product Lines: A Systematic Mapping. Empirical Software Engineering 22, 6 (2017), 2972--3016.Google ScholarDigital Library
- Thorsten Berger, Ralf Rublack, Divya Nair, Joanne M. Atlee, Martin Becker, Krzysztof Czarnecki, and Andrzej Wasowski. 2013. A Survey of Variability Modeling in Industrial Practice. In VaMoS.Google Scholar
- Thorsten Berger, Jan-Philipp Steghöfer, Tewfik Ziadi, Jacques Robin, and Jabier Martinez. 2019. The State of Adoption and the Challenges of Systematic Variability Management in Industry. Empirical Software Engineering (2019). Preprint.Google Scholar
- Yuriy Brun, Reid Holmes, Michael D. Ernst, and David Notkin. 2011. Proactive Detection of Collaboration Conflicts. In ESEC/FSE. New York, NY, USA.Google Scholar
- John Businge, Openja Moses, Sarah Nadi, Engineer Bainomugisha, and Thorsten Berger. 2018. Clone-Based Variability Management in the Android Ecosystem. In ICSME.Google Scholar
- Guilherme Cavalcanti, Paulo Borba, and Paola Accioly. 2017. Evaluating and Improving Semistructured Merge. OOPSLA (Oct. 2017).Google Scholar
- DB-Engines. 2019. Ranking of Search Engines. https://db-engines.com/en/ranking/search+engine.Google Scholar
- Gleiph Ghiotto Lima de Menezes. 2016. On the nature of software merge conflicts. Ph.D. Dissertation. Federal Fluminense University.Google Scholar
- Danny Dig, Tien N Nguyen, and Ralph Johnson. 2006. Refactoring-aware software configuration management. Technical Report UIUCDCS.Google Scholar
- Yael Dubinsky, Julia Rubin, Thorsten Berger, Slawomir Duszynski, Martin Becker, and Krzysztof Czarnecki. 2013. An Exploratory Study of Cloning in Industrial Software Product Lines. In CSMR.Google Scholar
- Elastic. 2017. Getting Started. https://www.elastic.co/guide/en/elasticsearch/reference/current/getting-started.html.Google Scholar
- Sina Entekhabi, Anton Solback, Jan-Philipp Steghöfer, and Thorsten Berger. 2019. Visualization of Feature Locations with the Tool FeatureDashboard. In SPLC.Google Scholar
- Tammo Freese. 2006. Refactoring-aware version control. In ICSE.Google Scholar
- Sergio Garcia, Daniel Strueber, Davide Brugali, Alessandro Di Fava, Philipp Schillinger, Patrizio Pelliccione, and Thorsten Berger. 2019. Variability Modeling of Service Robots: Experiences and Challenges. In VaMoS.Google Scholar
- Gleiph Ghiotto, Leonardo Murta, Márcio Barros, and André van der Hoek. 2018. On the Nature of Merge Conflicts: a Study of 2,731 Open Source Java Projects Hosted by GitHub. IEEE Transactions on Software Engineering 99, 1 (2018), 1--25.Google Scholar
- G. Gousios, M. A. Storey, and A. Bacchelli. 2016. Work Practices and Challenges in Pull-Based Development: The Contributor's Perspective. In ICSE.Google Scholar
- Georgios Gousios, Andy Zaidman, Margaret-Anne Storey, and Arie van Deursen. 2015. Work Practices and Challenges in Pull-based Development: The Integrator's Perspective. In ICSE.Google Scholar
- M. L. Guimarães and A. R. Silva. 2012. Improving early detection of software merge conflicts. In ICSE.Google Scholar
- Anja Guzzi, Alberto Bacchelli, Yann Riche, and Arie van Deursen. 2015. Supporting Developers' Coordination in the IDE (CSCW '15).Google Scholar
- Abram Hindle. 2010. Software process recovery: recovering process from artifacts. In WCRE.Google Scholar
- Wenbin Ji, Thorsten Berger, Michal Antkiewicz, and Krzysztof Czarnecki. 2015. Maintaining Feature Traceability with Embedded Annotations. In SPLC.Google Scholar
- Bakhtiar Khan Kasi and Anita Sarma. 2013. Cassandra: Proactive Conflict Minimization Through Optimized Task Scheduling. In ICSE.Google Scholar
- Jacob Krueger and Thorsten Berger. 2020. Activities and Costs of Re-Engineering Cloned Variants Into an Integrated Platform. In VaMoS.Google Scholar
- Max Lillack, Stefan Stanciulescu, Wilhelm Hedman, Thorsten Berger, and Andrzej Wasowski. 2019. Intention-Based Integration of Software Variants. In ICSE.Google Scholar
- S. McKee, N. Nelson, A. Sarma, and D. Dig. 2017. Software Practitioner Perspectives on Merge Conflicts and Resolutions. In ICSME.Google Scholar
- Tom Mens. 2002. A state-of-the-art survey on software merging. IEEE Transactions on Software Engineering 28, 5 (2002), 449--462.Google ScholarDigital Library
- Leticia Montalvillo and Oscar Díaz. 2015. Tuning GitHub for SPL development: branching models & repository operations for product engineers. In SPLC.Google Scholar
- Leticia Montalvillo, Oscar Díaz, and Thomas Fogdal. 2018. Reducing coordination overhead in SPLs: peering in on peers. In SPLC.Google Scholar
- Julia Rubin and Marsha Chechik. 2013. A Framework for Managing Cloned Product Variants. In ICSE.Google Scholar
- Julia Rubin, Krzysztof Czarnecki, and Marsha Chechik. 2015. Cloned product variants: from ad-hoc to managed software product lines. Software Tools for Technology Transfer 17, 5 (2015), 627--646.Google ScholarDigital Library
- A. Sarma, D. F. Redmiles, and A. van der Hoek. 2012. Palantır: Early Detection of Development Conflicts Arising from Parallel Code Changes. IEEE Transactions on Software Engineering 38, 4 (July 2012), 889--908.Google ScholarDigital Library
- Ştefan Stănciulescu, Sandro Schulze, and Andrzej Wąsowski. 2015. Forked and Integrated Variants in an Open-Source Firmware Project. In ICSME.Google Scholar
- Ştefan Stănciulescu, Sandro Schulze, and Andrzej Wąsowski. 2015. Forked and integrated variants in an open-source firmware project. In ICSME.Google Scholar
- Mark Staples and Derrick Hill. 2004. Experiences Adopting Software Product Line Development Without a Product Line Architecture (APSEC).Google Scholar
- Daniel Strueber, Mukelabai Mukelabai, Jacob Krueger, Stefan Fischer, Lukas Linsbauer, Jabier Martinez, and Thorsten Berger. 2019. Facing the Truth: Benchmarking the Techniques for the Evolution of Variant-Rich Systems. In SPLC.Google Scholar
Index Terms
- Causes of merge conflicts: a case study of ElasticSearch
Recommendations
What causes merge conflicts?
SBES '20: Proceedings of the XXXIV Brazilian Symposium on Software EngineeringDuring the software development process, several developers commonly change artifacts in parallel. A merge process can combine parallel changes. In the case of changes that cannot be automatically combined, the developer responsible for the merge must ...
Semistructured merge: rethinking merge in revision control systems
ESEC/FSE '11: Proceedings of the 19th ACM SIGSOFT symposium and the 13th European conference on Foundations of software engineeringAn ongoing problem in revision control systems is how to resolve conflicts in a merge of independently developed revisions. Unstructured revision control systems are purely text-based and solve conflicts based on textual similarity. Structured revision ...
An empirical investigation into merge conflicts and their effect on software quality
AbstractMerge conflicts are known to cause extra effort for developers, but little is known about their effect on software. While some research has been done, many questions remain. To better understand merge conflicts and their impact we performed an ...
Comments