aws-samples / nexus-oss-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 21 units with 1,120 lines of code in units (84.8% of code).
    • 1 very long units (787 lines of code)
    • 2 long units (124 lines of code)
    • 3 medium size units (88 lines of code)
    • 4 small units (61 lines of code)
    • 11 very small units (60 lines of code)
70% | 11% | 7% | 5% | 5%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
ts91% | 8% | 0% | 0% | <1%
py0% | 23% | 40% | 16% | 19%
groovy0% | 0% | 0% | 61% | 38%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src/lib91% | 8% | 0% | 0% | <1%
src/lambda.d/nexus3-purge0% | 44% | 24% | 30% | 0%
src/lambda.d/nexuspreconfigure0% | 0% | 47% | 20% | 31%
src/lambda.d/nexuspreconfigure-integration-test0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
constructor()
in src/lib/sonatype-nexus3-stack.ts
787 40 3
getAwsLoadBalancerControllerRepo()
in src/lib/sonatype-nexus3-stack.ts
73 1 0
def handler()
in src/lambda.d/nexus3-purge/index.py
51 10 2
def handler()
in src/lambda.d/nexuspreconfigure/index.py
32 7 2
def cfn_send()
in src/lambda.d/nexus3-purge/index.py
28 4 7
def cfn_send()
in src/lambda.d/nexuspreconfigure/index.py
28 4 7
def wait_for_purge()
in src/lambda.d/nexus3-purge/index.py
19 6 2
def kubectl()
in src/lambda.d/nexus3-purge/index.py
16 5 1
def convertJsonFileToBlobstore()
in src/lambda.d/nexuspreconfigure/createBlobstore.groovy
15 4 1
def createBlobstore()
in src/lambda.d/nexuspreconfigure/createBlobstore.groovy
11 3 1
def nexus_password()
in src/lambda.d/nexuspreconfigure-integration-test/conftest.py
8 2 0
def _createScript()
in src/lambda.d/nexuspreconfigure/nexus.py
8 2 3
def validateBlobstore()
in src/lambda.d/nexuspreconfigure/createBlobstore.groovy
8 6 1
void deleteDefaultBlobStores()
in src/lambda.d/nexuspreconfigure/deleteDefaultBlobstore.groovy
8 1 0
def nexus_client()
in src/lambda.d/nexuspreconfigure-integration-test/conftest.py
5 1 1
def deleteAllRepos()
in src/lambda.d/nexuspreconfigure/nexus.py
5 2 1
def removeDefaultFileBlobstore()
in src/lambda.d/nexuspreconfigure/nexus.py
5 1 1
def nexus_helper()
in src/lambda.d/nexuspreconfigure-integration-test/conftest.py
4 1 1
def __init__()
in src/lambda.d/nexuspreconfigure/nexus.py
4 1 4
private azOfSubnets()
in src/lib/sonatype-nexus3-stack.ts
3 1 1