GerritCodeReview / plugins_owners
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 146 units with 1,155 lines of code in units (57.1% 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)
    • 5 simple units (205 lines of code)
    • 141 very simple units (950 lines of code)
0% | 0% | 0% | 17% | 82%
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
java0% | 0% | 0% | 17% | 82%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
owners-common/src0% | 0% | 0% | 16% | 83%
owners-autoassign/src0% | 0% | 0% | 36% | 63%
owners/src0% | 0% | 0% | 0% | 100%
owners-api/src0% | 0% | 0% | 0% | 100%
plugins/owners-api0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
private PathOwnersEntry resolvePathEntry()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/PathOwners.java
46 8 5
private OwnersMap fetchOwners()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/PathOwners.java
57 7 1
public void addReviewers()
in owners-autoassign/src/main/java/com/googlesource/gerrit/owners/common/ReviewerManager.java
53 6 3
private void handleGitReferenceUpdated()
in owners-autoassign/src/main/java/com/googlesource/gerrit/owners/common/GitRefListener.java
25 6 1
private boolean isChangeSetReadyForReview()
in owners-autoassign/src/main/java/com/googlesource/gerrit/owners/common/GitRefListener.java
24 6 3
private Set getModifiedPaths()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/PathOwners.java
13 5 0
private Set findUserOrEmail()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/AccountsImpl.java
35 5 1
private boolean isFullMatch()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/AccountsImpl.java
11 5 2
public void onGitReferenceUpdated()
in owners-autoassign/src/main/java/com/googlesource/gerrit/owners/common/GitRefListener.java
19 5 1
public void processEvent()
in owners-autoassign/src/main/java/com/googlesource/gerrit/owners/common/GitRefListener.java
26 5 4
private PatchList getPatchList()
in owners-autoassign/src/main/java/com/googlesource/gerrit/owners/common/GitRefListener.java
20 4 3
public Operation exec()
in owners/src/main/java/gerrit_owners/PRED_matcher_owner_2.java
22 4 1
public Operation exec()
in owners/src/main/java/gerrit_owners/PRED_owner_2.java
21 4 1
public void addFileOwners()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/OwnersMap.java
11 3 2
public void addFileReviewers()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/OwnersMap.java
11 3 2
private void processMatcherPerPath()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/PathOwners.java
15 3 4
private Set findAccountsInGroup()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/AccountsImpl.java
19 3 1
private Optional keySchemeRest()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/AccountsImpl.java
6 3 2
public PathOwnersEntry()
in owners-common/src/main/java/com/googlesource/gerrit/owners/common/PathOwnersEntry.java
26 3 6
public Operation exec()
in owners/src/main/java/gerrit_owners/PRED_file_owners_2.java
12 3 1