streamclone: getting revlog data from the revlog themselves
- May 29, 2023
-
-
Pierre-Yves David authored
This detect and handle the most common case for a race condition around stream and revlog splitting. The one were the revlog is split between the initial collection of data and the time were we start considering stream that data. In such case, we repatch an inlined version of that revlog together when this happens. This is necessary as stream-v2 promised a specific number of bytes and a specific number of files to the client. In stream-v3, we will have the opportunity to just send a split revlog instead. Getting a better version of the protocol for stream-v3 is still useful, but it is no longer a blocket to fix that race condition. Note that another, rarer race condition exist, were the revlog is split while we creating the revlog and extracing content from it. This can be dealt with later.
5460424092e2 -
Pierre-Yves David authored
For revlog, we can do better using the maximum linkrev expected. This approach open the way to dealing with a much larger set of non-trivial changes, like splitting of inline revlogs. We will actually tackle this issue in the next changesets (thanks to this one).
9caa860dcbec
-
- May 28, 2023
-
-
Pierre-Yves David authored
The store entry has more context, this will especially be true when it comes to revlogs. So we move the details of how to retrieve binary content to the StoreEntry. The stream clone code now focus on the protocol bits.
5e60abf811f3
-
- May 29, 2023
-
-
Pierre-Yves David authored
This will help pytype to type check. We have to move `StoreFile` earlier in the file to use it in the type declaration.
8fc10bfd9887
-
- May 28, 2023
-
-
Pierre-Yves David authored
This might seen weird, but I actually thing we have been needing this for a long time. There is multiple object that kind of pretend being revlogs while actually wrapping the actual revlog. Since multiple code needs to access the actuel revlog. See documentation for more details. Expect cleanup of various places one the current series is done.
32837c7e2e4b
-
- May 29, 2023
-
-
Pierre-Yves David authored
It has no user left.
c90ea9bbf327 -
Pierre-Yves David authored
This does not requires that much changes and will give us much more flexibility, like improving revlog handling to gracefully handle race situation.
3416b46320dc -
Pierre-Yves David authored
This make the next changeset clearer.
1415e17ea20f
-
- May 28, 2023
-
-
Pierre-Yves David authored
We previously used `_v2_walk`. However it is not bringing us much. So lets use the higher level function instead. This will offer us more flexibility with the `_v2_walk` function… like deleting it eventually.
f2ae815ae34c
-
- May 29, 2023
-
-
Pierre-Yves David authored
The point of caching `files` is to ensure consistency and avoiding redoing expensive work. So we cache the file_size once retrieved.
786443bd3bc1
-
- May 28, 2023
-
-
Pierre-Yves David authored
This make it more efficient to directly use the entries list to retrieve data in various location. It also make the entry record the file size it previously promissed to user code, especially the stream clone code.
b59e0a4f692f
-
- May 27, 2023
-
-
Pierre-Yves David authored
This replace the previous `copy` callable with a richer object that allow access to the backup path. This will simplify the user code as they won't need to keep and pass around the backup path explicitly.
8c7b04e69894
-
- May 29, 2023
-
-
Pierre-Yves David authored
Creating RevlogStoreEntry is good, but we need to drop the final `00manifest` part to create something correct.
309cbd8400ae -
Pierre-Yves David authored
This bug, inherited from the upgrade code leads to the acces/creation of broken revlog with name `DIRECTORY00manifest.i` instead of `DIRECTORY/00manifest.i` We fix it in its own changeset to preserve the "pure code movement" aspect of the previous changesets.
3ea3767c23a4
-
- May 27, 2023
-
-
Pierre-Yves David authored
The upgrade code needs this a lot, and the stream code is about to needs it too. So we start by moving the upgrade code in a more generic location.
e1ee6910f6bc
-
- May 29, 2023
-
-
Pierre-Yves David authored
This has been a long running problem, we should have a tests for it.
9b0fe2b075b5
-
- May 28, 2023
-
-
Pierre-Yves David authored
We are not using the extension we create inline, we are using `tests/testlib/ext-stream-clone-steps.py`. So let us deleted the unused version.
1a554956af84 -
Pierre-Yves David authored
This extension is useful, let us clarify how to use it.
c2633c69cbe0
-
- May 29, 2023
-
-
Pierre-Yves David authored
This made my life easier debugging.
99dfe806d2f3
-