'bzr branch --stacked' makes empty repo then builds a working tree with inefficient fetching
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
In Progress
|
High
|
John A Meinel |
Bug Description
When doing a 'bzr branch --stacked' from a smart server that builds a working tree (the default scenario, i.e. --no-tree is not used, and not in a shared repo with working trees disabled), then it creates an empty repository and then starts the build-tree logic. This slowly walks the inventory and fetches texts individually, and doesn't cache any of that data in the local repo when done.
It would take far fewer network roundtrips (especially HPSS VFS ones), and greatly reduce bytes transferred, to instead ask the remote server to stream just the revision+
I have a rough branch that does this by:
* define a new fetch spec for that
* in BzrDir.sprout if we have a new stacked repository and are building a working tree, use that fetch spec
* extend the StreamSource to understand that fetch spec.
This also has the benefit that the data that is being fetched anyway is saved in the local repo to benefit future operations (as well as fetching that data much much more effiiciently).
Related branches
- Vincent Ladeuil: Needs Information
-
Diff: 627 lines (+280/-50) (has conflicts)11 files modifiedbzrlib/bzrdir.py (+22/-4)
bzrlib/chk_map.py (+9/-0)
bzrlib/graph.py (+109/-0)
bzrlib/remote.py (+4/-1)
bzrlib/repofmt/groupcompress_repo.py (+56/-3)
bzrlib/smart/repository.py (+4/-0)
bzrlib/tests/blackbox/test_branch.py (+2/-3)
bzrlib/tests/per_branch/test_stacking.py (+12/-10)
bzrlib/tests/per_repository_reference/test_commit_with_stacking.py (+11/-17)
bzrlib/tests/test_remote.py (+49/-11)
bzrlib/tests/test_repository.py (+2/-1)
- Vincent Ladeuil: Pending requested
-
Diff: 741 lines (+284/-80)14 files modifiedbzrlib/__init__.py (+4/-7)
bzrlib/bzrdir.py (+21/-4)
bzrlib/chk_map.py (+9/-0)
bzrlib/remote.py (+5/-3)
bzrlib/repofmt/groupcompress_repo.py (+56/-3)
bzrlib/smart/repository.py (+4/-0)
bzrlib/tests/blackbox/test_branch.py (+2/-3)
bzrlib/tests/per_branch/test_stacking.py (+12/-10)
bzrlib/tests/per_repository/test_commit_builder.py (+19/-13)
bzrlib/tests/per_repository_reference/test_commit_with_stacking.py (+11/-17)
bzrlib/tests/test_remote.py (+42/-19)
bzrlib/tests/test_repository.py (+2/-1)
bzrlib/vf_search.py (+93/-0)
doc/en/release-notes/bzr-2.5.txt (+4/-0)
Changed in bzr: | |
status: | Confirmed → In Progress |
(This may help bug 444293 too)