76 lines · 3.7 KB · Markdown
RawDownload

Cloning

  • gixp-pack-receive
    • a program to (initially only) clone from a given URL, storing a full pack with index only. No support for git-refs.
    • git-packetline
      • pkt-lines support
      • Don't forcibly remove newlines at the end of pack lines, but make that an extra step.
      • decode band should be able to fail
      • PacketLine 'Iterator' from Read
      • Read from packet lines with sideband
        • Progress parsing, with 'info(…)' fallback if that fails
        • SetName in Progress trait (to allow setting the correct progress information)
        • Disable sideband support (e.g. github http V2 doesn't have it)
      • don't coerce line delimiters into empty slices.
      • Make 'ERR ' handling as error optional, as it may occur only in certain contexts.
      • Write with packet line encoding
    • git-url
      • parse into components to make them easy to understand
    • connect
      • via file and git-upload-pack
        • receive pack with V1 protocol
        • receive pack with V2 protocol
      • via https
        • receive pack with V1 protocol
        • receive pack with V2 protocol
  • git-refs
    • a way to know if a ref needs to be parsed (like ref/name^{})
    • create ref pointing to ID
      • assure to keep the path towards symbolic refs open, and allow specifying if these should be followed or not
    • gixp-pack-receive may optionally write received refs to the specified directory
  • git-repository
    • instance for a valid looking repository
      • support shallow repos/references
    • create-update refs as received from clone/git-receive-pack
  • gix clone
    • try initializing repo on output path - if so, use that to learn about pack location and place new pack there, allow Repo to create refs somehow.
      • _probably this is done using the repository itself, which steers the whole process and injects it's own delegates.
    • otherwise create the scaffolding needed for a new repository, probably based on init implementation

Fetching more analysis needed after previous block

  • git-daemon-proxy - obtain real-world examples for the V1/V2 git protocols
    • a standalone tool to serve as git-daemon-proxy, which intercepts all interactions with it and dumps each one into files like N.request and N.response.
    • Differentiate request and response delimiters using timeouts
  • receive pack
    • resolve thin pack with Bundle
  • git-repository
    • clone from https remote

FSCK an entire repository

  • multi-db (incorporate object lookup for loose objects and packs)
    • single threaded
    • optional object cache
    • fs-check - verify all object content of a git repository

Notes

  • response-end packets of V2 are not sent in stateless-rpc mode (i.e. http mode) and maybe even V2 daemons
  • protocol V2 is always stateless
  • The negotiation is the meat of the fetch algorithm, and even though not important for clones, the back-and-forth seems very relevant to how the transfer interface should be built. I feel it must be on packet line level.

Other

To be picked in any order….

  • prodash
    • finish transitioning to futures-lite to get rid of futures-util dependency to reduce compile times
  • criner
    • upgrade to prodash 9.0
    • switch to isahc seems to allow async-reading of bodies, allowing to get rid of reqwest and tokio. Redirect is configurable.
  • miniz-oxide