diff mercurial/obsolete.py @ 32393:f432897a9f49

obsmarker: add an experimental flag controlling "operation" recording It seems better to introduce the experiment behind a flag for now as there are multiple concerns around the feature: * Storing operation increase the size of obsolescence markers significantly (+10-20%). * It performs poorly when exchanging markers (cannot combine command names, command name might be unknown remotely, etc)
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Sat, 20 May 2017 03:10:23 +0200
parents 566cfe9cbbb9
children df448de7cf3b
line wrap: on
line diff
--- a/mercurial/obsolete.py	Fri May 19 19:46:45 2017 -0700
+++ b/mercurial/obsolete.py	Sat May 20 03:10:23 2017 +0200
@@ -1246,7 +1246,10 @@
         metadata = {}
     if 'user' not in metadata:
         metadata['user'] = repo.ui.username()
-    if operation:
+    useoperation = repo.ui.configbool('experimental',
+                                      'evolution.track-operation',
+                                      False)
+    if useoperation and operation:
         metadata['operation'] = operation
     tr = repo.transaction('add-obsolescence-marker')
     try: