Summary:
Core hg now has support for writing bundle2 bundles. Those bundles are not
readable by older versions of Mercurial though, so we need to first deploy a
mercurial that can read the new, but writes the old, then later we will begin
writing the new as well.
Test Plan:
Created a bundle with my local machine that had the latest hg, and
handed it to a piece of infrastructure that unbundled it using the old hg.
Reviewers: #sourcecontrol, rmcelroy, sid0
Reviewed By: rmcelroy, sid0
Subscribers: rmcelroy
Differential Revision: https://phabricator.fb.com/D2587398
Signature: t1:2587398:1446027602:f711941d49ed8b1b40330c4a6bc21949b3461c10
Summary:
According to pyd, Mercurial core now writes bundle2 bundles when the repo is
generaldelta, so we don't need this anymore. Plus we're using evolve now so
we're not producing many bundles anyway.
The motivation for disabling this is that the code broke due to changes from
upstream, and I was too lazy to fix it.
Test Plan: nope
Reviewers: pyd, ericsumner, #sourcecontrol
Differential Revision: https://phabricator.fb.com/D2538749
Our hack for preventing overbundling was incorrect. Upstream has 22c0e29cfb77
which is the right fix.
We're also seeing missing manifest revisions in bundles for some users, so this
change (or the one upstream), might be exposing a deeper bug in the general
delta bundle creation.
Summary:
Fix node computation in overridechangegroupsubset(). Previously it could
return many nodes that weren't descendants of any of the roots.
Say you had a tree like this:
A E
| |
B D
|/
C
If you tried to strip A and B, the old code would set discbases to [C],
and incorrectly include D and E in the returned results.
This bug also exists in the upstream changegroup.changegroupsubset() function.
We should probably fix it there too.
Test Plan:
Confirmed that 'hg strip -v' didn't grossly overreport how many commits needed
to be included in the bundle. In my test case the old code incorrectly put
15k+ commits in the bundle, instead of just the 4 commits being stripped.
Reviewers: pyd, mpm, ericsumner, durham
Reviewed By: durham
Subscribers: ericsumner, net-systems@, exa
Differential Revision: https://phabricator.fb.com/D2150067
Tasks: 7391096
Signature: t1:2150067:1434410675:f7e2520e9b7783e97b69c898b3f447a3e7cb2763
Summary:
Upstream has finalized bundle2 and removed the experimental flags. So let's
upgrade along with it.
Test Plan: Ran the tests
Reviewers: sid0, rmcelroy, lcharignon, pyd, ericsumner
Differential Revision: https://phabricator.fb.com/D2003046
Summary:
Through experiments we've found that for highly interleaved histories, generating a changegroup2 can be 6-7x as slow as generating a changegroup1.
While we work this out upstream, ship an extension to write changegroup2s out to disk.
Note that we'll only write cg2s for strips (and related operations like amend) -- for regular bundles we'll continue to write changegroup1 for maximum compatibility.
Test Plan:
Ran the included tests. Also ran the full Mercurial test suite with:
```
python run-tests.py -j32 --extra-config-opt extensions.writecg2=/home/sid0/local/fb-hgext/writecg2.py
```
Finally, tried it out in fbobjc. Found a 6x gain in strip performance with this extension enabled.
Reviewers: durham, davidsp, rmcelroy, akushner, daviser, mitrandir, ericsumner, pyd
Reviewed By: pyd
Differential Revision: https://phabricator.fb.com/D1774334
Signature: t1:1774334:1420844207:461b830aafd7728ea3b5593fe0a02f6f66444ec3