author | Shawn O. Pearce <spearce@spearce.org> | |
Tue, 15 Mar 2011 00:59:40 +0000 (17:59 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 15 Mar 2011 19:14:35 +0000 (12:14 -0700) | ||
commit | 3e63b21aced116badd30a279c479535449a63560 | |
tree | 665e66ec370b0f53c3e5634c1e27f6f4cff81d86 | tree | snapshot |
parent | 49bee717f7080f99d3405682cc43ad525dde0973 | commit | diff |
upload-pack: Implement no-done capability
If the client requests both multi_ack_detailed and no-done then
upload-pack is free to immediately send a PACK following its first
'ACK %s ready' message. The upload-pack response actually winds
up being:
ACK %s common
... (maybe more) ...
ACK %s ready
NAK
ACK %s
PACK.... the pack stream ....
For smart HTTP connections this saves one HTTP RPC, reducing
the overall latency for a trivial fetch. For git:// and ssh://
a no-done option slightly reduces latency by removing one
server->client->server round-trip at the end of the common
ancestor negotiation.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
If the client requests both multi_ack_detailed and no-done then
upload-pack is free to immediately send a PACK following its first
'ACK %s ready' message. The upload-pack response actually winds
up being:
ACK %s common
... (maybe more) ...
ACK %s ready
NAK
ACK %s
PACK.... the pack stream ....
For smart HTTP connections this saves one HTTP RPC, reducing
the overall latency for a trivial fetch. For git:// and ssh://
a no-done option slightly reduces latency by removing one
server->client->server round-trip at the end of the common
ancestor negotiation.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
upload-pack.c | diff | blob | history |