[Paper Review] Microservice Architecture Practices and Experience: a Focused Look on Docker Configuration Files
This paper conducts a Mining Software Repositories (MSR) study on 29 open-source GitHub projects to analyze Docker configuration files—Dockerfiles and docker-compose files—revealing current microservice architecture practices. It finds that while small, independent services are common, polyglot programming is rare, and tools like API gateways and service registries are widely adopted, highlighting gaps in real-world adherence to established microservice principles.
Cloud applications are more and more microservice-oriented, but a concrete charting of the microservices architecture landscape -- namely, the space of technical options available for microservice software architects in their decision-making -- is still very much lacking, thereby limiting the ability of software architects to properly evaluate their architectural decisions with sound experiential devices and/or practical design principles. On the one hand, Microservices are fine-grained, loosely coupled services that communicate through lightweight protocols. On the other hand, each microservice can use a different software stack, be deployed and scaled independently or even executed in different containers, which provide isolation and a wide-range of configuration options but also offer unforeseeable architectural interactions and under-explored architecture smells, with such experience captured mainly in software repositories where such solutions are cycled. This paper adopts a mining software repositories (MSR) approach to capture the practice within the microservice architecture landscape, by eliciting and analysing Docker configuration files, being Docker the leading technical device to design for, and implement modern microservices. Our analysis of Docker-based microservices gives an interesting summary of the current state of microservices practice and experience. Conversely, observing that all our datapoints have their own shape and characteristics, we conclude that further comparative assessment with industrial systems is needed to better address the recurring positive principles and patterns around microservices.
Motivation & Objective
- To map current microservice architecture practices by analyzing real-world Docker configuration files from open-source repositories.
- To identify common patterns and anti-patterns in Dockerfile and docker-compose file usage among microservice-based systems.
- To assess the extent to which established microservice principles—such as service independence and minimal coupling—are reflected in actual development practice.
- To highlight discrepancies between theoretical microservice design principles and observed implementation patterns in production-like environments.
- To support software architects with empirically grounded, experience-driven design guidance through data extracted from real-world codebases.
Proposed method
- Conducted an MSR study on GitHub repositories containing Docker configuration files (Dockerfiles and docker-compose.yml).
- Used a semi-automated pipeline to filter and select 29 open-source microservice projects with relevant Docker configuration files.
- Collected and analyzed Dockerfiles to understand service build and configuration practices.
- Analyzed docker-compose files to study service composition, inter-service communication, and deployment topology.
- Identified and categorized tools and patterns (e.g., API gateways, service registries, monitoring) used in the configuration files.
- Compared findings with established microservice principles and related work to identify gaps in practice.
Experimental results
Research questions
- RQ1To what extent are well-known microservice principles—such as fine-grained, loosely-coupled services—reflected in real-world Docker configuration files?
- RQ2How prevalent is the use of multiple programming languages and software stacks in microservice projects, as evidenced by Docker configuration files?
- RQ3Which architectural components (e.g., API gateways, service registries, message buses) are most commonly used and how are they configured?
- RQ4How do the configuration patterns in Dockerfiles and docker-compose files reflect actual deployment and communication strategies in microservice systems?
- RQ5What are the most common anti-patterns or deviations from best practices observed in real-world microservice configurations?
Key findings
- The average microservice project analyzed is small, with most projects containing fewer than three business functions per service, supporting the principle of fine-grained services.
- Despite theoretical support for polyglot programming, the use of multiple programming languages within the same microservice project is negligible in the analyzed repositories.
- API gateways, service registries, and message buses are widely used, indicating strong adoption of patterns that support service discovery and decoupled communication.
- Monitoring systems are frequently included in configurations, suggesting a strong emphasis on observability in production-grade microservice deployments.
- The analysis reveals that while some best practices are well-established, others—such as true service independence—are inconsistently applied, indicating potential architectural risks.
- The study identifies a need for further comparative analysis with industrial, closed-source systems to validate and generalize the observed patterns.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.