aws / aws-parallelcluster-node
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 191 units with 1,759 lines of code in units (77.2% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 3 medium complex units (93 lines of code)
    • 21 simple units (458 lines of code)
    • 167 very simple units (1,208 lines of code)
0% | 0% | 5% | 26% | 68%
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% | 5% | 26% | 68%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/slurm_plugin0% | 0% | 6% | 24% | 68%
src/common/schedulers0% | 0% | 0% | 28% | 71%
src/common0% | 0% | 0% | 39% | 60%
ROOT0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def _handle_protected_mode_process()
in src/slurm_plugin/clustermgtd.py
35 13 3
def is_state_healthy()
in src/slurm_plugin/slurm_resources.py
26 11 4
def _manage_compute_fleet_status_transitions()
in src/slurm_plugin/clustermgtd.py
32 11 1
def is_state_healthy()
in src/slurm_plugin/slurm_resources.py
13 10 4
def _update_dns_hostnames()
in src/slurm_plugin/instance_manager.py
30 10 2
def is_bootstrap_failure()
in src/slurm_plugin/slurm_resources.py
23 9 1
def manage_cluster()
in src/slurm_plugin/clustermgtd.py
35 9 1
def _update_slurm_node_addrs()
in src/slurm_plugin/instance_manager.py
28 9 3
def from_xml_to_obj()
in src/common/schedulers/converters.py
19 8 2
def _run_command()
in src/common/utils.py
27 8 6
19 8 2
def _run_computemgtd()
in src/slurm_plugin/computemgtd.py
30 8 1
def is_bootstrap_failure()
in src/slurm_plugin/slurm_resources.py
23 8 1
def _reset_nodes_in_inactive_partitions()
in src/slurm_plugin/clustermgtd.py
23 8 1
def _update_static_nodes_in_replacement()
in src/slurm_plugin/clustermgtd.py
12 8 2
def _retrieve_scheduler_partitions()
in src/slurm_plugin/clustermgtd.py
17 8 1
def _batch_node_info()
in src/common/schedulers/slurm_commands.py
19 7 4
def _handle_powering_down_nodes()
in src/slurm_plugin/clustermgtd.py
10 7 2
def _get_partition_nodes()
in src/common/schedulers/slurm_commands.py
9 6 2
def fail_ec2_health_check()
in src/slurm_plugin/slurm_resources.py
22 6 3