aws-samples / jenkins-on-aws
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 5 units with 299 lines of code in units (74.9% of code).
    • 1 very long units (204 lines of code)
    • 0 long units (0 lines of code)
    • 2 medium size units (73 lines of code)
    • 1 small units (16 lines of code)
    • 1 very small units (6 lines of code)
68% | 0% | 24% | 5% | 2%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py68% | 0% | 24% | 5% | 2%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
cdk/jenkins72% | 0% | 25% | 0% | 2%
cdk/docker/leader0% | 0% | 0% | 100% | 0%
Alternative Visuals
Longest Units
Top 5 longest units
Unit# linesMcCabe index# params
def __init__()
in cdk/jenkins/jenkins_leader.py
204 10 7
def __init__()
in cdk/jenkins/ecs.py
40 4 6
def __init__()
in cdk/jenkins/jenkins_worker.py
33 8 6
def main()
in cdk/docker/leader/modify_casc.py
16 1 0
def __init__()
in cdk/jenkins/network.py
6 1 4