diff options
author | Jeff King <peff@peff.net> | 2016-07-15 06:34:22 -0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-07-20 12:11:10 -0700 |
commit | e376f17fd1a1efd4fe425d023610172bcba3fe97 (patch) | |
tree | 528f67a0b217180ddb4cebe82e06c8df882dfd28 /xdiff | |
parent | clone: use a real progress meter for connectivity check (diff) | |
download | tgif-e376f17fd1a1efd4fe425d023610172bcba3fe97.tar.xz |
index-pack: add flag for showing delta-resolution progress
The index-pack command has two progress meters: one for
"receiving objects", and one for "resolving deltas". You get
neither by default, or both with "-v".
But for a push through receive-pack, we would want only the
"resolving deltas" phase, _not_ the "receiving objects"
progress. There are two reasons for this.
One is simply that existing clients are already printing
"writing objects" progress at the same time. Arguably
"receiving" from the far end is more useful, because it
tells you what has actually gotten there, as opposed to what
might be stuck in a buffer somewhere between the client and
server. But that would require a protocol extension to tell
clients not to print their progress. Possible, but
complexity for little gain.
The second reason is much more important. In a full-duplex
connection like git-over-ssh, we can print progress while
the pack is incoming, and it will immediately get to the
client. But for a half-duplex connection like git-over-http,
we should not say anything until we have received the full
request. Anything we write is subject to being stuck in a
buffer by the webserver. Worse, we can end up in a deadlock
if that buffer fills up.
So our best bet is to avoid writing anything that isn't a
small fixed size until we've received the full pack.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'xdiff')
0 files changed, 0 insertions, 0 deletions