Mercurial > hg
comparison tests/test-upgrade-repo.t @ 35345:6226668a7169
upgrade: add a 'redeltafullall' mode
We add a new mode for delta recomputation, when selected, each full text will
go through the full "addrevision" mechanism again. This is slower than
"redeltaall" but this gives the opportunity for extensions to trigger special
logic. For example, the lfs extensions can decide to promote some revision to
lfs storage during the upgrade.
author | Boris Feld <boris.feld@octobus.net> |
---|---|
date | Thu, 07 Dec 2017 20:27:03 +0100 |
parents | 75520786ad2f |
children | 6699825f1242 |
comparison
equal
deleted
inserted
replaced
35344:8f3f8b8dbab7 | 35345:6226668a7169 |
---|---|
98 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges | 98 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges |
99 | 99 |
100 redeltaall | 100 redeltaall |
101 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed | 101 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed |
102 | 102 |
103 redeltafulladd | |
104 every revision will be re-added as if it was new content. It will go through the full storage mechanism giving extensions a chance to process it (eg. lfs). This is similar to "redeltaall" but even slower since more logic is involved. | |
105 | |
103 | 106 |
104 --optimize can be used to add optimizations | 107 --optimize can be used to add optimizations |
105 | 108 |
106 $ hg debugupgrade --optimize redeltaparent | 109 $ hg debugupgrade --optimize redeltaparent |
107 (no feature deficiencies found in existing repository) | 110 (no feature deficiencies found in existing repository) |
118 redeltamultibase | 121 redeltamultibase |
119 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges | 122 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges |
120 | 123 |
121 redeltaall | 124 redeltaall |
122 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed | 125 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed |
126 | |
127 redeltafulladd | |
128 every revision will be re-added as if it was new content. It will go through the full storage mechanism giving extensions a chance to process it (eg. lfs). This is similar to "redeltaall" but even slower since more logic is involved. | |
123 | 129 |
124 | 130 |
125 Various sub-optimal detections work | 131 Various sub-optimal detections work |
126 | 132 |
127 $ cat > .hg/requires << EOF | 133 $ cat > .hg/requires << EOF |
194 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges | 200 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges |
195 | 201 |
196 redeltaall | 202 redeltaall |
197 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed | 203 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed |
198 | 204 |
205 redeltafulladd | |
206 every revision will be re-added as if it was new content. It will go through the full storage mechanism giving extensions a chance to process it (eg. lfs). This is similar to "redeltaall" but even slower since more logic is involved. | |
207 | |
199 | 208 |
200 $ hg --config format.dotencode=false debugupgraderepo | 209 $ hg --config format.dotencode=false debugupgraderepo |
201 repository lacks features recommended by current config options: | 210 repository lacks features recommended by current config options: |
202 | 211 |
203 fncache | 212 fncache |
232 redeltamultibase | 241 redeltamultibase |
233 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges | 242 deltas within internal storage will be recalculated against multiple base revision and the smallest difference will be used; the size of the repository may shrink significantly when there are many merges; this optimization will slow down execution in proportion to the number of merges in the repository and the amount of files in the repository; this slow down should not be significant unless there are tens of thousands of files and thousands of merges |
234 | 243 |
235 redeltaall | 244 redeltaall |
236 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed | 245 deltas within internal storage will always be recalculated without reusing prior deltas; this will likely make execution run several times slower; this optimization is typically not needed |
246 | |
247 redeltafulladd | |
248 every revision will be re-added as if it was new content. It will go through the full storage mechanism giving extensions a chance to process it (eg. lfs). This is similar to "redeltaall" but even slower since more logic is involved. | |
237 | 249 |
238 | 250 |
239 $ cd .. | 251 $ cd .. |
240 | 252 |
241 Upgrading a repository that is already modern essentially no-ops | 253 Upgrading a repository that is already modern essentially no-ops |
400 marking source repository as being upgraded; clients will be unable to read from repository | 412 marking source repository as being upgraded; clients will be unable to read from repository |
401 starting in-place swap of repository data | 413 starting in-place swap of repository data |
402 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob) | 414 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob) |
403 replacing store... | 415 replacing store... |
404 store replacement complete; repository was inconsistent for *s (glob) | 416 store replacement complete; repository was inconsistent for *s (glob) |
417 finalizing requirements file and making repository readable again | |
418 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob) | |
419 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob) | |
420 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified | |
421 $ hg debugupgraderepo --run --optimize redeltafulladd | |
422 upgrade will perform the following actions: | |
423 | |
424 requirements | |
425 preserved: dotencode, fncache, generaldelta, revlogv1, store | |
426 | |
427 redeltafulladd | |
428 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 | |
429 | |
430 beginning upgrade... | |
431 repository locked and read-only | |
432 creating temporary repository to stage migrated data: $TESTTMP/store-filenames/.hg/upgrade.* (glob) | |
433 (it is safe to interrupt this process any time before data migration completes) | |
434 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog) | |
435 migrating 109 bytes in store; 107 bytes tracked data | |
436 migrating 1 filelogs containing 1 revisions (0 bytes in store; 0 bytes tracked data) | |
437 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes | |
438 migrating 1 manifests containing 1 revisions (46 bytes in store; 45 bytes tracked data) | |
439 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes | |
440 migrating changelog containing 1 revisions (63 bytes in store; 62 bytes tracked data) | |
441 finished migrating 1 changelog revisions; change in size: 0 bytes | |
442 finished migrating 3 total revisions; total change in store size: 0 bytes | |
443 copying .XX_special_filename | |
444 copying phaseroots | |
445 data fully migrated to temporary repository | |
446 marking source repository as being upgraded; clients will be unable to read from repository | |
447 starting in-place swap of repository data | |
448 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob) | |
449 replacing store... | |
450 store replacement complete; repository was inconsistent for 0.0s | |
405 finalizing requirements file and making repository readable again | 451 finalizing requirements file and making repository readable again |
406 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob) | 452 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob) |
407 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob) | 453 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob) |
408 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified | 454 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified |
409 | 455 |