Network performance problems when pulling and cloning from HTTP server

Scott Palmer swpalmer at gmail.com
Thu Nov 22 23:05:35 UTC 2012


On 2012-11-22, at 5:05 PM, Augie Fackler <raf at durin42.com> wrote:

> 
> On Nov 22, 2012, at 7:03 AM, Angel Ezquerra <ezquerra at gmail.com> wrote:
> 
>> On Wed, Nov 21, 2012 at 10:24 PM, Matt Mackall <mpm at selenic.com> wrote:
>>> On Wed, 2012-11-21 at 08:02 +0100, Angel Ezquerra wrote:
>>>> On Nov 20, 2012 6:55 PM, "Bryan O'Sullivan" <bos at serpentine.com> wrote:
>>>>> 
>>>>> On Tue, Nov 20, 2012 at 8:30 AM, Angel Ezquerra <ezquerra at gmail.com> wrote:
>> 
>> Matt, thanks for pitching in.
>> 
>> I understand now the need to get the hashes, usernames, dates and
>> descriptions. As for also getting the diffs, that would only happen
>> when using the --bundle option, right? That is, calling a plain "hg
>> incoming" (without --bundle) should be pretty fast regardless of the
>> contents of the changesets themselves. Is that correct?
> 
> Sadly no, incoming pulls a complete bundle, then throws it on the floor when done. In fact, 'hg help incoming' tells you that '--bundle FILE' lets you save the requested bundle to a file so you can apply it later.
> 
>> 
>>>> In any case, may I ask why you are not surprised by this?
>>> 
>>> You've hit the trifecta of ways to have suboptimal performance:
>>> 
>>> a) Windows
>>> b) large files
>>> c) using a protocol designed for broadband and slower on a LAN
>> 
>> By protocol you mean the underlying http or mercurial's own protocol?
> 
> hg's own protocol, which can use http (or ssh) as a transport.
> 
> 
>>>>> Do you have the ability to serve the repo that shows poor performance using "hg serve"? If so, it would be helpful to "hg serve --profile", do a pull from a client, then stop the server and share the profile dump.
>>>> C:\mercurial_tests\tmp_bigfiles_not_large>hg serve --port 7000
>>>> --profile --verbose
>>> 
>>> ..no profile. A profile looks like this:
>>> 
>>> $ hg serve --profile
>>> listening at http://calx:8000/ (bound to *:8000)
>>> [do something]
>>> [hit ctrl-c]
>>>  CallCount    Recursive     Total(s)    Inline(s) module:lineno(function)
>>>          4            0      1.5059      1.5058   <select.select>
>>>         57           46      0.0052      0.0036   <__import__>
>>>          1            0      0.0025      0.0013   mimetypes:205(readfp)
>>>        684            0      0.0006      0.0005   mercurial.config:20(__setitem__)
>>>        665            0      0.0007      0.0005   mimetypes:78(add_type)
>>>          2            0      0.0004      0.0004   <_socket.gethostbyaddr>
>>>         80            0      0.0008      0.0003   mercurial.config:27(update)
>>>        971            0      0.0003      0.0003   <method 'split' of 'str' objects>
>>> 
>> 
>> Sorry, I did not know that.
>> 
>> Unfortunately, I cannot get --profile to work. Whenever I use Ctrl+C
>> to stop the server it just exits without printing any profile
>> information.

I can confirm on Windows 7 with "Mercurial Distributed SCM (version 2.3.2)" from TortoiseHG 2.5.1, that terminating "hg server --profile" with CTRL-C does NOT output anything to the console.

Scott




More information about the Mercurial mailing list