@@ -34,8 +34,8 @@ a new object representation for large blobs as discussed in:
3434
3535https://lore.kernel.org/git/
[email protected] /
3636
37- 0) Non goals
38- ------------
37+ Non goals
38+ ---------
3939
4040- We will not discuss those client side improvements here, as they
4141 would require changes in different parts of Git than this effort.
@@ -90,8 +90,8 @@ later in this document:
9090 even more to host content with larger blobs or more large blobs
9191 than currently.
9292
93- I) Issues with the current situation
94- ------------------------------------
93+ I Issues with the current situation
94+ -----------------------------------
9595
9696- Some statistics made on GitLab repos have shown that more than 75%
9797 of the disk space is used by blobs that are larger than 1MB and
@@ -138,8 +138,8 @@ I) Issues with the current situation
138138 complaining that these tools require significant effort to set up,
139139 learn and use correctly.
140140
141- II) Main features of the "Large Object Promisors" solution
142- ----------------------------------------------------------
141+ II Main features of the "Large Object Promisors" solution
142+ ---------------------------------------------------------
143143
144144The main features below should give a rough overview of how the
145145solution may work. Details about needed elements can be found in
@@ -166,7 +166,7 @@ format. They should be used along with main remotes that contain the
166166other objects.
167167
168168Note 1
169- ++++++
169+ ^^^^^^
170170
171171To clarify, a LOP is a normal promisor remote, except that:
172172
@@ -178,21 +178,21 @@ To clarify, a LOP is a normal promisor remote, except that:
178178 itself.
179179
180180Note 2
181- ++++++
181+ ^^^^^^
182182
183183Git already makes it possible for a main remote to also be a promisor
184184remote storing both regular objects and large blobs for a client that
185185clones from it with a filter on blob size. But here we explicitly want
186186to avoid that.
187187
188188Rationale
189- +++++++++
189+ ^^^^^^^^^
190190
191191LOPs aim to be good at handling large blobs while main remotes are
192192already good at handling other objects.
193193
194194Implementation
195- ++++++++++++++
195+ ^^^^^^^^^^^^^^
196196
197197Git already has support for multiple promisor remotes, see
198198link:partial-clone.html#using-many-promisor-remotes[the partial clone documentation].
@@ -213,19 +213,19 @@ remote helper (see linkgit:gitremote-helpers[7]) which makes the
213213underlying object storage appear like a remote to Git.
214214
215215Note
216- ++++
216+ ^^^^
217217
218218A LOP can be a promisor remote accessed using a remote helper by
219219both some clients and the main remote.
220220
221221Rationale
222- +++++++++
222+ ^^^^^^^^^
223223
224224This looks like the simplest way to create LOPs that can cheaply
225225handle many large blobs.
226226
227227Implementation
228- ++++++++++++++
228+ ^^^^^^^^^^^^^^
229229
230230Remote helpers are quite easy to write as shell scripts, but it might
231231be more efficient and maintainable to write them using other languages
@@ -247,7 +247,7 @@ The underlying object storage that a LOP uses could also serve as
247247storage for large files handled by Git LFS.
248248
249249Rationale
250- +++++++++
250+ ^^^^^^^^^
251251
252252This would simplify the server side if it wants to both use a LOP and
253253act as a Git LFS server.
@@ -259,7 +259,7 @@ On the server side, a main remote should have a way to offload to a
259259LOP all its blobs with a size over a configurable threshold.
260260
261261Rationale
262- +++++++++
262+ ^^^^^^^^^
263263
264264This makes it easy to set things up and to clean things up. For
265265example, an admin could use this to manually convert a repo not using
@@ -268,7 +268,7 @@ some users would sometimes push large blobs, a cron job could use this
268268to regularly make sure the large blobs are moved to the LOP.
269269
270270Implementation
271- ++++++++++++++
271+ ^^^^^^^^^^^^^^
272272
273273Using something based on `git repack --filter=...` to separate the
274274blobs we want to offload from the other Git objects could be a good
@@ -284,13 +284,13 @@ should have ways to prevent oversize blobs to be fetched, and also
284284perhaps pushed, into it.
285285
286286Rationale
287- +++++++++
287+ ^^^^^^^^^
288288
289289A main remote containing many oversize blobs would defeat the purpose
290290of LOPs.
291291
292292Implementation
293- ++++++++++++++
293+ ^^^^^^^^^^^^^^
294294
295295The way to offload to a LOP discussed in 4) above can be used to
296296regularly offload oversize blobs. About preventing oversize blobs from
@@ -326,18 +326,18 @@ large blobs directly from the LOP and the server would not need to
326326fetch those blobs from the LOP to be able to serve the client.
327327
328328Note
329- ++++
329+ ^^^^
330330
331331For fetches instead of clones, a protocol negotiation might not always
332332happen, see the "What about fetches?" FAQ entry below for details.
333333
334334Rationale
335- +++++++++
335+ ^^^^^^^^^
336336
337337Security, configurability and efficiency of setting things up.
338338
339339Implementation
340- ++++++++++++++
340+ ^^^^^^^^^^^^^^
341341
342342A "promisor-remote" protocol v2 capability looks like a good way to
343343implement this. The way the client and server use this capability
@@ -356,7 +356,7 @@ the client should be able to offload some large blobs it has fetched,
356356but might not need anymore, to the LOP.
357357
358358Note
359- ++++
359+ ^^^^
360360
361361It might depend on the context if it should be OK or not for clients
362362to offload large blobs they have created, instead of fetched, directly
@@ -367,13 +367,13 @@ This should be discussed and refined when we get closer to
367367implementing this feature.
368368
369369Rationale
370- +++++++++
370+ ^^^^^^^^^
371371
372372On the client, the easiest way to deal with unneeded large blobs is to
373373offload them.
374374
375375Implementation
376- ++++++++++++++
376+ ^^^^^^^^^^^^^^
377377
378378This is very similar to what 4) above is about, except on the client
379379side instead of the server side. So a good solution to 4) could likely
@@ -385,8 +385,8 @@ when cloning (see 6) above). Also if the large blobs were fetched from
385385a LOP, it is likely, and can easily be confirmed, that the LOP still
386386has them, so that they can just be removed from the client.
387387
388- III) Benefits of using LOPs
389- ---------------------------
388+ III Benefits of using LOPs
389+ --------------------------
390390
391391Many benefits are related to the issues discussed in "I) Issues with
392392the current situation" above:
@@ -406,8 +406,8 @@ the current situation" above:
406406
407407- Reduced storage needs on the client side.
408408
409- IV) FAQ
410- -------
409+ IV FAQ
410+ ------
411411
412412What about using multiple LOPs on the server and client side?
413413~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -533,7 +533,7 @@ some objects it already knows about but doesn't have because they are
533533on a promisor remote.
534534
535535Regular fetch
536- +++++++++++++
536+ ^^^^^^^^^^^^^
537537
538538In a regular fetch, the client will contact the main remote and a
539539protocol negotiation will happen between them. It's a good thing that
@@ -551,7 +551,7 @@ new fetch will happen in the same way as the previous clone or fetch,
551551using, or not using, the same LOP(s) as last time.
552552
553553"Backfill" or "lazy" fetch
554- ++++++++++++++++++++++++++
554+ ^^^^^^^^^^^^^^^^^^^^^^^^^^
555555
556556When there is a backfill fetch, the client doesn't necessarily contact
557557the main remote first. It will try to fetch from its promisor remotes
@@ -576,8 +576,8 @@ from the client when it fetches from them. The client could get the
576576token when performing a protocol negotiation with the main remote (see
577577section II.6 above).
578578
579- V) Future improvements
580- ----------------------
579+ V Future improvements
580+ ---------------------
581581
582582It is expected that at the beginning using LOPs will be mostly worth
583583it either in a corporate context where the Git version that clients
0 commit comments