uber / cosmo
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
Learn more...
Duplication Overall
system24% (30,935 lines)
dependency graphs: 2D graph | 3D graph | 3D graph (with duplicates)...
Duplication per Extension
ts26% (14,911 lines)
tsx31% (11,724 lines)
yaml41% (1,859 lines)
go4% (706 lines)
sql24% (672 lines)
tpl49% (275 lines)
css50% (268 lines)
js44% (238 lines)
proto3% (114 lines)
tf11% (70 lines)
ftl6% (50 lines)
html29% (32 lines)
toml18% (16 lines)
Duplication per Component (primary)
studio28% (10,728 lines)
controlplane28% (9,995 lines)
playground72% (2,805 lines)
helm46% (2,081 lines)
cli35% (1,894 lines)
composition14% (1,894 lines)
router4% (800 lines)
graphqlmetrics23% (298 lines)
proto3% (114 lines)
infrastructure11% (70 lines)
data_migrations22% (68 lines)
cdn-server17% (61 lines)
keycloak4% (50 lines)
ROOT31% (40 lines)
composition-go3% (19 lines)
shared2% (12 lines)
admission-server15% (6 lines)
otelcollector0% (0 lines)
connect0% (0 lines)
aws-lambda-router0% (0 lines)
docker0% (0 lines)

Duplication Between Components (50+ lines)

G playground playground studio studio playground--studio 5756 graphqlmetrics graphqlmetrics router router graphqlmetrics--router 147 controlplane controlplane data_migrations data_migrations controlplane--data_migrations 102 data_migrations--graphqlmetrics 78 cdn-server cdn-server cdn-server--controlplane 66

Download: SVG DOT (open online Graphviz editor)

Open 2D force graph... Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 50 longest duplicates.
See data for all 6,392 duplicates...
Size#FoldersFilesLinesCode
520 x 2 playground/src/components/playground
studio/src/components/schema
1:682 (100%)
1:682 (100%)
view
109 x 2 studio/src/components/analytics
studio/src/pages/[organi...subgraphSlug]/analytics
696:815 (15%)
97:216 (32%)
view
107 x 2 controlplane/src/core/bufservices/federated-graph
controlplane/src/core/bufservices/federated-graph
45:170 (79%)
48:173 (78%)
view
98 x 2 router
router
23:155 (84%)
17:149 (85%)
view
64 x 2 playground/src/components/ui
studio/src/components/ui
14:83 (87%)
14:83 (87%)
view
61 x 2 playground/src/components/playground
studio/src/components/playground
45:111 (62%)
37:103 (67%)
view
59 x 2 playground/src/components/playground
studio/src/components/playground
22:91 (11%)
72:141 (6%)
view
59 x 2 playground/src/components/playground
studio/src/components/playground
5:65 (100%)
5:65 (100%)
view
58 x 2 playground/src/lib
studio/src/hooks
6:82 (100%)
6:82 (100%)
view
57 x 2 playground/src/components/ui
studio/src/components/ui
18:82 (85%)
18:82 (85%)
view
55 x 2 studio/src/pages/[organizationSlug]
studio/src/pages/[organizationSlug]
103:161 (9%)
78:136 (10%)
view
53 x 2 playground/src/components/playground
studio/src/components/playground
329:382 (9%)
464:517 (5%)
view
48 x 2 controlplane/src/core/bufservices/feature-flag
controlplane/src/core/bufservices/feature-flag
218:272 (22%)
187:241 (25%)
view
48 x 2 studio/src/pages/[organizationSlug]
studio/src/pages/[organizationSlug]
372:420 (8%)
414:461 (9%)
view
48 x 2 studio/src/pages/[organizationSlug]
studio/src/pages/[organizationSlug]
372:420 (8%)
471:519 (8%)
view
48 x 2 studio/src/pages/[organizationSlug]
studio/src/pages/[organizationSlug]
471:519 (8%)
414:461 (9%)
view
44 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/controlplane/templates
36:80 (54%)
36:80 (53%)
view
43 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/controlplane/templates
36:78 (53%)
35:77 (53%)
view
43 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/controlplane/templates
36:78 (51%)
35:77 (53%)
view
41 x 2 helm/cosmo/charts/router/templates
helm/cosmo/charts/studio/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/graphqlmetrics/templates
helm/cosmo/charts/otelcollector/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/graphqlmetrics/templates
helm/cosmo/charts/router/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/cdn/templates
helm/cosmo/charts/otelcollector/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/cdn/templates
helm/cosmo/charts/router/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/studio/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/graphqlmetrics/templates
helm/cosmo/charts/studio/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/cdn/templates
helm/cosmo/charts/controlplane/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
545:587 (7%)
567:609 (6%)
view
41 x 2 helm/cosmo/charts/cdn/templates
helm/cosmo/charts/graphqlmetrics/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/otelcollector/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/otelcollector/templates
helm/cosmo/charts/router/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/otelcollector/templates
helm/cosmo/charts/studio/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/router/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/controlplane/templates
helm/cosmo/charts/graphqlmetrics/templates
21:61 (67%)
21:61 (67%)
view
41 x 2 helm/cosmo/charts/cdn/templates
helm/cosmo/charts/studio/templates
21:61 (67%)
21:61 (67%)
view
40 x 2 controlplane/src/core/bufservices/contract
controlplane/src/core/bufservices/feature-flag
192:237 (20%)
148:194 (25%)
view
38 x 2 studio/src/components/checks
studio/src/components/checks
99:136 (31%)
101:138 (31%)
view
38 x 2 controlplane/src/core/bufservices/user
controlplane/src/core/bufservices/user
31:75 (38%)
29:72 (36%)
view
36 x 2 helm/cosmo/charts/cdn/templates
helm/cosmo/charts/controlplane/templates
120:155 (24%)
414:449 (8%)
view
36 x 2 studio/src/pages/[organi.../graph/[slug]/analytics
studio/src/pages/[organi...subgraphSlug]/analytics
68:109 (20%)
264:305 (10%)
view
35 x 2 controlplane/src/core/bufservices/subgraph
controlplane/src/core/bufservices/subgraph
137:177 (23%)
214:254 (15%)
view
35 x 2 studio/src/pages/[organi...raph/[slug]/discussions
studio/src/pages/[organi...bgraphSlug]/discussions
51:86 (36%)
53:88 (37%)
view
34 x 2 playground/src/components/playground
studio/src/components/playground
70:107 (11%)
82:119 (9%)
view
33 x 2 controlplane/src/core/bufservices/subgraph
controlplane/src/core/bufservices/subgraph
34:72 (63%)
37:75 (62%)
view
33 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
397:432 (5%)
409:444 (5%)
view
33 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
184:216 (13%)
258:290 (13%)
view
33 x 2 controlplane/src/core/bufservices/feature-flag
controlplane/src/core/bufservices/feature-flag
131:166 (21%)
116:151 (20%)
view
33 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
128:163 (5%)
140:175 (5%)
view
33 x 2 controlplane/clickhouse/migrations
controlplane/clickhouse/migrations
6:41 (94%)
4:39 (48%)
view
33 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
269:304 (5%)
281:316 (5%)
view
Duplicated Units
The list of top 21 duplicated units.
See data for all 21 unit duplicates...
Size#FoldersFilesLinesCode
56 x 2 playground/src/lib
studio/src/hooks
6:80 
6:80 
view
50 x 2 playground/src/lib
studio/src/hooks
14:80 
14:80 
view
35 x 2 playground/src/lib
studio/src/hooks
33:80 
33:80 
view
24 x 2 studio/src/components/analytics
studio/src/pages/[organi...subgraphSlug]/analytics
700:727 
101:128 
view
23 x 2 studio/src/components/analytics
studio/src/pages/[organi...subgraphSlug]/analytics
701:727 
102:128 
view
21 x 2 controlplane/src/core
cdn-server/src
393:419 
18:44 
view
20 x 5 controlplane/src/core/workers
controlplane/src/core/workers
controlplane/src/core/workers
controlplane/src/core/workers
controlplane/src/core/workers
25:47 
22:44 
23:45 
23:45 
24:46 
view
15 x 2 studio/src/pages/[organi...subgraphSlug]/analytics
studio/src/pages/[organi.../graph/[slug]/analytics
363:381 
167:185 
view
16 x 2 router/pkg/logging
graphqlmetrics/internal/logging
163:180 
91:108 
view
14 x 2 studio/src/pages/[organi...subgraphSlug]/analytics
studio/src/pages/[organi.../graph/[slug]/analytics
364:381 
168:185 
view
13 x 2 controlplane/src/core/repositories
controlplane/src/core/repositories
59:74 
619:634 
view
10 x 2 router
router
102:113 
96:107 
view
9 x 2 playground/src/lib
studio/src/hooks
5:17 
5:17 
view
9 x 2 router/pkg/logging
graphqlmetrics/internal/logging
50:62 
45:57 
view
8 x 2 composition/src/v1/federation
composition/src/v1/normalization
314:324 
2099:2109 
view
8 x 2 router/pkg/metric
router/pkg/metric
45:56 
45:55 
view
7 x 2 composition/src/utils
controlplane/src/core
159:167 
377:385 
view
7 x 2 router/pkg/logging
graphqlmetrics/internal/logging
32:40 
27:35 
view
6 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
153:160 
165:172 
view
6 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
294:301 
306:313 
view
6 x 2 controlplane/src/core/repositories/analytics
controlplane/src/core/repositories/analytics
422:429 
434:441 
view