aws-samples / cicd-for-networking-resources
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 17 units with 307 lines of code in units (29.7% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 7 medium size units (181 lines of code)
    • 6 small units (108 lines of code)
    • 4 very small units (18 lines of code)
0% | 0% | 58% | 35% | 5%
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% | 58% | 35% | 5%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
SecurityGroups/config/code0% | 0% | 58% | 35% | 5%
Alternative Visuals
Longest Units
Top 17 longest units
Unit# linesMcCabe index# params
def currentIngressRule()
in SecurityGroups/config/code/index.py
36 6 1
def currentEgressRule()
in SecurityGroups/config/code/index.py
36 6 1
def send()
in SecurityGroups/config/code/cfnresponse.py
25 4 7
def csvParser()
in SecurityGroups/config/code/index.py
21 5 0
def authorizeIngressRule()
in SecurityGroups/config/code/index.py
21 7 2
def compareSecurityGroupIngressRules()
in SecurityGroups/config/code/index.py
21 9 3
def compareSecurityGroupEgressRules()
in SecurityGroups/config/code/index.py
21 9 3
def revokeIngressRule()
in SecurityGroups/config/code/index.py
20 6 2
def authorizeEgressRule()
in SecurityGroups/config/code/index.py
20 7 2
def revokeEgressRule()
in SecurityGroups/config/code/index.py
20 6 2
def lambda_handler()
in SecurityGroups/config/code/index.py
20 5 2
def create_pipeline_managed_security_groups()
in SecurityGroups/config/code/index.py
14 1 1
def describe_pipeline_managed_security_groups()
in SecurityGroups/config/code/index.py
14 6 1
def get_vpc_id()
in SecurityGroups/config/code/index.py
9 3 1
def _add_entry()
in SecurityGroups/config/code/index.py
3 2 3
def extract_other_security_group()
in SecurityGroups/config/code/index.py
3 1 1
def extract_prefix_list_id()
in SecurityGroups/config/code/index.py
3 1 1