aws-samples / aws-saas-factory-eks-saas-workshop
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 162 units with 1,775 lines of code in units (26.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)
    • 0 simple units (0 lines of code)
    • 162 very simple units (1,775 lines of code)
0% | 0% | 0% | 0% | 100%
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
ts0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
cdk/root/lib0% | 0% | 0% | 0% | 100%
services/shared/apps0% | 0% | 0% | 0% | 100%
services/application/apps0% | 0% | 0% | 0% | 100%
client/web/application0% | 0% | 0% | 0% | 100%
client/web/admin0% | 0% | 0% | 0% | 100%
cdk/eks/lib0% | 0% | 0% | 0% | 100%
services/application/libs0% | 0% | 0% | 0% | 100%
services/shared/libs0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
remove()
in client/web/application/src/app/orders/orders-create/orders-create.component.ts
17 4 1
async getPlanBasedUserPool()
in services/shared/apps/tenant-registration/src/idp-service/idp.service.ts
30 4 3
private async createUserPool()
in services/shared/apps/tenant-registration/src/idp-service/idp.service.ts
50 4 2
getPath()
in services/shared/apps/tenant-management/src/tenants/tenants.service.ts
7 4 1
async getCredentials()
in services/application/libs/auth/src/credential-vendor.ts
25 4 1
isFieldInvalid()
in client/web/admin/src/app/tenants/create.component.ts
4 3 1
isFieldInvalid()
in client/web/admin/src/app/users/user-create/user-create.component.ts
4 3 1
isFieldInvalid()
in client/web/application/src/app/users/user-create/user-create.component.ts
4 3 1
add()
in client/web/application/src/app/orders/orders-create/orders-create.component.ts
14 3 1
async findOne()
in services/application/apps/product/src/products/products.service.ts
25 3 2
async findOne()
in services/application/apps/order/src/orders/orders.service.ts
33 3 2
async findAll()
in services/application/apps/user/src/users/users.service.ts
44 3 2
constructor()
in cdk/root/lib/admin/admin-stack.ts
57 2 3
dateTime: Date()
in cdk/root/lib/tenant-infra/tenant-infra-stack.ts
8 2 1
async function getTenantStackData()
in cdk/root/lib/tenant-infra/tenant-infra-stack.ts
12 2 0
async function getStackMetadata()
in cdk/root/lib/tenant-infra/tenant-infra-stack.ts
12 2 0
ngOnInit()
in client/web/admin/src/app/app.component.ts
8 2 0
getTenantUrl()
in client/web/admin/src/app/tenants/create.component.ts
10 2 0
ngOnInit()
in client/web/application/src/app/app.component.ts
8 2 0
async create()
in services/shared/apps/tenant-registration/src/registration/registration.service.ts
17 2 1