GerritCodeReview / jgit
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 10,927 units with 103,771 lines of code in units (72.3% of code).
    • 7 very complex units (1,620 lines of code)
    • 41 complex units (4,492 lines of code)
    • 285 medium complex units (14,993 lines of code)
    • 733 simple units (20,441 lines of code)
    • 9,861 very simple units (62,225 lines of code)
1% | 4% | 14% | 19% | 59%
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
java1% | 4% | 14% | 19% | 59%
rb0% | 0% | 0% | 0% | 100%
py0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
org.eclipse.jgit1% | 4% | 14% | 19% | 59%
org.eclipse.jgit.pgm0% | 5% | 23% | 21% | 49%
org.eclipse.jgit.gpg.bc0% | 8% | 21% | 41% | 27%
org.eclipse.jgit.lfs0% | 2% | 7% | 17% | 72%
org.eclipse.jgit.ssh.apache0% | 0% | 12% | 26% | 61%
org.eclipse.jgit.http.server0% | 0% | 5% | 20% | 74%
org.eclipse.jgit.ssh.jsch0% | 0% | 10% | 22% | 67%
org.eclipse.jgit.ui0% | 0% | 13% | 21% | 64%
org.eclipse.jgit.lfs.server0% | 0% | 6% | 8% | 85%
org.eclipse.jgit.junit0% | 0% | 2% | 12% | 84%
org.eclipse.jgit.ssh.apache.agent0% | 0% | 0% | 45% | 54%
org.eclipse.jgit.http.apache0% | 0% | 0% | 28% | 71%
org.eclipse.jgit.archive0% | 0% | 0% | 26% | 73%
org.eclipse.jgit.junit.ssh0% | 0% | 0% | 5% | 94%
org.eclipse.jgit.ant0% | 0% | 0% | 24% | 76%
org.eclipse.jgit.junit.http0% | 0% | 0% | 0% | 100%
org.eclipse.jgit.benchmarks0% | 0% | 0% | 0% | 100%
tools0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
static int check()
in org.eclipse.jgit/src/org/eclipse/jgit/util/sha1/UbcCheck.java
369 129 1
private Object resolve()
in org.eclipse.jgit/src/org/eclipse/jgit/lib/Repository.java
299 87 2
void processEntry()
in org.eclipse.jgit/src/org/eclipse/jgit/dircache/DirCacheCheckout.java
193 87 4
protected boolean processEntry()
in org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java
221 68 7
public boolean diff()
in org.eclipse.jgit/src/org/eclipse/jgit/lib/IndexDiff.java
188 65 5
private void findObjectsToPack()
in org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java
197 60 5
static Pattern convertGlob()
in org.eclipse.jgit/src/org/eclipse/jgit/ignore/internal/Strings.java
153 56 1
private void checkNotWindowsDevice()
in org.eclipse.jgit/src/org/eclipse/jgit/lib/ObjectChecker.java
61 38 4
void copyAsIs()
in org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java
160 37 4
private void sendPack()
in org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java
129 36 8
private void executeImp()
in org.eclipse.jgit/src/org/eclipse/jgit/transport/FetchProcess.java
110 36 3
private void parse()
in org.eclipse.jgit/src/org/eclipse/jgit/transport/NetRC.java
97 36 0
private void copyAsIs2()
in org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/Pack.java
156 36 4
private void negotiate()
in org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java
104 35 1
private boolean processMerge()
in org.eclipse.jgit/src/org/eclipse/jgit/blame/BlameGenerator.java
114 35 1
public DirCache call()
in org.eclipse.jgit/src/org/eclipse/jgit/api/AddCommand.java
93 35 0
public MergeResult merge()
in org.eclipse.jgit/src/org/eclipse/jgit/merge/MergeAlgorithm.java
168 35 4
public SignatureVerification verify()
in org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgSignatureVerifier.java
135 34 2
public void prune()
in org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java
119 33 1
private void fetchV2()
in org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java
113 32 1