microsoft / azure-maven-archetypes
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 16 units with 274 lines of code in units (13.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)
    • 1 simple units (31 lines of code)
    • 15 very simple units (243 lines of code)
0% | 0% | 0% | 11% | 88%
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
scala0% | 0% | 0% | 20% | 79%
java0% | 0% | 0% | 0% | 100%
kt0% | 0% | 0% | 0% | 100%
groovy0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala0% | 0% | 0% | 20% | 79%
azure-iot-edge-archetype/src/main/resources/archetype-resources/src/main/java0% | 0% | 0% | 0% | 100%
apache-spark-archetype/src/main/resources/archetype-resources/src/main/java0% | 0% | 0% | 0% | 100%
azure-functions-kotlin-archetype/src/main/resources/archetype-resources/src/main/kotlin0% | 0% | 0% | 0% | 100%
apache-spark-archetype/src/main/resources/META-INF0% | 0% | 0% | 0% | 100%
azure-functions-archetype/src/main/resources/archetype-resources/src/main/java0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 16 most complex units
Unit# linesMcCabe index# params
def main()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/LogQuery.scala
31 7 1
def main()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/SparkML_RankingMetricsExample.scala
50 5 1
public void execute()
in azure-iot-edge-archetype/src/main/resources/archetype-resources/src/main/java/App.java
22 5 4
public static void main()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/java/JavaSparkPi.java
26 4 1
void cleanupFolder()
in apache-spark-archetype/src/main/resources/META-INF/archetype-post-generate.groovy
6 3 1
void cleanupContent()
in apache-spark-archetype/src/main/resources/META-INF/archetype-post-generate.groovy
10 3 1
public void execute()
in azure-iot-edge-archetype/src/main/resources/archetype-resources/src/main/java/App.java
7 2 2
public IotHubMessageResult execute()
in azure-iot-edge-archetype/src/main/resources/archetype-resources/src/main/java/App.java
11 2 2
public static void main()
in azure-iot-edge-archetype/src/main/resources/archetype-resources/src/main/java/App.java
14 2 1
def main()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/SparkSQLExample.scala
11 1 1
private def runBasicDataFrameExample()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/SparkSQLExample.scala
17 1 1
private def runDatasetCreationExample()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/SparkSQLExample.scala
10 1 1
def main()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/SparkSQL_RDDRelation.scala
22 1 1
def main()
in apache-spark-archetype/src/main/resources/archetype-resources/src/main/scala/SparkStreaming_HdfsWordCount.scala
13 1 1
public HttpResponseMessage run()
in azure-functions-archetype/src/main/resources/archetype-resources/src/main/java/Function.java
4 1 0
fun run()
in azure-functions-kotlin-archetype/src/main/resources/archetype-resources/src/main/kotlin/Function.kt
20 1 4