aws-samples / amazon-chime-sdk-amazon-connect-integration-demo
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 30 units with 333 lines of code in units (24.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)
    • 1 simple units (52 lines of code)
    • 29 very simple units (281 lines of code)
0% | 0% | 0% | 15% | 84%
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
js0% | 0% | 0% | 15% | 84%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
customer/src/customer0% | 0% | 0% | 30% | 69%
agent/src/agent0% | 0% | 0% | 0% | 100%
agent/src/meeting-operations0% | 0% | 0% | 0% | 100%
customer/src0% | 0% | 0% | 0% | 100%
agent/src0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
function successHandler()
in customer/src/customer/index.js
52 7 1
chatSession.incomingItemDecorator = function()
in customer/src/customer/index.js
20 5 1
async function handleVideoToggleButton()
in agent/src/agent/index.js
13 4 1
function getMeetingInfo()
in agent/src/agent/index.js
12 4 1
$()
in customer/src/customer/index.js
48 3 1
export async function endMeeting()
in agent/src/meeting-operations/meeting.js
20 3 1
async function initializeMeetingSession()
in customer/src/customer/index.js
18 2 0
function endCurrentMeetingSession()
in customer/src/customer/index.js
10 2 0
function initButtons()
in agent/src/agent/index.js
9 2 0
async function handleContactEnded()
in agent/src/agent/index.js
9 2 1
function leave()
in agent/src/agent/index.js
14 2 0
$()
in customer/src/customer/index.js
2 1 1
function failureHandler()
in customer/src/customer/index.js
3 1 1
setTimeout()
in customer/src/customer/index.js
3 1 1
function resetForm()
in customer/src/customer/index.js
11 1 0
function leave()
in customer/src/customer/index.js
4 1 0
export function domElement()
in customer/src/utils.js
3 1 1
export function domShow()
in customer/src/utils.js
5 1 1
export function domHide()
in customer/src/utils.js
5 1 1
function initCCP()
in agent/src/agent/index.js
10 1 0