aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/protobuf
diff options
context:
space:
mode:
authorGravatar ccalvarin <ccalvarin@google.com>2017-08-14 21:09:07 +0200
committerGravatar Irina Iancu <elenairina@google.com>2017-08-16 11:04:41 +0200
commit1cbe62a09b37f2db76e11ebb18fb46616076ef87 (patch)
treef02a66fc345507f3eb3ab3bbe404fdcb161cbabc /src/main/protobuf
parentfc6412ca67a9d98c1b6b0c8b237c119e543bc266 (diff)
Send Bazel startup options to server.
Send the startup options tagged with their origin so that the server has correct information about the command line as the client received it. Removes the unconditional stderr printing of all bazelrc startup options in the bazel client. Instead, the startup options are sent to the server and the same informational printing is gated on the --announce_rc option. This avoids unconditional log spam to stderr early in startup. If the server is unreachable or there are errors parsing startup options, the message is still printed to stderr. Fixes https://github.com/bazelbuild/bazel/issues/2530. RELNOTES: --announce_rc now controls whether bazelrc startup options are printed to stderr. PiperOrigin-RevId: 165211007
Diffstat (limited to 'src/main/protobuf')
-rw-r--r--src/main/protobuf/command_server.proto15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/main/protobuf/command_server.proto b/src/main/protobuf/command_server.proto
index 79f44b9930..b55a68817d 100644
--- a/src/main/protobuf/command_server.proto
+++ b/src/main/protobuf/command_server.proto
@@ -51,6 +51,21 @@ message RunRequest {
// between batch and server mode, so the parsing logic is only in the Java
// code.
string invocation_policy = 5;
+
+ // Startup arguments, in the order they were applied, tagged with where they
+ // came from. These options have already been parsed and already have had
+ // their effect. This information should only be used for logging.
+ repeated StartupOption startup_options = 6;
+}
+
+// Contains the a startup option with its source file. Uses bytes to preserve
+// the way the user inputted the arguments, like the args in RunRequest.
+message StartupOption {
+ // Startup option in --nullaryflag or --unaryflag=value form.
+ bytes option = 1;
+ // Where the option came from, such as an rc file or an empty string for the
+ // command line.
+ bytes source = 2;
}
// Contains metadata and result data for a command execution.