aws-solutions / distributed-load-testing-on-aws
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 11% duplication:
    • 5,072 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 578 duplicated lines
  • 45 duplicates
system11% (578 lines)
Duplication per Extension
js12% (409 lines)
ts10% (169 lines)
Duplication per Component (primary)
source/infrastructure/lib10% (169 lines)
source/api-services/lib20% (106 lines)
source/console/src5% (102 lines)
source/results-parser/lib23% (69 lines)
source/results-parser28% (28 lines)
source/task-runner12% (25 lines)
source/custom-resource/lib22% (24 lines)
source/task-canceler38% (23 lines)
source/custom-resource41% (20 lines)
source/task-status-checker16% (12 lines)
source/console/public0% (0 lines)
source/api-services0% (0 lines)
source/infrastructure0% (0 lines)
deployment/ecr/distributed-load-testing-on-aws-load-tester0% (0 lines)

Duplication Between Components (50+ lines)

G source/api-services/lib source/api-services/lib source/results-parser/lib source/results-parser/lib source/api-services/lib--source/results-parser/lib 70

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 45 duplicates...
Size#FoldersFilesLinesCode
24 x 2 source/infrastructure/lib
source/infrastructure/lib
api.ts
test-task-lambdas.ts
87:110 (8%)
138:161 (7%)
view
20 x 2 source/api-services/lib/scenarios
source/api-services/lib/scenarios
index.js
index.js
213:232 (4%)
449:468 (4%)
view
18 x 2 source/custom-resource/lib/metrics
source/results-parser/lib/metrics
index.js
index.js
21:43 (56%)
28:50 (52%)
view
18 x 2 source/api-services/lib/metrics
source/custom-resource/lib/metrics
index.js
index.js
27:49 (54%)
21:43 (56%)
view
18 x 2 source/api-services/lib/metrics
source/results-parser/lib/metrics
index.js
index.js
27:49 (54%)
28:50 (52%)
view
12 x 2 source/results-parser
source/task-status-checker
index.js
index.js
111:123 (12%)
82:95 (16%)
view
12 x 2 source/console/src/Components/Create
source/console/src/Components/Create
Create.js
Create.js
535:546 (1%)
570:581 (1%)
view
11 x 2 source/results-parser/lib/parser
source/results-parser/lib/parser
index.js
index.js
209:219 (4%)
259:269 (4%)
view
11 x 2 source/console/src/Components/Details
source/console/src/Components/Details
Details.js
Details.js
343:353 (3%)
361:371 (3%)
view
11 x 2 source/api-services/lib/metrics
source/results-parser/lib/metrics
index.js
index.js
4:21 (33%)
4:21 (32%)
view
11 x 2 source/infrastructure/lib
source/infrastructure/lib
test-task-lambdas.ts
test-task-lambdas.ts
119:129 (3%)
355:365 (3%)
view
11 x 2 source/infrastructure/lib
source/infrastructure/lib
test-task-lambdas.ts
test-task-lambdas.ts
212:222 (3%)
279:289 (3%)
view
10 x 2 source/results-parser
source/results-parser
index.js
index.js
88:97 (10%)
114:123 (10%)
view
10 x 2 source/custom-resource
source/custom-resource
index.js
index.js
24:33 (20%)
38:47 (20%)
view
10 x 2 source/results-parser
source/task-status-checker
index.js
index.js
88:97 (10%)
86:95 (13%)
view
10 x 2 source/task-canceler
source/task-runner
index.js
index.js
26:36 (16%)
238:248 (4%)
view
9 x 2 source/infrastructure/lib
source/infrastructure/lib
test-task-lambdas.ts
test-task-lambdas.ts
212:220 (2%)
355:363 (2%)
view
9 x 2 source/results-parser
source/task-runner
index.js
index.js
89:97 (9%)
264:272 (4%)
view
9 x 2 source/infrastructure/lib
source/infrastructure/lib
test-task-lambdas.ts
test-task-lambdas.ts
119:127 (2%)
279:287 (2%)
view
9 x 2 source/infrastructure/lib
source/infrastructure/lib
test-task-lambdas.ts
test-task-lambdas.ts
279:287 (2%)
355:363 (2%)
view