How Do I Refactor This? An Empirical Study on Refactoring Trends and Topics in Stack Overflow

10/23/2021
by   Anthony Peruma, et al.
0

An essential part of software maintenance and evolution, refactoring is performed by developers, regardless of technology or domain, to improve the internal quality of the system, and reduce its technical debt. However, choosing the appropriate refactoring strategy is not always straightforward, resulting in developers seeking assistance. Although research in refactoring is well-established, with several studies altering between the detection of refactoring opportunities and the recommendation of appropriate code changes, little is known about their adoption in practice. Analyzing the perception of developers is critical to understand better what developers consider to be problematic in their code and how they handle it. Additionally, there is a need for bridging the gap between refactoring, as research, and its adoption in practice, by extracting common refactoring intents that are more suitable for what developers face in reality. In this study, we analyze refactoring discussions on Stack Overflow through a series of quantitative and qualitative experiments. Our results show that Stack Overflow is utilized by a diverse set of developers for refactoring assistance for a variety of technologies. Our observations show five areas that developers typically require help with refactoring – Code Optimization, Tools and IDEs, Architecture and Design Patterns, Unit Testing, and Database. We envision our findings better bridge the support between traditional (or academic) aspects of refactoring and their real-world applicability, including better tool support.

READ FULL TEXT
research
03/19/2022

An Exploratory Study on Refactoring Documentation in Issues Handling

Understanding the practice of refactoring documentation is of paramount ...
research
05/05/2023

Hearing the voice of experts: Unveiling Stack Exchange communities' knowledge of test smells

Refactorings are transformations to improve the code design without chan...
research
07/19/2020

Code2Que: A Tool for Improving Question Titles from Mined Code Snippets in Stack Overflow

Stack Overflow is one of the most popular technical Q A sites used by ...
research
09/02/2022

Developer Discussion Topics on the Adoption and Barriers of Low Code Software Development Platforms

Low-code software development (LCSD) is an emerging approach to democrat...
research
12/22/2020

Do We Need Improved Code Quality Metrics?

The software development community has been using code quality metrics f...
research
07/15/2021

One Thousand and One Stories: A Large-Scale Survey of Software Refactoring

Despite the availability of refactoring as a feature in popular IDEs, re...
research
06/18/2023

An Empirical Study of Untangling Patterns of Two-Class Dependency Cycles

Dependency cycles pose a significant challenge to software quality and m...

Please sign up or login with your details

Forgot password? Click here to reset