Block when another command is running on the server and not on the client when in gRPC mode.
--
MOS_MIGRATED_REVID=120233121
diff --git a/src/main/java/com/google/devtools/build/lib/runtime/CommonCommandOptions.java b/src/main/java/com/google/devtools/build/lib/runtime/CommonCommandOptions.java
index c23cbf2..68df6a7 100644
--- a/src/main/java/com/google/devtools/build/lib/runtime/CommonCommandOptions.java
+++ b/src/main/java/com/google/devtools/build/lib/runtime/CommonCommandOptions.java
@@ -247,4 +247,12 @@
category = "hidden",
help = "Enable processing of +<file> parameters.")
public boolean allowProjectFiles;
+
+ @Option(name = "block_for_lock",
+ defaultValue = "true",
+ category = "hidden",
+ help = "If set (the default), a command will block if there is another one running. If "
+ + "unset, these commands will immediately return with an error.")
+ public boolean blockForLock;
+
}