aws-quickstart / quickstart-eks-gitlab
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 25 units with 226 lines of code in units (6.0% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 2 medium size units (69 lines of code)
    • 4 small units (68 lines of code)
    • 19 very small units (89 lines of code)
0% | 0% | 30% | 30% | 39%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 0% | 30% | 30% | 39%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
functions/source/CleanupACMDNSValidation0% | 0% | 100% | 0% | 0%
functions/source/UpdateDnsRecord0% | 0% | 0% | 64% | 35%
functions/source/CreateDatabase0% | 0% | 0% | 0% | 100%
functions/source/SmtpPasswordGenerator0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def handler()
in functions/source/CleanupACMDNSValidation/handler.py
43 7 2
def send()
in functions/source/CleanupACMDNSValidation/cfnresponse.py
26 4 7
def lambda_handler()
in functions/source/UpdateDnsRecord/handler.py
20 4 2
def update_dns_record()
in functions/source/UpdateDnsRecord/handler.py
19 2 3
def complete_lifecycle_hook()
in functions/source/UpdateDnsRecord/handler.py
15 2 3
def get_free_replica_number()
in functions/source/UpdateDnsRecord/handler.py
14 3 0
def create()
in functions/source/CreateDatabase/handler.py
10 3 2
def calculateKey()
in functions/source/SmtpPasswordGenerator/handler.py
9 1 2
def check_response()
in functions/source/UpdateDnsRecord/handler.py
8 3 1
def create()
in functions/source/SmtpPasswordGenerator/handler.py
7 1 2
def createConnection()
in functions/source/CreateDatabase/handler.py
7 1 1
def get_instance_by_id()
in functions/source/UpdateDnsRecord/handler.py
7 3 1
def delete()
in functions/source/CreateDatabase/handler.py
6 1 2
def update_replica_number()
in functions/source/UpdateDnsRecord/handler.py
6 2 3
def get_replica_number_for_transition()
in functions/source/UpdateDnsRecord/handler.py
6 3 2
def createCursor()
in functions/source/CreateDatabase/handler.py
4 1 3
def get_replica_number()
in functions/source/UpdateDnsRecord/handler.py
3 3 1
def delete()
in functions/source/SmtpPasswordGenerator/handler.py
2 1 2
def handler()
in functions/source/SmtpPasswordGenerator/handler.py
2 1 2
def sign()
in functions/source/SmtpPasswordGenerator/handler.py
2 1 2