awslabs / aws-trusted-advisor-explorer
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 55 units with 902 lines of code in units (90.0% of code).
    • 0 very long units (0 lines of code)
    • 2 long units (178 lines of code)
    • 13 medium size units (366 lines of code)
    • 14 small units (181 lines of code)
    • 26 very small units (177 lines of code)
0% | 19% | 40% | 20% | 19%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 19% | 40% | 20% | 19%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
source0% | 19% | 40% | 20% | 19%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def lambda_handler()
in source/create-athena-views-lambda.py
93 7 2
def genericTAParse()
in source/extract-ta-data-lambda.py
85 11 10
def lambda_handler()
in source/get-accounts-info-lambda.py
45 8 2
def list_accounts_from_file()
in source/get-accounts-info-lambda.py
42 8 0
def lambda_handler()
in source/verify-ta-check-status-lambda.py
32 4 2
def lambda_handler()
in source/extract-ta-data-lambda.py
28 5 2
def getTagInfo()
in source/extract-tag-data-lambda.py
28 8 8
def lambda_handler()
in source/refresh-ta-check-lambda.py
27 3 2
def send_anonymous_metric()
in source/get-accounts-info-lambda.py
25 2 0
def lambda_handler()
in source/extract-tag-data-lambda.py
25 6 2
def lambda_handler()
in source/get-ta-checks-lambda.py
25 3 2
def send()
in source/solution-helper.py
23 3 6
def list_accounts_from_organizations()
in source/get-accounts-info-lambda.py
22 4 0
def get_Mappings()
in source/get-tags-lambda.py
22 3 6
def lambda_handler()
in source/get-tags-lambda.py
22 3 2
def get_trusted_advisor_checks()
in source/get-ta-checks-lambda.py
20 5 6
def athenaQuery()
in source/create-athena-views-lambda.py
17 1 4
def checkIfTagsTableExistInDB()
in source/create-athena-views-lambda.py
16 4 1
def write2csv()
in source/extract-tag-data-lambda.py
15 2 3
def lambda_handler()
in source/start-crawler-lambda.py
13 3 2