microsoft / azuredatastudio
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 42,499 units with 494,867 lines of code in units (46.4% of code).
    • 22 very complex units (4,863 lines of code)
    • 166 complex units (19,226 lines of code)
    • 1,427 medium complex units (72,161 lines of code)
    • 3,637 simple units (96,507 lines of code)
    • 37,247 very simple units (302,110 lines of code)
<1% | 3% | 14% | 19% | 61%
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
ts<1% | 3% | 14% | 19% | 61%
js5% | 3% | 17% | 23% | 49%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/vs<1% | 5% | 16% | 19% | 57%
extensions/schema-compare33% | 0% | 14% | 10% | 41%
src/sql1% | 1% | 9% | 16% | 71%
extensions/sql-migration3% | 1% | 6% | 18% | 69%
build/lib0% | 5% | 18% | 33% | 43%
extensions/agent0% | 13% | 16% | 20% | 50%
extensions/azurecore0% | 5% | 7% | 17% | 69%
extensions/git0% | 3% | 24% | 24% | 47%
extensions/json-language-features0% | 20% | 32% | 11% | 36%
extensions/sql-database-projects0% | 2% | 10% | 18% | 68%
build/azure-pipelines0% | 9% | 0% | 25% | 64%
resources/web0% | 31% | 0% | 32% | 35%
extensions/resource-deployment0% | <1% | 5% | 21% | 72%
extensions/big-data-cluster0% | 0% | 20% | 27% | 52%
extensions/notebook0% | 0% | 10% | 25% | 64%
build/monaco0% | 0% | 50% | 11% | 37%
extensions/mssql0% | 0% | 8% | 16% | 74%
extensions/arc0% | 0% | 7% | 17% | 74%
extensions/machine-learning0% | 0% | 5% | 18% | 76%
build0% | 0% | 35% | 16% | 47%
extensions/github0% | 0% | 63% | 0% | 36%
extensions/configuration-editing0% | 0% | 38% | 1% | 59%
extensions/search-result0% | 0% | 97% | 0% | 2%
extensions/microsoft-authentication0% | 0% | 20% | 27% | 52%
build/npm0% | 0% | 52% | 30% | 16%
extensions/merge-conflict0% | 0% | 17% | 30% | 52%
extensions/dacpac0% | 0% | 8% | 11% | 79%
src0% | 0% | 38% | 5% | 55%
extensions/theme-seti0% | 0% | 27% | 10% | 62%
extensions/markdown-language-features0% | 0% | 2% | 14% | 82%
extensions/azcli0% | 0% | 13% | 0% | 86%
extensions/admin-tool-ext-win0% | 0% | 35% | 19% | 45%
build/actions0% | 0% | 8% | 5% | 86%
extensions/github-authentication0% | 0% | 7% | 23% | 69%
extensions/import0% | 0% | 0% | 44% | 55%
extensions/data-workspace0% | 0% | 0% | 30% | 69%
extensions/azuremonitor0% | 0% | 0% | 26% | 73%
extensions/kusto0% | 0% | 0% | 26% | 73%
extensions/cms0% | 0% | 0% | 27% | 72%
extensions/sql-assessment0% | 0% | 0% | 16% | 83%
extensions/image-preview0% | 0% | 0% | 14% | 85%
build/builtin0% | 0% | 0% | 42% | 57%
extensions/liveshare0% | 0% | 0% | 6% | 93%
extensions0% | 0% | 0% | 64% | 35%
extensions/server-report0% | 0% | 0% | 25% | 74%
extensions/profiler0% | 0% | 0% | 11% | 88%
build/darwin0% | 0% | 0% | 0% | 100%
extensions/simple-browser0% | 0% | 0% | 0% | 100%
build/linux0% | 0% | 0% | 0% | 100%
extensions/markdown-math0% | 0% | 0% | 0% | 100%
extensions/json0% | 0% | 0% | 0% | 100%
extensions/xml-language-features0% | 0% | 0% | 0% | 100%
extensions/query-history0% | 0% | 0% | 0% | 100%
extensions/azurehybridtoolkit0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public getSchemaCompareIncludedObjectsUtil()
in extensions/schema-compare/src/models/schemaCompareOptionsModel.ts
143 139 1
public setSchemaCompareIncludedObjectsUtil()
in extensions/schema-compare/src/models/schemaCompareOptionsModel.ts
349 139 2
var Tokenizer_1 = function()
in src/sql/base/common/marked/marked.js
490 118 0
public setSchemaCompareOptionUtil()
in extensions/schema-compare/src/models/schemaCompareOptionsModel.ts
232 77 2
public getSchemaCompareOptionUtil()
in extensions/schema-compare/src/models/schemaCompareOptionsModel.ts
157 77 1
public getDescription()
in extensions/schema-compare/src/models/schemaCompareOptionsModel.ts
156 77 1
private registerListeners()
in src/vs/workbench/contrib/debug/browser/debugSession.ts
244 76 0
private _myTokenize()
in src/vs/editor/standalone/common/monarch/monarchLexer.ts
228 74 5
public async onPageEnter()
in extensions/sql-migration/src/wizard/databaseBackupPage.ts
345 73 1
var Lexer_1 = function()
in src/sql/base/common/marked/marked.js
308 65 0
private async createShellLaunchConfig()
in src/vs/workbench/contrib/tasks/browser/terminalTaskSystem.ts
148 62 8
private shouldRunExperiment()
in src/vs/workbench/contrib/experiments/common/experimentService.ts
129 61 2
private async resolveWorkspaceTags()
in src/vs/workbench/contrib/tags/electron-sandbox/workspaceTagsService.ts
152 60 0
private async executeInTerminal()
in src/vs/workbench/contrib/tasks/browser/terminalTaskSystem.ts
238 60 4
private _initialize()
in src/vs/workbench/contrib/notebook/browser/view/renderers/backLayerWebView.ts
252 59 1
async function webviewPreloads()
in src/vs/workbench/contrib/notebook/browser/view/renderers/webviewPreloads.ts
345 59 1
private addPane()
in src/vs/workbench/browser/parts/views/viewPaneContainer.ts
133 55 3
constructor()
in src/vs/workbench/services/keybinding/common/macLinuxKeyboardMapper.ts
244 54 3
async show()
in src/vs/base/browser/ui/dialog/dialog.ts
173 53 0
private getGroupedTasks()
in src/vs/workbench/contrib/tasks/browser/abstractTaskService.ts
197 52 1