aws-samples / amazon-aurora-labs-for-mysql
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 24 units with 433 lines of code in units (7.0% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 2 medium complex units (99 lines of code)
    • 1 simple units (29 lines of code)
    • 21 very simple units (305 lines of code)
0% | 0% | 22% | 6% | 70%
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% | 22% | 6% | 70%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
scripts0% | 0% | 24% | 7% | 68%
support0% | 0% | 0% | 0% | 100%
website/lambda/indexdoc-function/src0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def main()
in scripts/replicatekey.py
57 20 0
def thread_func()
in scripts/weather_perf.py
42 11 6
def thread_func()
in scripts/reader_loadtest.py
29 8 6
def validateregion()
in scripts/replicatekey.py
12 5 1
def keyexists()
in scripts/replicatekey.py
12 5 1
def progress_func()
in scripts/reader_loadtest.py
16 5 0
def query_db()
in scripts/bank_deposit.py
11 5 3
def make_deposit()
in scripts/bank_deposit.py
19 5 1
def progress_func()
in scripts/weather_perf.py
17 5 0
def instance_dns_endpoint()
in scripts/aware_failover.py
13 4 2
def track_analytics()
in support/peer_vpcs.py
24 4 0
def lambda_handler()
in website/lambda/indexdoc-function/src/function.py
5 3 2
def track_analytics()
in scripts/reader_loadtest.py
24 3 0
def track_analytics()
in scripts/simple_failover.py
24 3 0
def track_analytics()
in scripts/das_reader.py
24 3 0
def track_analytics()
in scripts/aware_failover.py
24 3 0
def track_analytics()
in scripts/bank_deposit.py
24 3 0
def show_summary()
in scripts/bank_deposit.py
14 3 3
def track_analytics()
in scripts/weather_perf.py
24 3 0
def __new__()
in scripts/das_reader.py
3 1 3