microsoft / m365-sample-connector-csharp-aspnet
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 171 units with 1,961 lines of code in units (50.2% 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)
    • 10 simple units (304 lines of code)
    • 161 very simple units (1,657 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
cs0% | 0% | 0% | 13% | 86%
js0% | 0% | 0% | 30% | 69%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
Facebook/FacebookSDK0% | 0% | 0% | 28% | 71%
Facebook/WebApp/Controllers0% | 0% | 0% | 20% | 79%
Facebook/WebApp/ClientJs0% | 0% | 0% | 30% | 69%
Facebook/WebApp/Auth0% | 0% | 0% | 83% | 16%
Facebook/WebApp/App_Start0% | 0% | 0% | 44% | 55%
Facebook/ConnectorTest0% | 0% | 0% | 0% | 100%
Common/ConnectorCommon0% | 0% | 0% | 0% | 100%
Common/ConnectorSDK0% | 0% | 0% | 0% | 100%
Facebook/WebJob0% | 0% | 0% | 0% | 100%
Common/ConnectorCommon/Workload0% | 0% | 0% | 0% | 100%
Facebook/WebApp/Extensions0% | 0% | 0% | 0% | 100%
Common/ConnectorCommon/SourceProvider0% | 0% | 0% | 0% | 100%
Common/ConnectorCommon/Tables0% | 0% | 0% | 0% | 100%
Facebook/WebApp0% | 0% | 0% | 0% | 100%
Facebook/WebApp/ErrorHandler0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public static async Task AuthenticateRequestAsync()
in Facebook/WebApp/Auth/AuthenticateRequest.cs
35 9 1
$scope.saveJob = function()
in Facebook/WebApp/ClientJs/NativeConnectorSetupController.js
42 9 0
private async Task CreatePostItem()
in Facebook/FacebookSDK/JobProcessorFB.cs
57 7 5
private async Task HandlePost()
in Facebook/FacebookSDK/JobProcessorFB.cs
22 6 6
private async Task HandleComment()
in Facebook/FacebookSDK/JobProcessorFB.cs
24 6 6
public IHttpHandler GetHttpHandler()
in Facebook/WebApp/App_Start/DefaultRouteHandler.cs
34 6 1
private static bool CheckIfCallerClaimIsAuthorized()
in Facebook/WebApp/Auth/AuthenticateRequest.cs
12 6 1
$scope.SaveConfigSettings = function()
in Facebook/WebApp/ClientJs/ConfigureController.js
15 6 0
public async Task Configure()
in Facebook/WebApp/Controllers/ConfigurationController.cs
30 6 1
private async Task SendDataAsync()
in Facebook/WebApp/Controllers/FbPageWebhookController.cs
33 6 1
private async Task CreateCommentItem()
in Facebook/FacebookSDK/JobProcessorFB.cs
39 5 5
private async Task CreateReplyItem()
in Facebook/FacebookSDK/JobProcessorFB.cs
38 5 6
public override void OnException()
in Facebook/WebApp/ErrorHandler/AiHandleErrorAttribute.cs
12 5 1
public async Task Execute()
in Facebook/WebJob/DataIngestion.cs
32 5 1
public Uri CreateRequestUri()
in Common/ConnectorCommon/RestApiRepository.cs
12 4 2
public override async Task Unsubscribe()
in Facebook/FacebookSDK/FacebookProvider.cs
20 4 1
public async Task FetchPosts()
in Facebook/FacebookSDK/JobProcessorFB.cs
21 4 3
public async Task FetchUpdates()
in Facebook/FacebookSDK/JobProcessorFB.cs
14 4 3
request: function()
in Facebook/WebApp/ClientJs/AuthInterceptor.js
9 4 1
public async Task ScheduleTask()
in Facebook/WebApp/Controllers/DataIngestionController.cs
35 4 1