aws-samples / amazon-redshift-infrastructure-automation
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
  • 25% duplication:
    • 1,126 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 292 duplicated lines
  • 20 duplicates
system25% (292 lines)
Duplication per Extension
py30% (278 lines)
yaml6% (14 lines)
Duplication per Component (primary)
redshift_poc_automation/stacks42% (264 lines)
ROOT5% (28 lines)
redshift_poc_automation0% (0 lines)
scripts0% (0 lines)
Longest Duplicates
The list of 20 longest duplicates.
See data for all 20 duplicates...
Size#FoldersFilesLinesCode
23 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dms_on_prem_to_redshift_stack.py
dmsinstance_stack.py
46:71 (26%)
54:80 (16%)
view
23 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
jmeter_stack.py
sct_stack.py
67:110 (28%)
68:111 (28%)
view
22 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
jmeter_stack.py
sct_stack.py
41:65 (27%)
41:65 (27%)
view
14 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
jmeter_stack.py
sct_stack.py
11:26 (17%)
11:26 (17%)
view
8 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
jmeter_stack.py
sct_stack.py
112:120 (10%)
113:121 (9%)
view
8 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
dmsinstance_stack.py
86:93 (5%)
117:124 (5%)
view
8 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dms_on_prem_to_redshift_stack.py
redshift_stack.py
84:93 (9%)
33:41 (5%)
view
7 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
jmeter_stack.py
sct_stack.py
28:35 (8%)
28:35 (8%)
view
7 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dms_on_prem_to_redshift_stack.py
dmsinstance_stack.py
9:19 (7%)
7:17 (4%)
view
7 x 2 ROOT
ROOT
app.py
app.py
87:93 (7%)
102:108 (7%)
view
7 x 2 ROOT
ROOT
CDKstaging.yaml
CDKstaging.yaml
107:113 (3%)
225:231 (3%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
sct_stack.py
88:93 (4%)
45:50 (7%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
dmsinstance_stack.py
86:91 (4%)
146:151 (4%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
dmsinstance_stack.py
97:102 (4%)
164:169 (4%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
dmsinstance_stack.py
117:122 (4%)
146:151 (4%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
jmeter_stack.py
119:124 (4%)
45:50 (7%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
dmsinstance_stack.py
97:102 (4%)
126:131 (4%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
dmsinstance_stack.py
126:131 (4%)
164:169 (4%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
jmeter_stack.py
88:93 (4%)
45:50 (7%)
view
6 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
dmsinstance_stack.py
sct_stack.py
119:124 (4%)
45:50 (7%)
view
Duplicated Units
The list of top 1 duplicated units.
See data for all 1 unit duplicate
Size#FoldersFilesLinesCode
9 x 2 redshift_poc_automation/stacks
redshift_poc_automation/stacks
jmeter_stack.py
sct_stack.py
0:0 
0:0 
view