git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jonathan Tan <jonathantanmy@google.com>
To: git@vger.kernel.org
Cc: Jonathan Tan <jonathantanmy@google.com>
Subject: [RFC 0/4] Implementation of fetch-blobs and fetch-refs
Date: Mon, 10 Apr 2017 13:46:06 -0700	[thread overview]
Message-ID: <cover.1491851452.git.jonathantanmy@google.com> (raw)

My previous proposal about a possible new server endpoint that serves
blobs and refs [1] didn't seem to garner much interest, so I thought I'd
provide a possible implementation of that proposal as a work in
progress.

In particular, patch 1 demonstrates that a new server endpoint that
serves refs without the initial ref advertisement can be done in 228
lines of code (according to "git diff --stat") while accounting for the
various special cases that upload-pack imposes (stateless RPC, inclusion
of an additional response when depth is requested, handling of "done" in
request, sending a packfile directly after a response containing "ACK
ready" without waiting for "done", and so on).

I'm hoping that these features would be of more interest to more people.
To that end, I'm sending these patches in the hope of showing that these
features are useful (omitting ref advertisements help greatly when
serving large repos, as described in the commit message of patch 1, and
serving blobs is useful for any fetch-blob-on-demand repo scheme) and
that my proposed way of implementing them can be done in a relatively
uncomplicated manner (as seen in these patches).

Patch 1-3 show what serving refs without the advertisement would look
like from the server's and fetch-pack's points of view. Patch 4 is
similar to some of the other blob-serving patches except that this
contains reachability checks and that this bundles the resulting objects
in a packfile.

[1] <ffd92ad9-39fe-c76b-178d-6e3d6a425037@google.com>

Jonathan Tan (4):
  server-endpoint: serve refs without advertisement
  fetch-pack: refactor "want" pkt-line generation
  fetch-pack: support new server endpoint
  server-endpoint: serve blobs by hash

 .gitignore                 |   1 +
 Makefile                   |   3 +
 builtin/fetch-pack.c       |  10 +-
 fetch-pack.c               | 129 +++++++++++------
 fetch-pack.h               |   1 +
 server-endpoint.c          | 347 +++++++++++++++++++++++++++++++++++++++++++++
 t/helper/.gitignore        |   1 +
 t/helper/test-un-pkt.c     |  40 ++++++
 t/t5573-server-endpoint.sh |  60 ++++++++
 t/t9999-mytests.sh         | 242 +++++++++++++++++++++++++++++++
 10 files changed, 790 insertions(+), 44 deletions(-)
 create mode 100644 server-endpoint.c
 create mode 100644 t/helper/test-un-pkt.c
 create mode 100644 t/t5573-server-endpoint.sh
 create mode 100644 t/t9999-mytests.sh

-- 
2.12.2.715.g7642488e1d-goog


             reply	other threads:[~2017-04-10 20:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-10 20:46 Jonathan Tan [this message]
2017-04-10 20:46 ` [RFC 1/4] server-endpoint: serve refs without advertisement Jonathan Tan
2017-04-10 20:46 ` [RFC 2/4] fetch-pack: refactor "want" pkt-line generation Jonathan Tan
2017-04-10 20:46 ` [RFC 3/4] fetch-pack: support new server endpoint Jonathan Tan
2017-04-10 20:46 ` [RFC 4/4] server-endpoint: serve blobs by hash Jonathan Tan
2017-06-30 22:41 ` [RFC 0/4] Implementation of fetch-blobs and fetch-refs Stefan Beller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cover.1491851452.git.jonathantanmy@google.com \
    --to=jonathantanmy@google.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).