aws-samples / aws-cdk-pipelines-datalake-etl
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 31 units with 682 lines of code in units (48.4% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 0 medium complex units (0 lines of code)
    • 4 simple units (221 lines of code)
    • 27 very simple units (461 lines of code)
0% | 0% | 0% | 32% | 67%
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% | 0% | 0% | 32% | 67%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lib/glue_scripts0% | 0% | 0% | 47% | 52%
lib/etl_job_auditor0% | 0% | 0% | 94% | 5%
lib0% | 0% | 0% | 13% | 86%
lib/state_machine_trigger0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def upsert_catalog_table()
in lib/glue_scripts/etl_conformed_to_purposebuilt.py
60 10 5
def lambda_handler()
in lib/etl_job_auditor/lambda_handler.py
65 8 2
def get_local_configuration()
in lib/configuration.py
36 8 1
def upsert_catalog_table()
in lib/glue_scripts/etl_raw_to_conformed.py
60 7 5
def lambda_handler()
in lib/state_machine_trigger/lambda_handler.py
74 5 2
def create_database()
in lib/glue_scripts/etl_conformed_to_purposebuilt.py
22 4 0
def create_database()
in lib/glue_scripts/etl_raw_to_conformed.py
22 4 0
def main()
in lib/glue_scripts/etl_raw_to_conformed.py
34 4 0
def start_etl_job_run()
in lib/state_machine_trigger/lambda_handler.py
23 3 6
def main()
in lib/glue_scripts/etl_conformed_to_purposebuilt.py
26 3 0
def __init__()
in lib/dynamodb_stack.py
19 3 5
def load_log_config()
in lib/state_machine_trigger/lambda_handler.py
4 2 0
def get_tag()
in lib/tagging.py
24 2 2
def table_exists()
in lib/glue_scripts/etl_conformed_to_purposebuilt.py
7 1 2
def add_partition()
in lib/glue_scripts/etl_conformed_to_purposebuilt.py
7 1 1
def table_exists()
in lib/glue_scripts/etl_raw_to_conformed.py
7 1 2
def add_partition()
in lib/glue_scripts/etl_raw_to_conformed.py
7 1 1
def load_log_config()
in lib/etl_job_auditor/lambda_handler.py
4 1 0
def __init__()
in lib/glue_stack.py
6 1 0
def glue_scripts_bucket()
in lib/glue_stack.py
7 1 0