go.chromium.org/luci@v0.0.0-20240309015107-7cdc2e660f33/resultdb/proto/v1/artifact.pb.go (about) 1 // Copyright 2020 The LUCI Authors. 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 // Code generated by protoc-gen-go. DO NOT EDIT. 16 // versions: 17 // protoc-gen-go v1.31.0 18 // protoc v3.21.7 19 // source: go.chromium.org/luci/resultdb/proto/v1/artifact.proto 20 21 package resultpb 22 23 import ( 24 _ "google.golang.org/genproto/googleapis/api/annotations" 25 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 26 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 27 timestamppb "google.golang.org/protobuf/types/known/timestamppb" 28 reflect "reflect" 29 sync "sync" 30 ) 31 32 const ( 33 // Verify that this generated code is sufficiently up-to-date. 34 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 35 // Verify that runtime/protoimpl is sufficiently up-to-date. 36 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 37 ) 38 39 // A file produced during a build/test, typically a test artifact. 40 // The parent resource is either a TestResult or an Invocation. 41 // 42 // An invocation-level artifact might be related to tests, or it might not, for 43 // example it may be used to store build step logs when streaming support is 44 // added. 45 // Next id: 9. 46 type Artifact struct { 47 state protoimpl.MessageState 48 sizeCache protoimpl.SizeCache 49 unknownFields protoimpl.UnknownFields 50 51 // Can be used to refer to this artifact. 52 // Format: 53 // - For invocation-level artifacts: 54 // "invocations/{INVOCATION_ID}/artifacts/{ARTIFACT_ID}". 55 // - For test-result-level artifacts: 56 // "invocations/{INVOCATION_ID}/tests/{URL_ESCAPED_TEST_ID}/results/{RESULT_ID}/artifacts/{ARTIFACT_ID}". 57 // 58 // where URL_ESCAPED_TEST_ID is the test_id escaped with 59 // https://golang.org/pkg/net/url/#PathEscape (see also https://aip.dev/122), 60 // and ARTIFACT_ID is documented below. 61 // Examples: "screenshot.png", "traces/a.txt". 62 Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` 63 // A local identifier of the artifact, unique within the parent resource. 64 // MAY have slashes, but MUST NOT start with a slash. 65 // SHOULD not use backslashes. 66 // Regex: ^[[:word:]]([[:print:]]{0,254}[[:word:]])?$ 67 ArtifactId string `protobuf:"bytes,2,opt,name=artifact_id,json=artifactId,proto3" json:"artifact_id,omitempty"` 68 // A signed short-lived URL to fetch the contents of the artifact. 69 // See also fetch_url_expiration. 70 FetchUrl string `protobuf:"bytes,3,opt,name=fetch_url,json=fetchUrl,proto3" json:"fetch_url,omitempty"` 71 // When fetch_url expires. If expired, re-request this Artifact. 72 FetchUrlExpiration *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=fetch_url_expiration,json=fetchUrlExpiration,proto3" json:"fetch_url_expiration,omitempty"` 73 // Media type of the artifact. 74 // Logs are typically "text/plain" and screenshots are typically "image/png". 75 // Optional. 76 ContentType string `protobuf:"bytes,5,opt,name=content_type,json=contentType,proto3" json:"content_type,omitempty"` 77 // Size of the file. 78 // Can be used in UI to decide between displaying the artifact inline or only 79 // showing a link if it is too large. 80 // If you are using the gcs_uri, this field is not verified, but only treated as a hint. 81 SizeBytes int64 `protobuf:"varint,6,opt,name=size_bytes,json=sizeBytes,proto3" json:"size_bytes,omitempty"` 82 // Contents of the artifact. 83 // This is INPUT_ONLY, and taken by BatchCreateArtifacts(). 84 // All getter RPCs, such as ListArtifacts(), do not populate values into 85 // the field in the response. 86 // If specified, `gcs_uri` must be empty. 87 Contents []byte `protobuf:"bytes,7,opt,name=contents,proto3" json:"contents,omitempty"` 88 // The GCS URI of the artifact if it's stored in GCS. If specified, `contents` must be empty. 89 GcsUri string `protobuf:"bytes,8,opt,name=gcs_uri,json=gcsUri,proto3" json:"gcs_uri,omitempty"` 90 } 91 92 func (x *Artifact) Reset() { 93 *x = Artifact{} 94 if protoimpl.UnsafeEnabled { 95 mi := &file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_msgTypes[0] 96 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 97 ms.StoreMessageInfo(mi) 98 } 99 } 100 101 func (x *Artifact) String() string { 102 return protoimpl.X.MessageStringOf(x) 103 } 104 105 func (*Artifact) ProtoMessage() {} 106 107 func (x *Artifact) ProtoReflect() protoreflect.Message { 108 mi := &file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_msgTypes[0] 109 if protoimpl.UnsafeEnabled && x != nil { 110 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 111 if ms.LoadMessageInfo() == nil { 112 ms.StoreMessageInfo(mi) 113 } 114 return ms 115 } 116 return mi.MessageOf(x) 117 } 118 119 // Deprecated: Use Artifact.ProtoReflect.Descriptor instead. 120 func (*Artifact) Descriptor() ([]byte, []int) { 121 return file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescGZIP(), []int{0} 122 } 123 124 func (x *Artifact) GetName() string { 125 if x != nil { 126 return x.Name 127 } 128 return "" 129 } 130 131 func (x *Artifact) GetArtifactId() string { 132 if x != nil { 133 return x.ArtifactId 134 } 135 return "" 136 } 137 138 func (x *Artifact) GetFetchUrl() string { 139 if x != nil { 140 return x.FetchUrl 141 } 142 return "" 143 } 144 145 func (x *Artifact) GetFetchUrlExpiration() *timestamppb.Timestamp { 146 if x != nil { 147 return x.FetchUrlExpiration 148 } 149 return nil 150 } 151 152 func (x *Artifact) GetContentType() string { 153 if x != nil { 154 return x.ContentType 155 } 156 return "" 157 } 158 159 func (x *Artifact) GetSizeBytes() int64 { 160 if x != nil { 161 return x.SizeBytes 162 } 163 return 0 164 } 165 166 func (x *Artifact) GetContents() []byte { 167 if x != nil { 168 return x.Contents 169 } 170 return nil 171 } 172 173 func (x *Artifact) GetGcsUri() string { 174 if x != nil { 175 return x.GcsUri 176 } 177 return "" 178 } 179 180 var File_go_chromium_org_luci_resultdb_proto_v1_artifact_proto protoreflect.FileDescriptor 181 182 var file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDesc = []byte{ 183 0x0a, 0x35, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 184 0x67, 0x2f, 0x6c, 0x75, 0x63, 0x69, 0x2f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x64, 0x62, 0x2f, 185 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x76, 0x31, 0x2f, 0x61, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 186 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x10, 0x6c, 0x75, 0x63, 0x69, 0x2e, 0x72, 0x65, 187 0x73, 0x75, 0x6c, 0x74, 0x64, 0x62, 0x2e, 0x76, 0x31, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 188 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x62, 0x65, 0x68, 0x61, 189 0x76, 0x69, 0x6f, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 190 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 191 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xa6, 0x02, 0x0a, 0x08, 192 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 193 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 194 0x61, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 195 0x09, 0x52, 0x0a, 0x61, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x49, 0x64, 0x12, 0x1b, 0x0a, 196 0x09, 0x66, 0x65, 0x74, 0x63, 0x68, 0x5f, 0x75, 0x72, 0x6c, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 197 0x52, 0x08, 0x66, 0x65, 0x74, 0x63, 0x68, 0x55, 0x72, 0x6c, 0x12, 0x4c, 0x0a, 0x14, 0x66, 0x65, 198 0x74, 0x63, 0x68, 0x5f, 0x75, 0x72, 0x6c, 0x5f, 0x65, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 199 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 200 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 201 0x74, 0x61, 0x6d, 0x70, 0x52, 0x12, 0x66, 0x65, 0x74, 0x63, 0x68, 0x55, 0x72, 0x6c, 0x45, 0x78, 202 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 203 0x65, 0x6e, 0x74, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 204 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 205 0x69, 0x7a, 0x65, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 206 0x09, 0x73, 0x69, 0x7a, 0x65, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x1f, 0x0a, 0x08, 0x63, 0x6f, 207 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x03, 0xe0, 0x41, 208 0x04, 0x52, 0x08, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x17, 0x0a, 0x07, 0x67, 209 0x63, 0x73, 0x5f, 0x75, 0x72, 0x69, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x67, 0x63, 210 0x73, 0x55, 0x72, 0x69, 0x42, 0x31, 0x5a, 0x2f, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 211 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x6c, 0x75, 0x63, 0x69, 0x2f, 0x72, 0x65, 0x73, 212 0x75, 0x6c, 0x74, 0x64, 0x62, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x76, 0x31, 0x3b, 0x72, 213 0x65, 0x73, 0x75, 0x6c, 0x74, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 214 } 215 216 var ( 217 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescOnce sync.Once 218 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescData = file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDesc 219 ) 220 221 func file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescGZIP() []byte { 222 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescOnce.Do(func() { 223 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescData = protoimpl.X.CompressGZIP(file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescData) 224 }) 225 return file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDescData 226 } 227 228 var file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_msgTypes = make([]protoimpl.MessageInfo, 1) 229 var file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_goTypes = []interface{}{ 230 (*Artifact)(nil), // 0: luci.resultdb.v1.Artifact 231 (*timestamppb.Timestamp)(nil), // 1: google.protobuf.Timestamp 232 } 233 var file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_depIdxs = []int32{ 234 1, // 0: luci.resultdb.v1.Artifact.fetch_url_expiration:type_name -> google.protobuf.Timestamp 235 1, // [1:1] is the sub-list for method output_type 236 1, // [1:1] is the sub-list for method input_type 237 1, // [1:1] is the sub-list for extension type_name 238 1, // [1:1] is the sub-list for extension extendee 239 0, // [0:1] is the sub-list for field type_name 240 } 241 242 func init() { file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_init() } 243 func file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_init() { 244 if File_go_chromium_org_luci_resultdb_proto_v1_artifact_proto != nil { 245 return 246 } 247 if !protoimpl.UnsafeEnabled { 248 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 249 switch v := v.(*Artifact); i { 250 case 0: 251 return &v.state 252 case 1: 253 return &v.sizeCache 254 case 2: 255 return &v.unknownFields 256 default: 257 return nil 258 } 259 } 260 } 261 type x struct{} 262 out := protoimpl.TypeBuilder{ 263 File: protoimpl.DescBuilder{ 264 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 265 RawDescriptor: file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDesc, 266 NumEnums: 0, 267 NumMessages: 1, 268 NumExtensions: 0, 269 NumServices: 0, 270 }, 271 GoTypes: file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_goTypes, 272 DependencyIndexes: file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_depIdxs, 273 MessageInfos: file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_msgTypes, 274 }.Build() 275 File_go_chromium_org_luci_resultdb_proto_v1_artifact_proto = out.File 276 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_rawDesc = nil 277 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_goTypes = nil 278 file_go_chromium_org_luci_resultdb_proto_v1_artifact_proto_depIdxs = nil 279 }