microsoft / Application-Insights-Workbooks
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
  • 10% duplication:
    • 1,123 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 122 duplicated lines
  • 7 duplicates
system10% (122 lines)
Duplication per Extension
js14% (98 lines)
cmd22% (24 lines)
Duplication per Component (primary)
scripts15% (122 lines)
Workbooks/Workloads/SQL/SQL Insights Onboarding Scripts0% (0 lines)
ROOT0% (0 lines)
Longest Duplicates
The list of 7 longest duplicates.
See data for all 7 duplicates...
Size#FoldersFilesLinesCode
29 x 2 scripts
scripts
extractStrings.js
generateTemplates.js
66:109 (10%)
66:109 (7%)
view
8 x 2 scripts
scripts
cmd
extractStrings.cmd
processDevPackageOnly.cmd
1:9 (88%)
1:9 (88%)
view
8 x 2 scripts
scripts
cmd
extractStrings.cmd
generateTemplates.cmd
1:9 (88%)
1:9 (88%)
view
8 x 2 scripts
scripts
cmd
generateTemplates.cmd
processDevPackageOnly.cmd
1:9 (88%)
1:9 (88%)
view
7 x 2 scripts
scripts
extractStrings.js
generateTemplates.js
345:352 (2%)
173:180 (1%)
view
7 x 2 scripts
scripts
extractStrings.js
generateTemplates.js
414:423 (2%)
533:542 (1%)
view
6 x 2 scripts
scripts
extractStrings.js
generateTemplates.js
169:175 (2%)
152:158 (1%)
view
Duplicated Units
The list of top 2 duplicated units.
See data for all 2 unit duplicates...
Size#FoldersFilesLinesCode
8 x 2 scripts
scripts
extractStrings.js
generateTemplates.js
66:74 
66:74 
view
8 x 2 scripts
scripts
extractStrings.js
generateTemplates.js
345:353 
173:181 
view