##// END OF EJS Templates
upgrade: detect the side-data format variants...
marmoute -
r43299:e16ca9fd default
parent child Browse files
Show More
@@ -0,0 +1,65 b''
1 ==========================================================
2 Test file dedicated to checking side-data related behavior
3 ==========================================================
4
5
6 Check upgrade behavior
7 ======================
8
9 Right now, sidedata has not upgrade support
10
11 Check that we cannot upgrade to sidedata
12 ----------------------------------------
13
14 $ hg init up-no-side-data --config format.use-side-data=no
15 $ hg debugformat -v -R up-no-side-data
16 format-variant repo config default
17 fncache: yes yes yes
18 dotencode: yes yes yes
19 generaldelta: yes yes yes
20 sparserevlog: yes yes yes
21 sidedata: no no no
22 plain-cl-delta: yes yes yes
23 compression: zlib zlib zlib
24 compression-level: default default default
25 $ hg debugformat -v -R up-no-side-data --config format.use-side-data=yes
26 format-variant repo config default
27 fncache: yes yes yes
28 dotencode: yes yes yes
29 generaldelta: yes yes yes
30 sparserevlog: yes yes yes
31 sidedata: no yes no
32 plain-cl-delta: yes yes yes
33 compression: zlib zlib zlib
34 compression-level: default default default
35 $ hg debugupgraderepo -R up-no-side-data --config format.use-side-data=yes
36 abort: cannot upgrade repository; do not support adding requirement: exp-sidedata-flag
37 [255]
38
39 Check that we cannot upgrade to sidedata
40 ----------------------------------------
41
42 $ hg init up-side-data --config format.use-side-data=yes
43 $ hg debugformat -v -R up-side-data
44 format-variant repo config default
45 fncache: yes yes yes
46 dotencode: yes yes yes
47 generaldelta: yes yes yes
48 sparserevlog: yes yes yes
49 sidedata: yes no no
50 plain-cl-delta: yes yes yes
51 compression: zlib zlib zlib
52 compression-level: default default default
53 $ hg debugformat -v -R up-side-data --config format.use-side-data=no
54 format-variant repo config default
55 fncache: yes yes yes
56 dotencode: yes yes yes
57 generaldelta: yes yes yes
58 sparserevlog: yes yes yes
59 sidedata: yes no no
60 plain-cl-delta: yes yes yes
61 compression: zlib zlib zlib
62 compression-level: default default default
63 $ hg debugupgraderepo -R up-side-data --config format.use-side-data=no
64 abort: cannot upgrade repository; requirement would be removed: exp-sidedata-flag
65 [255]
@@ -317,6 +317,19 b' class sparserevlog(requirementformatvari'
317 317 'better compression and faster exchange with server.')
318 318
319 319 @registerformatvariant
320 class sidedata(requirementformatvariant):
321 name = 'sidedata'
322
323 _requirement = localrepo.SIDEDATA_REQUIREMENT
324
325 default = False
326
327 description = _('Allows storage of extra data alongside a revision, '
328 'unlocking various caching options.')
329
330 upgrademessage = _('Allows storage of extra data alongside a revision.')
331
332 @registerformatvariant
320 333 class removecldeltachain(formatvariant):
321 334 name = 'plain-cl-delta'
322 335
@@ -132,6 +132,9 b' non-lfs content, and the extension enabl'
132 132 requirements
133 133 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
134 134
135 sidedata
136 Allows storage of extra data alongside a revision.
137
135 138 beginning upgrade...
136 139 repository locked and read-only
137 140 creating temporary repository to stage migrated data: * (glob)
@@ -57,6 +57,7 b' An upgrade of a repository created with '
57 57 dotencode: yes
58 58 generaldelta: yes
59 59 sparserevlog: yes
60 sidedata: no
60 61 plain-cl-delta: yes
61 62 compression: zlib
62 63 compression-level: default
@@ -66,6 +67,7 b' An upgrade of a repository created with '
66 67 dotencode: yes yes yes
67 68 generaldelta: yes yes yes
68 69 sparserevlog: yes yes yes
70 sidedata: no no no
69 71 plain-cl-delta: yes yes yes
70 72 compression: zlib zlib zlib
71 73 compression-level: default default default
@@ -75,6 +77,7 b' An upgrade of a repository created with '
75 77 dotencode: yes no yes
76 78 generaldelta: yes yes yes
77 79 sparserevlog: yes yes yes
80 sidedata: no no no
78 81 plain-cl-delta: yes yes yes
79 82 compression: zlib zlib zlib
80 83 compression-level: default default default
@@ -84,6 +87,7 b' An upgrade of a repository created with '
84 87 [formatvariant.name.mismatchconfig|dotencode: ][formatvariant.repo.mismatchconfig| yes][formatvariant.config.special| no][formatvariant.default| yes]
85 88 [formatvariant.name.uptodate|generaldelta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
86 89 [formatvariant.name.uptodate|sparserevlog: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
90 [formatvariant.name.uptodate|sidedata: ][formatvariant.repo.uptodate| no][formatvariant.config.default| no][formatvariant.default| no]
87 91 [formatvariant.name.uptodate|plain-cl-delta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
88 92 [formatvariant.name.uptodate|compression: ][formatvariant.repo.uptodate| zlib][formatvariant.config.default| zlib][formatvariant.default| zlib]
89 93 [formatvariant.name.uptodate|compression-level:][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
@@ -114,6 +118,12 b' An upgrade of a repository created with '
114 118 "repo": true
115 119 },
116 120 {
121 "config": false,
122 "default": false,
123 "name": "sidedata",
124 "repo": false
125 },
126 {
117 127 "config": true,
118 128 "default": true,
119 129 "name": "plain-cl-delta",
@@ -139,6 +149,9 b' An upgrade of a repository created with '
139 149 requirements
140 150 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
141 151
152 sidedata
153 Allows storage of extra data alongside a revision.
154
142 155 additional optimizations are available by specifying "--optimize <name>":
143 156
144 157 re-delta-parent
@@ -163,6 +176,9 b' An upgrade of a repository created with '
163 176 requirements
164 177 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
165 178
179 sidedata
180 Allows storage of extra data alongside a revision.
181
166 182 re-delta-parent
167 183 deltas within internal storage will choose a new base revision if needed
168 184
@@ -187,6 +203,9 b' modern form of the option'
187 203 requirements
188 204 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
189 205
206 sidedata
207 Allows storage of extra data alongside a revision.
208
190 209 re-delta-parent
191 210 deltas within internal storage will choose a new base revision if needed
192 211
@@ -222,6 +241,7 b' Various sub-optimal detections work'
222 241 dotencode: no
223 242 generaldelta: no
224 243 sparserevlog: no
244 sidedata: no
225 245 plain-cl-delta: yes
226 246 compression: zlib
227 247 compression-level: default
@@ -231,6 +251,7 b' Various sub-optimal detections work'
231 251 dotencode: no yes yes
232 252 generaldelta: no yes yes
233 253 sparserevlog: no yes yes
254 sidedata: no no no
234 255 plain-cl-delta: yes yes yes
235 256 compression: zlib zlib zlib
236 257 compression-level: default default default
@@ -240,6 +261,7 b' Various sub-optimal detections work'
240 261 dotencode: no yes yes
241 262 generaldelta: no no yes
242 263 sparserevlog: no no yes
264 sidedata: no no no
243 265 plain-cl-delta: yes yes yes
244 266 compression: zlib zlib zlib
245 267 compression-level: default default default
@@ -249,6 +271,7 b' Various sub-optimal detections work'
249 271 [formatvariant.name.mismatchconfig|dotencode: ][formatvariant.repo.mismatchconfig| no][formatvariant.config.default| yes][formatvariant.default| yes]
250 272 [formatvariant.name.mismatchdefault|generaldelta: ][formatvariant.repo.mismatchdefault| no][formatvariant.config.special| no][formatvariant.default| yes]
251 273 [formatvariant.name.mismatchdefault|sparserevlog: ][formatvariant.repo.mismatchdefault| no][formatvariant.config.special| no][formatvariant.default| yes]
274 [formatvariant.name.uptodate|sidedata: ][formatvariant.repo.uptodate| no][formatvariant.config.default| no][formatvariant.default| no]
252 275 [formatvariant.name.uptodate|plain-cl-delta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
253 276 [formatvariant.name.uptodate|compression: ][formatvariant.repo.uptodate| zlib][formatvariant.config.default| zlib][formatvariant.default| zlib]
254 277 [formatvariant.name.uptodate|compression-level:][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
@@ -286,6 +309,9 b' Various sub-optimal detections work'
286 309 sparserevlog
287 310 Revlog supports delta chain with more unused data between payload. These gaps will be skipped at read time. This allows for better delta chains, making a better compression and faster exchange with server.
288 311
312 sidedata
313 Allows storage of extra data alongside a revision.
314
289 315 additional optimizations are available by specifying "--optimize <name>":
290 316
291 317 re-delta-parent
@@ -334,6 +360,9 b' Various sub-optimal detections work'
334 360 sparserevlog
335 361 Revlog supports delta chain with more unused data between payload. These gaps will be skipped at read time. This allows for better delta chains, making a better compression and faster exchange with server.
336 362
363 sidedata
364 Allows storage of extra data alongside a revision.
365
337 366 additional optimizations are available by specifying "--optimize <name>":
338 367
339 368 re-delta-parent
@@ -360,6 +389,9 b' Upgrading a repository that is already m'
360 389 requirements
361 390 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
362 391
392 sidedata
393 Allows storage of extra data alongside a revision.
394
363 395 beginning upgrade...
364 396 repository locked and read-only
365 397 creating temporary repository to stage migrated data: $TESTTMP/modern/.hg/upgrade.* (glob)
@@ -411,6 +443,9 b' make sure we have a .d file'
411 443 generaldelta
412 444 repository storage will be able to create optimal deltas; new repository data will be smaller and read times should decrease; interacting with other repositories using this storage model should require less network and CPU resources, making "hg push" and "hg pull" faster
413 445
446 sidedata
447 Allows storage of extra data alongside a revision.
448
414 449 beginning upgrade...
415 450 repository locked and read-only
416 451 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
@@ -507,6 +542,9 b' unless --no-backup is passed'
507 542 sparserevlog
508 543 Revlog supports delta chain with more unused data between payload. These gaps will be skipped at read time. This allows for better delta chains, making a better compression and faster exchange with server.
509 544
545 sidedata
546 Allows storage of extra data alongside a revision.
547
510 548 beginning upgrade...
511 549 repository locked and read-only
512 550 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
@@ -541,6 +579,9 b' We can restrict optimization to some rev'
541 579 requirements
542 580 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
543 581
582 sidedata
583 Allows storage of extra data alongside a revision.
584
544 585 re-delta-parent
545 586 deltas within internal storage will choose a new base revision if needed
546 587
@@ -614,6 +655,9 b' Check we can select negatively'
614 655 requirements
615 656 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
616 657
658 sidedata
659 Allows storage of extra data alongside a revision.
660
617 661 re-delta-parent
618 662 deltas within internal storage will choose a new base revision if needed
619 663
@@ -660,6 +704,9 b' Check that we can select changelog only'
660 704 requirements
661 705 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
662 706
707 sidedata
708 Allows storage of extra data alongside a revision.
709
663 710 re-delta-parent
664 711 deltas within internal storage will choose a new base revision if needed
665 712
@@ -706,6 +753,9 b' Check that we can select filelog only'
706 753 requirements
707 754 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
708 755
756 sidedata
757 Allows storage of extra data alongside a revision.
758
709 759 re-delta-parent
710 760 deltas within internal storage will choose a new base revision if needed
711 761
@@ -757,6 +807,9 b" Check you can't skip revlog clone during"
757 807 preserved: dotencode, fncache, generaldelta, revlogv1, store
758 808 removed: sparserevlog
759 809
810 sidedata
811 Allows storage of extra data alongside a revision.
812
760 813 re-delta-parent
761 814 deltas within internal storage will choose a new base revision if needed
762 815
@@ -809,6 +862,9 b" Check you can't skip revlog clone during"
809 862 sparserevlog
810 863 Revlog supports delta chain with more unused data between payload. These gaps will be skipped at read time. This allows for better delta chains, making a better compression and faster exchange with server.
811 864
865 sidedata
866 Allows storage of extra data alongside a revision.
867
812 868 re-delta-parent
813 869 deltas within internal storage will choose a new base revision if needed
814 870
@@ -863,6 +919,9 b" store files with special filenames aren'"
863 919 requirements
864 920 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
865 921
922 sidedata
923 Allows storage of extra data alongside a revision.
924
866 925 beginning upgrade...
867 926 repository locked and read-only
868 927 creating temporary repository to stage migrated data: $TESTTMP/store-filenames/.hg/upgrade.* (glob)
@@ -894,6 +953,9 b" store files with special filenames aren'"
894 953 requirements
895 954 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
896 955
956 sidedata
957 Allows storage of extra data alongside a revision.
958
897 959 re-delta-fulladd
898 960 each revision will be added as new content to the internal storage; this will likely drastically slow down execution time, but some extensions might need it
899 961
@@ -958,6 +1020,9 b' Check upgrading a large file repository'
958 1020 requirements
959 1021 preserved: dotencode, fncache, generaldelta, largefiles, revlogv1, sparserevlog, store
960 1022
1023 sidedata
1024 Allows storage of extra data alongside a revision.
1025
961 1026 beginning upgrade...
962 1027 repository locked and read-only
963 1028 creating temporary repository to stage migrated data: $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
@@ -1011,6 +1076,9 b' Check upgrading a large file repository'
1011 1076 requirements
1012 1077 preserved: dotencode, fncache, generaldelta, largefiles, lfs, revlogv1, sparserevlog, store
1013 1078
1079 sidedata
1080 Allows storage of extra data alongside a revision.
1081
1014 1082 beginning upgrade...
1015 1083 repository locked and read-only
1016 1084 creating temporary repository to stage migrated data: $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
@@ -1106,6 +1174,9 b' repository config is taken in account'
1106 1174 requirements
1107 1175 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
1108 1176
1177 sidedata
1178 Allows storage of extra data alongside a revision.
1179
1109 1180 re-delta-all
1110 1181 deltas within internal storage will be fully recomputed; this will likely drastically slow down execution time
1111 1182
@@ -1197,6 +1268,7 b' upgrade'
1197 1268 dotencode: yes yes yes
1198 1269 generaldelta: yes yes yes
1199 1270 sparserevlog: yes yes yes
1271 sidedata: no no no
1200 1272 plain-cl-delta: yes yes yes
1201 1273 compression: zstd zlib zlib
1202 1274 compression-level: default default default
@@ -1218,6 +1290,7 b' downgrade'
1218 1290 dotencode: yes yes yes
1219 1291 generaldelta: yes yes yes
1220 1292 sparserevlog: yes yes yes
1293 sidedata: no no no
1221 1294 plain-cl-delta: yes yes yes
1222 1295 compression: zlib zlib zlib
1223 1296 compression-level: default default default
@@ -1242,6 +1315,7 b' upgrade from hgrc'
1242 1315 dotencode: yes yes yes
1243 1316 generaldelta: yes yes yes
1244 1317 sparserevlog: yes yes yes
1318 sidedata: no no no
1245 1319 plain-cl-delta: yes yes yes
1246 1320 compression: zstd zstd zlib
1247 1321 compression-level: default default default
General Comments 0
You need to be logged in to leave comments. Login now