Bug 3386 - largefiles: bulk-check and bulk-upload largefiles
Summary: largefiles: bulk-check and bulk-upload largefiles
Status: RESOLVED FIXED
Alias: None
Product: Mercurial
Classification: Unclassified
Component: largefiles (show other bugs)
Version: unspecified
Hardware: All All
: wish feature
Assignee: Na'Tosha Bard
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-04-19 14:05 UTC by Kevin Gessner
Modified: 2012-09-30 16:19 UTC (History)
7 users (show)

See Also:
Python Version: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Gessner 2012-04-19 14:05 UTC
When pushing a largefiles repo with N largefiles, we make N requests to see if 
each file exists on the server. We should batch these into a single request.

For the N' largefiles that are missing from the server, we do N' uploads. We 
should batch these, probably with a multi-part POST.

The per-request overhead can add up substantially, especially when SSL 
handshakes are involved.
Comment 1 Martin Geisler 2012-04-19 15:23 UTC
Great point! I remember Lantiq saying that the overhead in bfiles (and hence 
largefiles) was one of the reasons they began writing the snap extension. 
Apparently they had some 20,000 files, each 10 MB in size, and even a 100 ms 
overhead per file will then make 'hg push' take 40 minuttes extra (even if 
nothing needs to be uploaded).
Comment 2 Na'Tosha Bard 2012-04-20 03:47 UTC
This is partially related to issue3160

The general plan has been that we want to implement an http connection pool
and use that instead of what we're doing now but, no one has done it yet.

The problem could also be fixed with what Kevin describes below, but of
course someone needs to do it :-P

Na'Tosha
Comment 3 Matt Mackall 2012-04-20 11:47 UTC
The current wire protocol code already supports request batching generically.
Comment 4 Bugzilla 2012-05-12 09:30 UTC

--- Bug imported by bugzilla@serpentine.com 2012-05-12 09:30 EDT  ---

This bug was previously known as _bug_ 3385 at http://mercurial.selenic.com/bts/issue3385
Comment 5 Na'Tosha Bard 2012-06-24 14:43 UTC
Patch for batching the statlfile command submitted to the list here:

http://www.selenic.com/pipermail/mercurial-devel/2012-June/042013.html
Comment 6 Matt Mackall 2012-07-29 15:08 UTC
Fixed in stable by:

9e1616307c4c largefiles: batch statlfile requests when pushing a largefiles repo
Comment 7 Matt Mackall 2012-09-30 16:19 UTC
Mass close old bugs in testing.