aws-samples / amazon-emr-on-eks-scale-test-tool
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 27 units with 209 lines of code in units (21.1% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 1 medium size units (30 lines of code)
    • 6 small units (87 lines of code)
    • 20 very small units (92 lines of code)
0% | 0% | 14% | 41% | 44%
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% | 14% | 41% | 44%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
scale_test_tool/helper0% | 0% | 27% | 31% | 41%
scale_test_tool/tasks0% | 0% | 0% | 69% | 30%
scale_test_tool/locust0% | 0% | 0% | 36% | 63%
scale_test_tool/config0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def submit_job()
in scale_test_tool/helper/emr_container_helper.py
30 1 7
def create_virtual_cluster()
in scale_test_tool/helper/emr_container_helper.py
19 1 5
def generate_report()
in scale_test_tool/helper/scale_test_output_generator.py
16 2 1
def delete_virtual_cluster_namespace()
in scale_test_tool/tasks/virtual_cluster_task.py
15 2 3
def on_test_stop()
in scale_test_tool/locust/locust_main.py
13 3 1
def start_job_run()
in scale_test_tool/tasks/job_run_task.py
12 1 3
def create_namespace_and_virtual_cluster()
in scale_test_tool/tasks/virtual_cluster_task.py
12 1 2
def describe_job()
in scale_test_tool/helper/emr_container_helper.py
10 2 3
def _is_virtual_cluster_ready_for_cleanup()
in scale_test_tool/tasks/virtual_cluster_task.py
9 2 2
def start_job_run()
in scale_test_tool/locust/locust_main.py
9 1 1
def extract_job_run_report_data()
in scale_test_tool/helper/scale_test_output_generator.py
7 1 1
def write_job_run_report_header()
in scale_test_tool/helper/scale_test_output_generator.py
7 1 1
def write_job_run_entry_to_csv()
in scale_test_tool/helper/scale_test_output_generator.py
6 1 2
def list_job_run_in_running_state()
in scale_test_tool/helper/emr_container_helper.py
6 1 3
def delete_virtual_cluster()
in scale_test_tool/helper/emr_container_helper.py
5 1 2
def describe_virtual_cluster()
in scale_test_tool/helper/emr_container_helper.py
5 1 2
def _setup_virtual_cluster()
in scale_test_tool/locust/locust_main.py
5 1 0
def __init__()
in scale_test_tool/config/boto_client_config.py
4 2 1
def on_test_start()
in scale_test_tool/locust/locust_main.py
3 1 1
def __init__()
in scale_test_tool/tasks/job_run_task.py
2 1 2