comparison tests/test-rebase-conflicts.t @ 36965:b89a7ef29013

bundle: include advisory rev branch cache part in bundle2 bundle `hg bundle` command producing bundle2 will now include an optional part containing the revision-branch cache data. The data sent are mostly nodes so it is quite compact. The goal of the rev-branch-cache is to speed up branch map computation, especially when the branchmap gets invalidated so we send data for all exchanged changesets. In addition, computing the relevant heads to send in case of partial pulling would be challenging. As a reminder, the rev branch cache data significantly speed up branch computation. Having it around provides a small speedup to pull/clone and much higher tolerance to branch map cache invalidation that might happens from later commands. On the Mercurial repository, computing the visible branchmap from scratch move from 2.00 seconds to 0.34s (a -83% speedup). Using this new part, Unbundling the full Mercurial repository moves from 25.736 seconds to 24.030 seconds (around -7% speedup). The bundle size increase is around 3% (from 22.43 MB to 23.13MB) On an half a million revision repository with twenty thousand branches, computing the branchmap moves from 75 seconds to 45 second (-40%) if the caches is used. A bundle containing 50 000 changesets in such repository get a 0.5% size increase from such part for a -3% unbundling time speedup.
author Boris Feld <boris.feld@octobus.net>
date Wed, 21 Feb 2018 17:33:00 +0100
parents 4441705b7111
children 2090044a288d
comparison
equal deleted inserted replaced
36964:79b73be4dda5 36965:b89a7ef29013
295 getting f2.txt 295 getting f2.txt
296 2 changesets found 296 2 changesets found
297 list of changesets: 297 list of changesets:
298 e31216eec445e44352c5f01588856059466a24c9 298 e31216eec445e44352c5f01588856059466a24c9
299 2f2496ddf49d69b5ef23ad8cf9fb2e0e4faf0ac2 299 2f2496ddf49d69b5ef23ad8cf9fb2e0e4faf0ac2
300 bundle2-output-bundle: "HG20", (1 params) 2 parts total 300 bundle2-output-bundle: "HG20", (1 params) 3 parts total
301 bundle2-output-part: "changegroup" (params: 1 mandatory 1 advisory) streamed payload 301 bundle2-output-part: "changegroup" (params: 1 mandatory 1 advisory) streamed payload
302 bundle2-output-part: "cache:rev-branch-cache" streamed payload
302 bundle2-output-part: "phase-heads" 24 bytes payload 303 bundle2-output-part: "phase-heads" 24 bytes payload
303 saved backup bundle to $TESTTMP/issue4041/.hg/strip-backup/e31216eec445-15f7a814-rebase.hg 304 saved backup bundle to $TESTTMP/issue4041/.hg/strip-backup/e31216eec445-15f7a814-rebase.hg
304 3 changesets found 305 3 changesets found
305 list of changesets: 306 list of changesets:
306 4c9fbe56a16f30c0d5dcc40ec1a97bbe3325209c 307 4c9fbe56a16f30c0d5dcc40ec1a97bbe3325209c
307 19c888675e133ab5dff84516926a65672eaf04d9 308 19c888675e133ab5dff84516926a65672eaf04d9
308 2a7f09cac94c7f4b73ebd5cd1a62d3b2e8e336bf 309 2a7f09cac94c7f4b73ebd5cd1a62d3b2e8e336bf
309 bundle2-output-bundle: "HG20", 2 parts total 310 bundle2-output-bundle: "HG20", 3 parts total
310 bundle2-output-part: "changegroup" (params: 1 mandatory 1 advisory) streamed payload 311 bundle2-output-part: "changegroup" (params: 1 mandatory 1 advisory) streamed payload
312 bundle2-output-part: "cache:rev-branch-cache" streamed payload
311 bundle2-output-part: "phase-heads" 24 bytes payload 313 bundle2-output-part: "phase-heads" 24 bytes payload
312 adding branch 314 adding branch
313 bundle2-input-bundle: with-transaction 315 bundle2-input-bundle: with-transaction
314 bundle2-input-part: "changegroup" (params: 1 mandatory 1 advisory) supported 316 bundle2-input-part: "changegroup" (params: 1 mandatory 1 advisory) supported
315 adding changesets 317 adding changesets
319 adding manifests 321 adding manifests
320 adding file changes 322 adding file changes
321 adding f1.txt revisions 323 adding f1.txt revisions
322 added 2 changesets with 2 changes to 1 files 324 added 2 changesets with 2 changes to 1 files
323 bundle2-input-part: total payload size 1686 325 bundle2-input-part: total payload size 1686
326 bundle2-input-part: "cache:rev-branch-cache" supported
327 bundle2-input-part: total payload size 74
324 bundle2-input-part: "phase-heads" supported 328 bundle2-input-part: "phase-heads" supported
325 bundle2-input-part: total payload size 24 329 bundle2-input-part: total payload size 24
326 bundle2-input-bundle: 1 parts total 330 bundle2-input-bundle: 2 parts total
327 updating the branch cache 331 updating the branch cache
328 invalid branchheads cache (served): tip differs 332 invalid branchheads cache (served): tip differs
329 rebase completed 333 rebase completed
334 truncating cache/rbc-revs-v1 to 0
330 335
331 Test minimization of merge conflicts 336 Test minimization of merge conflicts
332 $ hg up -q null 337 $ hg up -q null
333 $ echo a > a 338 $ echo a > a
334 $ hg add a 339 $ hg add a