awslabs / qldb-workbench
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 40 units with 990 lines of code in units (44.0% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 1 medium complex units (279 lines of code)
    • 2 simple units (74 lines of code)
    • 37 very simple units (637 lines of code)
0% | 0% | 28% | 7% | 64%
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
tsx0% | 0% | 36% | 0% | 63%
ts0% | 0% | 0% | 32% | 67%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/core0% | 0% | 31% | 8% | 59%
src/mode0% | 0% | 0% | 0% | 100%
src0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
export default()
in src/core/DrawerItems.tsx
279 17 7
32 8 2
42 8 3
function findAllHeaders()
in src/core/Results.tsx
13 5 1
export function execute()
in src/core/Results.tsx
36 5 3
export default()
in src/core/Results.tsx
121 5 11
19 3 0
25 3 3
function tablesOf()
in src/core/DrawerItems.tsx
9 3 1
function determineRegion()
in src/core/ledger.ts
6 2 1
export function openLedger()
in src/core/session.ts
26 2 1
queryStats: flattenQueryStats()
in src/core/QueryHandler.tsx
4 2 1
function TabPanel()
in src/core/Results.tsx
18 2 1
function prepareQueryStatsView()
in src/core/Results.tsx
19 2 1
function prepareIonView()
in src/core/Results.tsx
41 2 2
function historyEntrySelected()
in src/core/Results.tsx
9 2 1
4 1 0
function parseTableInfos()
in src/core/ledger.ts
3 1 1
function parseTableInfo()
in src/core/ledger.ts
8 1 1
indexes: parseIndexInfos()
in src/core/ledger.ts
5 1 1