All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kevin Willford <Kevin.Willford@microsoft.com>
To: Junio C Hamano <gitster@pobox.com>,
	Kevin Willford via GitGitGadget <gitgitgadget@gmail.com>
Cc: "git@vger.kernel.org" <git@vger.kernel.org>
Subject: RE: [PATCH 0/1] fsmonitor: fix watchman integration
Date: Wed, 6 Nov 2019 15:32:22 +0000	[thread overview]
Message-ID: <BN6PR21MB0786856156CFB55E8812D51E91790@BN6PR21MB0786.namprd21.prod.outlook.com> (raw)
In-Reply-To: <xmqqlfstvg09.fsf@gitster-ct.c.googlers.com>

> From: Junio C Hamano <gitster@pobox.com>
> Sent: Tuesday, November 5, 2019 8:30 PM
> 
> "Kevin Willford via GitGitGadget" <gitgitgadget@gmail.com> writes:
> 
> > When running Git commands quickly -- such as in a shell script or the
> > test suite -- the Git commands frequently complete and start again
> > during the same second. The example fsmonitor hooks to integrate with
> > Watchman truncate the nanosecond times to seconds. In principle, this
> > is fine, as Watchman claims to use inclusive comparisons [1]. The
> > result should only be an over-representation of the changed paths since
> the last Git command.
> > ...
> 
> So, it doesn't seem to use "inclusive" and we need a workaround?

That is what is seems like.  I would like to dig into the watchman code
to understand what is really going on.  They also document that "Using
a timestamp is prone to race conditions in understanding the complete
state of the file tree." Which could be the cause since the tests are
running things in quick succession, i.e. change a file, run a git command.

Long term we should switch to using watchman's clock id which the
documentation says does not have the race conditions. But the clock
id is a string and would take more invasive changes to integrate that
into the index where we are now simply using a uint64_t.


  reply	other threads:[~2019-11-06 15:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-04 17:50 [PATCH 0/1] fsmonitor: fix watchman integration Kevin Willford via GitGitGadget
2019-11-04 17:50 ` [PATCH 1/1] " Kevin Willford via GitGitGadget
2019-11-12 11:32   ` SZEDER Gábor
2019-11-06  3:29 ` [PATCH 0/1] " Junio C Hamano
2019-11-06 15:32   ` Kevin Willford [this message]
2019-11-06 15:46     ` Derrick Stolee

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=BN6PR21MB0786856156CFB55E8812D51E91790@BN6PR21MB0786.namprd21.prod.outlook.com \
    --to=kevin.willford@microsoft.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=gitster@pobox.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.