Patchwork D8422: nodemap: move the mode option to storage.revlog.nodemap.mode

login
register
mail settings
Submitter phabricator
Date May 7, 2020, 3:37 p.m.
Message ID <7278610d4332e11be6226087afcc789e@localhost.localdomain>
Download mbox | patch
Permalink /patch/46280/
State Not Applicable
Headers show

Comments

phabricator - May 7, 2020, 3:37 p.m.
Closed by commit rHGd36283e20833: nodemap: move the mode option to storage.revlog.nodemap.mode (authored by marmoute).
This revision was automatically updated to reflect the committed changes.
This revision was not accepted when it landed; it landed in state "Needs Review".

CHANGED PRIOR TO COMMIT
  https://phab.mercurial-scm.org/D8422?vs=21232&id=21298#toc

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D8422?vs=21232&id=21298

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D8422/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D8422

AFFECTED FILES
  mercurial/configitems.py
  mercurial/localrepo.py
  tests/test-persistent-nodemap.t

CHANGE DETAILS




To: marmoute, #hg-reviewers, Alphare
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/tests/test-persistent-nodemap.t b/tests/test-persistent-nodemap.t
--- a/tests/test-persistent-nodemap.t
+++ b/tests/test-persistent-nodemap.t
@@ -10,7 +10,7 @@ 
   > EOF
   $ hg init test-repo
   $ cd test-repo
-  $ hg debugbuilddag .+5000 --new-file --config "experimental.exp-persistent-nodemap.mode=warn"
+  $ hg debugbuilddag .+5000 --new-file --config "storage.revlog.nodemap.mode=warn"
   persistent nodemap in strict mode without efficient method (no-rust no-pure !)
   persistent nodemap in strict mode without efficient method (no-rust no-pure !)
   $ hg debugnodemap --metadata
@@ -99,7 +99,7 @@ 
 
 #if no-pure no-rust
 
-  $ hg ci -m 'foo' --config "experimental.exp-persistent-nodemap.mode=strict"
+  $ hg ci -m 'foo' --config "storage.revlog.nodemap.mode=strict"
   transaction abort!
   rollback completed
   abort: persistent nodemap in strict mode without efficient method
diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
--- a/mercurial/localrepo.py
+++ b/mercurial/localrepo.py
@@ -940,7 +940,7 @@ 
         options[b'persistent-nodemap'] = True
     if ui.configbool(b'storage', b'revlog.nodemap.mmap'):
         options[b'persistent-nodemap.mmap'] = True
-    epnm = ui.config(b'experimental', b'exp-persistent-nodemap.mode')
+    epnm = ui.config(b'storage', b'revlog.nodemap.mode')
     options[b'persistent-nodemap.mode'] = epnm
     if ui.configbool(b'devel', b'persistent-nodemap'):
         options[b'devel-force-nodemap'] = True
diff --git a/mercurial/configitems.py b/mercurial/configitems.py
--- a/mercurial/configitems.py
+++ b/mercurial/configitems.py
@@ -663,9 +663,6 @@ 
     b'experimental', b'rust.index', default=False,
 )
 coreconfigitem(
-    b'experimental', b'exp-persistent-nodemap.mode', default=b'compat',
-)
-coreconfigitem(
     b'experimental', b'server.filesdata.recommended-batch-size', default=50000,
 )
 coreconfigitem(
@@ -1083,6 +1080,10 @@ 
 coreconfigitem(
     b'storage', b'revlog.nodemap.mmap', default=True, experimental=True
 )
+# experimental as long as format.use-persistent-nodemap is.
+coreconfigitem(
+    b'storage', b'revlog.nodemap.mode', default=b'compat', experimental=True
+)
 coreconfigitem(
     b'storage', b'revlog.reuse-external-delta', default=True,
 )