aws-samples / otl-service-launcher
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
  • 10% duplication:
    • 2,073 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 214 duplicated lines
  • 32 duplicates
system10% (214 lines)
Duplication per Extension
tf12% (214 lines)
Duplication per Component (primary)
ROOT9% (68 lines)
modules/storagegateway13% (29 lines)
modules/rds34% (27 lines)
modules/elasticache45% (27 lines)
modules/emr7% (23 lines)
modules/eks_outposts_node_group5% (11 lines)
modules/eks_cluster18% (11 lines)
modules/cloud932% (9 lines)
modules/on_prem_vpc5% (9 lines)
cfn0% (0 lines)

Duplication Between Components (50+ lines)

G modules/elasticache modules/elasticache modules/rds modules/rds modules/elasticache--modules/rds 54

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 32 duplicates...
Size#FoldersFilesLinesCode
21 x 2 modules/elasticache
modules/rds
variables.tf
variables.tf
4:32 (77%)
4:32 (77%)
view
15 x 2 ROOT
ROOT
vpc.tf
vpc.tf
310:326 (5%)
331:347 (5%)
view
11 x 2 modules/eks_cluster
modules/eks_outposts_node_group
variables.tf
variables.tf
4:20 (64%)
4:22 (18%)
view
9 x 2 modules/rds
modules/storagegateway
variables.tf
variables.tf
4:13 (33%)
4:13 (24%)
view
9 x 2 modules/elasticache
modules/storagegateway
variables.tf
variables.tf
4:13 (33%)
4:13 (24%)
view
9 x 2 modules/cloud9
modules/elasticache
variables.tf
variables.tf
4:13 (42%)
4:13 (33%)
view
9 x 2 modules/on_prem_vpc
modules/rds
variables.tf
variables.tf
4:13 (60%)
4:13 (33%)
view
9 x 2 modules/cloud9
modules/on_prem_vpc
variables.tf
variables.tf
4:13 (42%)
4:13 (60%)
view
9 x 2 modules/elasticache
modules/on_prem_vpc
variables.tf
variables.tf
4:13 (33%)
4:13 (60%)
view
9 x 2 modules/cloud9
modules/emr
variables.tf
variables.tf
4:13 (42%)
4:13 (6%)
view
9 x 2 modules/emr
modules/storagegateway
variables.tf
variables.tf
4:13 (6%)
4:13 (24%)
view
9 x 2 modules/emr
modules/on_prem_vpc
variables.tf
variables.tf
4:13 (6%)
4:13 (60%)
view
9 x 2 modules/cloud9
modules/rds
variables.tf
variables.tf
4:13 (42%)
4:13 (33%)
view
9 x 2 modules/on_prem_vpc
modules/storagegateway
variables.tf
variables.tf
4:13 (60%)
4:13 (24%)
view
9 x 2 modules/cloud9
modules/storagegateway
variables.tf
variables.tf
4:13 (42%)
4:13 (24%)
view
9 x 2 modules/emr
modules/rds
variables.tf
variables.tf
4:13 (6%)
4:13 (33%)
view
9 x 2 modules/elasticache
modules/emr
variables.tf
variables.tf
4:13 (33%)
4:13 (6%)
view
8 x 2 modules/storagegateway
ROOT
main.tf
vpc.tf
62:69 (4%)
318:326 (3%)
view
8 x 2 modules/storagegateway
ROOT
main.tf
vpc.tf
62:69 (4%)
339:347 (3%)
view
7 x 2 ROOT
ROOT
vpc.tf
vpc.tf
65:72 (2%)
78:85 (2%)
view