aboutsummaryrefslogtreecommitdiff
path: root/crosperf/settings_factory.py
diff options
context:
space:
mode:
authorcmtice <cmtice@google.com>2015-06-12 12:22:32 -0700
committerChromeOS Commit Bot <chromeos-commit-bot@chromium.org>2015-06-13 01:25:14 +0000
commit517dc98884e398fa863ce22b6bc1ef8323853416 (patch)
tree5dfdce78bbe6c9626404cc88672d068640cd99f8 /crosperf/settings_factory.py
parentd1172b4df650c89b6fef7719db8225c31a4eba0e (diff)
downloadtoolchain-utils-517dc98884e398fa863ce22b6bc1ef8323853416.tar.gz
Add flag to crosperf to use file lock mechanism.
This CL adds a flag to crosperf that specifies using the old file locking mechanism, rather than the new AFE server locking mechanism. This is useful when there are issues with accessing the AFE server. BUG=None TEST=Tested crosperf with this, both using the AFE locking mechanism and using the file locking mechanism. Change-Id: If6aa3e97a77d8ccb53f0e8f0405cc7f45e983b75 Reviewed-on: https://chrome-internal-review.googlesource.com/219096 Reviewed-by: Luis Lozano <llozano@chromium.org> Commit-Queue: Caroline Tice <cmtice@google.com> Tested-by: Caroline Tice <cmtice@google.com>
Diffstat (limited to 'crosperf/settings_factory.py')
-rw-r--r--crosperf/settings_factory.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/crosperf/settings_factory.py b/crosperf/settings_factory.py
index 6793a608..96e8d90b 100644
--- a/crosperf/settings_factory.py
+++ b/crosperf/settings_factory.py
@@ -99,6 +99,10 @@ class GlobalSettings(Settings):
self.AddField(BooleanField("same_machine", default=False,
description="Ensure cached runs are run on the "
"exact the same remote"))
+ self.AddField(BooleanField("use_file_locks", default=False,
+ description="Whether to use the file locks "
+ "mechanism (deprecated) instead of the AFE "
+ "server lock mechanism."))
self.AddField(IntegerField("iterations", default=1,
description="Number of iterations to run all "
"tests."))
@@ -140,7 +144,8 @@ class GlobalSettings(Settings):
description="The results dir"))
self.AddField(TextField("locks_dir", default="",
description="An alternate directory to use for "
- "storing/checking machine locks.\n"
+ "storing/checking machine locks. Using this field "
+ "automatically sets use_file_locks to True.\n"
"WARNING: If you use your own locks directory, "
"there is no guarantee that someone else might not "
"hold a lock on the same machine in a different "