Built motion from commit 6a09e18b.|2.6.11
[motion2.git] / legacy-libs / google-proto-files / google / devtools / resultstore / v2 / invocation.proto
1 // Copyright 2018 Google LLC.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 //     http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 //
15
16 syntax = "proto3";
17
18 package google.devtools.resultstore.v2;
19
20 import "google/devtools/resultstore/v2/common.proto";
21 import "google/devtools/resultstore/v2/coverage_summary.proto";
22 import "google/devtools/resultstore/v2/file.proto";
23
24 option go_package = "google.golang.org/genproto/googleapis/devtools/resultstore/v2;resultstore";
25 option java_multiple_files = true;
26 option java_package = "com.google.devtools.resultstore.v2";
27
28 // An Invocation typically represents the result of running a tool. Each has a
29 // unique ID, typically generated by the server. Target resources under each
30 // Invocation contain the bulk of the data.
31 message Invocation {
32   // The resource ID components that identify the Invocation.
33   message Id {
34     // The Invocation ID.
35     string invocation_id = 1;
36   }
37
38   // The resource name.  Its format must be:
39   // invocations/${INVOCATION_ID}
40   string name = 1;
41
42   // The resource ID components that identify the Invocation. They must match
43   // the resource name after proper encoding.
44   Id id = 2;
45
46   // The aggregate status of the invocation.
47   StatusAttributes status_attributes = 3;
48
49   // When this invocation started and its duration.
50   Timing timing = 4;
51
52   // Attributes of this invocation.
53   InvocationAttributes invocation_attributes = 5;
54
55   // The workspace the tool was run in.
56   WorkspaceInfo workspace_info = 6;
57
58   // Arbitrary name-value pairs.
59   // This is implemented as a multi-map. Multiple properties are allowed with
60   // the same key. Properties will be returned in lexicographical order by key.
61   repeated Property properties = 7;
62
63   // A list of file references for invocation level files.
64   // The file IDs must be unique within this list. Duplicate file IDs will
65   // result in an error. Files will be returned in lexicographical order by ID.
66   // Use this field to specify build logs, and other invocation level logs.
67   repeated File files = 8;
68
69   // Summary of aggregate coverage across all Actions in this Invocation.
70   // the server populates this for you in the post-processing phase.
71   repeated LanguageCoverageSummary coverage_summaries = 9;
72 }
73
74 // If known, represents the state of the user/build-system workspace.
75 message WorkspaceContext {}
76
77 // Describes the workspace under which the tool was invoked, this includes
78 // information that was fed into the command, the source code referenced, and
79 // the tool itself.
80 message WorkspaceInfo {
81   // Data about the workspace that might be useful for debugging.
82   WorkspaceContext workspace_context = 1;
83
84   // Where the tool was invoked
85   string hostname = 3;
86
87   // The client's working directory where the build/test was run from.
88   string working_directory = 4;
89
90   // Tools should set tool_tag to the name of the tool or use case.
91   string tool_tag = 5;
92
93   // The command lines invoked. The first command line is the one typed by the
94   // user, then each one after that should be an expansion of the previous
95   // command line.
96   repeated CommandLine command_lines = 7;
97 }
98
99 // The command and arguments that produced this Invocation.
100 message CommandLine {
101   // A label describing this command line.
102   string label = 1;
103
104   // The command-line tool that is run: argv[0].
105   string tool = 2;
106
107   // The arguments to the above tool: argv[1]...argv[N].
108   repeated string args = 3;
109
110   // The actual command that was run with the tool.  (e.g. "build", or "test")
111   // Omit if the tool doesn't accept a command.
112   // This is a duplicate of one of the fields in args.
113   string command = 4;
114 }
115
116 // Attributes that apply to all invocations.
117 message InvocationAttributes {
118   // The project ID this invocation is associated with. This must be
119   // set in the CreateInvocation call, and can't be changed.
120   string project_id = 1;
121
122   // The list of users in the command chain.  The first user in this sequence
123   // is the one who instigated the first command in the chain.
124   repeated string users = 2;
125
126   // Labels to categorize this invocation.
127   // This is implemented as a set. All labels will be unique. Any duplicate
128   // labels added will be ignored. Labels will be returned in lexicographical
129   // order. Labels should be short, easy to read, and you
130   // shouldn't have more than a handful.
131   // Labels should match regex \w([- \w]*\w)?
132   // Labels should not be used for unique properties such as unique IDs.
133   // Use properties in cases that don't meet these conditions.
134   repeated string labels = 3;
135
136   // This field describes the overall context or purpose of this invocation.
137   // It will be used in the UI to give users more information about
138   // how or why this invocation was run.
139   string description = 4;
140
141   // If this Invocation was run in the context of a larger Continuous
142   // Integration build or other automated system, this field may contain more
143   // information about the greater context.
144   repeated InvocationContext invocation_contexts = 6;
145 }
146
147 // Describes the invocation context which includes a display name and URL.
148 message InvocationContext {
149   // A human readable name for the context under which this Invocation was run.
150   string display_name = 1;
151
152   // A URL pointing to a UI containing more information
153   string url = 2;
154 }