# On Microservice Analysis and Architecture Evolution:
## 4 Review of the Selected Studies
### Approaches and Tools
#### 4.1.5 Graph-Based Analysis  
Another common technique we found was graph-based analysis, representing the architecture of a microservice-based system in the form of a graph. Graph-based analysis can fall into either static or dynamic analysis categories based on the source of graph creation. For example, if the graph is created from the source code, it is a static analysis. In contrast, creating the graph from logs or network connections is dynamic analysis. A representation of microservices based on a graph has an advantage in easy visualization and being able to naturally represent the graph-like connections between the services. Graph-based analysis was used most commonly in papers to handle root cause analysis, with papers by [PERSON] et al. [47], [PERSON] et al. and [PERSON] et al. [54; 55] creating graphs based on a microservice system in an erroneous state, using nodes representing the clients, hosts, databases, etc. and then tracing back through the created graph to determine an error's most likely root causes. An article by [PERSON] et al. [52] also uses graph-based analysis for handling root cause analysis by first generating a causal graph of the system using an application called Microscope. Their proposed algorithm for Root Cause Analysis then traverses over the created graph. An article by [46] first describes gathering span logs from an execution trace of a system, then using this data to assemble a graph with traces, paths, and business flows. This graph is meant to make it easier for developers to understand the architecture of their microservice systems and diagnose future problems. [PERSON] et al. [2] create a similar graph of a microservice system meant to visualize microservices. An article by [PERSON] et al. [50] on the other hand, primarily breaks down a monolithic architecture into a data-flow diagram (a specific kind of graph) and uses the diagram to determine the best candidates for a microservice translation. A tracing and analytics tool called JCallGraph developed by [PERSON] et al. [53] uses graph-based analysis as a tool for developers who need to monitor and debug their systems, which works by tracing the invocations of microservices by other microservices in a system and assembling an invocation graph representation of the system. [PERSON] et al. [27; 28] achieve their goal of code smell detection by performing graph-based static analysis. First, a graph is generated that shows the different interactions between the microservices by exploring each microservice for a connection to other microservices. The dependency management tools for each microservice and the application configuration are then analyzed and processed to detect if any of 11 selected microservice smells are detected. Similarly, [PERSON] et al. [26] use this same approach to extract system architecture. [PERSON] et al. [48] achieve their goal of assisting with migration to microservices by identifying key concepts and organizing them as a Multi-Layer Fuzzy Cognitive Map. Static analysis is performed on the model to allow the identification of strong concepts by determining the complexity of the graph, the weight and number of edges of each node, and the tendency of cycles. Next, dynamic analysis is performed on the model during execution through simulations of manually configured scenarios. This allows the concepts identified by the static analysis to be ranked based on their significance. [PERSON] et al. [49]use an approach based on static analysis of monolithic source code to develop a text-call graph. Next, the call graph is used to generate a dendrogram, which is then cut into a set of clusters. These clusters are then used for visualization and modeling to determine the best decomposition. [PERSON] et al. [23] analyzed the way to migrate systems from monolithic to microservices architecture. They applied graph clustering techniques to the analysis results to identify microservice candidates. [PERSON] et al. [24] approached the migration of legacy monolithic applications to a microservices architecture-based one.