awslabs / aws-codebuild-jenkins-plugin
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 230 units with 2,362 lines of code in units (57.8% of code).
    • 1 very complex units (268 lines of code)
    • 2 complex units (220 lines of code)
    • 5 medium complex units (189 lines of code)
    • 15 simple units (354 lines of code)
    • 207 very simple units (1,331 lines of code)
11% | 9% | 8% | 14% | 56%
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
java11% | 9% | 8% | 14% | 56%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/main/java12% | 10% | 8% | 14% | 54%
src/main/java/com0% | 0% | 0% | 28% | 71%
src/main/java/enums0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public void perform()
in src/main/java/CodeBuilder.java
268 55 4
private void logStartBuildMessage()
in src/main/java/CodeBuilder.java
123 41 2
public static String checkStartBuildOverridesConfig()
in src/main/java/CodeBuilderValidation.java
97 26 1
private void updateDashboard()
in src/main/java/CodeBuilder.java
33 17 4
public FormValidation doCheckMaxSleepTime()
in src/main/java/CodeBuilder.java
38 14 3
public AWSClientFactory()
in src/main/java/AWSClientFactory.java
51 12 10
38 11 0
public static Collection mapEnvVariables()
in src/main/java/CodeBuilder.java
29 11 2
37 10 0
private void download()
in src/main/java/S3Downloader.java
30 10 3
public static void zipSource()
in src/main/java/ZipSourceCallable.java
41 9 4
public UploadToS3Output uploadSourceToS3()
in src/main/java/S3DataManager.java
40 9 2
public ListBoxModel doFillCredentialsIdItems()
in src/main/java/CodeBuilder.java
26 8 0
public ListBoxModel doFillCredentialsIdItems()
in src/main/java/CodeBuildStep.java
26 8 0
public static AWSCredentialsProvider getBasicCredentialsOrDefaultChain()
in src/main/java/com/amazonaws/codebuild/jenkinsplugin/Validation.java
17 7 3
public static void checkS3SourceUploaderConfig()
in src/main/java/CodeBuilderValidation.java
11 7 4
private AWSCredentialsProvider getStepCreds()
in src/main/java/AWSClientFactory.java
14 7 1
private BuildPhase getErrorPhase()
in src/main/java/CodeBuildAction.java
15 7 0
public void updateLogs()
in src/main/java/CodeBuildAction.java
16 7 1
public FormValidation doCheckIamRoleArn()
in src/main/java/com/amazonaws/codebuild/jenkinsplugin/CodeBuildBaseCredentials.java
29 6 1