firecracker-microvm / firecracker-go-sdk
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
  • 7% duplication:
    • 7,175 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 511 duplicated lines
  • 321 duplicates
system7% (511 lines)
Duplication per Extension
go4% (287 lines)
yaml27% (224 lines)
Duplication per Component (primary)
client26% (224 lines)
client/operations6% (209 lines)
client/models8% (78 lines)
ROOT0% (0 lines)
fctesting0% (0 lines)
cni/vmconf0% (0 lines)
cni/internal0% (0 lines)
Longest Duplicates
The list of 20 longest duplicates.
See data for all 321 duplicates...
Size#FoldersFilesLinesCode
13 x 2 client
client
swagger.yaml
swagger.yaml
313:325 (1%)
337:349 (1%)
view
11 x 2 client/operations
client/operations
patch_guest_network_interface_by_id_p...
put_guest_network_interface_by_id_par...
153:172 (18%)
153:172 (18%)
view
11 x 2 client/operations
client/operations
patch_guest_drive_by_id_parameters.go
put_guest_drive_by_id_parameters.go
153:172 (18%)
153:172 (18%)
view
11 x 2 client
client
swagger.yaml
swagger.yaml
206:216 (1%)
235:245 (1%)
view
9 x 2 client/operations
client/operations
put_guest_vsock_parameters.go
put_machine_configuration_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
patch_mmds_parameters.go
put_mmds_parameters.go
135:149 (17%)
135:149 (17%)
view
9 x 2 client/operations
client/operations
create_snapshot_parameters.go
put_guest_boot_source_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
create_snapshot_parameters.go
load_snapshot_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
put_guest_boot_source_parameters.go
put_machine_configuration_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
create_snapshot_parameters.go
patch_balloon_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
load_snapshot_parameters.go
put_logger_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
load_snapshot_parameters.go
put_balloon_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
create_snapshot_parameters.go
put_logger_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
patch_mmds_parameters.go
put_balloon_parameters.go
135:149 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
patch_balloon_stats_interval_paramete...
put_mmds_config_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
put_metrics_parameters.go
put_mmds_parameters.go
137:151 (17%)
135:149 (17%)
view
9 x 2 client/operations
client/operations
load_snapshot_parameters.go
put_metrics_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
patch_vm_parameters.go
put_guest_boot_source_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
patch_vm_parameters.go
put_balloon_parameters.go
137:151 (17%)
137:151 (17%)
view
9 x 2 client/operations
client/operations
put_logger_parameters.go
put_mmds_parameters.go
137:151 (17%)
135:149 (17%)
view
Duplicated Units
The list of top 9 duplicated units.
See data for all 9 unit duplicates...
Size#FoldersFilesLinesCode
17 x 2 client/operations
client/operations
put_guest_drive_by_id_parameters.go
patch_guest_drive_by_id_parameters.go
151:173 
151:173 
view
17 x 2 client/operations
client/operations
put_guest_network_interface_by_id_par...
patch_guest_network_interface_by_id_p...
151:173 
151:173 
view
14 x 15 client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
...
put_metrics_parameters.go
put_machine_configuration_parameters.go
patch_balloon_parameters.go
put_guest_boot_source_parameters.go
patch_vm_parameters.go
patch_mmds_parameters.go
put_guest_vsock_parameters.go
put_mmds_config_parameters.go
load_snapshot_parameters.go
patch_machine_configuration_parameter...
...
135:152 
135:152 
135:152 
135:152 
135:152 
133:150 
135:152 
135:152 
135:152 
135:152 
...
view
13 x 2 client/models
client/models
partial_network_interface.go
network_interface.go
75:91 
98:114 
view
13 x 2 client/models
client/models
partial_network_interface.go
network_interface.go
93:109 
116:132 
view
13 x 2 client/models
client/models
partial_drive.go
drive.go
71:87 
122:138 
view
9 x 5 client/operations
client/operations
client/operations
client/operations
client/operations
get_mmds_parameters.go
describe_balloon_config_parameters.go
get_machine_configuration_parameters.go
describe_balloon_stats_parameters.go
describe_instance_parameters.go
115:126 
115:126 
115:126 
115:126 
115:126 
view
8 x 2 client/models
client/models
vm.go
instance_info.go
84:96 
129:141 
view
6 x 26 client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
client/operations
...
patch_balloon_stats_interval_response...
patch_balloon_stats_interval_response...
load_snapshot_responses.go
put_guest_boot_source_responses.go
patch_balloon_responses.go
describe_instance_responses.go
patch_vm_responses.go
get_mmds_responses.go
put_machine_configuration_responses.go
put_balloon_responses.go
...
106:116 
148:158 
106:116 
106:116 
106:116 
121:131 
106:116 
116:126 
106:116 
106:116 
...
view