awslabs / aurora-snapshot-tool
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 24 units with 466 lines of code in units (70.0% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (52 lines of code)
    • 7 medium size units (230 lines of code)
    • 7 small units (110 lines of code)
    • 9 very small units (74 lines of code)
0% | 11% | 49% | 23% | 15%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 11% | 49% | 23% | 15%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
lambda/copy_snapshots_dest_aurora0% | 100% | 0% | 0% | 0%
lambda/take_snapshots_aurora0% | 0% | 100% | 0% | 0%
lambda/delete_old_snapshots_dest_aurora0% | 0% | 100% | 0% | 0%
lambda/copy_snapshots_no_x_account_aurora0% | 0% | 100% | 0% | 0%
lambda/delete_old_snapshots_no_x_account_aurora0% | 0% | 100% | 0% | 0%
lambda/delete_old_snapshots_aurora0% | 0% | 100% | 0% | 0%
lambda/share_snapshots_aurora0% | 0% | 100% | 0% | 0%
lambda0% | 0% | 10% | 53% | 36%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def lambda_handler()
in lambda/copy_snapshots_dest_aurora/lambda_function.py
52 6 2
def lambda_handler()
in lambda/take_snapshots_aurora/lambda_function.py
46 8 2
def lambda_handler()
in lambda/delete_old_snapshots_dest_aurora/lambda_function.py
37 10 2
def lambda_handler()
in lambda/copy_snapshots_no_x_account_aurora/lambda_function.py
36 4 2
def lambda_handler()
in lambda/delete_old_snapshots_no_x_account_aurora/lambda_function.py
36 10 2
def lambda_handler()
in lambda/delete_old_snapshots_aurora/lambda_function.py
29 7 2
def lambda_handler()
in lambda/share_snapshots_aurora/lambda_function.py
25 7 2
def copy_local()
in lambda/snapshots_tool_utils.py
21 2 2
def copy_remote()
in lambda/snapshots_tool_utils.py
20 2 2
def get_own_snapshots_source()
in lambda/snapshots_tool_utils.py
18 13 2
def get_own_snapshots_no_x_account()
in lambda/snapshots_tool_utils.py
18 12 3
def get_shared_snapshots()
in lambda/snapshots_tool_utils.py
16 11 2
def get_own_snapshots_dest()
in lambda/snapshots_tool_utils.py
16 11 2
def get_latest_snapshot_ts()
in lambda/snapshots_tool_utils.py
11 6 2
def requires_backup()
in lambda/snapshots_tool_utils.py
11 5 3
def filter_clusters()
in lambda/snapshots_tool_utils.py
10 7 2
def get_own_snapshots_share()
in lambda/snapshots_tool_utils.py
10 9 2
def search_tag_share()
in lambda/snapshots_tool_utils.py
10 10 1
def search_tag_created()
in lambda/snapshots_tool_utils.py
9 7 1
def get_timestamp()
in lambda/snapshots_tool_utils.py
9 4 2