Show More
@@ -1,803 +1,785 | |||||
1 | #require serve no-reposimplestore no-chg |
|
1 | #require serve no-reposimplestore no-chg | |
2 |
|
2 | |||
3 | #testcases stream-legacy stream-bundle2-v2 stream-bundle2-v3 |
|
3 | #testcases stream-legacy stream-bundle2-v2 stream-bundle2-v3 | |
4 |
|
4 | |||
5 | #if stream-legacy |
|
5 | #if stream-legacy | |
6 | $ cat << EOF >> $HGRCPATH |
|
6 | $ cat << EOF >> $HGRCPATH | |
7 | > [server] |
|
7 | > [server] | |
8 | > bundle2.stream = no |
|
8 | > bundle2.stream = no | |
9 | > [format] |
|
9 | > [format] | |
10 | > # persistent nodemap is too broken with legacy format, |
|
10 | > # persistent nodemap is too broken with legacy format, | |
11 | > # however client with nodemap support will have better stream support. |
|
11 | > # however client with nodemap support will have better stream support. | |
12 | > use-persistent-nodemap=no |
|
12 | > use-persistent-nodemap=no | |
13 | > EOF |
|
13 | > EOF | |
14 | #endif |
|
14 | #endif | |
15 | #if stream-bundle2-v3 |
|
15 | #if stream-bundle2-v3 | |
16 | $ cat << EOF >> $HGRCPATH |
|
16 | $ cat << EOF >> $HGRCPATH | |
17 | > [experimental] |
|
17 | > [experimental] | |
18 | > stream-v3 = yes |
|
18 | > stream-v3 = yes | |
19 | > EOF |
|
19 | > EOF | |
20 | #endif |
|
20 | #endif | |
21 |
|
21 | |||
22 | Initialize repository |
|
22 | Initialize repository | |
23 |
|
23 | |||
24 | $ hg init server |
|
24 | $ hg init server | |
25 | $ cd server |
|
25 | $ cd server | |
26 | $ sh $TESTDIR/testlib/stream_clone_setup.sh |
|
26 | $ sh $TESTDIR/testlib/stream_clone_setup.sh | |
27 | adding 00changelog-ab349180a0405010.nd |
|
27 | adding 00changelog-ab349180a0405010.nd | |
28 | adding 00changelog.d |
|
28 | adding 00changelog.d | |
29 | adding 00changelog.i |
|
29 | adding 00changelog.i | |
30 | adding 00changelog.n |
|
30 | adding 00changelog.n | |
31 | adding 00manifest.d |
|
31 | adding 00manifest.d | |
32 | adding 00manifest.i |
|
32 | adding 00manifest.i | |
33 | adding container/isam-build-centos7/bazel-coverage-generator-sandboxfs-compatibility-0758e3e4f6057904d44399bd666faba9e7f40686.patch |
|
33 | adding container/isam-build-centos7/bazel-coverage-generator-sandboxfs-compatibility-0758e3e4f6057904d44399bd666faba9e7f40686.patch | |
34 | adding data/foo.d |
|
34 | adding data/foo.d | |
35 | adding data/foo.i |
|
35 | adding data/foo.i | |
36 | adding data/foo.n |
|
36 | adding data/foo.n | |
37 | adding data/undo.babar |
|
37 | adding data/undo.babar | |
38 | adding data/undo.d |
|
38 | adding data/undo.d | |
39 | adding data/undo.foo.d |
|
39 | adding data/undo.foo.d | |
40 | adding data/undo.foo.i |
|
40 | adding data/undo.foo.i | |
41 | adding data/undo.foo.n |
|
41 | adding data/undo.foo.n | |
42 | adding data/undo.i |
|
42 | adding data/undo.i | |
43 | adding data/undo.n |
|
43 | adding data/undo.n | |
44 | adding data/undo.py |
|
44 | adding data/undo.py | |
45 | adding foo.d |
|
45 | adding foo.d | |
46 | adding foo.i |
|
46 | adding foo.i | |
47 | adding foo.n |
|
47 | adding foo.n | |
48 | adding meta/foo.d |
|
48 | adding meta/foo.d | |
49 | adding meta/foo.i |
|
49 | adding meta/foo.i | |
50 | adding meta/foo.n |
|
50 | adding meta/foo.n | |
51 | adding meta/undo.babar |
|
51 | adding meta/undo.babar | |
52 | adding meta/undo.d |
|
52 | adding meta/undo.d | |
53 | adding meta/undo.foo.d |
|
53 | adding meta/undo.foo.d | |
54 | adding meta/undo.foo.i |
|
54 | adding meta/undo.foo.i | |
55 | adding meta/undo.foo.n |
|
55 | adding meta/undo.foo.n | |
56 | adding meta/undo.i |
|
56 | adding meta/undo.i | |
57 | adding meta/undo.n |
|
57 | adding meta/undo.n | |
58 | adding meta/undo.py |
|
58 | adding meta/undo.py | |
59 | adding savanah/foo.d |
|
59 | adding savanah/foo.d | |
60 | adding savanah/foo.i |
|
60 | adding savanah/foo.i | |
61 | adding savanah/foo.n |
|
61 | adding savanah/foo.n | |
62 | adding savanah/undo.babar |
|
62 | adding savanah/undo.babar | |
63 | adding savanah/undo.d |
|
63 | adding savanah/undo.d | |
64 | adding savanah/undo.foo.d |
|
64 | adding savanah/undo.foo.d | |
65 | adding savanah/undo.foo.i |
|
65 | adding savanah/undo.foo.i | |
66 | adding savanah/undo.foo.n |
|
66 | adding savanah/undo.foo.n | |
67 | adding savanah/undo.i |
|
67 | adding savanah/undo.i | |
68 | adding savanah/undo.n |
|
68 | adding savanah/undo.n | |
69 | adding savanah/undo.py |
|
69 | adding savanah/undo.py | |
70 | adding store/C\xc3\xa9lesteVille_is_a_Capital_City (esc) |
|
70 | adding store/C\xc3\xa9lesteVille_is_a_Capital_City (esc) | |
71 | adding store/foo.d |
|
71 | adding store/foo.d | |
72 | adding store/foo.i |
|
72 | adding store/foo.i | |
73 | adding store/foo.n |
|
73 | adding store/foo.n | |
74 | adding store/undo.babar |
|
74 | adding store/undo.babar | |
75 | adding store/undo.d |
|
75 | adding store/undo.d | |
76 | adding store/undo.foo.d |
|
76 | adding store/undo.foo.d | |
77 | adding store/undo.foo.i |
|
77 | adding store/undo.foo.i | |
78 | adding store/undo.foo.n |
|
78 | adding store/undo.foo.n | |
79 | adding store/undo.i |
|
79 | adding store/undo.i | |
80 | adding store/undo.n |
|
80 | adding store/undo.n | |
81 | adding store/undo.py |
|
81 | adding store/undo.py | |
82 | adding undo.babar |
|
82 | adding undo.babar | |
83 | adding undo.d |
|
83 | adding undo.d | |
84 | adding undo.foo.d |
|
84 | adding undo.foo.d | |
85 | adding undo.foo.i |
|
85 | adding undo.foo.i | |
86 | adding undo.foo.n |
|
86 | adding undo.foo.n | |
87 | adding undo.i |
|
87 | adding undo.i | |
88 | adding undo.n |
|
88 | adding undo.n | |
89 | adding undo.py |
|
89 | adding undo.py | |
90 |
|
90 | |||
91 | $ hg --config server.uncompressed=false serve -p $HGPORT -d --pid-file=hg.pid |
|
91 | $ hg --config server.uncompressed=false serve -p $HGPORT -d --pid-file=hg.pid | |
92 | $ cat hg.pid > $DAEMON_PIDS |
|
92 | $ cat hg.pid > $DAEMON_PIDS | |
93 | $ cd .. |
|
93 | $ cd .. | |
94 |
|
94 | |||
95 | Check local clone |
|
95 | Check local clone | |
96 | ================== |
|
96 | ================== | |
97 |
|
97 | |||
98 | The logic is close enough of uncompressed. |
|
98 | The logic is close enough of uncompressed. | |
99 | This is present here to reuse the testing around file with "special" names. |
|
99 | This is present here to reuse the testing around file with "special" names. | |
100 |
|
100 | |||
101 | $ hg clone server local-clone |
|
101 | $ hg clone server local-clone | |
102 | updating to branch default |
|
102 | updating to branch default | |
103 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
103 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
104 |
|
104 | |||
105 | Check that the clone went well |
|
105 | Check that the clone went well | |
106 |
|
106 | |||
107 | $ hg verify -R local-clone -q |
|
107 | $ hg verify -R local-clone -q | |
108 |
|
108 | |||
109 | Check uncompressed |
|
109 | Check uncompressed | |
110 | ================== |
|
110 | ================== | |
111 |
|
111 | |||
112 | Cannot stream clone when server.uncompressed is set to false |
|
112 | Cannot stream clone when server.uncompressed is set to false | |
113 | ------------------------------------------------------------ |
|
113 | ------------------------------------------------------------ | |
114 |
|
114 | |||
115 | When `server.uncompressed` is disabled, the client should fallback to a bundle |
|
115 | When `server.uncompressed` is disabled, the client should fallback to a bundle | |
116 | based clone with a warning. |
|
116 | based clone with a warning. | |
117 |
|
117 | |||
118 |
|
118 | |||
119 | $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=stream_out' |
|
119 | $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=stream_out' | |
120 | 200 Script output follows |
|
120 | 200 Script output follows | |
121 |
|
121 | |||
122 | 1 |
|
122 | 1 | |
123 |
|
123 | |||
124 | $ hg debugcapabilities http://localhost:$HGPORT |
|
124 | $ hg debugcapabilities http://localhost:$HGPORT | |
125 | Main capabilities: |
|
125 | Main capabilities: | |
126 | batch |
|
126 | batch | |
127 | branchmap |
|
127 | branchmap | |
128 | $USUAL_BUNDLE2_CAPS_SERVER$ |
|
128 | $USUAL_BUNDLE2_CAPS_SERVER$ | |
129 | changegroupsubset |
|
129 | changegroupsubset | |
130 | compression=$BUNDLE2_COMPRESSIONS$ |
|
130 | compression=$BUNDLE2_COMPRESSIONS$ | |
131 | getbundle |
|
131 | getbundle | |
132 | httpheader=1024 |
|
132 | httpheader=1024 | |
133 | httpmediatype=0.1rx,0.1tx,0.2tx |
|
133 | httpmediatype=0.1rx,0.1tx,0.2tx | |
134 | known |
|
134 | known | |
135 | lookup |
|
135 | lookup | |
136 | pushkey |
|
136 | pushkey | |
137 | unbundle=HG10GZ,HG10BZ,HG10UN |
|
137 | unbundle=HG10GZ,HG10BZ,HG10UN | |
138 | unbundlehash |
|
138 | unbundlehash | |
139 | Bundle2 capabilities: |
|
139 | Bundle2 capabilities: | |
140 | HG20 |
|
140 | HG20 | |
141 | bookmarks |
|
141 | bookmarks | |
142 | changegroup |
|
142 | changegroup | |
143 | 01 |
|
143 | 01 | |
144 | 02 |
|
144 | 02 | |
145 | 03 |
|
145 | 03 | |
146 | checkheads |
|
146 | checkheads | |
147 | related |
|
147 | related | |
148 | digests |
|
148 | digests | |
149 | md5 |
|
149 | md5 | |
150 | sha1 |
|
150 | sha1 | |
151 | sha512 |
|
151 | sha512 | |
152 | error |
|
152 | error | |
153 | abort |
|
153 | abort | |
154 | unsupportedcontent |
|
154 | unsupportedcontent | |
155 | pushraced |
|
155 | pushraced | |
156 | pushkey |
|
156 | pushkey | |
157 | hgtagsfnodes |
|
157 | hgtagsfnodes | |
158 | listkeys |
|
158 | listkeys | |
159 | phases |
|
159 | phases | |
160 | heads |
|
160 | heads | |
161 | pushkey |
|
161 | pushkey | |
162 | remote-changegroup |
|
162 | remote-changegroup | |
163 | http |
|
163 | http | |
164 | https |
|
164 | https | |
165 |
|
165 | |||
166 | $ hg clone --stream -U http://localhost:$HGPORT server-disabled |
|
166 | $ hg clone --stream -U http://localhost:$HGPORT server-disabled | |
167 | warning: stream clone requested but server has them disabled |
|
167 | warning: stream clone requested but server has them disabled | |
168 | requesting all changes |
|
168 | requesting all changes | |
169 | adding changesets |
|
169 | adding changesets | |
170 | adding manifests |
|
170 | adding manifests | |
171 | adding file changes |
|
171 | adding file changes | |
172 | added 3 changesets with 1088 changes to 1088 files |
|
172 | added 3 changesets with 1088 changes to 1088 files | |
173 | new changesets 96ee1d7354c4:5223b5e3265f |
|
173 | new changesets 96ee1d7354c4:5223b5e3265f | |
174 |
|
174 | |||
175 | $ killdaemons.py |
|
175 | $ killdaemons.py | |
176 | $ cd server |
|
176 | $ cd server | |
177 | $ hg serve -p $HGPORT -d --pid-file=hg.pid --error errors.txt |
|
177 | $ hg serve -p $HGPORT -d --pid-file=hg.pid --error errors.txt | |
178 | $ cat hg.pid > $DAEMON_PIDS |
|
178 | $ cat hg.pid > $DAEMON_PIDS | |
179 | $ cd .. |
|
179 | $ cd .. | |
180 |
|
180 | |||
181 | Basic clone |
|
181 | Basic clone | |
182 | ----------- |
|
182 | ----------- | |
183 |
|
183 | |||
184 | Check that --stream trigger a stream clone and result in a valid repositoty |
|
184 | Check that --stream trigger a stream clone and result in a valid repositoty | |
185 |
|
185 | |||
186 | We check the associated output for exact bytes on file number as changes in |
|
186 | We check the associated output for exact bytes on file number as changes in | |
187 | these value implies changes in the data transfered and can detect unintended |
|
187 | these value implies changes in the data transfered and can detect unintended | |
188 | changes in the process. |
|
188 | changes in the process. | |
189 |
|
189 | |||
190 | #if stream-legacy |
|
190 | #if stream-legacy | |
191 | $ hg clone --stream -U http://localhost:$HGPORT clone1 |
|
191 | $ hg clone --stream -U http://localhost:$HGPORT clone1 | |
192 | streaming all changes |
|
192 | streaming all changes | |
193 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
193 | 1091 files to transfer, 102 KB of data (no-zstd !) | |
194 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
194 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
195 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
195 | 1091 files to transfer, 98.8 KB of data (zstd !) | |
196 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
196 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) | |
197 | searching for changes |
|
197 | searching for changes | |
198 | no changes found |
|
198 | no changes found | |
199 | #endif |
|
199 | #endif | |
200 | #if stream-bundle2-v2 |
|
200 | #if stream-bundle2-v2 | |
201 | $ hg clone --stream -U http://localhost:$HGPORT clone1 |
|
201 | $ hg clone --stream -U http://localhost:$HGPORT clone1 | |
202 | streaming all changes |
|
202 | streaming all changes | |
203 | 1094 files to transfer, 102 KB of data (no-zstd !) |
|
203 | 1094 files to transfer, 102 KB of data (no-zstd !) | |
204 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
204 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
205 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) |
|
205 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) | |
206 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
206 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
207 | 1096 files to transfer, 99.0 KB of data (zstd rust !) |
|
207 | 1096 files to transfer, 99.0 KB of data (zstd rust !) | |
208 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
208 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) | |
209 | #endif |
|
209 | #endif | |
210 |
|
210 | |||
211 | #if stream-bundle2-v3 |
|
211 | #if stream-bundle2-v3 | |
212 | $ hg clone --stream -U http://localhost:$HGPORT clone1 |
|
212 | $ hg clone --stream -U http://localhost:$HGPORT clone1 | |
213 | streaming all changes |
|
213 | streaming all changes | |
214 | 1093 entries to transfer |
|
214 | 1093 entries to transfer | |
215 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
215 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
216 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
216 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
217 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
217 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) | |
218 | #endif |
|
218 | #endif | |
219 |
|
219 | |||
220 | #if no-stream-legacy |
|
220 | #if no-stream-legacy | |
221 | $ ls -1 clone1/.hg/cache |
|
221 | $ ls -1 clone1/.hg/cache | |
222 | branch2-base |
|
222 | branch2-base | |
223 | branch2-immutable |
|
223 | branch2-immutable | |
224 | branch2-served |
|
224 | branch2-served | |
225 | branch2-served.hidden |
|
225 | branch2-served.hidden | |
226 | branch2-visible |
|
226 | branch2-visible | |
227 | branch2-visible-hidden |
|
227 | branch2-visible-hidden | |
228 | rbc-names-v1 |
|
228 | rbc-names-v1 | |
229 | rbc-revs-v1 |
|
229 | rbc-revs-v1 | |
230 | tags2 |
|
230 | tags2 | |
231 | tags2-served |
|
231 | tags2-served | |
232 | #endif |
|
232 | #endif | |
233 |
|
233 | |||
234 | $ hg -R clone1 verify --quiet |
|
234 | $ hg -R clone1 verify --quiet | |
235 | $ cat server/errors.txt |
|
235 | $ cat server/errors.txt | |
236 |
|
236 | |||
237 | getbundle requests with stream=1 are uncompressed |
|
237 | getbundle requests with stream=1 are uncompressed | |
238 | ------------------------------------------------- |
|
238 | ------------------------------------------------- | |
239 |
|
239 | |||
240 | We check that `getbundle` will return a stream bundle when requested. |
|
240 | We check that `getbundle` will return a stream bundle when requested. | |
241 |
|
241 | |||
242 | XXX manually building the --requestheader is fragile and will drift away from actual usage |
|
242 | XXX manually building the --requestheader is fragile and will drift away from actual usage | |
243 |
|
243 | |||
244 | $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=getbundle' content-type --bodyfile body --hgproto '0.1 0.2 comp=zlib,none' --requestheader "x-hgarg-1=bundlecaps=HG20%2Cbundle2%3DHG20%250Abookmarks%250Achangegroup%253D01%252C02%252C03%250Adigests%253Dmd5%252Csha1%252Csha512%250Aerror%253Dabort%252Cunsupportedcontent%252Cpushraced%252Cpushkey%250Ahgtagsfnodes%250Alistkeys%250Aphases%253Dheads%250Apushkey%250Aremote-changegroup%253Dhttp%252Chttps%250Astream%253Dv2&cg=0&common=0000000000000000000000000000000000000000&heads=c17445101a72edac06facd130d14808dfbd5c7c2&stream=1" |
|
244 | $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=getbundle' content-type --bodyfile body --hgproto '0.1 0.2 comp=zlib,none' --requestheader "x-hgarg-1=bundlecaps=HG20%2Cbundle2%3DHG20%250Abookmarks%250Achangegroup%253D01%252C02%252C03%250Adigests%253Dmd5%252Csha1%252Csha512%250Aerror%253Dabort%252Cunsupportedcontent%252Cpushraced%252Cpushkey%250Ahgtagsfnodes%250Alistkeys%250Aphases%253Dheads%250Apushkey%250Aremote-changegroup%253Dhttp%252Chttps%250Astream%253Dv2&cg=0&common=0000000000000000000000000000000000000000&heads=c17445101a72edac06facd130d14808dfbd5c7c2&stream=1" | |
245 | 200 Script output follows |
|
245 | 200 Script output follows | |
246 | content-type: application/mercurial-0.2 |
|
246 | content-type: application/mercurial-0.2 | |
247 |
|
247 | |||
248 |
|
248 | |||
249 | $ f --size --hex --bytes 48 body |
|
249 | $ f --size --hex --bytes 48 body | |
250 | body: size=* (glob) |
|
250 | body: size=* (glob) | |
251 | 0000: 04 6e 6f 6e 65 48 47 32 30 00 00 00 00 00 00 00 |.noneHG20.......| |
|
251 | 0000: 04 6e 6f 6e 65 48 47 32 30 00 00 00 00 00 00 00 |.noneHG20.......| | |
252 | 0010: ?? 07 53 54 52 45 41 4d 32 00 00 00 00 03 00 09 |?.STREAM2.......| (glob) |
|
252 | 0010: ?? 07 53 54 52 45 41 4d 32 00 00 00 00 03 00 09 |?.STREAM2.......| (glob) | |
253 | 0020: 06 09 04 0c ?? 62 79 74 65 63 6f 75 6e 74 31 30 |....?bytecount10| (glob) |
|
253 | 0020: 06 09 04 0c ?? 62 79 74 65 63 6f 75 6e 74 31 30 |....?bytecount10| (glob) | |
254 |
|
254 | |||
255 | --uncompressed is an alias to --stream |
|
255 | --uncompressed is an alias to --stream | |
|
256 | --------------------------------------- | |||
256 |
|
257 | |||
257 | #if stream-legacy |
|
258 | The alias flag should trigger a stream clone too. | |
258 | $ hg clone --uncompressed -U http://localhost:$HGPORT clone1-uncompressed |
|
259 | ||
259 | streaming all changes |
|
|||
260 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
|||
261 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
|||
262 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
|||
263 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
|||
264 | searching for changes |
|
|||
265 | no changes found |
|
|||
266 | #endif |
|
|||
267 | #if stream-bundle2-v2 |
|
|||
268 | $ hg clone --uncompressed -U http://localhost:$HGPORT clone1-uncompressed |
|
260 | $ hg clone --uncompressed -U http://localhost:$HGPORT clone1-uncompressed | |
269 | streaming all changes |
|
261 | streaming all changes | |
270 |
|
|
262 | * files to transfer* (glob) (no-stream-bundle2-v3 !) | |
271 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
263 | * entries to transfer (glob) (stream-bundle2-v3 !) | |
272 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) |
|
264 | transferred * KB in * seconds (* */sec) (glob) | |
273 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
265 | searching for changes (stream-legacy !) | |
274 | 1096 files to transfer, 99.0 KB of data (zstd rust !) |
|
266 | no changes found (stream-legacy !) | |
275 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
|||
276 | #endif |
|
|||
277 | #if stream-bundle2-v3 |
|
|||
278 | $ hg clone --uncompressed -U http://localhost:$HGPORT clone1-uncompressed |
|
|||
279 | streaming all changes |
|
|||
280 | 1093 entries to transfer |
|
|||
281 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
|||
282 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
|||
283 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
|||
284 | #endif |
|
|||
285 |
|
|
267 | ||
286 | Clone with background file closing enabled |
|
268 | Clone with background file closing enabled | |
287 |
|
269 | |||
288 | #if stream-legacy |
|
270 | #if stream-legacy | |
289 | $ hg --debug --config worker.backgroundclose=true --config worker.backgroundcloseminfilecount=1 clone --stream -U http://localhost:$HGPORT clone-background | grep -v adding |
|
271 | $ hg --debug --config worker.backgroundclose=true --config worker.backgroundcloseminfilecount=1 clone --stream -U http://localhost:$HGPORT clone-background | grep -v adding | |
290 | using http://localhost:$HGPORT/ |
|
272 | using http://localhost:$HGPORT/ | |
291 | sending capabilities command |
|
273 | sending capabilities command | |
292 | sending branchmap command |
|
274 | sending branchmap command | |
293 | streaming all changes |
|
275 | streaming all changes | |
294 | sending stream_out command |
|
276 | sending stream_out command | |
295 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
277 | 1091 files to transfer, 102 KB of data (no-zstd !) | |
296 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
278 | 1091 files to transfer, 98.8 KB of data (zstd !) | |
297 | starting 4 threads for background file closing |
|
279 | starting 4 threads for background file closing | |
298 | updating the branch cache |
|
280 | updating the branch cache | |
299 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
281 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
300 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
282 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) | |
301 | query 1; heads |
|
283 | query 1; heads | |
302 | sending batch command |
|
284 | sending batch command | |
303 | searching for changes |
|
285 | searching for changes | |
304 | all remote heads known locally |
|
286 | all remote heads known locally | |
305 | no changes found |
|
287 | no changes found | |
306 | sending getbundle command |
|
288 | sending getbundle command | |
307 | bundle2-input-bundle: with-transaction |
|
289 | bundle2-input-bundle: with-transaction | |
308 | bundle2-input-part: "listkeys" (params: 1 mandatory) supported |
|
290 | bundle2-input-part: "listkeys" (params: 1 mandatory) supported | |
309 | bundle2-input-part: "phase-heads" supported |
|
291 | bundle2-input-part: "phase-heads" supported | |
310 | bundle2-input-part: total payload size 24 |
|
292 | bundle2-input-part: total payload size 24 | |
311 | bundle2-input-bundle: 2 parts total |
|
293 | bundle2-input-bundle: 2 parts total | |
312 | checking for updated bookmarks |
|
294 | checking for updated bookmarks | |
313 | updating the branch cache |
|
295 | updating the branch cache | |
314 | (sent 5 HTTP requests and * bytes; received * bytes in responses) (glob) |
|
296 | (sent 5 HTTP requests and * bytes; received * bytes in responses) (glob) | |
315 | #endif |
|
297 | #endif | |
316 | #if stream-bundle2-v2 |
|
298 | #if stream-bundle2-v2 | |
317 | $ hg --debug --config worker.backgroundclose=true --config worker.backgroundcloseminfilecount=1 clone --stream -U http://localhost:$HGPORT clone-background | grep -v adding |
|
299 | $ hg --debug --config worker.backgroundclose=true --config worker.backgroundcloseminfilecount=1 clone --stream -U http://localhost:$HGPORT clone-background | grep -v adding | |
318 | using http://localhost:$HGPORT/ |
|
300 | using http://localhost:$HGPORT/ | |
319 | sending capabilities command |
|
301 | sending capabilities command | |
320 | query 1; heads |
|
302 | query 1; heads | |
321 | sending batch command |
|
303 | sending batch command | |
322 | streaming all changes |
|
304 | streaming all changes | |
323 | sending getbundle command |
|
305 | sending getbundle command | |
324 | bundle2-input-bundle: with-transaction |
|
306 | bundle2-input-bundle: with-transaction | |
325 | bundle2-input-part: "stream2" (params: 3 mandatory) supported |
|
307 | bundle2-input-part: "stream2" (params: 3 mandatory) supported | |
326 | applying stream bundle |
|
308 | applying stream bundle | |
327 | 1094 files to transfer, 102 KB of data (no-zstd !) |
|
309 | 1094 files to transfer, 102 KB of data (no-zstd !) | |
328 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) |
|
310 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) | |
329 | 1096 files to transfer, 99.0 KB of data (zstd rust !) |
|
311 | 1096 files to transfer, 99.0 KB of data (zstd rust !) | |
330 | starting 4 threads for background file closing |
|
312 | starting 4 threads for background file closing | |
331 | starting 4 threads for background file closing |
|
313 | starting 4 threads for background file closing | |
332 | updating the branch cache |
|
314 | updating the branch cache | |
333 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
315 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
334 | bundle2-input-part: total payload size 119001 (no-zstd !) |
|
316 | bundle2-input-part: total payload size 119001 (no-zstd !) | |
335 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
317 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
336 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
318 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) | |
337 | bundle2-input-part: total payload size 116162 (zstd no-bigendian no-rust !) |
|
319 | bundle2-input-part: total payload size 116162 (zstd no-bigendian no-rust !) | |
338 | bundle2-input-part: total payload size 116330 (zstd no-bigendian rust !) |
|
320 | bundle2-input-part: total payload size 116330 (zstd no-bigendian rust !) | |
339 | bundle2-input-part: total payload size 116157 (zstd bigendian no-rust !) |
|
321 | bundle2-input-part: total payload size 116157 (zstd bigendian no-rust !) | |
340 | bundle2-input-part: total payload size 116325 (zstd bigendian rust !) |
|
322 | bundle2-input-part: total payload size 116325 (zstd bigendian rust !) | |
341 | bundle2-input-part: "listkeys" (params: 1 mandatory) supported |
|
323 | bundle2-input-part: "listkeys" (params: 1 mandatory) supported | |
342 | bundle2-input-bundle: 2 parts total |
|
324 | bundle2-input-bundle: 2 parts total | |
343 | checking for updated bookmarks |
|
325 | checking for updated bookmarks | |
344 | updating the branch cache |
|
326 | updating the branch cache | |
345 | (sent 3 HTTP requests and * bytes; received * bytes in responses) (glob) |
|
327 | (sent 3 HTTP requests and * bytes; received * bytes in responses) (glob) | |
346 | #endif |
|
328 | #endif | |
347 | #if stream-bundle2-v3 |
|
329 | #if stream-bundle2-v3 | |
348 | $ hg --debug --config worker.backgroundclose=true --config worker.backgroundcloseminfilecount=1 clone --stream -U http://localhost:$HGPORT clone-background | grep -v adding |
|
330 | $ hg --debug --config worker.backgroundclose=true --config worker.backgroundcloseminfilecount=1 clone --stream -U http://localhost:$HGPORT clone-background | grep -v adding | |
349 | using http://localhost:$HGPORT/ |
|
331 | using http://localhost:$HGPORT/ | |
350 | sending capabilities command |
|
332 | sending capabilities command | |
351 | query 1; heads |
|
333 | query 1; heads | |
352 | sending batch command |
|
334 | sending batch command | |
353 | streaming all changes |
|
335 | streaming all changes | |
354 | sending getbundle command |
|
336 | sending getbundle command | |
355 | bundle2-input-bundle: with-transaction |
|
337 | bundle2-input-bundle: with-transaction | |
356 | bundle2-input-part: "stream3-exp" (params: 1 mandatory) supported |
|
338 | bundle2-input-part: "stream3-exp" (params: 1 mandatory) supported | |
357 | applying stream bundle |
|
339 | applying stream bundle | |
358 | 1093 entries to transfer |
|
340 | 1093 entries to transfer | |
359 | starting 4 threads for background file closing |
|
341 | starting 4 threads for background file closing | |
360 | starting 4 threads for background file closing |
|
342 | starting 4 threads for background file closing | |
361 | updating the branch cache |
|
343 | updating the branch cache | |
362 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
344 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
363 | bundle2-input-part: total payload size 120096 (no-zstd !) |
|
345 | bundle2-input-part: total payload size 120096 (no-zstd !) | |
364 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
346 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
365 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
347 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) | |
366 | bundle2-input-part: total payload size 117257 (zstd no-rust no-bigendian !) |
|
348 | bundle2-input-part: total payload size 117257 (zstd no-rust no-bigendian !) | |
367 | bundle2-input-part: total payload size 117425 (zstd rust no-bigendian !) |
|
349 | bundle2-input-part: total payload size 117425 (zstd rust no-bigendian !) | |
368 | bundle2-input-part: total payload size 117252 (zstd bigendian no-rust !) |
|
350 | bundle2-input-part: total payload size 117252 (zstd bigendian no-rust !) | |
369 | bundle2-input-part: total payload size 117420 (zstd bigendian rust !) |
|
351 | bundle2-input-part: total payload size 117420 (zstd bigendian rust !) | |
370 | bundle2-input-part: "listkeys" (params: 1 mandatory) supported |
|
352 | bundle2-input-part: "listkeys" (params: 1 mandatory) supported | |
371 | bundle2-input-bundle: 2 parts total |
|
353 | bundle2-input-bundle: 2 parts total | |
372 | checking for updated bookmarks |
|
354 | checking for updated bookmarks | |
373 | updating the branch cache |
|
355 | updating the branch cache | |
374 | (sent 3 HTTP requests and * bytes; received * bytes in responses) (glob) |
|
356 | (sent 3 HTTP requests and * bytes; received * bytes in responses) (glob) | |
375 | #endif |
|
357 | #endif | |
376 |
|
358 | |||
377 | Cannot stream clone when there are secret changesets |
|
359 | Cannot stream clone when there are secret changesets | |
378 |
|
360 | |||
379 | $ hg -R server phase --force --secret -r tip |
|
361 | $ hg -R server phase --force --secret -r tip | |
380 | $ hg clone --stream -U http://localhost:$HGPORT secret-denied |
|
362 | $ hg clone --stream -U http://localhost:$HGPORT secret-denied | |
381 | warning: stream clone requested but server has them disabled |
|
363 | warning: stream clone requested but server has them disabled | |
382 | requesting all changes |
|
364 | requesting all changes | |
383 | adding changesets |
|
365 | adding changesets | |
384 | adding manifests |
|
366 | adding manifests | |
385 | adding file changes |
|
367 | adding file changes | |
386 | added 2 changesets with 1025 changes to 1025 files |
|
368 | added 2 changesets with 1025 changes to 1025 files | |
387 | new changesets 96ee1d7354c4:c17445101a72 |
|
369 | new changesets 96ee1d7354c4:c17445101a72 | |
388 |
|
370 | |||
389 | $ killdaemons.py |
|
371 | $ killdaemons.py | |
390 |
|
372 | |||
391 | Streaming of secrets can be overridden by server config |
|
373 | Streaming of secrets can be overridden by server config | |
392 |
|
374 | |||
393 | $ cd server |
|
375 | $ cd server | |
394 | $ hg serve --config server.uncompressedallowsecret=true -p $HGPORT -d --pid-file=hg.pid |
|
376 | $ hg serve --config server.uncompressedallowsecret=true -p $HGPORT -d --pid-file=hg.pid | |
395 | $ cat hg.pid > $DAEMON_PIDS |
|
377 | $ cat hg.pid > $DAEMON_PIDS | |
396 | $ cd .. |
|
378 | $ cd .. | |
397 |
|
379 | |||
398 | #if stream-legacy |
|
380 | #if stream-legacy | |
399 | $ hg clone --stream -U http://localhost:$HGPORT secret-allowed |
|
381 | $ hg clone --stream -U http://localhost:$HGPORT secret-allowed | |
400 | streaming all changes |
|
382 | streaming all changes | |
401 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
383 | 1091 files to transfer, 102 KB of data (no-zstd !) | |
402 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
384 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
403 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
385 | 1091 files to transfer, 98.8 KB of data (zstd !) | |
404 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
386 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) | |
405 | searching for changes |
|
387 | searching for changes | |
406 | no changes found |
|
388 | no changes found | |
407 | #endif |
|
389 | #endif | |
408 | #if stream-bundle2-v2 |
|
390 | #if stream-bundle2-v2 | |
409 | $ hg clone --stream -U http://localhost:$HGPORT secret-allowed |
|
391 | $ hg clone --stream -U http://localhost:$HGPORT secret-allowed | |
410 | streaming all changes |
|
392 | streaming all changes | |
411 | 1094 files to transfer, 102 KB of data (no-zstd !) |
|
393 | 1094 files to transfer, 102 KB of data (no-zstd !) | |
412 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
394 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
413 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) |
|
395 | 1094 files to transfer, 98.9 KB of data (zstd no-rust !) | |
414 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
396 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
415 | 1096 files to transfer, 99.0 KB of data (zstd rust !) |
|
397 | 1096 files to transfer, 99.0 KB of data (zstd rust !) | |
416 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
398 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) | |
417 | #endif |
|
399 | #endif | |
418 | #if stream-bundle2-v3 |
|
400 | #if stream-bundle2-v3 | |
419 | $ hg clone --stream -U http://localhost:$HGPORT secret-allowed |
|
401 | $ hg clone --stream -U http://localhost:$HGPORT secret-allowed | |
420 | streaming all changes |
|
402 | streaming all changes | |
421 | 1093 entries to transfer |
|
403 | 1093 entries to transfer | |
422 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
404 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
423 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
405 | transferred 98.9 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
424 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
406 | transferred 99.0 KB in * seconds (* */sec) (glob) (zstd rust !) | |
425 | #endif |
|
407 | #endif | |
426 |
|
408 | |||
427 | $ killdaemons.py |
|
409 | $ killdaemons.py | |
428 |
|
410 | |||
429 | Verify interaction between preferuncompressed and secret presence |
|
411 | Verify interaction between preferuncompressed and secret presence | |
430 |
|
412 | |||
431 | $ cd server |
|
413 | $ cd server | |
432 | $ hg serve --config server.preferuncompressed=true -p $HGPORT -d --pid-file=hg.pid |
|
414 | $ hg serve --config server.preferuncompressed=true -p $HGPORT -d --pid-file=hg.pid | |
433 | $ cat hg.pid > $DAEMON_PIDS |
|
415 | $ cat hg.pid > $DAEMON_PIDS | |
434 | $ cd .. |
|
416 | $ cd .. | |
435 |
|
417 | |||
436 | $ hg clone -U http://localhost:$HGPORT preferuncompressed-secret |
|
418 | $ hg clone -U http://localhost:$HGPORT preferuncompressed-secret | |
437 | requesting all changes |
|
419 | requesting all changes | |
438 | adding changesets |
|
420 | adding changesets | |
439 | adding manifests |
|
421 | adding manifests | |
440 | adding file changes |
|
422 | adding file changes | |
441 | added 2 changesets with 1025 changes to 1025 files |
|
423 | added 2 changesets with 1025 changes to 1025 files | |
442 | new changesets 96ee1d7354c4:c17445101a72 |
|
424 | new changesets 96ee1d7354c4:c17445101a72 | |
443 |
|
425 | |||
444 | $ killdaemons.py |
|
426 | $ killdaemons.py | |
445 |
|
427 | |||
446 | Clone not allowed when full bundles disabled and can't serve secrets |
|
428 | Clone not allowed when full bundles disabled and can't serve secrets | |
447 |
|
429 | |||
448 | $ cd server |
|
430 | $ cd server | |
449 | $ hg serve --config server.disablefullbundle=true -p $HGPORT -d --pid-file=hg.pid |
|
431 | $ hg serve --config server.disablefullbundle=true -p $HGPORT -d --pid-file=hg.pid | |
450 | $ cat hg.pid > $DAEMON_PIDS |
|
432 | $ cat hg.pid > $DAEMON_PIDS | |
451 | $ cd .. |
|
433 | $ cd .. | |
452 |
|
434 | |||
453 | $ hg clone --stream http://localhost:$HGPORT secret-full-disabled |
|
435 | $ hg clone --stream http://localhost:$HGPORT secret-full-disabled | |
454 | warning: stream clone requested but server has them disabled |
|
436 | warning: stream clone requested but server has them disabled | |
455 | requesting all changes |
|
437 | requesting all changes | |
456 | remote: abort: server has pull-based clones disabled |
|
438 | remote: abort: server has pull-based clones disabled | |
457 | abort: pull failed on remote |
|
439 | abort: pull failed on remote | |
458 | (remove --pull if specified or upgrade Mercurial) |
|
440 | (remove --pull if specified or upgrade Mercurial) | |
459 | [100] |
|
441 | [100] | |
460 |
|
442 | |||
461 | Local stream clone with secrets involved |
|
443 | Local stream clone with secrets involved | |
462 | (This is just a test over behavior: if you have access to the repo's files, |
|
444 | (This is just a test over behavior: if you have access to the repo's files, | |
463 | there is no security so it isn't important to prevent a clone here.) |
|
445 | there is no security so it isn't important to prevent a clone here.) | |
464 |
|
446 | |||
465 | $ hg clone -U --stream server local-secret |
|
447 | $ hg clone -U --stream server local-secret | |
466 | warning: stream clone requested but server has them disabled |
|
448 | warning: stream clone requested but server has them disabled | |
467 | requesting all changes |
|
449 | requesting all changes | |
468 | adding changesets |
|
450 | adding changesets | |
469 | adding manifests |
|
451 | adding manifests | |
470 | adding file changes |
|
452 | adding file changes | |
471 | added 2 changesets with 1025 changes to 1025 files |
|
453 | added 2 changesets with 1025 changes to 1025 files | |
472 | new changesets 96ee1d7354c4:c17445101a72 |
|
454 | new changesets 96ee1d7354c4:c17445101a72 | |
473 |
|
455 | |||
474 | Stream clone while repo is changing: |
|
456 | Stream clone while repo is changing: | |
475 |
|
457 | |||
476 | $ mkdir changing |
|
458 | $ mkdir changing | |
477 | $ cd changing |
|
459 | $ cd changing | |
478 |
|
460 | |||
479 | prepare repo with small and big file to cover both code paths in emitrevlogdata |
|
461 | prepare repo with small and big file to cover both code paths in emitrevlogdata | |
480 |
|
462 | |||
481 | $ hg init repo |
|
463 | $ hg init repo | |
482 | $ touch repo/f1 |
|
464 | $ touch repo/f1 | |
483 | $ $TESTDIR/seq.py 50000 > repo/f2 |
|
465 | $ $TESTDIR/seq.py 50000 > repo/f2 | |
484 | $ hg -R repo ci -Aqm "0" |
|
466 | $ hg -R repo ci -Aqm "0" | |
485 | $ HG_TEST_STREAM_WALKED_FILE_1="$TESTTMP/sync_file_walked_1" |
|
467 | $ HG_TEST_STREAM_WALKED_FILE_1="$TESTTMP/sync_file_walked_1" | |
486 | $ export HG_TEST_STREAM_WALKED_FILE_1 |
|
468 | $ export HG_TEST_STREAM_WALKED_FILE_1 | |
487 | $ HG_TEST_STREAM_WALKED_FILE_2="$TESTTMP/sync_file_walked_2" |
|
469 | $ HG_TEST_STREAM_WALKED_FILE_2="$TESTTMP/sync_file_walked_2" | |
488 | $ export HG_TEST_STREAM_WALKED_FILE_2 |
|
470 | $ export HG_TEST_STREAM_WALKED_FILE_2 | |
489 | $ HG_TEST_STREAM_WALKED_FILE_3="$TESTTMP/sync_file_walked_3" |
|
471 | $ HG_TEST_STREAM_WALKED_FILE_3="$TESTTMP/sync_file_walked_3" | |
490 | $ export HG_TEST_STREAM_WALKED_FILE_3 |
|
472 | $ export HG_TEST_STREAM_WALKED_FILE_3 | |
491 | # $ cat << EOF >> $HGRCPATH |
|
473 | # $ cat << EOF >> $HGRCPATH | |
492 | # > [hooks] |
|
474 | # > [hooks] | |
493 | # > pre-clone=rm -f "$TESTTMP/sync_file_walked_*" |
|
475 | # > pre-clone=rm -f "$TESTTMP/sync_file_walked_*" | |
494 | # > EOF |
|
476 | # > EOF | |
495 | $ hg serve -R repo -p $HGPORT1 -d --error errors.log --pid-file=hg.pid --config extensions.stream_steps="$RUNTESTDIR/testlib/ext-stream-clone-steps.py" |
|
477 | $ hg serve -R repo -p $HGPORT1 -d --error errors.log --pid-file=hg.pid --config extensions.stream_steps="$RUNTESTDIR/testlib/ext-stream-clone-steps.py" | |
496 | $ cat hg.pid >> $DAEMON_PIDS |
|
478 | $ cat hg.pid >> $DAEMON_PIDS | |
497 |
|
479 | |||
498 | clone while modifying the repo between stating file with write lock and |
|
480 | clone while modifying the repo between stating file with write lock and | |
499 | actually serving file content |
|
481 | actually serving file content | |
500 |
|
482 | |||
501 | $ (hg clone -q --stream -U http://localhost:$HGPORT1 clone; touch "$HG_TEST_STREAM_WALKED_FILE_3") & |
|
483 | $ (hg clone -q --stream -U http://localhost:$HGPORT1 clone; touch "$HG_TEST_STREAM_WALKED_FILE_3") & | |
502 | $ $RUNTESTDIR/testlib/wait-on-file 10 $HG_TEST_STREAM_WALKED_FILE_1 |
|
484 | $ $RUNTESTDIR/testlib/wait-on-file 10 $HG_TEST_STREAM_WALKED_FILE_1 | |
503 | $ echo >> repo/f1 |
|
485 | $ echo >> repo/f1 | |
504 | $ echo >> repo/f2 |
|
486 | $ echo >> repo/f2 | |
505 | $ hg -R repo ci -m "1" --config ui.timeout.warn=-1 |
|
487 | $ hg -R repo ci -m "1" --config ui.timeout.warn=-1 | |
506 | $ touch $HG_TEST_STREAM_WALKED_FILE_2 |
|
488 | $ touch $HG_TEST_STREAM_WALKED_FILE_2 | |
507 | $ $RUNTESTDIR/testlib/wait-on-file 10 $HG_TEST_STREAM_WALKED_FILE_3 |
|
489 | $ $RUNTESTDIR/testlib/wait-on-file 10 $HG_TEST_STREAM_WALKED_FILE_3 | |
508 | $ hg -R clone id |
|
490 | $ hg -R clone id | |
509 | 000000000000 |
|
491 | 000000000000 | |
510 | $ cat errors.log |
|
492 | $ cat errors.log | |
511 | $ cd .. |
|
493 | $ cd .. | |
512 |
|
494 | |||
513 | Stream repository with bookmarks |
|
495 | Stream repository with bookmarks | |
514 | -------------------------------- |
|
496 | -------------------------------- | |
515 |
|
497 | |||
516 | (revert introduction of secret changeset) |
|
498 | (revert introduction of secret changeset) | |
517 |
|
499 | |||
518 | $ hg -R server phase --draft 'secret()' |
|
500 | $ hg -R server phase --draft 'secret()' | |
519 |
|
501 | |||
520 | add a bookmark |
|
502 | add a bookmark | |
521 |
|
503 | |||
522 | $ hg -R server bookmark -r tip some-bookmark |
|
504 | $ hg -R server bookmark -r tip some-bookmark | |
523 |
|
505 | |||
524 | clone it |
|
506 | clone it | |
525 |
|
507 | |||
526 | #if stream-legacy |
|
508 | #if stream-legacy | |
527 | $ hg clone --stream http://localhost:$HGPORT with-bookmarks |
|
509 | $ hg clone --stream http://localhost:$HGPORT with-bookmarks | |
528 | streaming all changes |
|
510 | streaming all changes | |
529 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
511 | 1091 files to transfer, 102 KB of data (no-zstd !) | |
530 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
512 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
531 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
513 | 1091 files to transfer, 98.8 KB of data (zstd !) | |
532 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
514 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) | |
533 | searching for changes |
|
515 | searching for changes | |
534 | no changes found |
|
516 | no changes found | |
535 | updating to branch default |
|
517 | updating to branch default | |
536 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
518 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
537 | #endif |
|
519 | #endif | |
538 | #if stream-bundle2-v2 |
|
520 | #if stream-bundle2-v2 | |
539 | $ hg clone --stream http://localhost:$HGPORT with-bookmarks |
|
521 | $ hg clone --stream http://localhost:$HGPORT with-bookmarks | |
540 | streaming all changes |
|
522 | streaming all changes | |
541 | 1097 files to transfer, 102 KB of data (no-zstd !) |
|
523 | 1097 files to transfer, 102 KB of data (no-zstd !) | |
542 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
524 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
543 | 1097 files to transfer, 99.1 KB of data (zstd no-rust !) |
|
525 | 1097 files to transfer, 99.1 KB of data (zstd no-rust !) | |
544 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
526 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
545 | 1099 files to transfer, 99.2 KB of data (zstd rust !) |
|
527 | 1099 files to transfer, 99.2 KB of data (zstd rust !) | |
546 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
528 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) | |
547 | updating to branch default |
|
529 | updating to branch default | |
548 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
530 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
549 | #endif |
|
531 | #endif | |
550 | #if stream-bundle2-v3 |
|
532 | #if stream-bundle2-v3 | |
551 | $ hg clone --stream http://localhost:$HGPORT with-bookmarks |
|
533 | $ hg clone --stream http://localhost:$HGPORT with-bookmarks | |
552 | streaming all changes |
|
534 | streaming all changes | |
553 | 1096 entries to transfer |
|
535 | 1096 entries to transfer | |
554 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
536 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
555 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
537 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
556 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
538 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) | |
557 | updating to branch default |
|
539 | updating to branch default | |
558 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
540 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
559 | #endif |
|
541 | #endif | |
560 | $ hg verify -R with-bookmarks -q |
|
542 | $ hg verify -R with-bookmarks -q | |
561 | $ hg -R with-bookmarks bookmarks |
|
543 | $ hg -R with-bookmarks bookmarks | |
562 | some-bookmark 2:5223b5e3265f |
|
544 | some-bookmark 2:5223b5e3265f | |
563 |
|
545 | |||
564 | Stream repository with phases |
|
546 | Stream repository with phases | |
565 | ----------------------------- |
|
547 | ----------------------------- | |
566 |
|
548 | |||
567 | Clone as publishing |
|
549 | Clone as publishing | |
568 |
|
550 | |||
569 | $ hg -R server phase -r 'all()' |
|
551 | $ hg -R server phase -r 'all()' | |
570 | 0: draft |
|
552 | 0: draft | |
571 | 1: draft |
|
553 | 1: draft | |
572 | 2: draft |
|
554 | 2: draft | |
573 |
|
555 | |||
574 | #if stream-legacy |
|
556 | #if stream-legacy | |
575 | $ hg clone --stream http://localhost:$HGPORT phase-publish |
|
557 | $ hg clone --stream http://localhost:$HGPORT phase-publish | |
576 | streaming all changes |
|
558 | streaming all changes | |
577 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
559 | 1091 files to transfer, 102 KB of data (no-zstd !) | |
578 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
560 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
579 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
561 | 1091 files to transfer, 98.8 KB of data (zstd !) | |
580 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
562 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) | |
581 | searching for changes |
|
563 | searching for changes | |
582 | no changes found |
|
564 | no changes found | |
583 | updating to branch default |
|
565 | updating to branch default | |
584 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
566 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
585 | #endif |
|
567 | #endif | |
586 | #if stream-bundle2-v2 |
|
568 | #if stream-bundle2-v2 | |
587 | $ hg clone --stream http://localhost:$HGPORT phase-publish |
|
569 | $ hg clone --stream http://localhost:$HGPORT phase-publish | |
588 | streaming all changes |
|
570 | streaming all changes | |
589 | 1097 files to transfer, 102 KB of data (no-zstd !) |
|
571 | 1097 files to transfer, 102 KB of data (no-zstd !) | |
590 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
572 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
591 | 1097 files to transfer, 99.1 KB of data (zstd no-rust !) |
|
573 | 1097 files to transfer, 99.1 KB of data (zstd no-rust !) | |
592 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
574 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
593 | 1099 files to transfer, 99.2 KB of data (zstd rust !) |
|
575 | 1099 files to transfer, 99.2 KB of data (zstd rust !) | |
594 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
576 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) | |
595 | updating to branch default |
|
577 | updating to branch default | |
596 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
578 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
597 | #endif |
|
579 | #endif | |
598 | #if stream-bundle2-v3 |
|
580 | #if stream-bundle2-v3 | |
599 | $ hg clone --stream http://localhost:$HGPORT phase-publish |
|
581 | $ hg clone --stream http://localhost:$HGPORT phase-publish | |
600 | streaming all changes |
|
582 | streaming all changes | |
601 | 1096 entries to transfer |
|
583 | 1096 entries to transfer | |
602 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
584 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
603 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
585 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
604 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
586 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) | |
605 | updating to branch default |
|
587 | updating to branch default | |
606 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
588 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
607 | #endif |
|
589 | #endif | |
608 | $ hg verify -R phase-publish -q |
|
590 | $ hg verify -R phase-publish -q | |
609 | $ hg -R phase-publish phase -r 'all()' |
|
591 | $ hg -R phase-publish phase -r 'all()' | |
610 | 0: public |
|
592 | 0: public | |
611 | 1: public |
|
593 | 1: public | |
612 | 2: public |
|
594 | 2: public | |
613 |
|
595 | |||
614 | Clone as non publishing |
|
596 | Clone as non publishing | |
615 |
|
597 | |||
616 | $ cat << EOF >> server/.hg/hgrc |
|
598 | $ cat << EOF >> server/.hg/hgrc | |
617 | > [phases] |
|
599 | > [phases] | |
618 | > publish = False |
|
600 | > publish = False | |
619 | > EOF |
|
601 | > EOF | |
620 | $ killdaemons.py |
|
602 | $ killdaemons.py | |
621 | $ hg -R server serve -p $HGPORT -d --pid-file=hg.pid |
|
603 | $ hg -R server serve -p $HGPORT -d --pid-file=hg.pid | |
622 | $ cat hg.pid > $DAEMON_PIDS |
|
604 | $ cat hg.pid > $DAEMON_PIDS | |
623 |
|
605 | |||
624 | #if stream-legacy |
|
606 | #if stream-legacy | |
625 |
|
607 | |||
626 | With v1 of the stream protocol, changeset are always cloned as public. It make |
|
608 | With v1 of the stream protocol, changeset are always cloned as public. It make | |
627 | stream v1 unsuitable for non-publishing repository. |
|
609 | stream v1 unsuitable for non-publishing repository. | |
628 |
|
610 | |||
629 | $ hg clone --stream http://localhost:$HGPORT phase-no-publish |
|
611 | $ hg clone --stream http://localhost:$HGPORT phase-no-publish | |
630 | streaming all changes |
|
612 | streaming all changes | |
631 | 1091 files to transfer, 102 KB of data (no-zstd !) |
|
613 | 1091 files to transfer, 102 KB of data (no-zstd !) | |
632 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
614 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
633 | 1091 files to transfer, 98.8 KB of data (zstd !) |
|
615 | 1091 files to transfer, 98.8 KB of data (zstd !) | |
634 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) |
|
616 | transferred 98.8 KB in * seconds (* */sec) (glob) (zstd !) | |
635 | searching for changes |
|
617 | searching for changes | |
636 | no changes found |
|
618 | no changes found | |
637 | updating to branch default |
|
619 | updating to branch default | |
638 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
620 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
639 | $ hg -R phase-no-publish phase -r 'all()' |
|
621 | $ hg -R phase-no-publish phase -r 'all()' | |
640 | 0: public |
|
622 | 0: public | |
641 | 1: public |
|
623 | 1: public | |
642 | 2: public |
|
624 | 2: public | |
643 | #endif |
|
625 | #endif | |
644 | #if stream-bundle2-v2 |
|
626 | #if stream-bundle2-v2 | |
645 | $ hg clone --stream http://localhost:$HGPORT phase-no-publish |
|
627 | $ hg clone --stream http://localhost:$HGPORT phase-no-publish | |
646 | streaming all changes |
|
628 | streaming all changes | |
647 | 1098 files to transfer, 102 KB of data (no-zstd !) |
|
629 | 1098 files to transfer, 102 KB of data (no-zstd !) | |
648 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
630 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
649 | 1098 files to transfer, 99.1 KB of data (zstd no-rust !) |
|
631 | 1098 files to transfer, 99.1 KB of data (zstd no-rust !) | |
650 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
632 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
651 | 1100 files to transfer, 99.2 KB of data (zstd rust !) |
|
633 | 1100 files to transfer, 99.2 KB of data (zstd rust !) | |
652 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
634 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) | |
653 | updating to branch default |
|
635 | updating to branch default | |
654 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
636 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
655 | $ hg -R phase-no-publish phase -r 'all()' |
|
637 | $ hg -R phase-no-publish phase -r 'all()' | |
656 | 0: draft |
|
638 | 0: draft | |
657 | 1: draft |
|
639 | 1: draft | |
658 | 2: draft |
|
640 | 2: draft | |
659 | #endif |
|
641 | #endif | |
660 | #if stream-bundle2-v3 |
|
642 | #if stream-bundle2-v3 | |
661 | $ hg clone --stream http://localhost:$HGPORT phase-no-publish |
|
643 | $ hg clone --stream http://localhost:$HGPORT phase-no-publish | |
662 | streaming all changes |
|
644 | streaming all changes | |
663 | 1097 entries to transfer |
|
645 | 1097 entries to transfer | |
664 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
646 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
665 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
647 | transferred 99.1 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
666 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
648 | transferred 99.2 KB in * seconds (* */sec) (glob) (zstd rust !) | |
667 | updating to branch default |
|
649 | updating to branch default | |
668 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
650 | 1088 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
669 | $ hg -R phase-no-publish phase -r 'all()' |
|
651 | $ hg -R phase-no-publish phase -r 'all()' | |
670 | 0: draft |
|
652 | 0: draft | |
671 | 1: draft |
|
653 | 1: draft | |
672 | 2: draft |
|
654 | 2: draft | |
673 | #endif |
|
655 | #endif | |
674 | $ hg verify -R phase-no-publish -q |
|
656 | $ hg verify -R phase-no-publish -q | |
675 |
|
657 | |||
676 | $ killdaemons.py |
|
658 | $ killdaemons.py | |
677 |
|
659 | |||
678 | #if stream-legacy |
|
660 | #if stream-legacy | |
679 |
|
661 | |||
680 | With v1 of the stream protocol, changeset are always cloned as public. There's |
|
662 | With v1 of the stream protocol, changeset are always cloned as public. There's | |
681 | no obsolescence markers exchange in stream v1. |
|
663 | no obsolescence markers exchange in stream v1. | |
682 |
|
664 | |||
683 | #endif |
|
665 | #endif | |
684 | #if stream-bundle2-v2 |
|
666 | #if stream-bundle2-v2 | |
685 |
|
667 | |||
686 | Stream repository with obsolescence |
|
668 | Stream repository with obsolescence | |
687 | ----------------------------------- |
|
669 | ----------------------------------- | |
688 |
|
670 | |||
689 | Clone non-publishing with obsolescence |
|
671 | Clone non-publishing with obsolescence | |
690 |
|
672 | |||
691 | $ cat >> $HGRCPATH << EOF |
|
673 | $ cat >> $HGRCPATH << EOF | |
692 | > [experimental] |
|
674 | > [experimental] | |
693 | > evolution=all |
|
675 | > evolution=all | |
694 | > EOF |
|
676 | > EOF | |
695 |
|
677 | |||
696 | $ cd server |
|
678 | $ cd server | |
697 | $ echo foo > foo |
|
679 | $ echo foo > foo | |
698 | $ hg -q commit -m 'about to be pruned' |
|
680 | $ hg -q commit -m 'about to be pruned' | |
699 | $ hg debugobsolete `hg log -r . -T '{node}'` -d '0 0' -u test --record-parents |
|
681 | $ hg debugobsolete `hg log -r . -T '{node}'` -d '0 0' -u test --record-parents | |
700 | 1 new obsolescence markers |
|
682 | 1 new obsolescence markers | |
701 | obsoleted 1 changesets |
|
683 | obsoleted 1 changesets | |
702 | $ hg up null -q |
|
684 | $ hg up null -q | |
703 | $ hg log -T '{rev}: {phase}\n' |
|
685 | $ hg log -T '{rev}: {phase}\n' | |
704 | 2: draft |
|
686 | 2: draft | |
705 | 1: draft |
|
687 | 1: draft | |
706 | 0: draft |
|
688 | 0: draft | |
707 | $ hg serve -p $HGPORT -d --pid-file=hg.pid |
|
689 | $ hg serve -p $HGPORT -d --pid-file=hg.pid | |
708 | $ cat hg.pid > $DAEMON_PIDS |
|
690 | $ cat hg.pid > $DAEMON_PIDS | |
709 | $ cd .. |
|
691 | $ cd .. | |
710 |
|
692 | |||
711 | $ hg clone -U --stream http://localhost:$HGPORT with-obsolescence |
|
693 | $ hg clone -U --stream http://localhost:$HGPORT with-obsolescence | |
712 | streaming all changes |
|
694 | streaming all changes | |
713 | 1099 files to transfer, 102 KB of data (no-zstd !) |
|
695 | 1099 files to transfer, 102 KB of data (no-zstd !) | |
714 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
696 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
715 | 1099 files to transfer, 99.5 KB of data (zstd no-rust !) |
|
697 | 1099 files to transfer, 99.5 KB of data (zstd no-rust !) | |
716 | transferred 99.5 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
698 | transferred 99.5 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
717 | 1101 files to transfer, 99.6 KB of data (zstd rust !) |
|
699 | 1101 files to transfer, 99.6 KB of data (zstd rust !) | |
718 | transferred 99.6 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
700 | transferred 99.6 KB in * seconds (* */sec) (glob) (zstd rust !) | |
719 | $ hg -R with-obsolescence log -T '{rev}: {phase}\n' |
|
701 | $ hg -R with-obsolescence log -T '{rev}: {phase}\n' | |
720 | 2: draft |
|
702 | 2: draft | |
721 | 1: draft |
|
703 | 1: draft | |
722 | 0: draft |
|
704 | 0: draft | |
723 | $ hg debugobsolete -R with-obsolescence |
|
705 | $ hg debugobsolete -R with-obsolescence | |
724 | 8c206a663911c1f97f2f9d7382e417ae55872cfa 0 {5223b5e3265f0df40bb743da62249413d74ac70f} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
706 | 8c206a663911c1f97f2f9d7382e417ae55872cfa 0 {5223b5e3265f0df40bb743da62249413d74ac70f} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
725 | $ hg verify -R with-obsolescence -q |
|
707 | $ hg verify -R with-obsolescence -q | |
726 |
|
708 | |||
727 | $ hg clone -U --stream --config experimental.evolution=0 http://localhost:$HGPORT with-obsolescence-no-evolution |
|
709 | $ hg clone -U --stream --config experimental.evolution=0 http://localhost:$HGPORT with-obsolescence-no-evolution | |
728 | streaming all changes |
|
710 | streaming all changes | |
729 | remote: abort: server has obsolescence markers, but client cannot receive them via stream clone |
|
711 | remote: abort: server has obsolescence markers, but client cannot receive them via stream clone | |
730 | abort: pull failed on remote |
|
712 | abort: pull failed on remote | |
731 | [100] |
|
713 | [100] | |
732 |
|
714 | |||
733 | $ killdaemons.py |
|
715 | $ killdaemons.py | |
734 |
|
716 | |||
735 | #endif |
|
717 | #endif | |
736 | #if stream-bundle2-v3 |
|
718 | #if stream-bundle2-v3 | |
737 |
|
719 | |||
738 | Stream repository with obsolescence |
|
720 | Stream repository with obsolescence | |
739 | ----------------------------------- |
|
721 | ----------------------------------- | |
740 |
|
722 | |||
741 | Clone non-publishing with obsolescence |
|
723 | Clone non-publishing with obsolescence | |
742 |
|
724 | |||
743 | $ cat >> $HGRCPATH << EOF |
|
725 | $ cat >> $HGRCPATH << EOF | |
744 | > [experimental] |
|
726 | > [experimental] | |
745 | > evolution=all |
|
727 | > evolution=all | |
746 | > EOF |
|
728 | > EOF | |
747 |
|
729 | |||
748 | $ cd server |
|
730 | $ cd server | |
749 | $ echo foo > foo |
|
731 | $ echo foo > foo | |
750 | $ hg -q commit -m 'about to be pruned' |
|
732 | $ hg -q commit -m 'about to be pruned' | |
751 | $ hg debugobsolete `hg log -r . -T '{node}'` -d '0 0' -u test --record-parents |
|
733 | $ hg debugobsolete `hg log -r . -T '{node}'` -d '0 0' -u test --record-parents | |
752 | 1 new obsolescence markers |
|
734 | 1 new obsolescence markers | |
753 | obsoleted 1 changesets |
|
735 | obsoleted 1 changesets | |
754 | $ hg up null -q |
|
736 | $ hg up null -q | |
755 | $ hg log -T '{rev}: {phase}\n' |
|
737 | $ hg log -T '{rev}: {phase}\n' | |
756 | 2: draft |
|
738 | 2: draft | |
757 | 1: draft |
|
739 | 1: draft | |
758 | 0: draft |
|
740 | 0: draft | |
759 | $ hg serve -p $HGPORT -d --pid-file=hg.pid |
|
741 | $ hg serve -p $HGPORT -d --pid-file=hg.pid | |
760 | $ cat hg.pid > $DAEMON_PIDS |
|
742 | $ cat hg.pid > $DAEMON_PIDS | |
761 | $ cd .. |
|
743 | $ cd .. | |
762 |
|
744 | |||
763 | $ hg clone -U --stream http://localhost:$HGPORT with-obsolescence |
|
745 | $ hg clone -U --stream http://localhost:$HGPORT with-obsolescence | |
764 | streaming all changes |
|
746 | streaming all changes | |
765 | 1098 entries to transfer |
|
747 | 1098 entries to transfer | |
766 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) |
|
748 | transferred 102 KB in * seconds (* */sec) (glob) (no-zstd !) | |
767 | transferred 99.5 KB in * seconds (* */sec) (glob) (zstd no-rust !) |
|
749 | transferred 99.5 KB in * seconds (* */sec) (glob) (zstd no-rust !) | |
768 | transferred 99.6 KB in * seconds (* */sec) (glob) (zstd rust !) |
|
750 | transferred 99.6 KB in * seconds (* */sec) (glob) (zstd rust !) | |
769 | $ hg -R with-obsolescence log -T '{rev}: {phase}\n' |
|
751 | $ hg -R with-obsolescence log -T '{rev}: {phase}\n' | |
770 | 2: draft |
|
752 | 2: draft | |
771 | 1: draft |
|
753 | 1: draft | |
772 | 0: draft |
|
754 | 0: draft | |
773 | $ hg debugobsolete -R with-obsolescence |
|
755 | $ hg debugobsolete -R with-obsolescence | |
774 | 8c206a663911c1f97f2f9d7382e417ae55872cfa 0 {5223b5e3265f0df40bb743da62249413d74ac70f} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} |
|
756 | 8c206a663911c1f97f2f9d7382e417ae55872cfa 0 {5223b5e3265f0df40bb743da62249413d74ac70f} (Thu Jan 01 00:00:00 1970 +0000) {'user': 'test'} | |
775 | $ hg verify -R with-obsolescence -q |
|
757 | $ hg verify -R with-obsolescence -q | |
776 |
|
758 | |||
777 | $ hg clone -U --stream --config experimental.evolution=0 http://localhost:$HGPORT with-obsolescence-no-evolution |
|
759 | $ hg clone -U --stream --config experimental.evolution=0 http://localhost:$HGPORT with-obsolescence-no-evolution | |
778 | streaming all changes |
|
760 | streaming all changes | |
779 | remote: abort: server has obsolescence markers, but client cannot receive them via stream clone |
|
761 | remote: abort: server has obsolescence markers, but client cannot receive them via stream clone | |
780 | abort: pull failed on remote |
|
762 | abort: pull failed on remote | |
781 | [100] |
|
763 | [100] | |
782 |
|
764 | |||
783 | $ killdaemons.py |
|
765 | $ killdaemons.py | |
784 |
|
766 | |||
785 | #endif |
|
767 | #endif | |
786 |
|
768 | |||
787 | Cloning a repo with no requirements doesn't give some obscure error |
|
769 | Cloning a repo with no requirements doesn't give some obscure error | |
788 |
|
770 | |||
789 | $ mkdir -p empty-repo/.hg |
|
771 | $ mkdir -p empty-repo/.hg | |
790 | $ hg clone -q --stream ssh://user@dummy/empty-repo empty-repo2 |
|
772 | $ hg clone -q --stream ssh://user@dummy/empty-repo empty-repo2 | |
791 | $ hg --cwd empty-repo2 verify -q |
|
773 | $ hg --cwd empty-repo2 verify -q | |
792 |
|
774 | |||
793 | Cloning a repo with an empty manifestlog doesn't give some weird error |
|
775 | Cloning a repo with an empty manifestlog doesn't give some weird error | |
794 |
|
776 | |||
795 | $ rm -r empty-repo; hg init empty-repo |
|
777 | $ rm -r empty-repo; hg init empty-repo | |
796 | $ (cd empty-repo; touch x; hg commit -Am empty; hg debugstrip -r 0) > /dev/null |
|
778 | $ (cd empty-repo; touch x; hg commit -Am empty; hg debugstrip -r 0) > /dev/null | |
797 | $ hg clone -q --stream ssh://user@dummy/empty-repo empty-repo3 |
|
779 | $ hg clone -q --stream ssh://user@dummy/empty-repo empty-repo3 | |
798 | $ hg --cwd empty-repo3 verify -q 2>&1 | grep -v warning |
|
780 | $ hg --cwd empty-repo3 verify -q 2>&1 | grep -v warning | |
799 | [1] |
|
781 | [1] | |
800 |
|
782 | |||
801 | The warnings filtered out here are talking about zero-length 'orphan' data files. |
|
783 | The warnings filtered out here are talking about zero-length 'orphan' data files. | |
802 | Those are harmless, so that's fine. |
|
784 | Those are harmless, so that's fine. | |
803 |
|
785 |
General Comments 0
You need to be logged in to leave comments.
Login now