golang / appengine
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
  • 79% duplication:
    • 43,311 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 34,321 duplicated lines
  • 122 duplicates
system79% (34,321 lines)
Duplication per Extension
go79% (31,553 lines)
proto75% (2,768 lines)
Duplication per Component (primary)
v298% (17,152 lines)
internal63% (12,346 lines)
datastore99% (1,855 lines)
cmd97% (1,342 lines)
taskqueue100% (288 lines)
memcache100% (250 lines)
blobstore100% (229 lines)
aetest94% (224 lines)
delay86% (130 lines)
ROOT91% (111 lines)
urlfetch100% (101 lines)
runtime100% (72 lines)
user78% (71 lines)
module100% (54 lines)
mail100% (50 lines)
image100% (25 lines)
capability100% (11 lines)
log5% (10 lines)
channel0% (0 lines)
remote_api0% (0 lines)
search0% (0 lines)
xmpp0% (0 lines)
socket0% (0 lines)
file0% (0 lines)
cloudsql0% (0 lines)

Duplication Between Components (50+ lines)

G internal internal v2 v2 internal--v2 24675 datastore datastore datastore--v2 3710 cmd cmd cmd--v2 2684 taskqueue taskqueue taskqueue--v2 576 memcache memcache memcache--v2 500 blobstore blobstore blobstore--v2 458 aetest aetest aetest--v2 448 delay delay delay--v2 260 ROOT ROOT ROOT--v2 222 urlfetch urlfetch urlfetch--v2 202 runtime runtime runtime--v2 144 user user user--v2 142 module module module--v2 108 mail mail mail--v2 100 image image image--v2 50

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 122 duplicates...
Size#FoldersFilesLinesCode
2715 x 2 internal/datastore
v2/internal/datastore
datastore_v3.pb.go
datastore_v3.pb.go
11:4101 (91%)
11:4101 (91%)
view
1970 x 2 internal/taskqueue
v2/internal/taskqueue
taskqueue_service.pb.go
taskqueue_service.pb.go
12:2971 (91%)
12:2971 (91%)
view
968 x 2 internal/memcache
v2/internal/memcache
memcache_service.pb.go
memcache_service.pb.go
11:1469 (91%)
11:1469 (91%)
view
856 x 2 internal/image
v2/internal/image
images_service.pb.go
images_service.pb.go
11:1277 (90%)
11:1277 (90%)
view
495 x 2 internal/modules
v2/internal/modules
modules_service.pb.go
modules_service.pb.go
11:751 (94%)
11:751 (94%)
view
459 x 2 cmd/aefix
v2/cmd/aefix
fix.go
fix.go
19:718 (84%)
19:718 (83%)
view
428 x 2 datastore
v2/datastore
query.go
query.go
22:773 (100%)
22:773 (100%)
view
404 x 2 internal/blobstore
v2/internal/blobstore
blobstore_service.pb.go
blobstore_service.pb.go
11:613 (89%)
11:613 (89%)
view
403 x 2 internal/datastore
v2/internal/datastore
proto
datastore_v3.proto
datastore_v3.proto
1:551 (100%)
1:551 (100%)
view
371 x 2 internal/app_identity
v2/internal/app_identity
app_identity_service.pb.go
app_identity_service.pb.go
11:562 (89%)
11:562 (89%)
view
357 x 2 cmd/aefix
v2/cmd/aefix
typecheck.go
typecheck.go
53:672 (100%)
53:672 (100%)
view
318 x 2 internal/user
v2/internal/user
user_service.pb.go
user_service.pb.go
11:489 (89%)
11:489 (89%)
view
317 x 2 internal/urlfetch
v2/internal/urlfetch
urlfetch_service.pb.go
urlfetch_service.pb.go
11:472 (86%)
11:472 (86%)
view
288 x 2 taskqueue
v2/taskqueue
taskqueue.go
taskqueue.go
36:540 (100%)
36:540 (100%)
view
283 x 2 internal/taskqueue
v2/internal/taskqueue
proto
taskqueue_service.proto
taskqueue_service.proto
6:342 (98%)
6:342 (98%)
view
273 x 2 datastore
v2/datastore
load.go
load.go
18:428 (100%)
18:428 (100%)
view
261 x 2 internal/datastore
v2/internal/datastore
datastore_v3.pb.go
datastore_v3.pb.go
4105:4366 (8%)
4105:4366 (8%)
view
250 x 2 memcache
v2/memcache
memcache.go
memcache.go
46:525 (100%)
46:525 (100%)
view
230 x 2 datastore
v2/datastore
save.go
save.go
20:332 (100%)
20:332 (100%)
view
225 x 2 datastore
v2/datastore
datastore.go
datastore.go
20:406 (100%)
20:406 (100%)
view
Duplicated Units
The list of top 20 duplicated units.
See data for all 290 unit duplicates...
Size#FoldersFilesLinesCode
274 x 2 cmd/aefix
v2/cmd/aefix
typecheck.go
typecheck.go
229:587 
229:587 
view
209 x 2 cmd/aefix
v2/cmd/aefix
fix.go
fix.go
57:283 
57:283 
view
97 x 2 datastore
v2/datastore
load.go
load.go
176:280 
176:280 
view
97 x 2 datastore
v2/datastore
prop.go
prop.go
176:289 
176:289 
view
92 x 2 cmd/aefix
v2/cmd/aefix
ae.go
ae.go
47:172 
42:167 
view
91 x 2 v2/blobstore
blobstore
blobstore.go
blobstore.go
167:280 
167:280 
view
87 x 2 v2/internal
internal
api.go
api.go
409:512 
463:566 
view
83 x 2 datastore
v2/datastore
load.go
load.go
63:173 
63:173 
view
78 x 2 datastore
v2/datastore
save.go
save.go
225:307 
225:307 
view
74 x 2 datastore
v2/datastore
query.go
query.go
292:366 
292:366 
view
71 x 2 cmd/aefix
v2/cmd/aefix
typecheck.go
typecheck.go
136:216 
136:216 
view
70 x 2 datastore
v2/datastore
save.go
save.go
38:112 
38:112 
view
67 x 2 cmd/aefix
v2/cmd/aefix
main.go
main.go
110:196 
110:196 
view
66 x 2 v2/urlfetch
urlfetch
urlfetch.go
urlfetch.go
127:205 
126:204 
view
64 x 2 v2/taskqueue
taskqueue
taskqueue.go
taskqueue.go
202:274 
202:274 
view
63 x 2 v2/memcache
memcache
memcache.go
memcache.go
239:314 
239:314 
view
61 x 2 cmd/aefix
v2/cmd/aefix
fix.go
fix.go
560:641 
560:641 
view
57 x 2 cmd/aefix
v2/cmd/aefix
fix.go
fix.go
481:548 
481:548 
view
56 x 2 v2/internal/datastore
internal/datastore
datastore_v3.pb.go
datastore_v3.pb.go
4043:4099 
4043:4099 
view
54 x 2 v2/delay
delay
delay.go
delay.go
239:305 
227:293 
view