aws-samples / aws-xray-dotnet-webapp
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 57 units with 431 lines of code in units (43.5% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 0 medium complex units (0 lines of code)
    • 0 simple units (0 lines of code)
    • 57 very simple units (431 lines of code)
0% | 0% | 0% | 0% | 100%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
cs0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
DotNET/src0% | 0% | 0% | 0% | 100%
DotNETCore/Controllers0% | 0% | 0% | 0% | 100%
DotNET-Agent/src0% | 0% | 0% | 0% | 100%
DotNETCore-Agent/Controllers0% | 0% | 0% | 0% | 100%
DotNETCore0% | 0% | 0% | 0% | 100%
DotNETCore-Agent0% | 0% | 0% | 0% | 100%
DotNETCore/Models0% | 0% | 0% | 0% | 100%
DotNETCore-Agent/Models0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public string Get()
in DotNETCore/Controllers/ProductsController.cs
15 2 1
private void CustomSubsegment()
in DotNETCore/Controllers/ProductsController.cs
15 2 0
private Product QueryProduct()
in DotNETCore/Controllers/ProductsController.cs
9 2 1
public void Configure()
in DotNETCore/Startup.cs
15 2 2
public string Get()
in DotNETCore-Agent/Controllers/ProductsController.cs
13 2 1
private Product QueryProduct()
in DotNETCore-Agent/Controllers/ProductsController.cs
9 2 1
public void Configure()
in DotNETCore-Agent/Startup.cs
14 2 2
public IHttpActionResult GetProduct()
in DotNET/src/Controllers/ProductsController.cs
14 2 1
private void CustomSubsegment()
in DotNET/src/Controllers/ProductsController.cs
15 2 0
public IHttpActionResult PostProduct()
in DotNET/src/Controllers/ProductsController.cs
12 2 1
private Product QueryProduct()
in DotNET/src/Controllers/ProductsController.cs
9 2 1
public IHttpActionResult GetProduct()
in DotNET-Agent/src/Controllers/ProductsController.cs
13 2 1
public IHttpActionResult PostProduct()
in DotNET-Agent/src/Controllers/ProductsController.cs
12 2 1
private Product QueryProduct()
in DotNET-Agent/src/Controllers/ProductsController.cs
9 2 1
static ProductsController()
in DotNETCore/Controllers/ProductsController.cs
13 1 0
public IEnumerable Get()
in DotNETCore/Controllers/ProductsController.cs
4 1 0
public void Post()
in DotNETCore/Controllers/ProductsController.cs
4 1 1
public void Put()
in DotNETCore/Controllers/ProductsController.cs
3 1 2
private static void MakeHttpWebRequest()
in DotNETCore/Controllers/ProductsController.cs
7 1 1
private async Task AddProduct()
in DotNETCore/Controllers/ProductsController.cs
8 1 1