aws / aws-app-mesh-controller-for-k8s
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 1,104 units with 12,804 lines of code in units (50.3% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 18 medium complex units (904 lines of code)
    • 89 simple units (2,372 lines of code)
    • 997 very simple units (9,528 lines of code)
0% | 0% | 7% | 18% | 74%
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% | 7% | 18% | 74%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
ROOT0% | 0% | 97% | 0% | 2%
pkg/inject0% | 0% | 14% | 16% | 69%
pkg/virtualrouter0% | 0% | 19% | 13% | 67%
pkg/conversions0% | 0% | 5% | 30% | 64%
pkg/cloudmap0% | 0% | 8% | 32% | 58%
pkg/k8s0% | 0% | 13% | 19% | 67%
apis/appmesh0% | 0% | 1% | 10% | 87%
pkg/gatewayroute0% | 0% | 9% | 13% | 76%
pkg/virtualservice0% | 0% | 8% | 5% | 86%
pkg/virtualgateway0% | 0% | 8% | 17% | 73%
pkg/mesh0% | 0% | 7% | 21% | 70%
webhooks/appmesh0% | 0% | 0% | 24% | 75%
pkg/aws0% | 0% | 0% | 29% | 70%
pkg/virtualnode0% | 0% | 0% | 23% | 76%
controllers/appmesh0% | 0% | 0% | 12% | 87%
pkg/webhook0% | 0% | 0% | 15% | 84%
pkg/equality0% | 0% | 0% | 44% | 55%
mocks/aws-app-mesh-controller-for-k8s0% | 0% | 0% | 0% | 100%
pkg/references0% | 0% | 0% | 0% | 100%
pkg/runtime0% | 0% | 0% | 0% | 100%
mocks/apimachinery0% | 0% | 0% | 0% | 100%
webhooks/core0% | 0% | 0% | 0% | 100%
pkg/algorithm0% | 0% | 0% | 0% | 100%
pkg/version0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
func main()
in main.go
176 16 0
func()
in pkg/inject/inject.go
39 15 1
func()
in pkg/k8s/custom_controller.go
52 15 1
func updateEnvMapForEnvoy()
in pkg/inject/sidecar_builder.go
57 14 3
func ExtractVirtualNodeReferences()
in pkg/virtualrouter/references.go
34 14 1
func sidecarResources()
in pkg/inject/sidecar_builder.go
40 13 4
func Convert_CRD_VirtualNodeSpec_To_SDK_VirtualNodeSpec()
in pkg/conversions/virtualnode_types_conversion.go
51 13 3
func()
in pkg/cloudmap/instances_health_prober.go
56 12 1
func Convert_CRD_Listener_To_SDK_Listener()
in pkg/conversions/virtualnode_types_conversion.go
47 12 3
func()
in pkg/inject/xray.go
38 11 1
func()
in pkg/virtualservice/resource_manager.go
39 11 1
func()
in pkg/virtualrouter/routes_manager.go
41 11 1
func()
in pkg/virtualrouter/resource_manager.go
41 11 1
func()
in pkg/mesh/members_finalizer.go
28 11 1
func()
in pkg/virtualgateway/membership_designator.go
37 11 1
func()
in pkg/cloudmap/resource_manager.go
42 11 1
func()
in pkg/gatewayroute/resource_manager.go
39 11 1
func()
in apis/appmesh/v1beta2/zz_generated.deepcopy.go
47 11 1
func()
in pkg/inject/virtualgateway_envoy.go
35 10 1
func()
in pkg/aws/throttle/config.go
43 10 1