##// END OF EJS Templates
tests: conditionalize output for Python 3...
Gregory Szorc -
r43344:9cc55b74 default
parent child Browse files
Show More
@@ -1,1333 +1,1334 b''
1 #require no-reposimplestore
1 #require no-reposimplestore
2
2
3 $ cat >> $HGRCPATH << EOF
3 $ cat >> $HGRCPATH << EOF
4 > [extensions]
4 > [extensions]
5 > share =
5 > share =
6 > EOF
6 > EOF
7
7
8 store and revlogv1 are required in source
8 store and revlogv1 are required in source
9
9
10 $ hg --config format.usestore=false init no-store
10 $ hg --config format.usestore=false init no-store
11 $ hg -R no-store debugupgraderepo
11 $ hg -R no-store debugupgraderepo
12 abort: cannot upgrade repository; requirement missing: store
12 abort: cannot upgrade repository; requirement missing: store
13 [255]
13 [255]
14
14
15 $ hg init no-revlogv1
15 $ hg init no-revlogv1
16 $ cat > no-revlogv1/.hg/requires << EOF
16 $ cat > no-revlogv1/.hg/requires << EOF
17 > dotencode
17 > dotencode
18 > fncache
18 > fncache
19 > generaldelta
19 > generaldelta
20 > store
20 > store
21 > EOF
21 > EOF
22
22
23 $ hg -R no-revlogv1 debugupgraderepo
23 $ hg -R no-revlogv1 debugupgraderepo
24 abort: cannot upgrade repository; requirement missing: revlogv1
24 abort: cannot upgrade repository; requirement missing: revlogv1
25 [255]
25 [255]
26
26
27 Cannot upgrade shared repositories
27 Cannot upgrade shared repositories
28
28
29 $ hg init share-parent
29 $ hg init share-parent
30 $ hg -q share share-parent share-child
30 $ hg -q share share-parent share-child
31
31
32 $ hg -R share-child debugupgraderepo
32 $ hg -R share-child debugupgraderepo
33 abort: cannot upgrade repository; unsupported source requirement: shared
33 abort: cannot upgrade repository; unsupported source requirement: shared
34 [255]
34 [255]
35
35
36 Do not yet support upgrading treemanifest repos
36 Do not yet support upgrading treemanifest repos
37
37
38 $ hg --config experimental.treemanifest=true init treemanifest
38 $ hg --config experimental.treemanifest=true init treemanifest
39 $ hg -R treemanifest debugupgraderepo
39 $ hg -R treemanifest debugupgraderepo
40 abort: cannot upgrade repository; unsupported source requirement: treemanifest
40 abort: cannot upgrade repository; unsupported source requirement: treemanifest
41 [255]
41 [255]
42
42
43 Cannot add treemanifest requirement during upgrade
43 Cannot add treemanifest requirement during upgrade
44
44
45 $ hg init disallowaddedreq
45 $ hg init disallowaddedreq
46 $ hg -R disallowaddedreq --config experimental.treemanifest=true debugupgraderepo
46 $ hg -R disallowaddedreq --config experimental.treemanifest=true debugupgraderepo
47 abort: cannot upgrade repository; do not support adding requirement: treemanifest
47 abort: cannot upgrade repository; do not support adding requirement: treemanifest
48 [255]
48 [255]
49
49
50 An upgrade of a repository created with recommended settings only suggests optimizations
50 An upgrade of a repository created with recommended settings only suggests optimizations
51
51
52 $ hg init empty
52 $ hg init empty
53 $ cd empty
53 $ cd empty
54 $ hg debugformat
54 $ hg debugformat
55 format-variant repo
55 format-variant repo
56 fncache: yes
56 fncache: yes
57 dotencode: yes
57 dotencode: yes
58 generaldelta: yes
58 generaldelta: yes
59 sparserevlog: yes
59 sparserevlog: yes
60 sidedata: no
60 sidedata: no
61 plain-cl-delta: yes
61 plain-cl-delta: yes
62 compression: zlib
62 compression: zlib
63 compression-level: default
63 compression-level: default
64 $ hg debugformat --verbose
64 $ hg debugformat --verbose
65 format-variant repo config default
65 format-variant repo config default
66 fncache: yes yes yes
66 fncache: yes yes yes
67 dotencode: yes yes yes
67 dotencode: yes yes yes
68 generaldelta: yes yes yes
68 generaldelta: yes yes yes
69 sparserevlog: yes yes yes
69 sparserevlog: yes yes yes
70 sidedata: no no no
70 sidedata: no no no
71 plain-cl-delta: yes yes yes
71 plain-cl-delta: yes yes yes
72 compression: zlib zlib zlib
72 compression: zlib zlib zlib
73 compression-level: default default default
73 compression-level: default default default
74 $ hg debugformat --verbose --config format.usefncache=no
74 $ hg debugformat --verbose --config format.usefncache=no
75 format-variant repo config default
75 format-variant repo config default
76 fncache: yes no yes
76 fncache: yes no yes
77 dotencode: yes no yes
77 dotencode: yes no yes
78 generaldelta: yes yes yes
78 generaldelta: yes yes yes
79 sparserevlog: yes yes yes
79 sparserevlog: yes yes yes
80 sidedata: no no no
80 sidedata: no no no
81 plain-cl-delta: yes yes yes
81 plain-cl-delta: yes yes yes
82 compression: zlib zlib zlib
82 compression: zlib zlib zlib
83 compression-level: default default default
83 compression-level: default default default
84 $ hg debugformat --verbose --config format.usefncache=no --color=debug
84 $ hg debugformat --verbose --config format.usefncache=no --color=debug
85 format-variant repo config default
85 format-variant repo config default
86 [formatvariant.name.mismatchconfig|fncache: ][formatvariant.repo.mismatchconfig| yes][formatvariant.config.special| no][formatvariant.default| yes]
86 [formatvariant.name.mismatchconfig|fncache: ][formatvariant.repo.mismatchconfig| yes][formatvariant.config.special| no][formatvariant.default| yes]
87 [formatvariant.name.mismatchconfig|dotencode: ][formatvariant.repo.mismatchconfig| yes][formatvariant.config.special| no][formatvariant.default| yes]
87 [formatvariant.name.mismatchconfig|dotencode: ][formatvariant.repo.mismatchconfig| yes][formatvariant.config.special| no][formatvariant.default| yes]
88 [formatvariant.name.uptodate|generaldelta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
88 [formatvariant.name.uptodate|generaldelta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
89 [formatvariant.name.uptodate|sparserevlog: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
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]
90 [formatvariant.name.uptodate|sidedata: ][formatvariant.repo.uptodate| no][formatvariant.config.default| no][formatvariant.default| no]
91 [formatvariant.name.uptodate|plain-cl-delta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
91 [formatvariant.name.uptodate|plain-cl-delta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
92 [formatvariant.name.uptodate|compression: ][formatvariant.repo.uptodate| zlib][formatvariant.config.default| zlib][formatvariant.default| zlib]
92 [formatvariant.name.uptodate|compression: ][formatvariant.repo.uptodate| zlib][formatvariant.config.default| zlib][formatvariant.default| zlib]
93 [formatvariant.name.uptodate|compression-level:][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
93 [formatvariant.name.uptodate|compression-level:][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
94 $ hg debugformat -Tjson
94 $ hg debugformat -Tjson
95 [
95 [
96 {
96 {
97 "config": true,
97 "config": true,
98 "default": true,
98 "default": true,
99 "name": "fncache",
99 "name": "fncache",
100 "repo": true
100 "repo": true
101 },
101 },
102 {
102 {
103 "config": true,
103 "config": true,
104 "default": true,
104 "default": true,
105 "name": "dotencode",
105 "name": "dotencode",
106 "repo": true
106 "repo": true
107 },
107 },
108 {
108 {
109 "config": true,
109 "config": true,
110 "default": true,
110 "default": true,
111 "name": "generaldelta",
111 "name": "generaldelta",
112 "repo": true
112 "repo": true
113 },
113 },
114 {
114 {
115 "config": true,
115 "config": true,
116 "default": true,
116 "default": true,
117 "name": "sparserevlog",
117 "name": "sparserevlog",
118 "repo": true
118 "repo": true
119 },
119 },
120 {
120 {
121 "config": false,
121 "config": false,
122 "default": false,
122 "default": false,
123 "name": "sidedata",
123 "name": "sidedata",
124 "repo": false
124 "repo": false
125 },
125 },
126 {
126 {
127 "config": true,
127 "config": true,
128 "default": true,
128 "default": true,
129 "name": "plain-cl-delta",
129 "name": "plain-cl-delta",
130 "repo": true
130 "repo": true
131 },
131 },
132 {
132 {
133 "config": "zlib",
133 "config": "zlib",
134 "default": "zlib",
134 "default": "zlib",
135 "name": "compression",
135 "name": "compression",
136 "repo": "zlib"
136 "repo": "zlib"
137 },
137 },
138 {
138 {
139 "config": "default",
139 "config": "default",
140 "default": "default",
140 "default": "default",
141 "name": "compression-level",
141 "name": "compression-level",
142 "repo": "default"
142 "repo": "default"
143 }
143 }
144 ]
144 ]
145 $ hg debugupgraderepo
145 $ hg debugupgraderepo
146 (no feature deficiencies found in existing repository)
146 (no feature deficiencies found in existing repository)
147 performing an upgrade with "--run" will make the following changes:
147 performing an upgrade with "--run" will make the following changes:
148
148
149 requirements
149 requirements
150 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
150 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
151
151
152 sidedata
152 sidedata
153 Allows storage of extra data alongside a revision.
153 Allows storage of extra data alongside a revision.
154
154
155 additional optimizations are available by specifying "--optimize <name>":
155 additional optimizations are available by specifying "--optimize <name>":
156
156
157 re-delta-parent
157 re-delta-parent
158 deltas within internal storage will be recalculated to choose an optimal base revision where this was not already done; the size of the repository may shrink and various operations may become faster; the first time this optimization is performed could slow down upgrade execution considerably; subsequent invocations should not run noticeably slower
158 deltas within internal storage will be recalculated to choose an optimal base revision where this was not already done; the size of the repository may shrink and various operations may become faster; the first time this optimization is performed could slow down upgrade execution considerably; subsequent invocations should not run noticeably slower
159
159
160 re-delta-multibase
160 re-delta-multibase
161 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
161 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
162
162
163 re-delta-all
163 re-delta-all
164 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
164 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
165
165
166 re-delta-fulladd
166 re-delta-fulladd
167 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 "re-delta-all" but even slower since more logic is involved.
167 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 "re-delta-all" but even slower since more logic is involved.
168
168
169
169
170 --optimize can be used to add optimizations
170 --optimize can be used to add optimizations
171
171
172 $ hg debugupgrade --optimize redeltaparent
172 $ hg debugupgrade --optimize redeltaparent
173 (no feature deficiencies found in existing repository)
173 (no feature deficiencies found in existing repository)
174 performing an upgrade with "--run" will make the following changes:
174 performing an upgrade with "--run" will make the following changes:
175
175
176 requirements
176 requirements
177 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
177 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
178
178
179 sidedata
179 sidedata
180 Allows storage of extra data alongside a revision.
180 Allows storage of extra data alongside a revision.
181
181
182 re-delta-parent
182 re-delta-parent
183 deltas within internal storage will choose a new base revision if needed
183 deltas within internal storage will choose a new base revision if needed
184
184
185 additional optimizations are available by specifying "--optimize <name>":
185 additional optimizations are available by specifying "--optimize <name>":
186
186
187 re-delta-multibase
187 re-delta-multibase
188 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
188 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
189
189
190 re-delta-all
190 re-delta-all
191 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
191 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
192
192
193 re-delta-fulladd
193 re-delta-fulladd
194 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 "re-delta-all" but even slower since more logic is involved.
194 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 "re-delta-all" but even slower since more logic is involved.
195
195
196
196
197 modern form of the option
197 modern form of the option
198
198
199 $ hg debugupgrade --optimize re-delta-parent
199 $ hg debugupgrade --optimize re-delta-parent
200 (no feature deficiencies found in existing repository)
200 (no feature deficiencies found in existing repository)
201 performing an upgrade with "--run" will make the following changes:
201 performing an upgrade with "--run" will make the following changes:
202
202
203 requirements
203 requirements
204 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
204 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
205
205
206 sidedata
206 sidedata
207 Allows storage of extra data alongside a revision.
207 Allows storage of extra data alongside a revision.
208
208
209 re-delta-parent
209 re-delta-parent
210 deltas within internal storage will choose a new base revision if needed
210 deltas within internal storage will choose a new base revision if needed
211
211
212 additional optimizations are available by specifying "--optimize <name>":
212 additional optimizations are available by specifying "--optimize <name>":
213
213
214 re-delta-multibase
214 re-delta-multibase
215 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
215 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
216
216
217 re-delta-all
217 re-delta-all
218 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
218 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
219
219
220 re-delta-fulladd
220 re-delta-fulladd
221 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 "re-delta-all" but even slower since more logic is involved.
221 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 "re-delta-all" but even slower since more logic is involved.
222
222
223
223
224 unknown optimization:
224 unknown optimization:
225
225
226 $ hg debugupgrade --optimize foobar
226 $ hg debugupgrade --optimize foobar
227 abort: unknown optimization action requested: foobar
227 abort: unknown optimization action requested: foobar
228 (run without arguments to see valid optimizations)
228 (run without arguments to see valid optimizations)
229 [255]
229 [255]
230
230
231 Various sub-optimal detections work
231 Various sub-optimal detections work
232
232
233 $ cat > .hg/requires << EOF
233 $ cat > .hg/requires << EOF
234 > revlogv1
234 > revlogv1
235 > store
235 > store
236 > EOF
236 > EOF
237
237
238 $ hg debugformat
238 $ hg debugformat
239 format-variant repo
239 format-variant repo
240 fncache: no
240 fncache: no
241 dotencode: no
241 dotencode: no
242 generaldelta: no
242 generaldelta: no
243 sparserevlog: no
243 sparserevlog: no
244 sidedata: no
244 sidedata: no
245 plain-cl-delta: yes
245 plain-cl-delta: yes
246 compression: zlib
246 compression: zlib
247 compression-level: default
247 compression-level: default
248 $ hg debugformat --verbose
248 $ hg debugformat --verbose
249 format-variant repo config default
249 format-variant repo config default
250 fncache: no yes yes
250 fncache: no yes yes
251 dotencode: no yes yes
251 dotencode: no yes yes
252 generaldelta: no yes yes
252 generaldelta: no yes yes
253 sparserevlog: no yes yes
253 sparserevlog: no yes yes
254 sidedata: no no no
254 sidedata: no no no
255 plain-cl-delta: yes yes yes
255 plain-cl-delta: yes yes yes
256 compression: zlib zlib zlib
256 compression: zlib zlib zlib
257 compression-level: default default default
257 compression-level: default default default
258 $ hg debugformat --verbose --config format.usegeneraldelta=no
258 $ hg debugformat --verbose --config format.usegeneraldelta=no
259 format-variant repo config default
259 format-variant repo config default
260 fncache: no yes yes
260 fncache: no yes yes
261 dotencode: no yes yes
261 dotencode: no yes yes
262 generaldelta: no no yes
262 generaldelta: no no yes
263 sparserevlog: no no yes
263 sparserevlog: no no yes
264 sidedata: no no no
264 sidedata: no no no
265 plain-cl-delta: yes yes yes
265 plain-cl-delta: yes yes yes
266 compression: zlib zlib zlib
266 compression: zlib zlib zlib
267 compression-level: default default default
267 compression-level: default default default
268 $ hg debugformat --verbose --config format.usegeneraldelta=no --color=debug
268 $ hg debugformat --verbose --config format.usegeneraldelta=no --color=debug
269 format-variant repo config default
269 format-variant repo config default
270 [formatvariant.name.mismatchconfig|fncache: ][formatvariant.repo.mismatchconfig| no][formatvariant.config.default| yes][formatvariant.default| yes]
270 [formatvariant.name.mismatchconfig|fncache: ][formatvariant.repo.mismatchconfig| no][formatvariant.config.default| yes][formatvariant.default| yes]
271 [formatvariant.name.mismatchconfig|dotencode: ][formatvariant.repo.mismatchconfig| no][formatvariant.config.default| yes][formatvariant.default| yes]
271 [formatvariant.name.mismatchconfig|dotencode: ][formatvariant.repo.mismatchconfig| no][formatvariant.config.default| yes][formatvariant.default| yes]
272 [formatvariant.name.mismatchdefault|generaldelta: ][formatvariant.repo.mismatchdefault| no][formatvariant.config.special| no][formatvariant.default| yes]
272 [formatvariant.name.mismatchdefault|generaldelta: ][formatvariant.repo.mismatchdefault| no][formatvariant.config.special| no][formatvariant.default| yes]
273 [formatvariant.name.mismatchdefault|sparserevlog: ][formatvariant.repo.mismatchdefault| no][formatvariant.config.special| no][formatvariant.default| yes]
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]
274 [formatvariant.name.uptodate|sidedata: ][formatvariant.repo.uptodate| no][formatvariant.config.default| no][formatvariant.default| no]
275 [formatvariant.name.uptodate|plain-cl-delta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
275 [formatvariant.name.uptodate|plain-cl-delta: ][formatvariant.repo.uptodate| yes][formatvariant.config.default| yes][formatvariant.default| yes]
276 [formatvariant.name.uptodate|compression: ][formatvariant.repo.uptodate| zlib][formatvariant.config.default| zlib][formatvariant.default| zlib]
276 [formatvariant.name.uptodate|compression: ][formatvariant.repo.uptodate| zlib][formatvariant.config.default| zlib][formatvariant.default| zlib]
277 [formatvariant.name.uptodate|compression-level:][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
277 [formatvariant.name.uptodate|compression-level:][formatvariant.repo.uptodate| default][formatvariant.config.default| default][formatvariant.default| default]
278 $ hg debugupgraderepo
278 $ hg debugupgraderepo
279 repository lacks features recommended by current config options:
279 repository lacks features recommended by current config options:
280
280
281 fncache
281 fncache
282 long and reserved filenames may not work correctly; repository performance is sub-optimal
282 long and reserved filenames may not work correctly; repository performance is sub-optimal
283
283
284 dotencode
284 dotencode
285 storage of filenames beginning with a period or space may not work correctly
285 storage of filenames beginning with a period or space may not work correctly
286
286
287 generaldelta
287 generaldelta
288 deltas within internal storage are unable to choose optimal revisions; repository is larger and slower than it could be; interaction with other repositories may require extra network and CPU resources, making "hg push" and "hg pull" slower
288 deltas within internal storage are unable to choose optimal revisions; repository is larger and slower than it could be; interaction with other repositories may require extra network and CPU resources, making "hg push" and "hg pull" slower
289
289
290 sparserevlog
290 sparserevlog
291 in order to limit disk reading and memory usage on older version, the span of a delta chain from its root to its end is limited, whatever the relevant data in this span. This can severly limit Mercurial ability to build good chain of delta resulting is much more storage space being taken and limit reusability of on disk delta during exchange.
291 in order to limit disk reading and memory usage on older version, the span of a delta chain from its root to its end is limited, whatever the relevant data in this span. This can severly limit Mercurial ability to build good chain of delta resulting is much more storage space being taken and limit reusability of on disk delta during exchange.
292
292
293
293
294 performing an upgrade with "--run" will make the following changes:
294 performing an upgrade with "--run" will make the following changes:
295
295
296 requirements
296 requirements
297 preserved: revlogv1, store
297 preserved: revlogv1, store
298 added: dotencode, fncache, generaldelta, sparserevlog
298 added: dotencode, fncache, generaldelta, sparserevlog
299
299
300 fncache
300 fncache
301 repository will be more resilient to storing certain paths and performance of certain operations should be improved
301 repository will be more resilient to storing certain paths and performance of certain operations should be improved
302
302
303 dotencode
303 dotencode
304 repository will be better able to store files beginning with a space or period
304 repository will be better able to store files beginning with a space or period
305
305
306 generaldelta
306 generaldelta
307 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
307 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
308
308
309 sparserevlog
309 sparserevlog
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.
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.
311
311
312 sidedata
312 sidedata
313 Allows storage of extra data alongside a revision.
313 Allows storage of extra data alongside a revision.
314
314
315 additional optimizations are available by specifying "--optimize <name>":
315 additional optimizations are available by specifying "--optimize <name>":
316
316
317 re-delta-parent
317 re-delta-parent
318 deltas within internal storage will be recalculated to choose an optimal base revision where this was not already done; the size of the repository may shrink and various operations may become faster; the first time this optimization is performed could slow down upgrade execution considerably; subsequent invocations should not run noticeably slower
318 deltas within internal storage will be recalculated to choose an optimal base revision where this was not already done; the size of the repository may shrink and various operations may become faster; the first time this optimization is performed could slow down upgrade execution considerably; subsequent invocations should not run noticeably slower
319
319
320 re-delta-multibase
320 re-delta-multibase
321 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
321 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
322
322
323 re-delta-all
323 re-delta-all
324 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
324 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
325
325
326 re-delta-fulladd
326 re-delta-fulladd
327 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 "re-delta-all" but even slower since more logic is involved.
327 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 "re-delta-all" but even slower since more logic is involved.
328
328
329
329
330 $ hg --config format.dotencode=false debugupgraderepo
330 $ hg --config format.dotencode=false debugupgraderepo
331 repository lacks features recommended by current config options:
331 repository lacks features recommended by current config options:
332
332
333 fncache
333 fncache
334 long and reserved filenames may not work correctly; repository performance is sub-optimal
334 long and reserved filenames may not work correctly; repository performance is sub-optimal
335
335
336 generaldelta
336 generaldelta
337 deltas within internal storage are unable to choose optimal revisions; repository is larger and slower than it could be; interaction with other repositories may require extra network and CPU resources, making "hg push" and "hg pull" slower
337 deltas within internal storage are unable to choose optimal revisions; repository is larger and slower than it could be; interaction with other repositories may require extra network and CPU resources, making "hg push" and "hg pull" slower
338
338
339 sparserevlog
339 sparserevlog
340 in order to limit disk reading and memory usage on older version, the span of a delta chain from its root to its end is limited, whatever the relevant data in this span. This can severly limit Mercurial ability to build good chain of delta resulting is much more storage space being taken and limit reusability of on disk delta during exchange.
340 in order to limit disk reading and memory usage on older version, the span of a delta chain from its root to its end is limited, whatever the relevant data in this span. This can severly limit Mercurial ability to build good chain of delta resulting is much more storage space being taken and limit reusability of on disk delta during exchange.
341
341
342 repository lacks features used by the default config options:
342 repository lacks features used by the default config options:
343
343
344 dotencode
344 dotencode
345 storage of filenames beginning with a period or space may not work correctly
345 storage of filenames beginning with a period or space may not work correctly
346
346
347
347
348 performing an upgrade with "--run" will make the following changes:
348 performing an upgrade with "--run" will make the following changes:
349
349
350 requirements
350 requirements
351 preserved: revlogv1, store
351 preserved: revlogv1, store
352 added: fncache, generaldelta, sparserevlog
352 added: fncache, generaldelta, sparserevlog
353
353
354 fncache
354 fncache
355 repository will be more resilient to storing certain paths and performance of certain operations should be improved
355 repository will be more resilient to storing certain paths and performance of certain operations should be improved
356
356
357 generaldelta
357 generaldelta
358 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
358 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
359
359
360 sparserevlog
360 sparserevlog
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.
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.
362
362
363 sidedata
363 sidedata
364 Allows storage of extra data alongside a revision.
364 Allows storage of extra data alongside a revision.
365
365
366 additional optimizations are available by specifying "--optimize <name>":
366 additional optimizations are available by specifying "--optimize <name>":
367
367
368 re-delta-parent
368 re-delta-parent
369 deltas within internal storage will be recalculated to choose an optimal base revision where this was not already done; the size of the repository may shrink and various operations may become faster; the first time this optimization is performed could slow down upgrade execution considerably; subsequent invocations should not run noticeably slower
369 deltas within internal storage will be recalculated to choose an optimal base revision where this was not already done; the size of the repository may shrink and various operations may become faster; the first time this optimization is performed could slow down upgrade execution considerably; subsequent invocations should not run noticeably slower
370
370
371 re-delta-multibase
371 re-delta-multibase
372 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
372 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
373
373
374 re-delta-all
374 re-delta-all
375 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
375 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
376
376
377 re-delta-fulladd
377 re-delta-fulladd
378 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 "re-delta-all" but even slower since more logic is involved.
378 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 "re-delta-all" but even slower since more logic is involved.
379
379
380
380
381 $ cd ..
381 $ cd ..
382
382
383 Upgrading a repository that is already modern essentially no-ops
383 Upgrading a repository that is already modern essentially no-ops
384
384
385 $ hg init modern
385 $ hg init modern
386 $ hg -R modern debugupgraderepo --run
386 $ hg -R modern debugupgraderepo --run
387 upgrade will perform the following actions:
387 upgrade will perform the following actions:
388
388
389 requirements
389 requirements
390 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
390 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
391
391
392 sidedata
392 sidedata
393 Allows storage of extra data alongside a revision.
393 Allows storage of extra data alongside a revision.
394
394
395 beginning upgrade...
395 beginning upgrade...
396 repository locked and read-only
396 repository locked and read-only
397 creating temporary repository to stage migrated data: $TESTTMP/modern/.hg/upgrade.* (glob)
397 creating temporary repository to stage migrated data: $TESTTMP/modern/.hg/upgrade.* (glob)
398 (it is safe to interrupt this process any time before data migration completes)
398 (it is safe to interrupt this process any time before data migration completes)
399 data fully migrated to temporary repository
399 data fully migrated to temporary repository
400 marking source repository as being upgraded; clients will be unable to read from repository
400 marking source repository as being upgraded; clients will be unable to read from repository
401 starting in-place swap of repository data
401 starting in-place swap of repository data
402 replaced files will be backed up at $TESTTMP/modern/.hg/upgradebackup.* (glob)
402 replaced files will be backed up at $TESTTMP/modern/.hg/upgradebackup.* (glob)
403 replacing store...
403 replacing store...
404 store replacement complete; repository was inconsistent for *s (glob)
404 store replacement complete; repository was inconsistent for *s (glob)
405 finalizing requirements file and making repository readable again
405 finalizing requirements file and making repository readable again
406 removing temporary repository $TESTTMP/modern/.hg/upgrade.* (glob)
406 removing temporary repository $TESTTMP/modern/.hg/upgrade.* (glob)
407 copy of old repository backed up at $TESTTMP/modern/.hg/upgradebackup.* (glob)
407 copy of old repository backed up at $TESTTMP/modern/.hg/upgradebackup.* (glob)
408 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
408 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
409
409
410 Upgrading a repository to generaldelta works
410 Upgrading a repository to generaldelta works
411
411
412 $ hg --config format.usegeneraldelta=false init upgradegd
412 $ hg --config format.usegeneraldelta=false init upgradegd
413 $ cd upgradegd
413 $ cd upgradegd
414 $ touch f0
414 $ touch f0
415 $ hg -q commit -A -m initial
415 $ hg -q commit -A -m initial
416 $ mkdir FooBarDirectory.d
416 $ mkdir FooBarDirectory.d
417 $ touch FooBarDirectory.d/f1
417 $ touch FooBarDirectory.d/f1
418 $ hg -q commit -A -m 'add f1'
418 $ hg -q commit -A -m 'add f1'
419 $ hg -q up -r 0
419 $ hg -q up -r 0
420 >>> from __future__ import absolute_import, print_function
420 >>> from __future__ import absolute_import, print_function
421 >>> import random
421 >>> import random
422 >>> random.seed(0) # have a reproducible content
422 >>> random.seed(0) # have a reproducible content
423 >>> with open("f2", "w") as f:
423 >>> with open("f2", "w") as f:
424 ... for i in range(100000):
424 ... for i in range(100000):
425 ... f.write("%d\n" % random.randint(1000000000, 9999999999)) and None
425 ... f.write("%d\n" % random.randint(1000000000, 9999999999)) and None
426 $ hg -q commit -A -m 'add f2'
426 $ hg -q commit -A -m 'add f2'
427
427
428 make sure we have a .d file
428 make sure we have a .d file
429
429
430 $ ls -d .hg/store/data/*
430 $ ls -d .hg/store/data/*
431 .hg/store/data/_foo_bar_directory.d.hg
431 .hg/store/data/_foo_bar_directory.d.hg
432 .hg/store/data/f0.i
432 .hg/store/data/f0.i
433 .hg/store/data/f2.d
433 .hg/store/data/f2.d
434 .hg/store/data/f2.i
434 .hg/store/data/f2.i
435
435
436 $ hg debugupgraderepo --run --config format.sparse-revlog=false
436 $ hg debugupgraderepo --run --config format.sparse-revlog=false
437 upgrade will perform the following actions:
437 upgrade will perform the following actions:
438
438
439 requirements
439 requirements
440 preserved: dotencode, fncache, revlogv1, store
440 preserved: dotencode, fncache, revlogv1, store
441 added: generaldelta
441 added: generaldelta
442
442
443 generaldelta
443 generaldelta
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
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
445
445
446 sidedata
446 sidedata
447 Allows storage of extra data alongside a revision.
447 Allows storage of extra data alongside a revision.
448
448
449 beginning upgrade...
449 beginning upgrade...
450 repository locked and read-only
450 repository locked and read-only
451 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
451 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
452 (it is safe to interrupt this process any time before data migration completes)
452 (it is safe to interrupt this process any time before data migration completes)
453 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
453 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
454 migrating 519 KB in store; 1.05 MB tracked data
454 migrating 519 KB in store; 1.05 MB tracked data
455 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
455 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
456 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
456 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
457 migrating 1 manifests containing 3 revisions (384 bytes in store; 238 bytes tracked data)
457 migrating 1 manifests containing 3 revisions (384 bytes in store; 238 bytes tracked data)
458 finished migrating 3 manifest revisions across 1 manifests; change in size: -17 bytes
458 finished migrating 3 manifest revisions across 1 manifests; change in size: -17 bytes
459 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
459 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
460 finished migrating 3 changelog revisions; change in size: 0 bytes
460 finished migrating 3 changelog revisions; change in size: 0 bytes
461 finished migrating 9 total revisions; total change in store size: -17 bytes
461 finished migrating 9 total revisions; total change in store size: -17 bytes
462 copying phaseroots
462 copying phaseroots
463 data fully migrated to temporary repository
463 data fully migrated to temporary repository
464 marking source repository as being upgraded; clients will be unable to read from repository
464 marking source repository as being upgraded; clients will be unable to read from repository
465 starting in-place swap of repository data
465 starting in-place swap of repository data
466 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
466 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
467 replacing store...
467 replacing store...
468 store replacement complete; repository was inconsistent for *s (glob)
468 store replacement complete; repository was inconsistent for *s (glob)
469 finalizing requirements file and making repository readable again
469 finalizing requirements file and making repository readable again
470 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
470 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
471 copy of old repository backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
471 copy of old repository backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
472 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
472 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
473
473
474 Original requirements backed up
474 Original requirements backed up
475
475
476 $ cat .hg/upgradebackup.*/requires
476 $ cat .hg/upgradebackup.*/requires
477 dotencode
477 dotencode
478 fncache
478 fncache
479 revlogv1
479 revlogv1
480 store
480 store
481
481
482 generaldelta added to original requirements files
482 generaldelta added to original requirements files
483
483
484 $ cat .hg/requires
484 $ cat .hg/requires
485 dotencode
485 dotencode
486 fncache
486 fncache
487 generaldelta
487 generaldelta
488 revlogv1
488 revlogv1
489 store
489 store
490
490
491 store directory has files we expect
491 store directory has files we expect
492
492
493 $ ls .hg/store
493 $ ls .hg/store
494 00changelog.i
494 00changelog.i
495 00manifest.i
495 00manifest.i
496 data
496 data
497 fncache
497 fncache
498 phaseroots
498 phaseroots
499 undo
499 undo
500 undo.backupfiles
500 undo.backupfiles
501 undo.phaseroots
501 undo.phaseroots
502
502
503 manifest should be generaldelta
503 manifest should be generaldelta
504
504
505 $ hg debugrevlog -m | grep flags
505 $ hg debugrevlog -m | grep flags
506 flags : inline, generaldelta
506 flags : inline, generaldelta
507
507
508 verify should be happy
508 verify should be happy
509
509
510 $ hg verify
510 $ hg verify
511 checking changesets
511 checking changesets
512 checking manifests
512 checking manifests
513 crosschecking files in changesets and manifests
513 crosschecking files in changesets and manifests
514 checking files
514 checking files
515 checked 3 changesets with 3 changes to 3 files
515 checked 3 changesets with 3 changes to 3 files
516
516
517 old store should be backed up
517 old store should be backed up
518
518
519 $ ls -d .hg/upgradebackup.*/
519 $ ls -d .hg/upgradebackup.*/
520 .hg/upgradebackup.*/ (glob)
520 .hg/upgradebackup.*/ (glob)
521 $ ls .hg/upgradebackup.*/store
521 $ ls .hg/upgradebackup.*/store
522 00changelog.i
522 00changelog.i
523 00manifest.i
523 00manifest.i
524 data
524 data
525 fncache
525 fncache
526 phaseroots
526 phaseroots
527 undo
527 undo
528 undo.backup.fncache
528 undo.backup.fncache
529 undo.backupfiles
529 undo.backupfiles
530 undo.phaseroots
530 undo.phaseroots
531
531
532 unless --no-backup is passed
532 unless --no-backup is passed
533
533
534 $ rm -rf .hg/upgradebackup.*/
534 $ rm -rf .hg/upgradebackup.*/
535 $ hg debugupgraderepo --run --no-backup
535 $ hg debugupgraderepo --run --no-backup
536 upgrade will perform the following actions:
536 upgrade will perform the following actions:
537
537
538 requirements
538 requirements
539 preserved: dotencode, fncache, generaldelta, revlogv1, store
539 preserved: dotencode, fncache, generaldelta, revlogv1, store
540 added: sparserevlog
540 added: sparserevlog
541
541
542 sparserevlog
542 sparserevlog
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.
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.
544
544
545 sidedata
545 sidedata
546 Allows storage of extra data alongside a revision.
546 Allows storage of extra data alongside a revision.
547
547
548 beginning upgrade...
548 beginning upgrade...
549 repository locked and read-only
549 repository locked and read-only
550 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
550 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
551 (it is safe to interrupt this process any time before data migration completes)
551 (it is safe to interrupt this process any time before data migration completes)
552 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
552 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
553 migrating 519 KB in store; 1.05 MB tracked data
553 migrating 519 KB in store; 1.05 MB tracked data
554 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
554 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
555 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
555 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
556 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
556 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
557 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
557 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
558 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
558 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
559 finished migrating 3 changelog revisions; change in size: 0 bytes
559 finished migrating 3 changelog revisions; change in size: 0 bytes
560 finished migrating 9 total revisions; total change in store size: 0 bytes
560 finished migrating 9 total revisions; total change in store size: 0 bytes
561 copying phaseroots
561 copying phaseroots
562 data fully migrated to temporary repository
562 data fully migrated to temporary repository
563 marking source repository as being upgraded; clients will be unable to read from repository
563 marking source repository as being upgraded; clients will be unable to read from repository
564 starting in-place swap of repository data
564 starting in-place swap of repository data
565 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
565 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
566 replacing store...
566 replacing store...
567 store replacement complete; repository was inconsistent for * (glob)
567 store replacement complete; repository was inconsistent for * (glob)
568 finalizing requirements file and making repository readable again
568 finalizing requirements file and making repository readable again
569 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
569 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
570 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
570 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
571 $ ls -1 .hg/ | grep upgradebackup
571 $ ls -1 .hg/ | grep upgradebackup
572 [1]
572 [1]
573
573
574 We can restrict optimization to some revlog:
574 We can restrict optimization to some revlog:
575
575
576 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
576 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
577 upgrade will perform the following actions:
577 upgrade will perform the following actions:
578
578
579 requirements
579 requirements
580 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
580 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
581
581
582 sidedata
582 sidedata
583 Allows storage of extra data alongside a revision.
583 Allows storage of extra data alongside a revision.
584
584
585 re-delta-parent
585 re-delta-parent
586 deltas within internal storage will choose a new base revision if needed
586 deltas within internal storage will choose a new base revision if needed
587
587
588 beginning upgrade...
588 beginning upgrade...
589 repository locked and read-only
589 repository locked and read-only
590 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
590 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
591 (it is safe to interrupt this process any time before data migration completes)
591 (it is safe to interrupt this process any time before data migration completes)
592 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
592 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
593 migrating 519 KB in store; 1.05 MB tracked data
593 migrating 519 KB in store; 1.05 MB tracked data
594 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
594 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
595 blindly copying data/FooBarDirectory.d/f1.i containing 1 revisions
595 blindly copying data/FooBarDirectory.d/f1.i containing 1 revisions
596 blindly copying data/f0.i containing 1 revisions
596 blindly copying data/f0.i containing 1 revisions
597 blindly copying data/f2.i containing 1 revisions
597 blindly copying data/f2.i containing 1 revisions
598 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
598 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
599 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
599 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
600 cloning 3 revisions from 00manifest.i
600 cloning 3 revisions from 00manifest.i
601 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
601 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
602 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
602 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
603 blindly copying 00changelog.i containing 3 revisions
603 blindly copying 00changelog.i containing 3 revisions
604 finished migrating 3 changelog revisions; change in size: 0 bytes
604 finished migrating 3 changelog revisions; change in size: 0 bytes
605 finished migrating 9 total revisions; total change in store size: 0 bytes
605 finished migrating 9 total revisions; total change in store size: 0 bytes
606 copying phaseroots
606 copying phaseroots
607 data fully migrated to temporary repository
607 data fully migrated to temporary repository
608 marking source repository as being upgraded; clients will be unable to read from repository
608 marking source repository as being upgraded; clients will be unable to read from repository
609 starting in-place swap of repository data
609 starting in-place swap of repository data
610 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
610 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
611 replacing store...
611 replacing store...
612 store replacement complete; repository was inconsistent for *s (glob)
612 store replacement complete; repository was inconsistent for *s (glob)
613 finalizing requirements file and making repository readable again
613 finalizing requirements file and making repository readable again
614 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
614 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
615 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
615 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
616
616
617 Check that the repo still works fine
617 Check that the repo still works fine
618
618
619 $ hg log -G --stat
619 $ hg log -G --stat
620 @ changeset: 2:76d4395f5413
620 @ changeset: 2:76d4395f5413 (no-py3 !)
621 @ changeset: 2:fca376863211 (py3 !)
621 | tag: tip
622 | tag: tip
622 | parent: 0:ba592bf28da2
623 | parent: 0:ba592bf28da2
623 | user: test
624 | user: test
624 | date: Thu Jan 01 00:00:00 1970 +0000
625 | date: Thu Jan 01 00:00:00 1970 +0000
625 | summary: add f2
626 | summary: add f2
626 |
627 |
627 | f2 | 100000 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
628 | f2 | 100000 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
628 | 1 files changed, 100000 insertions(+), 0 deletions(-)
629 | 1 files changed, 100000 insertions(+), 0 deletions(-)
629 |
630 |
630 | o changeset: 1:2029ce2354e2
631 | o changeset: 1:2029ce2354e2
631 |/ user: test
632 |/ user: test
632 | date: Thu Jan 01 00:00:00 1970 +0000
633 | date: Thu Jan 01 00:00:00 1970 +0000
633 | summary: add f1
634 | summary: add f1
634 |
635 |
635 |
636 |
636 o changeset: 0:ba592bf28da2
637 o changeset: 0:ba592bf28da2
637 user: test
638 user: test
638 date: Thu Jan 01 00:00:00 1970 +0000
639 date: Thu Jan 01 00:00:00 1970 +0000
639 summary: initial
640 summary: initial
640
641
641
642
642
643
643 $ hg verify
644 $ hg verify
644 checking changesets
645 checking changesets
645 checking manifests
646 checking manifests
646 crosschecking files in changesets and manifests
647 crosschecking files in changesets and manifests
647 checking files
648 checking files
648 checked 3 changesets with 3 changes to 3 files
649 checked 3 changesets with 3 changes to 3 files
649
650
650 Check we can select negatively
651 Check we can select negatively
651
652
652 $ hg debugupgrade --optimize re-delta-parent --run --no-manifest --no-backup --debug --traceback
653 $ hg debugupgrade --optimize re-delta-parent --run --no-manifest --no-backup --debug --traceback
653 upgrade will perform the following actions:
654 upgrade will perform the following actions:
654
655
655 requirements
656 requirements
656 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
657 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
657
658
658 sidedata
659 sidedata
659 Allows storage of extra data alongside a revision.
660 Allows storage of extra data alongside a revision.
660
661
661 re-delta-parent
662 re-delta-parent
662 deltas within internal storage will choose a new base revision if needed
663 deltas within internal storage will choose a new base revision if needed
663
664
664 beginning upgrade...
665 beginning upgrade...
665 repository locked and read-only
666 repository locked and read-only
666 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
667 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
667 (it is safe to interrupt this process any time before data migration completes)
668 (it is safe to interrupt this process any time before data migration completes)
668 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
669 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
669 migrating 519 KB in store; 1.05 MB tracked data
670 migrating 519 KB in store; 1.05 MB tracked data
670 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
671 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
671 cloning 1 revisions from data/FooBarDirectory.d/f1.i
672 cloning 1 revisions from data/FooBarDirectory.d/f1.i
672 cloning 1 revisions from data/f0.i
673 cloning 1 revisions from data/f0.i
673 cloning 1 revisions from data/f2.i
674 cloning 1 revisions from data/f2.i
674 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
675 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
675 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
676 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
676 blindly copying 00manifest.i containing 3 revisions
677 blindly copying 00manifest.i containing 3 revisions
677 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
678 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
678 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
679 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
679 cloning 3 revisions from 00changelog.i
680 cloning 3 revisions from 00changelog.i
680 finished migrating 3 changelog revisions; change in size: 0 bytes
681 finished migrating 3 changelog revisions; change in size: 0 bytes
681 finished migrating 9 total revisions; total change in store size: 0 bytes
682 finished migrating 9 total revisions; total change in store size: 0 bytes
682 copying phaseroots
683 copying phaseroots
683 data fully migrated to temporary repository
684 data fully migrated to temporary repository
684 marking source repository as being upgraded; clients will be unable to read from repository
685 marking source repository as being upgraded; clients will be unable to read from repository
685 starting in-place swap of repository data
686 starting in-place swap of repository data
686 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
687 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
687 replacing store...
688 replacing store...
688 store replacement complete; repository was inconsistent for *s (glob)
689 store replacement complete; repository was inconsistent for *s (glob)
689 finalizing requirements file and making repository readable again
690 finalizing requirements file and making repository readable again
690 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
691 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
691 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
692 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
692 $ hg verify
693 $ hg verify
693 checking changesets
694 checking changesets
694 checking manifests
695 checking manifests
695 crosschecking files in changesets and manifests
696 crosschecking files in changesets and manifests
696 checking files
697 checking files
697 checked 3 changesets with 3 changes to 3 files
698 checked 3 changesets with 3 changes to 3 files
698
699
699 Check that we can select changelog only
700 Check that we can select changelog only
700
701
701 $ hg debugupgrade --optimize re-delta-parent --run --changelog --no-backup --debug --traceback
702 $ hg debugupgrade --optimize re-delta-parent --run --changelog --no-backup --debug --traceback
702 upgrade will perform the following actions:
703 upgrade will perform the following actions:
703
704
704 requirements
705 requirements
705 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
706 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
706
707
707 sidedata
708 sidedata
708 Allows storage of extra data alongside a revision.
709 Allows storage of extra data alongside a revision.
709
710
710 re-delta-parent
711 re-delta-parent
711 deltas within internal storage will choose a new base revision if needed
712 deltas within internal storage will choose a new base revision if needed
712
713
713 beginning upgrade...
714 beginning upgrade...
714 repository locked and read-only
715 repository locked and read-only
715 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
716 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
716 (it is safe to interrupt this process any time before data migration completes)
717 (it is safe to interrupt this process any time before data migration completes)
717 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
718 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
718 migrating 519 KB in store; 1.05 MB tracked data
719 migrating 519 KB in store; 1.05 MB tracked data
719 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
720 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
720 blindly copying data/FooBarDirectory.d/f1.i containing 1 revisions
721 blindly copying data/FooBarDirectory.d/f1.i containing 1 revisions
721 blindly copying data/f0.i containing 1 revisions
722 blindly copying data/f0.i containing 1 revisions
722 blindly copying data/f2.i containing 1 revisions
723 blindly copying data/f2.i containing 1 revisions
723 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
724 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
724 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
725 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
725 blindly copying 00manifest.i containing 3 revisions
726 blindly copying 00manifest.i containing 3 revisions
726 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
727 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
727 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
728 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
728 cloning 3 revisions from 00changelog.i
729 cloning 3 revisions from 00changelog.i
729 finished migrating 3 changelog revisions; change in size: 0 bytes
730 finished migrating 3 changelog revisions; change in size: 0 bytes
730 finished migrating 9 total revisions; total change in store size: 0 bytes
731 finished migrating 9 total revisions; total change in store size: 0 bytes
731 copying phaseroots
732 copying phaseroots
732 data fully migrated to temporary repository
733 data fully migrated to temporary repository
733 marking source repository as being upgraded; clients will be unable to read from repository
734 marking source repository as being upgraded; clients will be unable to read from repository
734 starting in-place swap of repository data
735 starting in-place swap of repository data
735 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
736 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
736 replacing store...
737 replacing store...
737 store replacement complete; repository was inconsistent for *s (glob)
738 store replacement complete; repository was inconsistent for *s (glob)
738 finalizing requirements file and making repository readable again
739 finalizing requirements file and making repository readable again
739 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
740 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
740 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
741 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
741 $ hg verify
742 $ hg verify
742 checking changesets
743 checking changesets
743 checking manifests
744 checking manifests
744 crosschecking files in changesets and manifests
745 crosschecking files in changesets and manifests
745 checking files
746 checking files
746 checked 3 changesets with 3 changes to 3 files
747 checked 3 changesets with 3 changes to 3 files
747
748
748 Check that we can select filelog only
749 Check that we can select filelog only
749
750
750 $ hg debugupgrade --optimize re-delta-parent --run --no-changelog --no-manifest --no-backup --debug --traceback
751 $ hg debugupgrade --optimize re-delta-parent --run --no-changelog --no-manifest --no-backup --debug --traceback
751 upgrade will perform the following actions:
752 upgrade will perform the following actions:
752
753
753 requirements
754 requirements
754 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
755 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
755
756
756 sidedata
757 sidedata
757 Allows storage of extra data alongside a revision.
758 Allows storage of extra data alongside a revision.
758
759
759 re-delta-parent
760 re-delta-parent
760 deltas within internal storage will choose a new base revision if needed
761 deltas within internal storage will choose a new base revision if needed
761
762
762 beginning upgrade...
763 beginning upgrade...
763 repository locked and read-only
764 repository locked and read-only
764 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
765 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
765 (it is safe to interrupt this process any time before data migration completes)
766 (it is safe to interrupt this process any time before data migration completes)
766 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
767 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
767 migrating 519 KB in store; 1.05 MB tracked data
768 migrating 519 KB in store; 1.05 MB tracked data
768 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
769 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
769 cloning 1 revisions from data/FooBarDirectory.d/f1.i
770 cloning 1 revisions from data/FooBarDirectory.d/f1.i
770 cloning 1 revisions from data/f0.i
771 cloning 1 revisions from data/f0.i
771 cloning 1 revisions from data/f2.i
772 cloning 1 revisions from data/f2.i
772 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
773 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
773 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
774 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
774 blindly copying 00manifest.i containing 3 revisions
775 blindly copying 00manifest.i containing 3 revisions
775 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
776 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
776 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
777 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
777 blindly copying 00changelog.i containing 3 revisions
778 blindly copying 00changelog.i containing 3 revisions
778 finished migrating 3 changelog revisions; change in size: 0 bytes
779 finished migrating 3 changelog revisions; change in size: 0 bytes
779 finished migrating 9 total revisions; total change in store size: 0 bytes
780 finished migrating 9 total revisions; total change in store size: 0 bytes
780 copying phaseroots
781 copying phaseroots
781 data fully migrated to temporary repository
782 data fully migrated to temporary repository
782 marking source repository as being upgraded; clients will be unable to read from repository
783 marking source repository as being upgraded; clients will be unable to read from repository
783 starting in-place swap of repository data
784 starting in-place swap of repository data
784 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
785 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
785 replacing store...
786 replacing store...
786 store replacement complete; repository was inconsistent for *s (glob)
787 store replacement complete; repository was inconsistent for *s (glob)
787 finalizing requirements file and making repository readable again
788 finalizing requirements file and making repository readable again
788 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
789 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
789 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
790 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
790 $ hg verify
791 $ hg verify
791 checking changesets
792 checking changesets
792 checking manifests
793 checking manifests
793 crosschecking files in changesets and manifests
794 crosschecking files in changesets and manifests
794 checking files
795 checking files
795 checked 3 changesets with 3 changes to 3 files
796 checked 3 changesets with 3 changes to 3 files
796
797
797
798
798 Check you can't skip revlog clone during important format downgrade
799 Check you can't skip revlog clone during important format downgrade
799
800
800 $ echo "[format]" > .hg/hgrc
801 $ echo "[format]" > .hg/hgrc
801 $ echo "sparse-revlog=no" >> .hg/hgrc
802 $ echo "sparse-revlog=no" >> .hg/hgrc
802 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
803 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
803 ignoring revlogs selection flags, format requirements change: sparserevlog
804 ignoring revlogs selection flags, format requirements change: sparserevlog
804 upgrade will perform the following actions:
805 upgrade will perform the following actions:
805
806
806 requirements
807 requirements
807 preserved: dotencode, fncache, generaldelta, revlogv1, store
808 preserved: dotencode, fncache, generaldelta, revlogv1, store
808 removed: sparserevlog
809 removed: sparserevlog
809
810
810 sidedata
811 sidedata
811 Allows storage of extra data alongside a revision.
812 Allows storage of extra data alongside a revision.
812
813
813 re-delta-parent
814 re-delta-parent
814 deltas within internal storage will choose a new base revision if needed
815 deltas within internal storage will choose a new base revision if needed
815
816
816 beginning upgrade...
817 beginning upgrade...
817 repository locked and read-only
818 repository locked and read-only
818 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
819 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
819 (it is safe to interrupt this process any time before data migration completes)
820 (it is safe to interrupt this process any time before data migration completes)
820 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
821 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
821 migrating 519 KB in store; 1.05 MB tracked data
822 migrating 519 KB in store; 1.05 MB tracked data
822 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
823 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
823 cloning 1 revisions from data/FooBarDirectory.d/f1.i
824 cloning 1 revisions from data/FooBarDirectory.d/f1.i
824 cloning 1 revisions from data/f0.i
825 cloning 1 revisions from data/f0.i
825 cloning 1 revisions from data/f2.i
826 cloning 1 revisions from data/f2.i
826 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
827 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
827 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
828 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
828 cloning 3 revisions from 00manifest.i
829 cloning 3 revisions from 00manifest.i
829 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
830 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
830 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
831 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
831 cloning 3 revisions from 00changelog.i
832 cloning 3 revisions from 00changelog.i
832 finished migrating 3 changelog revisions; change in size: 0 bytes
833 finished migrating 3 changelog revisions; change in size: 0 bytes
833 finished migrating 9 total revisions; total change in store size: 0 bytes
834 finished migrating 9 total revisions; total change in store size: 0 bytes
834 copying phaseroots
835 copying phaseroots
835 data fully migrated to temporary repository
836 data fully migrated to temporary repository
836 marking source repository as being upgraded; clients will be unable to read from repository
837 marking source repository as being upgraded; clients will be unable to read from repository
837 starting in-place swap of repository data
838 starting in-place swap of repository data
838 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
839 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
839 replacing store...
840 replacing store...
840 store replacement complete; repository was inconsistent for *s (glob)
841 store replacement complete; repository was inconsistent for *s (glob)
841 finalizing requirements file and making repository readable again
842 finalizing requirements file and making repository readable again
842 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
843 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
843 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
844 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
844 $ hg verify
845 $ hg verify
845 checking changesets
846 checking changesets
846 checking manifests
847 checking manifests
847 crosschecking files in changesets and manifests
848 crosschecking files in changesets and manifests
848 checking files
849 checking files
849 checked 3 changesets with 3 changes to 3 files
850 checked 3 changesets with 3 changes to 3 files
850
851
851 Check you can't skip revlog clone during important format upgrade
852 Check you can't skip revlog clone during important format upgrade
852
853
853 $ echo "sparse-revlog=yes" >> .hg/hgrc
854 $ echo "sparse-revlog=yes" >> .hg/hgrc
854 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
855 $ hg debugupgrade --optimize re-delta-parent --run --manifest --no-backup --debug --traceback
855 ignoring revlogs selection flags, format requirements change: sparserevlog
856 ignoring revlogs selection flags, format requirements change: sparserevlog
856 upgrade will perform the following actions:
857 upgrade will perform the following actions:
857
858
858 requirements
859 requirements
859 preserved: dotencode, fncache, generaldelta, revlogv1, store
860 preserved: dotencode, fncache, generaldelta, revlogv1, store
860 added: sparserevlog
861 added: sparserevlog
861
862
862 sparserevlog
863 sparserevlog
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.
864 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.
864
865
865 sidedata
866 sidedata
866 Allows storage of extra data alongside a revision.
867 Allows storage of extra data alongside a revision.
867
868
868 re-delta-parent
869 re-delta-parent
869 deltas within internal storage will choose a new base revision if needed
870 deltas within internal storage will choose a new base revision if needed
870
871
871 beginning upgrade...
872 beginning upgrade...
872 repository locked and read-only
873 repository locked and read-only
873 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
874 creating temporary repository to stage migrated data: $TESTTMP/upgradegd/.hg/upgrade.* (glob)
874 (it is safe to interrupt this process any time before data migration completes)
875 (it is safe to interrupt this process any time before data migration completes)
875 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
876 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
876 migrating 519 KB in store; 1.05 MB tracked data
877 migrating 519 KB in store; 1.05 MB tracked data
877 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
878 migrating 3 filelogs containing 3 revisions (518 KB in store; 1.05 MB tracked data)
878 cloning 1 revisions from data/FooBarDirectory.d/f1.i
879 cloning 1 revisions from data/FooBarDirectory.d/f1.i
879 cloning 1 revisions from data/f0.i
880 cloning 1 revisions from data/f0.i
880 cloning 1 revisions from data/f2.i
881 cloning 1 revisions from data/f2.i
881 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
882 finished migrating 3 filelog revisions across 3 filelogs; change in size: 0 bytes
882 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
883 migrating 1 manifests containing 3 revisions (367 bytes in store; 238 bytes tracked data)
883 cloning 3 revisions from 00manifest.i
884 cloning 3 revisions from 00manifest.i
884 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
885 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
885 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
886 migrating changelog containing 3 revisions (394 bytes in store; 199 bytes tracked data)
886 cloning 3 revisions from 00changelog.i
887 cloning 3 revisions from 00changelog.i
887 finished migrating 3 changelog revisions; change in size: 0 bytes
888 finished migrating 3 changelog revisions; change in size: 0 bytes
888 finished migrating 9 total revisions; total change in store size: 0 bytes
889 finished migrating 9 total revisions; total change in store size: 0 bytes
889 copying phaseroots
890 copying phaseroots
890 data fully migrated to temporary repository
891 data fully migrated to temporary repository
891 marking source repository as being upgraded; clients will be unable to read from repository
892 marking source repository as being upgraded; clients will be unable to read from repository
892 starting in-place swap of repository data
893 starting in-place swap of repository data
893 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
894 replaced files will be backed up at $TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
894 replacing store...
895 replacing store...
895 store replacement complete; repository was inconsistent for *s (glob)
896 store replacement complete; repository was inconsistent for *s (glob)
896 finalizing requirements file and making repository readable again
897 finalizing requirements file and making repository readable again
897 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
898 removing old repository content$TESTTMP/upgradegd/.hg/upgradebackup.* (glob)
898 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
899 removing temporary repository $TESTTMP/upgradegd/.hg/upgrade.* (glob)
899 $ hg verify
900 $ hg verify
900 checking changesets
901 checking changesets
901 checking manifests
902 checking manifests
902 crosschecking files in changesets and manifests
903 crosschecking files in changesets and manifests
903 checking files
904 checking files
904 checked 3 changesets with 3 changes to 3 files
905 checked 3 changesets with 3 changes to 3 files
905
906
906 $ cd ..
907 $ cd ..
907
908
908 store files with special filenames aren't encoded during copy
909 store files with special filenames aren't encoded during copy
909
910
910 $ hg init store-filenames
911 $ hg init store-filenames
911 $ cd store-filenames
912 $ cd store-filenames
912 $ touch foo
913 $ touch foo
913 $ hg -q commit -A -m initial
914 $ hg -q commit -A -m initial
914 $ touch .hg/store/.XX_special_filename
915 $ touch .hg/store/.XX_special_filename
915
916
916 $ hg debugupgraderepo --run
917 $ hg debugupgraderepo --run
917 upgrade will perform the following actions:
918 upgrade will perform the following actions:
918
919
919 requirements
920 requirements
920 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
921 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
921
922
922 sidedata
923 sidedata
923 Allows storage of extra data alongside a revision.
924 Allows storage of extra data alongside a revision.
924
925
925 beginning upgrade...
926 beginning upgrade...
926 repository locked and read-only
927 repository locked and read-only
927 creating temporary repository to stage migrated data: $TESTTMP/store-filenames/.hg/upgrade.* (glob)
928 creating temporary repository to stage migrated data: $TESTTMP/store-filenames/.hg/upgrade.* (glob)
928 (it is safe to interrupt this process any time before data migration completes)
929 (it is safe to interrupt this process any time before data migration completes)
929 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog)
930 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog)
930 migrating 301 bytes in store; 107 bytes tracked data
931 migrating 301 bytes in store; 107 bytes tracked data
931 migrating 1 filelogs containing 1 revisions (64 bytes in store; 0 bytes tracked data)
932 migrating 1 filelogs containing 1 revisions (64 bytes in store; 0 bytes tracked data)
932 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes
933 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes
933 migrating 1 manifests containing 1 revisions (110 bytes in store; 45 bytes tracked data)
934 migrating 1 manifests containing 1 revisions (110 bytes in store; 45 bytes tracked data)
934 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes
935 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes
935 migrating changelog containing 1 revisions (127 bytes in store; 62 bytes tracked data)
936 migrating changelog containing 1 revisions (127 bytes in store; 62 bytes tracked data)
936 finished migrating 1 changelog revisions; change in size: 0 bytes
937 finished migrating 1 changelog revisions; change in size: 0 bytes
937 finished migrating 3 total revisions; total change in store size: 0 bytes
938 finished migrating 3 total revisions; total change in store size: 0 bytes
938 copying .XX_special_filename
939 copying .XX_special_filename
939 copying phaseroots
940 copying phaseroots
940 data fully migrated to temporary repository
941 data fully migrated to temporary repository
941 marking source repository as being upgraded; clients will be unable to read from repository
942 marking source repository as being upgraded; clients will be unable to read from repository
942 starting in-place swap of repository data
943 starting in-place swap of repository data
943 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
944 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
944 replacing store...
945 replacing store...
945 store replacement complete; repository was inconsistent for *s (glob)
946 store replacement complete; repository was inconsistent for *s (glob)
946 finalizing requirements file and making repository readable again
947 finalizing requirements file and making repository readable again
947 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob)
948 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob)
948 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
949 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
949 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
950 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
950 $ hg debugupgraderepo --run --optimize redeltafulladd
951 $ hg debugupgraderepo --run --optimize redeltafulladd
951 upgrade will perform the following actions:
952 upgrade will perform the following actions:
952
953
953 requirements
954 requirements
954 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
955 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
955
956
956 sidedata
957 sidedata
957 Allows storage of extra data alongside a revision.
958 Allows storage of extra data alongside a revision.
958
959
959 re-delta-fulladd
960 re-delta-fulladd
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
961 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
961
962
962 beginning upgrade...
963 beginning upgrade...
963 repository locked and read-only
964 repository locked and read-only
964 creating temporary repository to stage migrated data: $TESTTMP/store-filenames/.hg/upgrade.* (glob)
965 creating temporary repository to stage migrated data: $TESTTMP/store-filenames/.hg/upgrade.* (glob)
965 (it is safe to interrupt this process any time before data migration completes)
966 (it is safe to interrupt this process any time before data migration completes)
966 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog)
967 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog)
967 migrating 301 bytes in store; 107 bytes tracked data
968 migrating 301 bytes in store; 107 bytes tracked data
968 migrating 1 filelogs containing 1 revisions (64 bytes in store; 0 bytes tracked data)
969 migrating 1 filelogs containing 1 revisions (64 bytes in store; 0 bytes tracked data)
969 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes
970 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes
970 migrating 1 manifests containing 1 revisions (110 bytes in store; 45 bytes tracked data)
971 migrating 1 manifests containing 1 revisions (110 bytes in store; 45 bytes tracked data)
971 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes
972 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes
972 migrating changelog containing 1 revisions (127 bytes in store; 62 bytes tracked data)
973 migrating changelog containing 1 revisions (127 bytes in store; 62 bytes tracked data)
973 finished migrating 1 changelog revisions; change in size: 0 bytes
974 finished migrating 1 changelog revisions; change in size: 0 bytes
974 finished migrating 3 total revisions; total change in store size: 0 bytes
975 finished migrating 3 total revisions; total change in store size: 0 bytes
975 copying .XX_special_filename
976 copying .XX_special_filename
976 copying phaseroots
977 copying phaseroots
977 data fully migrated to temporary repository
978 data fully migrated to temporary repository
978 marking source repository as being upgraded; clients will be unable to read from repository
979 marking source repository as being upgraded; clients will be unable to read from repository
979 starting in-place swap of repository data
980 starting in-place swap of repository data
980 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
981 replaced files will be backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
981 replacing store...
982 replacing store...
982 store replacement complete; repository was inconsistent for *s (glob)
983 store replacement complete; repository was inconsistent for *s (glob)
983 finalizing requirements file and making repository readable again
984 finalizing requirements file and making repository readable again
984 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob)
985 removing temporary repository $TESTTMP/store-filenames/.hg/upgrade.* (glob)
985 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
986 copy of old repository backed up at $TESTTMP/store-filenames/.hg/upgradebackup.* (glob)
986 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
987 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
987
988
988 fncache is valid after upgrade
989 fncache is valid after upgrade
989
990
990 $ hg debugrebuildfncache
991 $ hg debugrebuildfncache
991 fncache already up to date
992 fncache already up to date
992
993
993 $ cd ..
994 $ cd ..
994
995
995 Check upgrading a large file repository
996 Check upgrading a large file repository
996 ---------------------------------------
997 ---------------------------------------
997
998
998 $ hg init largefilesrepo
999 $ hg init largefilesrepo
999 $ cat << EOF >> largefilesrepo/.hg/hgrc
1000 $ cat << EOF >> largefilesrepo/.hg/hgrc
1000 > [extensions]
1001 > [extensions]
1001 > largefiles =
1002 > largefiles =
1002 > EOF
1003 > EOF
1003
1004
1004 $ cd largefilesrepo
1005 $ cd largefilesrepo
1005 $ touch foo
1006 $ touch foo
1006 $ hg add --large foo
1007 $ hg add --large foo
1007 $ hg -q commit -m initial
1008 $ hg -q commit -m initial
1008 $ cat .hg/requires
1009 $ cat .hg/requires
1009 dotencode
1010 dotencode
1010 fncache
1011 fncache
1011 generaldelta
1012 generaldelta
1012 largefiles
1013 largefiles
1013 revlogv1
1014 revlogv1
1014 sparserevlog
1015 sparserevlog
1015 store
1016 store
1016
1017
1017 $ hg debugupgraderepo --run
1018 $ hg debugupgraderepo --run
1018 upgrade will perform the following actions:
1019 upgrade will perform the following actions:
1019
1020
1020 requirements
1021 requirements
1021 preserved: dotencode, fncache, generaldelta, largefiles, revlogv1, sparserevlog, store
1022 preserved: dotencode, fncache, generaldelta, largefiles, revlogv1, sparserevlog, store
1022
1023
1023 sidedata
1024 sidedata
1024 Allows storage of extra data alongside a revision.
1025 Allows storage of extra data alongside a revision.
1025
1026
1026 beginning upgrade...
1027 beginning upgrade...
1027 repository locked and read-only
1028 repository locked and read-only
1028 creating temporary repository to stage migrated data: $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1029 creating temporary repository to stage migrated data: $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1029 (it is safe to interrupt this process any time before data migration completes)
1030 (it is safe to interrupt this process any time before data migration completes)
1030 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog)
1031 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog)
1031 migrating 355 bytes in store; 160 bytes tracked data
1032 migrating 355 bytes in store; 160 bytes tracked data
1032 migrating 1 filelogs containing 1 revisions (106 bytes in store; 41 bytes tracked data)
1033 migrating 1 filelogs containing 1 revisions (106 bytes in store; 41 bytes tracked data)
1033 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes
1034 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes
1034 migrating 1 manifests containing 1 revisions (116 bytes in store; 51 bytes tracked data)
1035 migrating 1 manifests containing 1 revisions (116 bytes in store; 51 bytes tracked data)
1035 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes
1036 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes
1036 migrating changelog containing 1 revisions (133 bytes in store; 68 bytes tracked data)
1037 migrating changelog containing 1 revisions (133 bytes in store; 68 bytes tracked data)
1037 finished migrating 1 changelog revisions; change in size: 0 bytes
1038 finished migrating 1 changelog revisions; change in size: 0 bytes
1038 finished migrating 3 total revisions; total change in store size: 0 bytes
1039 finished migrating 3 total revisions; total change in store size: 0 bytes
1039 copying phaseroots
1040 copying phaseroots
1040 data fully migrated to temporary repository
1041 data fully migrated to temporary repository
1041 marking source repository as being upgraded; clients will be unable to read from repository
1042 marking source repository as being upgraded; clients will be unable to read from repository
1042 starting in-place swap of repository data
1043 starting in-place swap of repository data
1043 replaced files will be backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1044 replaced files will be backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1044 replacing store...
1045 replacing store...
1045 store replacement complete; repository was inconsistent for *s (glob)
1046 store replacement complete; repository was inconsistent for *s (glob)
1046 finalizing requirements file and making repository readable again
1047 finalizing requirements file and making repository readable again
1047 removing temporary repository $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1048 removing temporary repository $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1048 copy of old repository backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1049 copy of old repository backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1049 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1050 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1050 $ cat .hg/requires
1051 $ cat .hg/requires
1051 dotencode
1052 dotencode
1052 fncache
1053 fncache
1053 generaldelta
1054 generaldelta
1054 largefiles
1055 largefiles
1055 revlogv1
1056 revlogv1
1056 sparserevlog
1057 sparserevlog
1057 store
1058 store
1058
1059
1059 $ cat << EOF >> .hg/hgrc
1060 $ cat << EOF >> .hg/hgrc
1060 > [extensions]
1061 > [extensions]
1061 > lfs =
1062 > lfs =
1062 > [lfs]
1063 > [lfs]
1063 > threshold = 10
1064 > threshold = 10
1064 > EOF
1065 > EOF
1065 $ echo '123456789012345' > lfs.bin
1066 $ echo '123456789012345' > lfs.bin
1066 $ hg ci -Am 'lfs.bin'
1067 $ hg ci -Am 'lfs.bin'
1067 adding lfs.bin
1068 adding lfs.bin
1068 $ grep lfs .hg/requires
1069 $ grep lfs .hg/requires
1069 lfs
1070 lfs
1070 $ find .hg/store/lfs -type f
1071 $ find .hg/store/lfs -type f
1071 .hg/store/lfs/objects/d0/beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1072 .hg/store/lfs/objects/d0/beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1072
1073
1073 $ hg debugupgraderepo --run
1074 $ hg debugupgraderepo --run
1074 upgrade will perform the following actions:
1075 upgrade will perform the following actions:
1075
1076
1076 requirements
1077 requirements
1077 preserved: dotencode, fncache, generaldelta, largefiles, lfs, revlogv1, sparserevlog, store
1078 preserved: dotencode, fncache, generaldelta, largefiles, lfs, revlogv1, sparserevlog, store
1078
1079
1079 sidedata
1080 sidedata
1080 Allows storage of extra data alongside a revision.
1081 Allows storage of extra data alongside a revision.
1081
1082
1082 beginning upgrade...
1083 beginning upgrade...
1083 repository locked and read-only
1084 repository locked and read-only
1084 creating temporary repository to stage migrated data: $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1085 creating temporary repository to stage migrated data: $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1085 (it is safe to interrupt this process any time before data migration completes)
1086 (it is safe to interrupt this process any time before data migration completes)
1086 migrating 6 total revisions (2 in filelogs, 2 in manifests, 2 in changelog)
1087 migrating 6 total revisions (2 in filelogs, 2 in manifests, 2 in changelog)
1087 migrating 801 bytes in store; 467 bytes tracked data
1088 migrating 801 bytes in store; 467 bytes tracked data
1088 migrating 2 filelogs containing 2 revisions (296 bytes in store; 182 bytes tracked data)
1089 migrating 2 filelogs containing 2 revisions (296 bytes in store; 182 bytes tracked data)
1089 finished migrating 2 filelog revisions across 2 filelogs; change in size: 0 bytes
1090 finished migrating 2 filelog revisions across 2 filelogs; change in size: 0 bytes
1090 migrating 1 manifests containing 2 revisions (241 bytes in store; 151 bytes tracked data)
1091 migrating 1 manifests containing 2 revisions (241 bytes in store; 151 bytes tracked data)
1091 finished migrating 2 manifest revisions across 1 manifests; change in size: 0 bytes
1092 finished migrating 2 manifest revisions across 1 manifests; change in size: 0 bytes
1092 migrating changelog containing 2 revisions (264 bytes in store; 134 bytes tracked data)
1093 migrating changelog containing 2 revisions (264 bytes in store; 134 bytes tracked data)
1093 finished migrating 2 changelog revisions; change in size: 0 bytes
1094 finished migrating 2 changelog revisions; change in size: 0 bytes
1094 finished migrating 6 total revisions; total change in store size: 0 bytes
1095 finished migrating 6 total revisions; total change in store size: 0 bytes
1095 copying phaseroots
1096 copying phaseroots
1096 copying lfs blob d0beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1097 copying lfs blob d0beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1097 data fully migrated to temporary repository
1098 data fully migrated to temporary repository
1098 marking source repository as being upgraded; clients will be unable to read from repository
1099 marking source repository as being upgraded; clients will be unable to read from repository
1099 starting in-place swap of repository data
1100 starting in-place swap of repository data
1100 replaced files will be backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1101 replaced files will be backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1101 replacing store...
1102 replacing store...
1102 store replacement complete; repository was inconsistent for *s (glob)
1103 store replacement complete; repository was inconsistent for *s (glob)
1103 finalizing requirements file and making repository readable again
1104 finalizing requirements file and making repository readable again
1104 removing temporary repository $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1105 removing temporary repository $TESTTMP/largefilesrepo/.hg/upgrade.* (glob)
1105 copy of old repository backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1106 copy of old repository backed up at $TESTTMP/largefilesrepo/.hg/upgradebackup.* (glob)
1106 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1107 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1107
1108
1108 $ grep lfs .hg/requires
1109 $ grep lfs .hg/requires
1109 lfs
1110 lfs
1110 $ find .hg/store/lfs -type f
1111 $ find .hg/store/lfs -type f
1111 .hg/store/lfs/objects/d0/beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1112 .hg/store/lfs/objects/d0/beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1112 $ hg verify
1113 $ hg verify
1113 checking changesets
1114 checking changesets
1114 checking manifests
1115 checking manifests
1115 crosschecking files in changesets and manifests
1116 crosschecking files in changesets and manifests
1116 checking files
1117 checking files
1117 checked 2 changesets with 2 changes to 2 files
1118 checked 2 changesets with 2 changes to 2 files
1118 $ hg debugdata lfs.bin 0
1119 $ hg debugdata lfs.bin 0
1119 version https://git-lfs.github.com/spec/v1
1120 version https://git-lfs.github.com/spec/v1
1120 oid sha256:d0beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1121 oid sha256:d0beab232adff5ba365880366ad30b1edb85c4c5372442b5d2fe27adc96d653f
1121 size 16
1122 size 16
1122 x-is-binary 0
1123 x-is-binary 0
1123
1124
1124 $ cd ..
1125 $ cd ..
1125
1126
1126 repository config is taken in account
1127 repository config is taken in account
1127 -------------------------------------
1128 -------------------------------------
1128
1129
1129 $ cat << EOF >> $HGRCPATH
1130 $ cat << EOF >> $HGRCPATH
1130 > [format]
1131 > [format]
1131 > maxchainlen = 1
1132 > maxchainlen = 1
1132 > EOF
1133 > EOF
1133
1134
1134 $ hg init localconfig
1135 $ hg init localconfig
1135 $ cd localconfig
1136 $ cd localconfig
1136 $ cat << EOF > file
1137 $ cat << EOF > file
1137 > some content
1138 > some content
1138 > with some length
1139 > with some length
1139 > to make sure we get a delta
1140 > to make sure we get a delta
1140 > after changes
1141 > after changes
1141 > very long
1142 > very long
1142 > very long
1143 > very long
1143 > very long
1144 > very long
1144 > very long
1145 > very long
1145 > very long
1146 > very long
1146 > very long
1147 > very long
1147 > very long
1148 > very long
1148 > very long
1149 > very long
1149 > very long
1150 > very long
1150 > very long
1151 > very long
1151 > very long
1152 > very long
1152 > EOF
1153 > EOF
1153 $ hg -q commit -A -m A
1154 $ hg -q commit -A -m A
1154 $ echo "new line" >> file
1155 $ echo "new line" >> file
1155 $ hg -q commit -m B
1156 $ hg -q commit -m B
1156 $ echo "new line" >> file
1157 $ echo "new line" >> file
1157 $ hg -q commit -m C
1158 $ hg -q commit -m C
1158
1159
1159 $ cat << EOF >> .hg/hgrc
1160 $ cat << EOF >> .hg/hgrc
1160 > [format]
1161 > [format]
1161 > maxchainlen = 9001
1162 > maxchainlen = 9001
1162 > EOF
1163 > EOF
1163 $ hg config format
1164 $ hg config format
1164 format.maxchainlen=9001
1165 format.maxchainlen=9001
1165 $ hg debugdeltachain file
1166 $ hg debugdeltachain file
1166 rev chain# chainlen prev delta size rawsize chainsize ratio lindist extradist extraratio readsize largestblk rddensity srchunks
1167 rev chain# chainlen prev delta size rawsize chainsize ratio lindist extradist extraratio readsize largestblk rddensity srchunks
1167 0 1 1 -1 base 77 182 77 0.42308 77 0 0.00000 77 77 1.00000 1
1168 0 1 1 -1 base 77 182 77 0.42308 77 0 0.00000 77 77 1.00000 1
1168 1 1 2 0 p1 21 191 98 0.51309 98 0 0.00000 98 98 1.00000 1
1169 1 1 2 0 p1 21 191 98 0.51309 98 0 0.00000 98 98 1.00000 1
1169 2 1 2 0 other 30 200 107 0.53500 128 21 0.19626 128 128 0.83594 1
1170 2 1 2 0 other 30 200 107 0.53500 128 21 0.19626 128 128 0.83594 1
1170
1171
1171 $ hg debugupgraderepo --run --optimize redeltaall
1172 $ hg debugupgraderepo --run --optimize redeltaall
1172 upgrade will perform the following actions:
1173 upgrade will perform the following actions:
1173
1174
1174 requirements
1175 requirements
1175 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
1176 preserved: dotencode, fncache, generaldelta, revlogv1, sparserevlog, store
1176
1177
1177 sidedata
1178 sidedata
1178 Allows storage of extra data alongside a revision.
1179 Allows storage of extra data alongside a revision.
1179
1180
1180 re-delta-all
1181 re-delta-all
1181 deltas within internal storage will be fully recomputed; this will likely drastically slow down execution time
1182 deltas within internal storage will be fully recomputed; this will likely drastically slow down execution time
1182
1183
1183 beginning upgrade...
1184 beginning upgrade...
1184 repository locked and read-only
1185 repository locked and read-only
1185 creating temporary repository to stage migrated data: $TESTTMP/localconfig/.hg/upgrade.* (glob)
1186 creating temporary repository to stage migrated data: $TESTTMP/localconfig/.hg/upgrade.* (glob)
1186 (it is safe to interrupt this process any time before data migration completes)
1187 (it is safe to interrupt this process any time before data migration completes)
1187 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
1188 migrating 9 total revisions (3 in filelogs, 3 in manifests, 3 in changelog)
1188 migrating 1019 bytes in store; 882 bytes tracked data
1189 migrating 1019 bytes in store; 882 bytes tracked data
1189 migrating 1 filelogs containing 3 revisions (320 bytes in store; 573 bytes tracked data)
1190 migrating 1 filelogs containing 3 revisions (320 bytes in store; 573 bytes tracked data)
1190 finished migrating 3 filelog revisions across 1 filelogs; change in size: -9 bytes
1191 finished migrating 3 filelog revisions across 1 filelogs; change in size: -9 bytes
1191 migrating 1 manifests containing 3 revisions (333 bytes in store; 138 bytes tracked data)
1192 migrating 1 manifests containing 3 revisions (333 bytes in store; 138 bytes tracked data)
1192 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
1193 finished migrating 3 manifest revisions across 1 manifests; change in size: 0 bytes
1193 migrating changelog containing 3 revisions (366 bytes in store; 171 bytes tracked data)
1194 migrating changelog containing 3 revisions (366 bytes in store; 171 bytes tracked data)
1194 finished migrating 3 changelog revisions; change in size: 0 bytes
1195 finished migrating 3 changelog revisions; change in size: 0 bytes
1195 finished migrating 9 total revisions; total change in store size: -9 bytes
1196 finished migrating 9 total revisions; total change in store size: -9 bytes
1196 copying phaseroots
1197 copying phaseroots
1197 data fully migrated to temporary repository
1198 data fully migrated to temporary repository
1198 marking source repository as being upgraded; clients will be unable to read from repository
1199 marking source repository as being upgraded; clients will be unable to read from repository
1199 starting in-place swap of repository data
1200 starting in-place swap of repository data
1200 replaced files will be backed up at $TESTTMP/localconfig/.hg/upgradebackup.* (glob)
1201 replaced files will be backed up at $TESTTMP/localconfig/.hg/upgradebackup.* (glob)
1201 replacing store...
1202 replacing store...
1202 store replacement complete; repository was inconsistent for *s (glob)
1203 store replacement complete; repository was inconsistent for *s (glob)
1203 finalizing requirements file and making repository readable again
1204 finalizing requirements file and making repository readable again
1204 removing temporary repository $TESTTMP/localconfig/.hg/upgrade.* (glob)
1205 removing temporary repository $TESTTMP/localconfig/.hg/upgrade.* (glob)
1205 copy of old repository backed up at $TESTTMP/localconfig/.hg/upgradebackup.* (glob)
1206 copy of old repository backed up at $TESTTMP/localconfig/.hg/upgradebackup.* (glob)
1206 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1207 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1207 $ hg debugdeltachain file
1208 $ hg debugdeltachain file
1208 rev chain# chainlen prev delta size rawsize chainsize ratio lindist extradist extraratio readsize largestblk rddensity srchunks
1209 rev chain# chainlen prev delta size rawsize chainsize ratio lindist extradist extraratio readsize largestblk rddensity srchunks
1209 0 1 1 -1 base 77 182 77 0.42308 77 0 0.00000 77 77 1.00000 1
1210 0 1 1 -1 base 77 182 77 0.42308 77 0 0.00000 77 77 1.00000 1
1210 1 1 2 0 p1 21 191 98 0.51309 98 0 0.00000 98 98 1.00000 1
1211 1 1 2 0 p1 21 191 98 0.51309 98 0 0.00000 98 98 1.00000 1
1211 2 1 3 1 p1 21 200 119 0.59500 119 0 0.00000 119 119 1.00000 1
1212 2 1 3 1 p1 21 200 119 0.59500 119 0 0.00000 119 119 1.00000 1
1212 $ cd ..
1213 $ cd ..
1213
1214
1214 $ cat << EOF >> $HGRCPATH
1215 $ cat << EOF >> $HGRCPATH
1215 > [format]
1216 > [format]
1216 > maxchainlen = 9001
1217 > maxchainlen = 9001
1217 > EOF
1218 > EOF
1218
1219
1219 Check upgrading a sparse-revlog repository
1220 Check upgrading a sparse-revlog repository
1220 ---------------------------------------
1221 ---------------------------------------
1221
1222
1222 $ hg init sparserevlogrepo --config format.sparse-revlog=no
1223 $ hg init sparserevlogrepo --config format.sparse-revlog=no
1223 $ cd sparserevlogrepo
1224 $ cd sparserevlogrepo
1224 $ touch foo
1225 $ touch foo
1225 $ hg add foo
1226 $ hg add foo
1226 $ hg -q commit -m "foo"
1227 $ hg -q commit -m "foo"
1227 $ cat .hg/requires
1228 $ cat .hg/requires
1228 dotencode
1229 dotencode
1229 fncache
1230 fncache
1230 generaldelta
1231 generaldelta
1231 revlogv1
1232 revlogv1
1232 store
1233 store
1233
1234
1234 Check that we can add the sparse-revlog format requirement
1235 Check that we can add the sparse-revlog format requirement
1235 $ hg --config format.sparse-revlog=yes debugupgraderepo --run >/dev/null
1236 $ hg --config format.sparse-revlog=yes debugupgraderepo --run >/dev/null
1236 copy of old repository backed up at $TESTTMP/sparserevlogrepo/.hg/upgradebackup.* (glob)
1237 copy of old repository backed up at $TESTTMP/sparserevlogrepo/.hg/upgradebackup.* (glob)
1237 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1238 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1238 $ cat .hg/requires
1239 $ cat .hg/requires
1239 dotencode
1240 dotencode
1240 fncache
1241 fncache
1241 generaldelta
1242 generaldelta
1242 revlogv1
1243 revlogv1
1243 sparserevlog
1244 sparserevlog
1244 store
1245 store
1245
1246
1246 Check that we can remove the sparse-revlog format requirement
1247 Check that we can remove the sparse-revlog format requirement
1247 $ hg --config format.sparse-revlog=no debugupgraderepo --run >/dev/null
1248 $ hg --config format.sparse-revlog=no debugupgraderepo --run >/dev/null
1248 copy of old repository backed up at $TESTTMP/sparserevlogrepo/.hg/upgradebackup.* (glob)
1249 copy of old repository backed up at $TESTTMP/sparserevlogrepo/.hg/upgradebackup.* (glob)
1249 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1250 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified
1250 $ cat .hg/requires
1251 $ cat .hg/requires
1251 dotencode
1252 dotencode
1252 fncache
1253 fncache
1253 generaldelta
1254 generaldelta
1254 revlogv1
1255 revlogv1
1255 store
1256 store
1256
1257
1257 #if zstd
1258 #if zstd
1258
1259
1259 Check upgrading to a zstd revlog
1260 Check upgrading to a zstd revlog
1260 --------------------------------
1261 --------------------------------
1261
1262
1262 upgrade
1263 upgrade
1263
1264
1264 $ hg --config format.revlog-compression=zstd debugupgraderepo --run --no-backup >/dev/null
1265 $ hg --config format.revlog-compression=zstd debugupgraderepo --run --no-backup >/dev/null
1265 $ hg debugformat -v
1266 $ hg debugformat -v
1266 format-variant repo config default
1267 format-variant repo config default
1267 fncache: yes yes yes
1268 fncache: yes yes yes
1268 dotencode: yes yes yes
1269 dotencode: yes yes yes
1269 generaldelta: yes yes yes
1270 generaldelta: yes yes yes
1270 sparserevlog: yes yes yes
1271 sparserevlog: yes yes yes
1271 sidedata: no no no
1272 sidedata: no no no
1272 plain-cl-delta: yes yes yes
1273 plain-cl-delta: yes yes yes
1273 compression: zstd zlib zlib
1274 compression: zstd zlib zlib
1274 compression-level: default default default
1275 compression-level: default default default
1275 $ cat .hg/requires
1276 $ cat .hg/requires
1276 dotencode
1277 dotencode
1277 fncache
1278 fncache
1278 generaldelta
1279 generaldelta
1279 revlog-compression-zstd
1280 revlog-compression-zstd
1280 revlogv1
1281 revlogv1
1281 sparserevlog
1282 sparserevlog
1282 store
1283 store
1283
1284
1284 downgrade
1285 downgrade
1285
1286
1286 $ hg debugupgraderepo --run --no-backup > /dev/null
1287 $ hg debugupgraderepo --run --no-backup > /dev/null
1287 $ hg debugformat -v
1288 $ hg debugformat -v
1288 format-variant repo config default
1289 format-variant repo config default
1289 fncache: yes yes yes
1290 fncache: yes yes yes
1290 dotencode: yes yes yes
1291 dotencode: yes yes yes
1291 generaldelta: yes yes yes
1292 generaldelta: yes yes yes
1292 sparserevlog: yes yes yes
1293 sparserevlog: yes yes yes
1293 sidedata: no no no
1294 sidedata: no no no
1294 plain-cl-delta: yes yes yes
1295 plain-cl-delta: yes yes yes
1295 compression: zlib zlib zlib
1296 compression: zlib zlib zlib
1296 compression-level: default default default
1297 compression-level: default default default
1297 $ cat .hg/requires
1298 $ cat .hg/requires
1298 dotencode
1299 dotencode
1299 fncache
1300 fncache
1300 generaldelta
1301 generaldelta
1301 revlogv1
1302 revlogv1
1302 sparserevlog
1303 sparserevlog
1303 store
1304 store
1304
1305
1305 upgrade from hgrc
1306 upgrade from hgrc
1306
1307
1307 $ cat >> .hg/hgrc << EOF
1308 $ cat >> .hg/hgrc << EOF
1308 > [format]
1309 > [format]
1309 > revlog-compression=zstd
1310 > revlog-compression=zstd
1310 > EOF
1311 > EOF
1311 $ hg debugupgraderepo --run --no-backup > /dev/null
1312 $ hg debugupgraderepo --run --no-backup > /dev/null
1312 $ hg debugformat -v
1313 $ hg debugformat -v
1313 format-variant repo config default
1314 format-variant repo config default
1314 fncache: yes yes yes
1315 fncache: yes yes yes
1315 dotencode: yes yes yes
1316 dotencode: yes yes yes
1316 generaldelta: yes yes yes
1317 generaldelta: yes yes yes
1317 sparserevlog: yes yes yes
1318 sparserevlog: yes yes yes
1318 sidedata: no no no
1319 sidedata: no no no
1319 plain-cl-delta: yes yes yes
1320 plain-cl-delta: yes yes yes
1320 compression: zstd zstd zlib
1321 compression: zstd zstd zlib
1321 compression-level: default default default
1322 compression-level: default default default
1322 $ cat .hg/requires
1323 $ cat .hg/requires
1323 dotencode
1324 dotencode
1324 fncache
1325 fncache
1325 generaldelta
1326 generaldelta
1326 revlog-compression-zstd
1327 revlog-compression-zstd
1327 revlogv1
1328 revlogv1
1328 sparserevlog
1329 sparserevlog
1329 store
1330 store
1330
1331
1331 $ cd ..
1332 $ cd ..
1332
1333
1333 #endif
1334 #endif
General Comments 0
You need to be logged in to leave comments. Login now