awslabs / aws-cloudendure-migration-factory-solution
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 495 units with 13,048 lines of code in units (65.9% of code).
    • 0 very complex units (0 lines of code)
    • 30 complex units (2,981 lines of code)
    • 58 medium complex units (3,350 lines of code)
    • 59 simple units (1,851 lines of code)
    • 348 very simple units (4,866 lines of code)
0% | 22% | 25% | 14% | 37%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
py0% | 32% | 30% | 16% | 20%
js0% | 0% | 15% | 9% | 75%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
Tools Integration/MGN-Integration0% | 37% | 28% | 17% | 16%
Tools Integration/CE-Integration0% | 17% | 40% | 22% | 20%
backend/lambda_schema_app0% | 100% | 0% | 0% | 0%
backend/lambda_schema_wave0% | 100% | 0% | 0% | 0%
backend/lambda_schema_server0% | 100% | 0% | 0% | 0%
backend/lambda_server_item0% | 88% | 0% | 0% | 11%
backend/lambda_app_item0% | 93% | 0% | 0% | 6%
backend/lambda_wave_item0% | 100% | 0% | 0% | 0%
backend/lambda_stage_attr0% | 100% | 0% | 0% | 0%
backend/lambda_servers0% | 84% | 0% | 0% | 15%
backend/lambda_apps0% | 91% | 0% | 0% | 8%
backend/lambda_stage0% | 100% | 0% | 0% | 0%
backend/lambda_role_item0% | 100% | 0% | 0% | 0%
frontend/src0% | 0% | 15% | 9% | 75%
backend/lambda_ams_wig0% | 0% | 80% | 19% | 0%
backend/policy0% | 0% | 46% | 22% | 30%
backend/lambda_waves0% | 0% | 100% | 0% | 0%
backend/lambda_build0% | 0% | 29% | 0% | 70%
backend/lambda_role0% | 0% | 100% | 0% | 0%
backend/lambda_migrationtracker_glue_scriptcopy0% | 0% | 0% | 35% | 64%
backend/lambda_migrationtracker_glue_execute0% | 0% | 0% | 39% | 60%
backend/lambda_service_account0% | 0% | 0% | 0% | 100%
backend/lambda_defaultschema0% | 0% | 0% | 0% | 100%
backend/helper0% | 0% | 0% | 0% | 100%
backend/lambda_reset0% | 0% | 0% | 0% | 100%
backend/lambda_login0% | 0% | 0% | 0% | 100%
backend/lambda_run_athena_savedquery0% | 0% | 0% | 0% | 100%
backend/lambda_cognitogroups0% | 0% | 0% | 0% | 100%
backend/lambda_auth0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def create_launch_template()
in source/Tools Integration/MGN-Integration/Lambdas/lambda_mgn_template.py
162 45 8
def lambda_handler()
in source/backend/lambda_server_item/lambda_server_item.py
118 44 2
def get_factory_servers()
in source/Tools Integration/CE-Integration/CE-automation-scripts/mfcommon.py
85 43 3
def lambda_handler()
in source/backend/lambda_schema_app/lambda_schema_app.py
139 43 2
def get_factory_servers()
in source/Tools Integration/MGN-Integration/MGN-automation-scripts/mfcommon.py
93 42 4
def verify_instance_status()
in source/Tools Integration/MGN-Integration/MGN-automation-scripts/3-Verify-instance-status.py
120 42 3
def lambda_handler()
in source/backend/lambda_schema_wave/lambda_schema_wave.py
132 41 2
def lambda_handler()
in source/backend/lambda_schema_server/lambda_schema_server.py
132 41 2
def lambda_handler()
in source/backend/lambda_app_item/lambda_app_item.py
111 39 2
def get_factory_servers()
in source/Tools Integration/MGN-Integration/MGN-automation-scripts/0-Prerequisites-checks.py
78 37 3
def lambda_handler()
in source/backend/lambda_wave_item/lambda_wave_item.py
109 36 2
def verify_instance_status()
in source/Tools Integration/CE-Integration/CE-automation-scripts/3-Verify-instance-status.py
113 35 6
def verify_target_account_servers()
in source/Tools Integration/MGN-Integration/Lambdas/lambda_mgn.py
86 35 1
def lambda_handler()
in source/backend/lambda_apps/lambda_apps.py
84 32 2
def lambda_handler()
in source/backend/lambda_servers/lambda_servers.py
86 32 2
def manage_action()
in source/Tools Integration/MGN-Integration/Lambdas/lambda_mgn_launch.py
90 31 2
def get_factory_servers()
in source/Tools Integration/MGN-Integration/Lambdas/lambda_mgn.py
58 30 2
def verify_replication()
in source/Tools Integration/MGN-Integration/MGN-automation-scripts/2-Verify-replication.py
91 30 2
def lambda_handler()
in source/backend/lambda_stage_attr/lambda_stage_attr.py
87 30 2
def status()
in source/Tools Integration/CE-Integration/Lambdas/CheckMachine.py
65 29 9