aws-samples / amazon-devopsguru-cdk-samples
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
  • 41% duplication:
    • 336 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 139 duplicated lines
  • 10 duplicates
system41% (139 lines)
Duplication per Extension
ts43% (139 lines)
Duplication per Component (primary)
lib43% (139 lines)
ROOT0% (0 lines)
scripts0% (0 lines)
Longest Duplicates
The list of 10 longest duplicates.
See data for all 10 duplicates...
Size#FoldersFilesLinesCode
17 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-spec-sta...
cdk-devopsguru-multi-acc-reg-stack.ts
33:50 (34%)
33:50 (34%)
view
12 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-spec-sta...
cdk-devopsguru-multi-acc-reg-stack.ts
13:27 (24%)
13:27 (24%)
view
12 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-stack.ts
cdk-devopsguru-org-uni-stack.ts
43:55 (24%)
44:56 (23%)
view
10 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-stack.ts
cdk-devopsguru-org-uni-stack.ts
57:67 (20%)
58:68 (19%)
view
10 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-spec-sta...
cdk-devopsguru-multi-acc-reg-stack.ts
57:67 (20%)
57:67 (20%)
view
10 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-spec-sta...
cdk-devopsguru-org-uni-stack.ts
57:67 (20%)
58:68 (19%)
view
8 x 2 lib
lib
infrastructure-stack.ts
infrastructure-stack.ts
146:154 (5%)
162:170 (5%)
view
8 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-spec-sta...
cdk-devopsguru-org-uni-stack.ts
43:50 (16%)
44:51 (15%)
view
6 x 2 lib
lib
infrastructure-stack.ts
infrastructure-stack.ts
31:36 (4%)
122:127 (4%)
view
6 x 2 lib
lib
cdk-devopsguru-multi-acc-reg-stack.ts
cdk-devopsguru-org-uni-stack.ts
22:29 (12%)
19:26 (11%)
view