From: Justin Tobler <jltobler@gmail.com>
To: Patrick Steinhardt <ps@pks.im>
Cc: Jeff King <peff@peff.net>, Junio C Hamano <gitster@pobox.com>,
Wolfgang Kritzinger <wkritzinger@atlassian.com>,
git@vger.kernel.org
Subject: Re: Performance regression in connectivity check during receive-pack (git 2.54)
Date: Mon, 27 Jul 2026 10:45:46 -0500 [thread overview]
Message-ID: <amd4yR3EEn_fVZcm@denethor> (raw)
In-Reply-To: <amLgMqkqxR8mKIbT@pks.im>
On 26/07/24 05:46AM, Patrick Steinhardt wrote:
> This would solve a bunch of smaller issues that we're currently
> grappling with where some of the concepts in Git really want to operate
> across all of the alternates:
>
> - The OBJECT_INFO_SECOND_READ flag can be dropped as it becomes an
> implementation detail.
>
> - We can fix the performance regression because we can now easily
> reorder access to read via packfiles first across all sub-sources.
Letting the backend control the ordering would be a nice property.
> - Commit graphs and bitmap really are a singleton, so loading them via
> multiple sources is awkward.
I completely agree. Having the ODB source be more self-contained with
the alternates better fits the shape of commits graphs and alternates
IMO.
> - The object storage extension that I've written got quite a bit ugly
> as it wasn't quite clear where exactly to draw the line. Especially
> hadnling the environment variables mentioned above into the "files"
> backend removes one point of friction I encountered.
>
> - Object database maintenance needs to be aware of the other non-local
> sources.
>
> Also, doing that change isn't as bad as it may sound at first. We'd
> still retain the whole `struct odb_source` list because we want to have
> them for submodule sources. Furthermore, alternates aren't required for
> isolation either as we currently use them via the temporary object
> directory. An alternative implementation may use a completely separate
> mechanism to achieve write isolation, which is also why we have made the
> environment variables pluggable that the `struct odb_transaction` ends
> up passing to the child process.
Once all temporary object directory users are updated to use ODB
transactions, we could stop reording source list when starting/ending a
transaction. Instead the transaction could be tracked separately
internally and during ODB read/writes the transaction could be directly
used as needed. This is something I plan to tackle in a future series
soon.
> I think overall this could simplify some of the design, and it makes a
> bunch of issues that I have been struggling with go away. The devil may
> be in the details of course, but I think transitioning towards this
> should be doable.
I am certainly a fan of this direction. We do lose some flexibility in
terms of supporting alternates more generically, but I'm not sure
supporting alternates of different source types in the same repo would
be something we want anyways in practice due to the additional
complexity.
-Justin
prev parent reply other threads:[~2026-07-27 15:45 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-21 3:17 Performance regression in connectivity check during receive-pack (git 2.54) Wolfgang Kritzinger
2026-07-21 3:57 ` Jeff King
2026-07-21 5:05 ` Taylor Blau
2026-07-21 14:40 ` Junio C Hamano
2026-07-22 11:49 ` Patrick Steinhardt
2026-07-22 15:49 ` Junio C Hamano
[not found] ` <20260723104943.GC604358@coredump.intra.peff.net>
2026-07-24 3:46 ` Patrick Steinhardt
2026-07-26 8:51 ` Jeff King
2026-07-27 15:45 ` Justin Tobler [this message]
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=amd4yR3EEn_fVZcm@denethor \
--to=jltobler@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=peff@peff.net \
--cc=ps@pks.im \
--cc=wkritzinger@atlassian.com \
/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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox