awslabs / federated-amazon-eks-clusters-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 26 units with 417 lines of code in units (79.7% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (51 lines of code)
    • 6 medium size units (198 lines of code)
    • 6 small units (93 lines of code)
    • 13 very small units (75 lines of code)
0% | 12% | 47% | 22% | 17%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 13% | 41% | 24% | 19%
ts0% | 0% | 100% | 0% | 0%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
eksfedctl0% | 13% | 41% | 24% | 19%
cdk-vpc-peering/src0% | 0% | 100% | 0% | 0%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def create_federated_clusters()
in source/eksfedctl/create_script.py
51 3 1
constructor()
in source/cdk-vpc-peering/src/vpc-peering-construct.ts
40 5 3
def main()
in source/eksfedctl/eksfedctl.py
37 4 0
def get_config()
in source/eksfedctl/create_action.py
35 11 1
def clusters_disable_public_access()
in source/eksfedctl/create_script.py
31 1 2
def create_vpc_peering()
in source/eksfedctl/create_script.py
31 4 8
def validate_user_yaml()
in source/eksfedctl/create_action.py
24 11 1
def validate_config()
in source/eksfedctl/create_action.py
19 8 1
def load_yaml()
in source/eksfedctl/create_action.py
19 5 1
def get_instance_metadata()
in source/eksfedctl/create_action.py
17 1 0
def clusters_join_federation()
in source/eksfedctl/create_script.py
14 3 2
def exec_command()
in source/eksfedctl/execution.py
13 3 2
def create_identity_mapping()
in source/eksfedctl/create_script.py
11 3 3
def process()
in source/eksfedctl/destroy_action.py
10 2 1
def process()
in source/eksfedctl/create_action.py
8 2 1
def write_output_config()
in source/eksfedctl/create_script.py
8 2 2
def try_remove_files()
in source/eksfedctl/create_script.py
8 3 1
def confirm_destroy()
in source/eksfedctl/destroy_action.py
8 3 0
def dump_config()
in source/eksfedctl/create_action.py
6 1 1
def error()
in source/eksfedctl/eksfedctl.py
6 2 2