Re: [PATCH 3/8] midx: stop using linked list when closing MIDX
On Thu, Jul 10, 2025 at 04:31:24PM -0500, Justin Tobler wrote:
Show 17 quoted lines
> On 25/07/09 09:54AM, Patrick Steinhardt wrote:
> > When calling `close_midx()` we not only close the multi-pack index for
> > one object source, but instead we iterate through the whole linked list
> > of MIDXs to close all of them. This linked list is about to go away in
> > favor of using the new per-source pointer to its respective MIDX.
> >
> > Refactor the function to iterate through sources instead.
>
> The `close_midx()` function itself is not iterating though the sources.
> Rather each of the callsites are now resposible to ensure `close_midx()`
> is called separately for each source. It might be nice to clarify this a
> bit in the message.
>
> I also noticed that there are several other existing `close_midx()`
> callsites that we leave as-is. Each of these sites though looks like
> they don't care about globally closing all MIDXs so they should be fine.
> This might also we worth mentioning.
Indeed. I'll add a note.
Patrick