Javascript must be enabled to continue!
Fixing Dockerfile smells: an empirical study
View through CrossRef
AbstractDocker is the de facto standard for software containerization. A Dockerfile contains the requirements to build a Docker image containing a target application. There are several best practice rules for writing Dockerfiles, but the developers do not always follow them. Violations of such practices, known as Dockerfile smells, can negatively impact the reliability and performance of Docker images. Previous studies showed that Dockerfile smells are widely diffused, and there is a lack of automatic tools that support developers in fixing them. However, it is still unclear what Dockerfile smells get fixed by developers and to what extent developers would be willing to fix smells in the first place. The aim of our study is twofold. First, we want to understand what Dockerfiles smells receive more attention from developers, i.e., are fixed more frequently in the history of open-source projects. Second, we want to check if developers are willing to accept changes aimed at fixing Dockerfile smells (e.g., generated by an automated tool), to understand if they care about them. We evaluated the survivability of Dockerfile smells from a total of 53,456 unique Dockerfiles, where we manually validated a large sample of smell-removing commits to understand (i) if developers performed the change with the intention of removing bad practices, and (ii) if they were aware of the removed smell. In the second part, we used a rule-based tool to automatically fix Dockerfile smells. Then, we proposed such fixes to developers via pull requests. Finally, we quantitatively and qualitatively evaluated the outcome after a monitoring period of more than 7 months. The results of our study showed that most developers pay more attention to changes aimed at improving the performance of Dockerfiles (image size and build time). Moreover, they are willing to accept the fixes for the most common smells, with some exceptions (e.g., missing version pinning for OS packages).
Springer Science and Business Media LLC
Title: Fixing Dockerfile smells: an empirical study
Description:
AbstractDocker is the de facto standard for software containerization.
A Dockerfile contains the requirements to build a Docker image containing a target application.
There are several best practice rules for writing Dockerfiles, but the developers do not always follow them.
Violations of such practices, known as Dockerfile smells, can negatively impact the reliability and performance of Docker images.
Previous studies showed that Dockerfile smells are widely diffused, and there is a lack of automatic tools that support developers in fixing them.
However, it is still unclear what Dockerfile smells get fixed by developers and to what extent developers would be willing to fix smells in the first place.
The aim of our study is twofold.
First, we want to understand what Dockerfiles smells receive more attention from developers, i.
e.
, are fixed more frequently in the history of open-source projects.
Second, we want to check if developers are willing to accept changes aimed at fixing Dockerfile smells (e.
g.
, generated by an automated tool), to understand if they care about them.
We evaluated the survivability of Dockerfile smells from a total of 53,456 unique Dockerfiles, where we manually validated a large sample of smell-removing commits to understand (i) if developers performed the change with the intention of removing bad practices, and (ii) if they were aware of the removed smell.
In the second part, we used a rule-based tool to automatically fix Dockerfile smells.
Then, we proposed such fixes to developers via pull requests.
Finally, we quantitatively and qualitatively evaluated the outcome after a monitoring period of more than 7 months.
The results of our study showed that most developers pay more attention to changes aimed at improving the performance of Dockerfiles (image size and build time).
Moreover, they are willing to accept the fixes for the most common smells, with some exceptions (e.
g.
, missing version pinning for OS packages).
Related Results
Code Smells Detection and Visualization of Software Systems
Code Smells Detection and Visualization of Software Systems
Bad smells are symptoms in the source code that indicate possible deeper problems and may serve as drivers for code refactoring. Although efforts have been made on measuring code c...
Continuous monitoring of software evolution
Continuous monitoring of software evolution
As software continues to evolve, complexity accumulates through various maintenance activities, such as bug fixes, new feature implementations, etc., inevitably resulting in archit...
Role of Rhizosphere Soil Microbes in Adapting Ramie (Boehmeria nivea L.) Plants to Poor Soil Conditions through N-Fixing and P-Solubilization
Role of Rhizosphere Soil Microbes in Adapting Ramie (Boehmeria nivea L.) Plants to Poor Soil Conditions through N-Fixing and P-Solubilization
The N-fixing and P-solubilization functions of soil microbes play a vital role in plant adaptation to nutrient-deficiency conditions. However, their exact roles toward the adaptati...
THE FORCING EDGE FIXING EDGE-TO-VERTEX MONOPHONIC NUMBER OF A GRAPH
THE FORCING EDGE FIXING EDGE-TO-VERTEX MONOPHONIC NUMBER OF A GRAPH
For a connected graph G = (V, E), a set Se ⊆ E(G)–{e} is called an edge fixing edge-to-vertex monophonic set of an edge e of a connected graph G if every vertex of G lies on an e –...
An Exploratory Evaluation of Code Smell Agglomerations
An Exploratory Evaluation of Code Smell Agglomerations
Abstract
Context.
Code smell is a symptom of decisions about the system design or code that may degrade its modularity. For example, they may indicate inheritance misuse, ...
Effectiveness of Applying Hyperbranched PVAc Copolymer Emulsion for Ecological Sand-Fixing in the High Salt-Affected Sandy Land
Effectiveness of Applying Hyperbranched PVAc Copolymer Emulsion for Ecological Sand-Fixing in the High Salt-Affected Sandy Land
This research seeks to reduce wind-blown sand hazards in saline deserts by introducing hyperbranched PVAc copolymer emulsion as a novel ecological sand-fixing material. The study b...
Performance of biological sand-fixing materials before and after inoculation on sandy desert surface
Performance of biological sand-fixing materials before and after inoculation on sandy desert surface
Abstract
Aims Desert biocrust played an important role for the control of desertification. Artificial inoculation can promote the formation of biocrusts. The physiological...
Attentionsmelling: Using Large Language Models to Identify Code Smells
Attentionsmelling: Using Large Language Models to Identify Code Smells
Large Language Models (LLMs) are becoming essential tools in software engineering, automating tasks like code generation, unit testing, and code review. However, their potential to...

