aws-quickstart / quickstart-fortinet-fortigate
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
  • 81% duplication:
    • 23,200 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 18,975 duplicated lines
  • 1,032 duplicates
system81% (18,975 lines)
Duplication per Extension
js95% (15,359 lines)
yaml49% (3,383 lines)
yml90% (233 lines)
Duplication per Component (primary)
templates49% (3,383 lines)
functions/source/fgt-asg-handler/lib/aws100% (2,734 lines)
functions/source/faz-handler/lib/aws100% (2,734 lines)
functions/source/nic-attachment/lib/aws100% (2,734 lines)
functions/source/nic-attachment/lib/core99% (2,293 lines)
functions/source/faz-handler/lib/core99% (2,293 lines)
functions/source/fgt-asg-handler/lib/core99% (2,293 lines)
ci/taskcat90% (233 lines)
functions/source/faz-handler25% (102 lines)
functions/source/nic-attachment/lib/aws_cfn_response100% (44 lines)
functions/source/faz-handler/lib/aws_cfn_response100% (44 lines)
functions/source/fgt-asg-handler/lib/aws_cfn_response100% (44 lines)
functions/source/nic-attachment22% (30 lines)
functions/source/fgt-asg-handler4% (14 lines)

Duplication Between Components (50+ lines)

G functions/source/fgt-asg-handler/lib/aws functions/source/fgt-asg-handler/lib/aws functions/source/nic-attachment/lib/aws functions/source/nic-attachment/lib/aws functions/source/fgt-asg-handler/lib/aws--functions/source/nic-attachment/lib/aws 5468 functions/source/nic-attachment/lib/core functions/source/nic-attachment/lib/core functions/source/fgt-asg-handler/lib/aws--functions/source/nic-attachment/lib/core 70 functions/source/fgt-asg-handler/lib/core functions/source/fgt-asg-handler/lib/core functions/source/fgt-asg-handler/lib/aws--functions/source/fgt-asg-handler/lib/core 70 functions/source/nic-attachment/lib/aws--functions/source/nic-attachment/lib/core 70 functions/source/faz-handler/lib/aws functions/source/faz-handler/lib/aws functions/source/faz-handler/lib/aws--functions/source/fgt-asg-handler/lib/aws 5468 functions/source/faz-handler/lib/aws--functions/source/nic-attachment/lib/aws 5468 functions/source/faz-handler/lib/core functions/source/faz-handler/lib/core functions/source/faz-handler/lib/aws--functions/source/faz-handler/lib/core 70 functions/source/faz-handler/lib/aws--functions/source/nic-attachment/lib/core 70 functions/source/faz-handler/lib/aws--functions/source/fgt-asg-handler/lib/core 70 functions/source/faz-handler/lib/core--functions/source/fgt-asg-handler/lib/aws 70 functions/source/faz-handler/lib/core--functions/source/nic-attachment/lib/aws 70 functions/source/faz-handler/lib/core--functions/source/nic-attachment/lib/core 4586 functions/source/faz-handler/lib/core--functions/source/fgt-asg-handler/lib/core 4586 functions/source/fgt-asg-handler/lib/core--functions/source/nic-attachment/lib/aws 70 functions/source/fgt-asg-handler/lib/core--functions/source/nic-attachment/lib/core 4586 functions/source/fgt-asg-handler/lib/aws_cfn_response functions/source/fgt-asg-handler/lib/aws_cfn_response functions/source/nic-attachment/lib/aws_cfn_response functions/source/nic-attachment/lib/aws_cfn_response functions/source/fgt-asg-handler/lib/aws_cfn_response--functions/source/nic-attachment/lib/aws_cfn_response 88 functions/source/faz-handler functions/source/faz-handler functions/source/faz-handler--functions/source/fgt-asg-handler/lib/aws_cfn_response 88 functions/source/faz-handler--functions/source/nic-attachment/lib/aws_cfn_response 88 functions/source/faz-handler/lib/aws_cfn_response functions/source/faz-handler/lib/aws_cfn_response functions/source/faz-handler--functions/source/faz-handler/lib/aws_cfn_response 88 functions/source/nic-attachment functions/source/nic-attachment functions/source/faz-handler--functions/source/nic-attachment 52 functions/source/faz-handler/lib/aws_cfn_response--functions/source/fgt-asg-handler/lib/aws_cfn_response 88 functions/source/faz-handler/lib/aws_cfn_response--functions/source/nic-attachment/lib/aws_cfn_response 88

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 1,032 duplicates...
Size#FoldersFilesLinesCode
2734 x 2 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
index.js
index.js
1:3572 (100%)
1:3572 (100%)
view
2734 x 2 functions/source/faz-handler/lib/aws
functions/source/nic-attachment/lib/aws
index.js
index.js
1:3572 (100%)
1:3572 (100%)
view
2734 x 2 functions/source/faz-handler/lib/aws
functions/source/fgt-asg-handler/lib/aws
index.js
index.js
1:3572 (100%)
1:3572 (100%)
view
1310 x 2 functions/source/faz-handler/lib/core
functions/source/nic-attachment/lib/core
autoscale-handler.js
autoscale-handler.js
1:1878 (100%)
1:1878 (100%)
view
1310 x 2 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
autoscale-handler.js
autoscale-handler.js
1:1878 (100%)
1:1878 (100%)
view
1310 x 2 functions/source/faz-handler/lib/core
functions/source/fgt-asg-handler/lib/core
autoscale-handler.js
autoscale-handler.js
1:1878 (100%)
1:1878 (100%)
view
343 x 2 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
db-definitions.js
db-definitions.js
1:461 (100%)
1:461 (100%)
view
343 x 2 functions/source/faz-handler/lib/core
functions/source/fgt-asg-handler/lib/core
db-definitions.js
db-definitions.js
1:461 (100%)
1:461 (100%)
view
343 x 2 functions/source/faz-handler/lib/core
functions/source/nic-attachment/lib/core
db-definitions.js
db-definitions.js
1:461 (100%)
1:461 (100%)
view
168 x 2 functions/source/faz-handler/lib/core
functions/source/nic-attachment/lib/core
core-functions.js
core-functions.js
1:256 (100%)
1:256 (100%)
view
168 x 2 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
core-functions.js
core-functions.js
1:256 (100%)
1:256 (100%)
view
168 x 2 functions/source/faz-handler/lib/core
functions/source/fgt-asg-handler/lib/core
core-functions.js
core-functions.js
1:256 (100%)
1:256 (100%)
view
132 x 2 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
cloud-platform.js
cloud-platform.js
1:459 (100%)
1:459 (100%)
view
132 x 2 functions/source/faz-handler/lib/core
functions/source/nic-attachment/lib/core
cloud-platform.js
cloud-platform.js
1:459 (100%)
1:459 (100%)
view
132 x 2 functions/source/faz-handler/lib/core
functions/source/fgt-asg-handler/lib/core
cloud-platform.js
cloud-platform.js
1:459 (100%)
1:459 (100%)
view
127 x 2 templates
templates
autoscale-existing-vpc.template.yaml
autoscale-new-vpc.template.yaml
658:784 (16%)
723:849 (14%)
view
120 x 2 templates
templates
autoscale-existing-vpc.template.yaml
autoscale-new-vpc.template.yaml
202:321 (15%)
212:331 (14%)
view
77 x 2 functions/source/faz-handler/lib/core
functions/source/fgt-asg-handler/lib/core
logger.js
logger.js
1:124 (100%)
1:124 (100%)
view
77 x 2 functions/source/faz-handler/lib/core
functions/source/nic-attachment/lib/core
logger.js
logger.js
1:124 (100%)
1:124 (100%)
view
77 x 2 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
logger.js
logger.js
1:124 (100%)
1:124 (100%)
view
Duplicated Units
The list of top 20 duplicated units.
See data for all 133 unit duplicates...
Size#FoldersFilesLinesCode
350 x 3 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
functions/source/faz-handler/lib/core
autoscale-handler.js
autoscale-handler.js
autoscale-handler.js
1204:1555 
1204:1555 
1204:1555 
view
245 x 3 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
functions/source/faz-handler/lib/core
autoscale-handler.js
autoscale-handler.js
autoscale-handler.js
528:892 
528:892 
528:892 
view
178 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
1333:1530 
1333:1530 
1333:1530 
view
158 x 3 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
functions/source/faz-handler/lib/core
autoscale-handler.js
autoscale-handler.js
autoscale-handler.js
1691:1858 
1691:1858 
1691:1858 
view
113 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2582:2729 
2582:2729 
2582:2729 
view
103 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
369:494 
369:494 
369:494 
view
101 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
3409:3523 
3409:3523 
3409:3523 
view
98 x 3 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
functions/source/faz-handler/lib/core
autoscale-handler.js
autoscale-handler.js
autoscale-handler.js
378:521 
378:521 
378:521 
view
85 x 3 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
functions/source/faz-handler/lib/core
autoscale-handler.js
autoscale-handler.js
autoscale-handler.js
223:319 
223:319 
223:319 
view
82 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2731:2830 
2731:2830 
2731:2830 
view
82 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2834:2919 
2834:2919 
2834:2919 
view
79 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
607:695 
607:695 
607:695 
view
78 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2381:2466 
2381:2466 
2381:2466 
view
72 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2468:2549 
2468:2549 
2468:2549 
view
68 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2921:3000 
2921:3000 
2921:3000 
view
67 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
3146:3234 
3146:3234 
3146:3234 
view
64 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
882:952 
882:952 
882:952 
view
64 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
3285:3351 
3285:3351 
3285:3351 
view
63 x 3 functions/source/fgt-asg-handler/lib/aws
functions/source/nic-attachment/lib/aws
functions/source/faz-handler/lib/aws
index.js
index.js
index.js
2141:2209 
2141:2209 
2141:2209 
view
62 x 3 functions/source/fgt-asg-handler/lib/core
functions/source/nic-attachment/lib/core
functions/source/faz-handler/lib/core
autoscale-handler.js
autoscale-handler.js
autoscale-handler.js
81:151 
81:151 
81:151 
view