Skip to content

RFC Design for offloading part of packfile response to CDN

Jonathan Tan git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest5 patches 24 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5Documentation: order protocol v2 sectionsDocumentation/technical/protocol-v2.txt+8 -103 replies
2/5Documentation: add Packfile URIs design docDocumentation/technical/packfile-uri.txt Documentation/technical/protocol-v2.txt+88 -114 replies
3/5upload-pack: refactor reading of pack-objects outupload-pack.c+46 -342 replies
4/5upload-pack: refactor writing of "packfile" lineupload-pack.c+36 -113 replies
5/5upload-pack: send part of packfile response as uribuiltin/pack-objects.c fetch-pack.c t/t5702-protocol-v2.sh +1 more+115 -41 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [WIP RFC 0/5] Design for offloading part of packfile response to CDN

Some of us have been working on a design to improve the scalability of Git servers by allowing them to offload part of the packfile response to CDNs in this way: returning HTTP(S) URIs in fetch responses in addition to packfiles.

This can reduce the load on individual Git servers and improves proximity (by having data served from closer to the user).

I have included here a design document (patch 2) and a rough implementation of the server (patch 5). Currently, the implementation only allows replacing single blobs with URIs, but the protocol improvement is designed in such a way as to allow independent improvement of Git server implementations.

There is a potential issue: a server which produces both the URIs and the packfile at roughly the same time (like the implementation in this patch set) will not have sideband access until it has concluded sending the URIs. Among other things, this means that the server cannot send keepalive packets until quite late in the response. One solution to this might be to add a feature that allows the server to use a sideband throughout the whole response - and this has other benefits too like allowing servers to inform the client throughout the whole fetch, not just at the end.

Jonathan Tan (5):
Documentation: order protocol v2 sections
Documentation: add Packfile URIs design doc
upload-pack: refactor reading of pack-objects out
upload-pack: refactor writing of "packfile" line
upload-pack: send part of packfile response as uri

 Documentation/technical/packfile-uri.txt |  83 +++++++++++++
 Documentation/technical/protocol-v2.txt  |  22 ++--
 builtin/pack-objects.c                   |  48 ++++++++
 fetch-pack.c                             |   9 ++
 t/t5702-protocol-v2.sh                   |  25 ++++
 upload-pack.c                            | 150 ++++++++++++++++-------
 6 files changed, 285 insertions(+), 52 deletions(-)
 create mode 100644 Documentation/technical/packfile-uri.txt
Signature · 1 line
2.19.0.271.gfe8321ec05.dirty