Defining and measuring microservice granularity-a literature overview
Fredy H Vera-Rivera1,2,3, Carlos Gaona2, Hernán Astudillo4
1GIA Research Group, Universidad Francisco de Paula Santander, Cúcuta, Norte de Santander, Colombia.
Background:
Microservices are an architectural approach of growing use, and the optimal granularity of a microservice directly affects the application's quality attributes and usage of computational resources. Determining microservice granularity is an open research topic.
Methodology:
We conducted a systematic literature review to analyze literature that addresses the definition of microservice granularity. We searched in IEEE Xplore, ACM Digital Library and Scopus. The research questions were: Which approaches have been proposed to define microservice granularity and determine the microservices' size? Which metrics are used to evaluate microservice granularity? Which quality attributes are addressed when researching microservice granularity?
Results:
We found 326 papers and selected 29 after applying inclusion and exclusion criteria. The quality attributes most often addressed are runtime properties (e.g., scalability and performance), not development properties (e.g., maintainability). Most proposed metrics were about the product, both static (coupling, cohesion, complexity, source code) and runtime (performance, and usage of computational resources), and a few were about the development team and process. The most used techniques for defining microservices granularity were machine learning (clustering), semantic similarity, genetic programming, and domain engineering. Most papers were concerned with migration from monoliths to microservices; and a few addressed green-field development, but none address improvement of granularity in existing microservice-based systems.
Conclusions:
Methodologically speaking, microservice granularity research is at a Wild West stage: no standard definition, no clear development-operation trade-offs, and scarce conceptual reuse (e.g., few methods seem applicable or replicable in projects other than their initial proposal). These gaps in granularity research offer clear options to investigate on continuous improvement of the development and operation of microservice-based systems.
Related Concept Videos
Microcracking in Concrete
Assembly of Complex Microtubule Structures
Microtubules
Microtubules have two structurally similar globular protein subunits: α and β tubulins. In the cytosol, the α and β tubulins form a heterodimer....
SI Units: 2019 Redefinition
A standard set of units has been defined...
Quantifying Work
Design Example: Aggregate Gradation
The grading, or particle-size distribution, of sand is determined using sieve analysis, with standard sizes ranging from 150 μm to 10 mm (ASTM No. 100 sieve to 3⁄8 in. sieve). Sand is...


