awslabs / aws-fluent-plugin-kinesis
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 71 units with 592 lines of code in units (67.6% of code).
    • 0 very complex units (0 lines of code)
    • 1 complex units (74 lines of code)
    • 0 medium complex units (0 lines of code)
    • 4 simple units (80 lines of code)
    • 66 very simple units (438 lines of code)
0% | 12% | 0% | 13% | 73%
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
rb0% | 14% | 0% | 11% | 74%
rake0% | 0% | 0% | 26% | 73%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lib/fluent/plugin/kinesis_helper0% | 22% | 0% | 18% | 58%
benchmark0% | 0% | 0% | 26% | 73%
lib/fluent/plugin0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
setup_credentials
in lib/fluent/plugin/kinesis_helper/client.rb
74 34 0
give_up_retries
in lib/fluent/plugin/kinesis_helper/api.rb
29 7 1
batch_request_with_retry
in lib/fluent/plugin/kinesis_helper/api.rb
18 6 4
client_options
in lib/fluent/plugin/kinesis_helper/client.rb
15 6 0
rake
create_driver
in benchmark/task.rake
18 6 2
configure
in lib/fluent/plugin/kinesis_helper/api.rb
13 5 1
increment_num_errors
in lib/fluent/plugin/kinesis_helper/api.rb
10 5 0
data_formatter_create
in lib/fluent/plugin/kinesis.rb
23 5 1
collect_failed_records
in lib/fluent/plugin/kinesis_helper/api.rb
16 4 2
failed_count
in lib/fluent/plugin/kinesis_helper/api.rb
8 4 1
results
in lib/fluent/plugin/kinesis_helper/api.rb
8 4 1
key_formatter_create
in lib/fluent/plugin/out_kinesis_streams.rb
12 3 0
deaggregate
in lib/fluent/plugin/kinesis_helper/aggregator.rb
13 3 1
split_to_batches
in lib/fluent/plugin/kinesis_helper/api.rb
15 3 2
retry_records
in lib/fluent/plugin/kinesis_helper/api.rb
8 3 1
client_class
in lib/fluent/plugin/kinesis_helper/client.rb
10 3 0
compressor_create
in lib/fluent/plugin/kinesis.rb
10 3 0
format_for_api
in lib/fluent/plugin/kinesis.rb
11 3 1
rake
run
in benchmark/task.rake
5 3 0
offset
in lib/fluent/plugin/out_kinesis_streams_aggregated.rb
3 2 0