microsoft / ApplicationInsights-Kubernetes
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:
    • 1,167 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 60 duplicated lines
  • 3 duplicates
system5% (60 lines)
Duplication per Extension
cs5% (60 lines)
Duplication per Component (primary)
dev/F5WebApi/Controllers100% (16 lines)
troubleshooting/AIK8sTroubleShooting/Controllers100% (16 lines)
src/ApplicationInsights.Kubernetes6% (14 lines)
dev/F5WebApi28% (7 lines)
troubleshooting/AIK8sTroubleShooting30% (7 lines)
build0% (0 lines)
src/ApplicationInsights.Kubernetes.HostingStartup0% (0 lines)
src/ApplicationInsights.Kubernetes/Debuggings0% (0 lines)
src/ApplicationInsights.Kubernetes/Entities0% (0 lines)
src/ApplicationInsights.Kubernetes/EntityExtensions0% (0 lines)
src/ApplicationInsights.Kubernetes/Extensions0% (0 lines)
src/ApplicationInsights.Kubernetes/Interfaces0% (0 lines)
src/ApplicationInsights.Kubernetes/K8sHttpClient0% (0 lines)
src/ApplicationInsights.Kubernetes/TelemetryInitializers0% (0 lines)
src/ApplicationInsights.Kubernetes/Utilities0% (0 lines)
src0% (0 lines)
troubleshooting/AIK8sTroubleShooting/k8s0% (0 lines)
Longest Duplicates
The list of 3 longest duplicates.
See data for all 3 duplicates...
Size#FoldersFilesLinesCode
16 x 2 dev/F5WebApi/Controllers
troubleshooting/AIK8sTroubleShooting/Controllers
ValuesController.cs
ValuesController.cs
1:41 (100%)
1:41 (100%)
view
7 x 2 src/ApplicationInsights.Kubernetes
src/ApplicationInsights.Kubernetes
K8sEnvironmentFactory.cs
K8sEnvironmentFactory.cs
116:126 (7%)
162:172 (7%)
view
7 x 2 dev/F5WebApi
troubleshooting/AIK8sTroubleShooting
Startup.cs
Startup.cs
43:56 (36%)
33:45 (46%)
view
Duplicated Units
The list of top 1 duplicated units.
See data for all 1 unit duplicate
Size#FoldersFilesLinesCode
12 x 2 dev/F5WebApi
troubleshooting/AIK8sTroubleShooting
Startup.cs
Startup.cs
43:57 
33:46 
view