aws / aws-xray-daemon
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 120 units with 1,601 lines of code in units (76.3% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 2 medium complex units (97 lines of code)
    • 10 simple units (394 lines of code)
    • 108 very simple units (1,110 lines of code)
0% | 0% | 6% | 24% | 69%
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
go0% | 0% | 6% | 24% | 69%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
pkg/processor0% | 0% | 29% | 15% | 54%
pkg/logger0% | 0% | 100% | 0% | 0%
cmd/tracing0% | 0% | 0% | 44% | 55%
pkg/telemetry0% | 0% | 0% | 33% | 66%
pkg/proxy0% | 0% | 0% | 68% | 31%
pkg/conn0% | 0% | 0% | 17% | 82%
pkg/util0% | 0% | 0% | 67% | 32%
pkg/cfg0% | 0% | 0% | 10% | 89%
pkg/bufferpool0% | 0% | 0% | 0% | 100%
pkg/cli0% | 0% | 0% | 0% | 100%
pkg/ringbuffer0% | 0% | 0% | 0% | 100%
pkg/tracesegment0% | 0% | 0% | 0% | 100%
pkg/profiler0% | 0% | 0% | 0% | 100%
pkg/socketconn0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
func LoadLogConfig()
in pkg/logger/log_config.go
35 14 3
func()
in pkg/processor/batchprocessor.go
62 11 1
func()
in cmd/tracing/daemon.go
58 10 1
func EvaluateConnectionError()
in pkg/telemetry/telemetry.go
26 9 1
func()
in pkg/processor/processor.go
33 9 1
func newT()
in pkg/telemetry/telemetry.go
56 8 4
func NewServer()
in pkg/proxy/server.go
49 8 3
func GetAWSConfigSession()
in pkg/conn/conn.go
42 8 5
func SplitHeaderBody()
in pkg/util/util.go
31 7 3
func ConfigValidation()
in pkg/cfg/cfg.go
23 6 1
func getServiceEndpoint()
in pkg/proxy/server.go
13 6 1
func initDaemon()
in cmd/tracing/daemon.go
63 6 1
func MemSnapShot()
in pkg/profiler/profiler.go
17 5 1
func configFlagArray()
in pkg/cfg/cfg.go
15 5 1
func()
in pkg/telemetry/telemetry.go
29 5 1
func()
in pkg/telemetry/telemetry.go
24 5 1
func LoadConfig()
in pkg/cfg/cfg.go
12 4 1
func merge()
in pkg/cfg/cfg.go
31 4 1
func()
in pkg/telemetry/telemetry.go
17 4 1
func()
in pkg/telemetry/telemetry.go
18 4 1