Browse Source
When fetching remote objects, WalkFetchConnection searches remote packs in the order provided by WalkRemoteObjectDatabase:getPackNames. Previously, for TransportAmazonS3, the packs were in no particular order. This resulted in potential many extra calls to get pack idx files. This change modifies TransportAmazonS3 and AmazonS3 so that getPackNames returns a list sorted with the most recently modified packs first. In the case of fetching recent changes to a repo, this dramatically reduces the number of packs searched and speeds up fetch. Note: WalkRemoteObjectDatabase::getPackNames does not specify the order of the returned names. Testing: did "mvn clean install" in root dir and all tests passed. And manually constructed some S3 repos and using jgit.sh confirmed that the freshest pack was checked first. Change-Id: I3b968fee825e793be55566e28c2d69d0cbe53807 Signed-off-by: Joshua Redstone <redstone@gmail.com> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>stable-5.8
Joshua Redstone
5 years ago
committed by
Matthias Sohn
2 changed files with 54 additions and 9 deletions
Loading…
Reference in new issue