[PATCH 2 of 4 V2] chgcache: report repo paths from worker to master
Yuya Nishihara
yuya at tcha.org
Mon Feb 27 10:46:14 EST 2017
On Wed, 22 Feb 2017 18:16:09 -0800, Jun Wu wrote:
> # HG changeset patch
> # User Jun Wu <quark at fb.com>
> # Date 1487807803 28800
> # Wed Feb 22 15:56:43 2017 -0800
> # Node ID 630457e88fa0485bce7822345ea640b5cdcb9b8e
> # Parent aef9e96fb573b85f5731367a470f574dbe730839
> # Available At https://bitbucket.org/quark-zju/hg-draft
> # hg pull https://bitbucket.org/quark-zju/hg-draft -r 630457e88fa0
> chgcache: report repo paths from worker to master
> diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
> --- a/mercurial/localrepo.py
> +++ b/mercurial/localrepo.py
> @@ -29,4 +29,5 @@ from . import (
> changegroup,
> changelog,
> + chgcache,
> context,
> dirstate,
> @@ -371,4 +372,7 @@ class localrepository(object):
> self.names = namespaces.namespaces()
>
> + # record the repo path so chg worker could tell master what to preload
> + chgcache.recordrepopath(path)
I feel this a bit uncomfortable that the repo instance registers itself to
chgcache. Suppose preloading will be handled in upper layer (maybe in dispatch),
I think recordrepopath() should be called at the same layer. Or are we planning
to handle all chgcache things in localrepo?
More information about the Mercurial-devel
mailing list