git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
From: Jeff Hostetler <git@jeffhostetler.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
	"Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re: [PATCH] fsmonitor: only enable it in non-bare repositories
Date: Mon, 3 May 2021 13:27:50 -0400	[thread overview]
Message-ID: <810dc60c-3730-b5f3-34f6-5cc2ddc9942a@jeffhostetler.com> (raw)
In-Reply-To: <87mttbx6ie.fsf@evledraar.gmail.com>



On 5/3/21 9:58 AM, Ævar Arnfjörð Bjarmason wrote:
> 
> On Thu, Apr 29 2021, Johannes Schindelin via GitGitGadget wrote:
> 
>> From: Johannes Schindelin <johannes.schindelin@gmx.de>
>>
>> The entire point of the FSMonitor is to monitor the worktree changes in
>> a more efficient manner than `lstat()`ing all worktree files every time
>> we refresh the index.
>>
>> But if there is no worktree, FSMonitor has nothing to monitor.
>>
>> So let's ignore if an FSMonitor is configured (e.g. in `~/.gitconfig`)
>> and we're running in a repository without worktree.
>>
>> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
>> ---
...
>>
>> base-commit: 14d50074ff19e68e7a8d718b22d138882087bbc9
> 
> This is surely a correct fix for now, but wouldn't it in the future also
> be useful to run it in bare repositories e.g. to be able cache lookups
> for non-existing loose objects?
> 

No, the FSMonitor feature only expects data for paths within the
working directory.  (And is independent of whether the FS change
data is provided by my fsmonitor--daemon or provided by a hook-based
provider, such as Watchman.)  The FSMonitor feature uses that data to
shortcut scans of the working directory.

There is no interaction with the contents of the .git/objects
directory and I'm not sure how that would work.

Jeff






  reply	other threads:[~2021-05-03 17:27 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-29  7:46 Johannes Schindelin via GitGitGadget
2021-04-30 13:55 ` Junio C Hamano
2021-05-03  9:11 ` [PATCH v2] " Johannes Schindelin via GitGitGadget
2021-05-03 13:58 ` [PATCH] " Ævar Arnfjörð Bjarmason
2021-05-03 17:27   ` Jeff Hostetler [this message]
2021-05-03 17:56     ` Ævar Arnfjörð Bjarmason
2021-05-11 19:24       ` Jeff Hostetler

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=810dc60c-3730-b5f3-34f6-5cc2ddc9942a@jeffhostetler.com \
    --to=git@jeffhostetler.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=johannes.schindelin@gmx.de \
    /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.
Code repositories for project(s) associated with this inbox:

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).