aws-samples / aws-quarkus-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 64 units with 556 lines of code in units (47.5% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 1 medium complex units (63 lines of code)
    • 0 simple units (0 lines of code)
    • 63 very simple units (493 lines of code)
0% | 0% | 11% | 0% | 88%
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
java0% | 0% | 19% | 0% | 80%
ts0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lambda/src/main/java/com/amazon/example0% | 0% | 95% | 0% | 4%
fargate/eks_cdk/lib0% | 0% | 0% | 0% | 100%
fargate/src/main/java/com/amazon/example/pojo0% | 0% | 0% | 0% | 100%
lambda/src/main/java/com/amazon/example/pojo0% | 0% | 0% | 0% | 100%
fargate/ecs_cdk/lib0% | 0% | 0% | 0% | 100%
fargate/src/main/java/com/amazon/example/service0% | 0% | 0% | 0% | 100%
lambda/src/main/java/com/amazon/example/service0% | 0% | 0% | 0% | 100%
fargate/src/main/java/com/amazon/example/resource0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
public APIGatewayProxyResponseEvent handleRequest()
in lambda/src/main/java/com/amazon/example/ProcessingLambda.java
63 13 2
public boolean equals()
in fargate/src/main/java/com/amazon/example/pojo/User.java
6 4 1
public boolean equals()
in lambda/src/main/java/com/amazon/example/pojo/User.java
6 4 1
public static User from()
in fargate/src/main/java/com/amazon/example/pojo/User.java
11 3 1
public static User from()
in lambda/src/main/java/com/amazon/example/pojo/User.java
11 3 1
constructor()
in fargate/ecs_cdk/lib/ecs_cdk-stack.ts
52 1 3
public String getTableName()
in fargate/src/main/java/com/amazon/example/service/AbstractService.java
3 1 0
protected ScanRequest scanRequest()
in fargate/src/main/java/com/amazon/example/service/AbstractService.java
4 1 0
protected PutItemRequest putRequest()
in fargate/src/main/java/com/amazon/example/service/AbstractService.java
12 1 1
protected DeleteItemRequest deleteRequest()
in fargate/src/main/java/com/amazon/example/service/AbstractService.java
5 1 1
protected GetItemRequest getRequest()
in fargate/src/main/java/com/amazon/example/service/AbstractService.java
9 1 1
public List findAll()
in fargate/src/main/java/com/amazon/example/service/UserService.java
5 1 0
public List add()
in fargate/src/main/java/com/amazon/example/service/UserService.java
4 1 1
public User get()
in fargate/src/main/java/com/amazon/example/service/UserService.java
3 1 1
public List delete()
in fargate/src/main/java/com/amazon/example/service/UserService.java
4 1 1
public User getUser()
in fargate/src/main/java/com/amazon/example/resource/UserResource.java
3 1 1
public List getUsers()
in fargate/src/main/java/com/amazon/example/resource/UserResource.java
3 1 0
public User createUser()
in fargate/src/main/java/com/amazon/example/resource/UserResource.java
6 1 1
public List deleteUser()
in fargate/src/main/java/com/amazon/example/resource/UserResource.java
3 1 1
private String createUserId()
in fargate/src/main/java/com/amazon/example/resource/UserResource.java
3 1 0