aws-robotics / cloudwatch-common
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 216 units with 2,219 lines of code in units (54.5% 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)
    • 20 simple units (707 lines of code)
    • 196 very simple units (1,512 lines of code)
0% | 0% | 0% | 31% | 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
cpp0% | 0% | 0% | 47% | 52%
h0% | 0% | 0% | 9% | 90%
hpp0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
cloudwatch_logs_common/src0% | 0% | 0% | 69% | 30%
cloudwatch_metrics_common/src0% | 0% | 0% | 46% | 53%
file_management/src0% | 0% | 0% | 17% | 82%
file_management/include0% | 0% | 0% | 19% | 80%
cloudwatch_metrics_common/include0% | 0% | 0% | 76% | 23%
dataflow_lite/include0% | 0% | 0% | 0% | 100%
dataflow_lite/src0% | 0% | 0% | 0% | 100%
cloudwatch_logs_common/include0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
bool LogBatcher::publishBatchedData()
in cloudwatch_logs_common/src/log_batcher.cpp
48 10 0
Aws::CloudWatchLogs::ROSCloudWatchLogsErrors CloudWatchLogsFacade::CheckLogStreamExists()
in cloudwatch_logs_common/src/utils/cloudwatch_logs_facade.cpp
48 10 3
bool MetricBatcher::publishBatchedData()
in cloudwatch_metrics_common/src/metric_batcher.cpp
48 10 0
Aws::CloudWatchLogs::ROSCloudWatchLogsErrors CloudWatchLogsFacade::CheckLogGroupExists()
in cloudwatch_logs_common/src/utils/cloudwatch_logs_facade.cpp
40 9 1
MetricDatum deserializeMetricDatum()
in cloudwatch_metrics_common/src/utils/metric_serialization.cpp
38 9 1
static MetricDatum metricObjectToDatum()
in cloudwatch_metrics_common/include/cloudwatch_metrics_common/utils/metric_object.h
39 9 2
Aws::CloudWatchLogs::ROSCloudWatchLogsErrors LogPublisher::SendLogs()
in cloudwatch_logs_common/src/log_publisher.cpp
38 8 2
bool LogPublisher::configure()
in cloudwatch_logs_common/src/log_publisher.cpp
25 8 0
Aws::CloudWatchLogs::ROSCloudWatchLogsErrors CloudWatchLogsFacade::SendLogsToCloudWatch()
in cloudwatch_logs_common/src/utils/cloudwatch_logs_facade.cpp
53 8 4
FileObject LogFileManager::readBatch()
in cloudwatch_logs_common/src/utils/log_file_manager.cpp
51 8 1
Aws::CloudWatchLogs::ROSCloudWatchLogsErrors CloudWatchLogsFacade::SendLogsRequest()
in cloudwatch_logs_common/src/utils/cloudwatch_logs_facade.cpp
34 7 2
bool LogPublisher::CreateGroup()
in cloudwatch_logs_common/src/log_publisher.cpp
31 6 0
bool LogPublisher::CreateStream()
in cloudwatch_logs_common/src/log_publisher.cpp
30 6 0
Aws::DataFlow::UploadStatus LogPublisher::publishData()
in cloudwatch_logs_common/src/log_publisher.cpp
24 6 1
CloudWatchMetricsStatus CloudWatchMetricsFacade::SendMetricsRequest()
in cloudwatch_metrics_common/src/utils/cloudwatch_metrics_facade.cpp
23 6 1
CloudWatchMetricsStatus CloudWatchMetricsFacade::SendMetricsToCloudWatch()
in cloudwatch_metrics_common/src/utils/cloudwatch_metrics_facade.cpp
28 6 2
bool FileManagerStrategy::isDataAvailable()
in file_management/src/file_upload/file_manager_strategy.cpp
8 6 0
DataToken FileManagerStrategy::read()
in file_management/src/file_upload/file_manager_strategy.cpp
31 6 1
void FileManagerStrategy::resolve()
in file_management/src/file_upload/file_manager_strategy.cpp
27 6 2
inline void work()
in file_management/include/file_management/file_upload/file_upload_streamer.h
43 6 0