aws-samples / aws-lakeformation-datasharing-workflow
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
  • 5% duplication:
    • 925 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 52 duplicated lines
  • 4 duplicates
system5% (52 lines)
Duplication per Extension
ts12% (26 lines)
js4% (26 lines)
Duplication per Component (primary)
infra/central/lib/SecurityStack17% (14 lines)
infra/central/lib/AppStack14% (12 lines)
src/Components3% (12 lines)
infra/central100% (7 lines)
infra/producer100% (7 lines)
ROOT0% (0 lines)
src0% (0 lines)
infra/central/lib0% (0 lines)
infra/central/functions/WorkflowActivityApprover0% (0 lines)
infra/central/functions/WorkflowGetTableDetails0% (0 lines)
infra/central/functions/WorkflowSendApprovalNotification0% (0 lines)
infra/central/functions/WorkflowShareCatalogItem0% (0 lines)
infra/producer/lib0% (0 lines)
public0% (0 lines)
Longest Duplicates
The list of 4 longest duplicates.
See data for all 4 duplicates...
Size#FoldersFilesLinesCode
7 x 2 infra/central/lib/SecurityStack
infra/central/lib/SecurityStack
index.ts
index.ts
75:81 (8%)
94:100 (8%)
view
7 x 2 infra/central
infra/producer
jest.config.js
jest.config.js
1:8 (100%)
1:8 (100%)
view
6 x 2 infra/central/lib/AppStack
infra/central/lib/AppStack
index.ts
index.ts
87:92 (7%)
105:110 (7%)
view
6 x 2 src/Components
src/Components
CatalogTablesComponent.js
TableDetailsComponent.js
55:60 (12%)
62:67 (9%)
view