aws-samples / terraform-aws-sap-netweaver-on-hana
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
  • 57% duplication:
    • 6,026 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 3,456 duplicated lines
  • 5,784 duplicates
system57% (3,456 lines)
Duplication per Extension
tf63% (3,108 lines)
MD72% (276 lines)
yaml9% (72 lines)
Duplication per Component (primary)
modules/aws-sap-ascs-host82% (699 lines)
modules/aws-sap-app-host94% (636 lines)
modules/aws-sap-hana-host50% (592 lines)
modules/_internal-modules/compute61% (520 lines)
ROOT40% (158 lines)
modules/_internal-modules/storage57% (149 lines)
modules/aws-sap-netweaver-efs64% (117 lines)
modules/_internal-modules/monitoring77% (112 lines)
modules/sap-deploymentscripts39% (107 lines)
modules/_internal-modules/systems-manager62% (102 lines)
modules/sap-deploymentscripts/scripts9% (72 lines)
modules/_internal-modules/security63% (71 lines)
modules/_internal-modules/common55% (69 lines)
modules/_internal-modules/db62% (52 lines)

Duplication Between Components (50+ lines)

G modules/aws-sap-app-host modules/aws-sap-app-host modules/aws-sap-ascs-host modules/aws-sap-ascs-host modules/aws-sap-app-host--modules/aws-sap-ascs-host 1281 modules/aws-sap-hana-host modules/aws-sap-hana-host modules/aws-sap-app-host--modules/aws-sap-hana-host 892 modules/aws-sap-netweaver-efs modules/aws-sap-netweaver-efs modules/aws-sap-app-host--modules/aws-sap-netweaver-efs 294 modules/sap-deploymentscripts modules/sap-deploymentscripts modules/aws-sap-app-host--modules/sap-deploymentscripts 282 ROOT ROOT modules/aws-sap-app-host--ROOT 268 modules/aws-sap-ascs-host--modules/aws-sap-hana-host 966 modules/aws-sap-ascs-host--modules/aws-sap-netweaver-efs 294 modules/aws-sap-ascs-host--modules/sap-deploymentscripts 282 modules/aws-sap-ascs-host--ROOT 293 modules/aws-sap-hana-host--modules/aws-sap-netweaver-efs 357 modules/aws-sap-hana-host--modules/sap-deploymentscripts 333 modules/aws-sap-hana-host--ROOT 301 modules/_internal-modules/compute modules/_internal-modules/compute modules/_internal-modules/compute--modules/aws-sap-app-host 662 modules/_internal-modules/compute--modules/aws-sap-ascs-host 662 modules/_internal-modules/compute--modules/aws-sap-hana-host 721 modules/_internal-modules/storage modules/_internal-modules/storage modules/_internal-modules/compute--modules/_internal-modules/storage 600 modules/_internal-modules/monitoring modules/_internal-modules/monitoring modules/_internal-modules/compute--modules/_internal-modules/monitoring 596 modules/_internal-modules/compute--modules/aws-sap-netweaver-efs 590 modules/_internal-modules/compute--modules/sap-deploymentscripts 578 modules/_internal-modules/systems-manager modules/_internal-modules/systems-manager modules/_internal-modules/compute--modules/_internal-modules/systems-manager 578 modules/_internal-modules/security modules/_internal-modules/security modules/_internal-modules/compute--modules/_internal-modules/security 550 modules/_internal-modules/compute--ROOT 544 modules/_internal-modules/db modules/_internal-modules/db modules/_internal-modules/compute--modules/_internal-modules/db 527 modules/_internal-modules/storage--modules/aws-sap-app-host 294 modules/_internal-modules/storage--modules/aws-sap-ascs-host 294 modules/_internal-modules/storage--modules/aws-sap-hana-host 345 modules/_internal-modules/storage--modules/aws-sap-netweaver-efs 223 modules/_internal-modules/storage--modules/sap-deploymentscripts 221 modules/_internal-modules/storage--modules/_internal-modules/systems-manager 221 modules/_internal-modules/monitoring--modules/aws-sap-app-host 272 modules/_internal-modules/monitoring--modules/aws-sap-ascs-host 272 modules/_internal-modules/monitoring--modules/aws-sap-hana-host 325 modules/_internal-modules/monitoring--modules/_internal-modules/storage 221 modules/_internal-modules/monitoring--modules/aws-sap-netweaver-efs 204 modules/_internal-modules/monitoring--modules/sap-deploymentscripts 204 modules/_internal-modules/monitoring--modules/_internal-modules/systems-manager 204 modules/aws-sap-netweaver-efs--modules/sap-deploymentscripts 214 modules/_internal-modules/systems-manager--modules/aws-sap-app-host 272 modules/_internal-modules/systems-manager--modules/aws-sap-ascs-host 272 modules/_internal-modules/systems-manager--modules/aws-sap-hana-host 323 modules/_internal-modules/security--modules/aws-sap-app-host 242 modules/_internal-modules/security--modules/aws-sap-ascs-host 242 modules/_internal-modules/security--modules/aws-sap-hana-host 293 modules/_internal-modules/common modules/_internal-modules/common modules/_internal-modules/common--modules/aws-sap-app-host 241 modules/_internal-modules/common--modules/aws-sap-ascs-host 241 modules/_internal-modules/common--modules/aws-sap-hana-host 293 modules/_internal-modules/common--modules/_internal-modules/compute 544 modules/_internal-modules/db--modules/aws-sap-app-host 221 modules/_internal-modules/db--modules/aws-sap-ascs-host 221 modules/_internal-modules/db--modules/aws-sap-hana-host 272

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 5,784 duplicates...
Size#FoldersFilesLinesCode
75 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
variables.tf
variables.tf
38:114 (68%)
46:124 (61%)
view
63 x 2 modules/aws-sap-ascs-host
modules/aws-sap-hana-host
default_role.tf
default_role.tf
22:100 (75%)
22:101 (75%)
view
44 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
application_security.tf
application_security.tf
1:49 (27%)
1:49 (18%)
view
36 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
instance_security.tf
instance_security.tf
1:43 (100%)
1:44 (100%)
view
36 x 2 modules/aws-sap-ascs-host
modules/aws-sap-hana-host
instance_security.tf
instance_security.tf
1:44 (100%)
1:45 (100%)
view
36 x 2 modules/aws-sap-app-host
modules/aws-sap-hana-host
instance_security.tf
instance_security.tf
1:43 (100%)
1:45 (100%)
view
35 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
application_security.tf
application_security.tf
49:87 (21%)
59:97 (15%)
view
32 x 2 modules/aws-sap-ascs-host
modules/aws-sap-hana-host
outputs.tf
outputs.tf
1:37 (100%)
1:37 (84%)
view
32 x 2 modules/aws-sap-app-host
modules/aws-sap-hana-host
outputs.tf
outputs.tf
1:37 (100%)
1:37 (84%)
view
32 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
outputs.tf
outputs.tf
1:37 (100%)
1:37 (100%)
view
31 x 2 modules/aws-sap-hana-host
modules/aws-sap-hana-host
hana-size-mapping.tf
hana-size-mapping.tf
59:89 (10%)
199:229 (10%)
view
31 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
README.MD
README.MD
26:66 (28%)
26:66 (22%)
view
27 x 2 modules/aws-sap-ascs-host
modules/aws-sap-hana-host
dns.tf
dns.tf
1:30 (100%)
1:30 (100%)
view
27 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
dns.tf
dns.tf
1:30 (100%)
1:30 (100%)
view
27 x 2 modules/aws-sap-app-host
modules/aws-sap-hana-host
dns.tf
dns.tf
1:30 (100%)
1:30 (100%)
view
26 x 2 modules/aws-sap-ascs-host
modules/aws-sap-hana-host
application_security.tf
application_security.tf
1:29 (11%)
1:29 (26%)
view
26 x 2 modules/aws-sap-app-host
modules/aws-sap-hana-host
application_security.tf
application_security.tf
1:29 (16%)
1:29 (26%)
view
24 x 2 modules/aws-sap-app-host
modules/aws-sap-hana-host
variables.tf
variables.tf
1:25 (21%)
1:27 (17%)
view
24 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
variables.tf
variables.tf
1:25 (21%)
1:25 (19%)
view
24 x 2 modules/aws-sap-app-host
modules/aws-sap-ascs-host
data.tf
data.tf
1:25 (100%)
1:26 (68%)
view