git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 0/1] pack-refs: always refreshing after take the lock file

From
Jeff King <peff@peff.net>
Date
Aug 16, 2019, 20:49 UTC
Message-ID
<20190816204906.GA29853@sigill.intra.peff.net>
In-Reply-To
<20190731183544.24406-1-16657101987@163.com>
On Thu, Aug 01, 2019 at 02:35:43AM +0800, 16657101987@163.com wrote:
Show 13 quoted lines
> > So I actually think the best path forward is just always refreshing when
> > we take the lock, something like:
> > 
> > Ultimately the best solution there is to move to a better format (like
> > the reftables proposal).
> 
> I do not know if we could get the new reftables in the next few versions,
> So I commit the changes as you suggested, which is also the same as
> another way I metioned in `PATCH v1`:
> 
> **force `update-ref -d` to update the snapshot before rewrite packed-refs.**
> 
> But if the reftables is comeing soon, please just ignore my PATCH :)

I'm undecided on this. I think reftables are still a while off, and even once they are here, many people will still be using the older format. So it makes sense to still apply fixes to the old code.

What I wonder, though, is whether always refreshing will cause a noticeable performance impact (and that's why I was so slow in responding -- I had hoped to try to come up with some numbers, but I just hadn't gotten around to it).

My gut says it's _probably_ not an issue, but it would be nice to have some data to back it up.

> **And thank a lot for your reply, it's great to me, because it's my first
> PATCh to git myself :)**
You're welcome. Thanks for diagnosing a rather tricky case. :)
-Peff
Previous: 16657101987@163.comNext: Junio C Hamano
Message 6 of 8 in “pack-refs: pack expired loose refs to packed_refs”
  1. 0/1 pack-refs: pack expired loose refs to packed_refs16657101987@163.com, Jul 21, 2019
  2. 1/1 pack-refs: pack expired loose refs to packed_refs16657101987@163.com, Jul 21, 2019
  3. Jeff KingJul 30, 2019
  4. 0/1 pack-refs: always refreshing after take the lock file16657101987@163.com, Jul 31, 2019
  5. 1/1 pack-refs: always refreshing after take the lock file16657101987@163.com, Jul 31, 2019
  6. Jeff KingAug 16, 2019
  7. Junio C HamanoAug 19, 2019
  8. 16657101987@163.comAug 20, 2019

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.