aws-solutions / operations-conductor
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
  • 28% duplication:
    • 7,992 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 2,289 duplicated lines
  • 331 duplicates
system28% (2,289 lines)
Duplication per Extension
yaml54% (1,035 lines)
tsx27% (1,014 lines)
ts10% (240 lines)
Duplication per Component (primary)
services/custom-resource45% (1,077 lines)
console/src27% (1,014 lines)
services/tasks12% (109 lines)
services/users16% (49 lines)
services/actions21% (24 lines)
services/resource-selector5% (16 lines)
console/public0% (0 lines)
services/logger0% (0 lines)
services/common0% (0 lines)
services/queue-consumer0% (0 lines)
services/metrics0% (0 lines)

Duplication Between Components (50+ lines)

G console/src console/src services/tasks services/tasks console/src--services/tasks 79

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 331 duplicates...
Size#FoldersFilesLinesCode
138 x 2 source/services/custom-r...onductor-ResizeInstance
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
682:821 (18%)
335:474 (32%)
view
70 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...onductor-ResizeInstance
automation_document.yaml
automation_document.yaml
216:285 (27%)
681:750 (9%)
view
70 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...onductor-CreateSnapshot
automation_document.yaml
automation_document.yaml
216:285 (27%)
188:257 (30%)
view
70 x 2 source/services/custom-r...onductor-CreateSnapshot
source/services/custom-r...onductor-ResizeInstance
automation_document.yaml
automation_document.yaml
188:257 (30%)
681:750 (9%)
view
69 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
217:285 (26%)
335:403 (16%)
view
69 x 2 source/services/custom-r...onductor-DeleteSnapshot
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
229:297 (26%)
335:403 (16%)
view
69 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...onductor-DeleteSnapshot
automation_document.yaml
automation_document.yaml
217:285 (26%)
229:297 (26%)
view
69 x 2 source/services/custom-r...onductor-DeleteSnapshot
source/services/custom-r...onductor-ResizeInstance
automation_document.yaml
automation_document.yaml
229:297 (26%)
682:750 (9%)
view
69 x 2 source/services/custom-r...onductor-CreateSnapshot
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
189:257 (29%)
335:403 (16%)
view
69 x 2 source/services/custom-r...onductor-CreateSnapshot
source/services/custom-r...onductor-DeleteSnapshot
automation_document.yaml
automation_document.yaml
189:257 (29%)
229:297 (26%)
view
24 x 2 source/services/custom-r...onductor-CreateSnapshot
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
34:64 (10%)
54:84 (5%)
view
24 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...onductor-CreateSnapshot
automation_document.yaml
automation_document.yaml
39:69 (9%)
34:64 (10%)
view
24 x 2 source/console/src/views
source/console/src/views
Actions.tsx
Users.tsx
222:250 (13%)
433:461 (4%)
view
24 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
39:69 (9%)
54:84 (5%)
view
23 x 2 source/console/src/views
source/console/src/views
AutomationExecutions.tsx
TaskDetail.tsx
231:253 (10%)
760:782 (2%)
view
22 x 2 source/services/custom-r...onductor-ResizeInstance
source/services/custom-r...onductor-ResizeInstance
automation_document.yaml
automation_document.yaml
729:750 (2%)
800:821 (2%)
view
22 x 2 source/services/custom-r...sConductor-CopySnapshot
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
264:285 (8%)
453:474 (5%)
view
22 x 2 source/services/custom-r...onductor-DeleteSnapshot
source/services/custom-r...onductor-ResizeInstance
automation_document.yaml
automation_document.yaml
276:297 (8%)
800:821 (2%)
view
22 x 2 source/services/custom-r...onductor-ResizeInstance
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
729:750 (2%)
453:474 (5%)
view
22 x 2 source/services/custom-r...tor-SetDynamoDBCapacity
source/services/custom-r...tor-SetDynamoDBCapacity
automation_document.yaml
automation_document.yaml
382:403 (5%)
453:474 (5%)
view