go.chromium.org/luci@v0.0.0-20240309015107-7cdc2e660f33/gce/api/instances/v1/service.pb.go (about) 1 // Copyright 2019 The LUCI Authors. All rights reserved. 2 // Use of this source code is governed under the Apache License, Version 2.0 3 // that can be found in the LICENSE file. 4 5 // Code generated by protoc-gen-go. DO NOT EDIT. 6 // versions: 7 // protoc-gen-go v1.31.0 8 // protoc v3.21.7 9 // source: go.chromium.org/luci/gce/api/instances/v1/service.proto 10 11 package instances 12 13 import prpc "go.chromium.org/luci/grpc/prpc" 14 15 import ( 16 context "context" 17 grpc "google.golang.org/grpc" 18 codes "google.golang.org/grpc/codes" 19 status "google.golang.org/grpc/status" 20 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 21 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 22 emptypb "google.golang.org/protobuf/types/known/emptypb" 23 timestamppb "google.golang.org/protobuf/types/known/timestamppb" 24 reflect "reflect" 25 sync "sync" 26 ) 27 28 const ( 29 // Verify that this generated code is sufficiently up-to-date. 30 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) 31 // Verify that runtime/protoimpl is sufficiently up-to-date. 32 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) 33 ) 34 35 // A disk associated with a GCE instance. 36 type Disk struct { 37 state protoimpl.MessageState 38 sizeCache protoimpl.SizeCache 39 unknownFields protoimpl.UnknownFields 40 41 // The image associated with this disk. 42 // https://cloud.google.com/compute/docs/reference/rest/v1/images/list. 43 Image string `protobuf:"bytes,1,opt,name=image,proto3" json:"image,omitempty"` 44 } 45 46 func (x *Disk) Reset() { 47 *x = Disk{} 48 if protoimpl.UnsafeEnabled { 49 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[0] 50 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 51 ms.StoreMessageInfo(mi) 52 } 53 } 54 55 func (x *Disk) String() string { 56 return protoimpl.X.MessageStringOf(x) 57 } 58 59 func (*Disk) ProtoMessage() {} 60 61 func (x *Disk) ProtoReflect() protoreflect.Message { 62 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[0] 63 if protoimpl.UnsafeEnabled && x != nil { 64 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 65 if ms.LoadMessageInfo() == nil { 66 ms.StoreMessageInfo(mi) 67 } 68 return ms 69 } 70 return mi.MessageOf(x) 71 } 72 73 // Deprecated: Use Disk.ProtoReflect.Descriptor instead. 74 func (*Disk) Descriptor() ([]byte, []int) { 75 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{0} 76 } 77 78 func (x *Disk) GetImage() string { 79 if x != nil { 80 return x.Image 81 } 82 return "" 83 } 84 85 // A network interface associated with a GCE instance. 86 type NetworkInterface struct { 87 state protoimpl.MessageState 88 sizeCache protoimpl.SizeCache 89 unknownFields protoimpl.UnknownFields 90 91 // The internal IP address associated with this network interface. 92 InternalIp string `protobuf:"bytes,1,opt,name=internal_ip,json=internalIp,proto3" json:"internal_ip,omitempty"` 93 // The external IP addresses associated with this network interface. 94 ExternalIps []string `protobuf:"bytes,2,rep,name=external_ips,json=externalIps,proto3" json:"external_ips,omitempty"` 95 } 96 97 func (x *NetworkInterface) Reset() { 98 *x = NetworkInterface{} 99 if protoimpl.UnsafeEnabled { 100 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[1] 101 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 102 ms.StoreMessageInfo(mi) 103 } 104 } 105 106 func (x *NetworkInterface) String() string { 107 return protoimpl.X.MessageStringOf(x) 108 } 109 110 func (*NetworkInterface) ProtoMessage() {} 111 112 func (x *NetworkInterface) ProtoReflect() protoreflect.Message { 113 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[1] 114 if protoimpl.UnsafeEnabled && x != nil { 115 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 116 if ms.LoadMessageInfo() == nil { 117 ms.StoreMessageInfo(mi) 118 } 119 return ms 120 } 121 return mi.MessageOf(x) 122 } 123 124 // Deprecated: Use NetworkInterface.ProtoReflect.Descriptor instead. 125 func (*NetworkInterface) Descriptor() ([]byte, []int) { 126 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{1} 127 } 128 129 func (x *NetworkInterface) GetInternalIp() string { 130 if x != nil { 131 return x.InternalIp 132 } 133 return "" 134 } 135 136 func (x *NetworkInterface) GetExternalIps() []string { 137 if x != nil { 138 return x.ExternalIps 139 } 140 return nil 141 } 142 143 // A GCE instance configured to exist. 144 // The instance actually exists iff the created timestamp is set. 145 type Instance struct { 146 state protoimpl.MessageState 147 sizeCache protoimpl.SizeCache 148 unknownFields protoimpl.UnknownFields 149 150 // The ID of the VM this instance was created from. 151 Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` 152 // The hostname associated with this instance. 153 Hostname string `protobuf:"bytes,2,opt,name=hostname,proto3" json:"hostname,omitempty"` 154 // The zone associated with this instance. 155 // https://cloud.google.com/compute/docs/reference/rest/v1/zones/list. 156 Zone string `protobuf:"bytes,3,opt,name=zone,proto3" json:"zone,omitempty"` 157 // The GCP project associated with this instance. 158 Project string `protobuf:"bytes,4,opt,name=project,proto3" json:"project,omitempty"` 159 // The timestamp when this instance was created. 160 Created *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=created,proto3" json:"created,omitempty"` 161 // The lifetime of this instance. 162 // At the end of its lifetime, the instance is deleted. 163 Lifetime int64 `protobuf:"varint,6,opt,name=lifetime,proto3" json:"lifetime,omitempty"` 164 // The hostname of the Swarming server this instance should connect to. 165 Swarming string `protobuf:"bytes,7,opt,name=swarming,proto3" json:"swarming,omitempty"` 166 // The timestamp when this instance connected to Swarming. 167 Connected *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=connected,proto3" json:"connected,omitempty"` 168 // The timeout of this instance. 169 // If no Swarming bot has connected by the timeout, the instance is deleted. 170 Timeout int64 `protobuf:"varint,9,opt,name=timeout,proto3" json:"timeout,omitempty"` 171 // Whether this instance is drained or not. 172 // A drained instance will be safely deleted regardless of lifetime. 173 Drained bool `protobuf:"varint,10,opt,name=drained,proto3" json:"drained,omitempty"` 174 // The config revision associated with this instance. 175 ConfigRevision string `protobuf:"bytes,11,opt,name=config_revision,json=configRevision,proto3" json:"config_revision,omitempty"` 176 // The disks associated with this instance. 177 Disks []*Disk `protobuf:"bytes,12,rep,name=disks,proto3" json:"disks,omitempty"` 178 // The network interfaces associated with this instance. 179 NetworkInterfaces []*NetworkInterface `protobuf:"bytes,13,rep,name=network_interfaces,json=networkInterfaces,proto3" json:"network_interfaces,omitempty"` 180 // The prefix associated with this instance. 181 Prefix string `protobuf:"bytes,14,opt,name=prefix,proto3" json:"prefix,omitempty"` 182 } 183 184 func (x *Instance) Reset() { 185 *x = Instance{} 186 if protoimpl.UnsafeEnabled { 187 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[2] 188 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 189 ms.StoreMessageInfo(mi) 190 } 191 } 192 193 func (x *Instance) String() string { 194 return protoimpl.X.MessageStringOf(x) 195 } 196 197 func (*Instance) ProtoMessage() {} 198 199 func (x *Instance) ProtoReflect() protoreflect.Message { 200 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[2] 201 if protoimpl.UnsafeEnabled && x != nil { 202 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 203 if ms.LoadMessageInfo() == nil { 204 ms.StoreMessageInfo(mi) 205 } 206 return ms 207 } 208 return mi.MessageOf(x) 209 } 210 211 // Deprecated: Use Instance.ProtoReflect.Descriptor instead. 212 func (*Instance) Descriptor() ([]byte, []int) { 213 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{2} 214 } 215 216 func (x *Instance) GetId() string { 217 if x != nil { 218 return x.Id 219 } 220 return "" 221 } 222 223 func (x *Instance) GetHostname() string { 224 if x != nil { 225 return x.Hostname 226 } 227 return "" 228 } 229 230 func (x *Instance) GetZone() string { 231 if x != nil { 232 return x.Zone 233 } 234 return "" 235 } 236 237 func (x *Instance) GetProject() string { 238 if x != nil { 239 return x.Project 240 } 241 return "" 242 } 243 244 func (x *Instance) GetCreated() *timestamppb.Timestamp { 245 if x != nil { 246 return x.Created 247 } 248 return nil 249 } 250 251 func (x *Instance) GetLifetime() int64 { 252 if x != nil { 253 return x.Lifetime 254 } 255 return 0 256 } 257 258 func (x *Instance) GetSwarming() string { 259 if x != nil { 260 return x.Swarming 261 } 262 return "" 263 } 264 265 func (x *Instance) GetConnected() *timestamppb.Timestamp { 266 if x != nil { 267 return x.Connected 268 } 269 return nil 270 } 271 272 func (x *Instance) GetTimeout() int64 { 273 if x != nil { 274 return x.Timeout 275 } 276 return 0 277 } 278 279 func (x *Instance) GetDrained() bool { 280 if x != nil { 281 return x.Drained 282 } 283 return false 284 } 285 286 func (x *Instance) GetConfigRevision() string { 287 if x != nil { 288 return x.ConfigRevision 289 } 290 return "" 291 } 292 293 func (x *Instance) GetDisks() []*Disk { 294 if x != nil { 295 return x.Disks 296 } 297 return nil 298 } 299 300 func (x *Instance) GetNetworkInterfaces() []*NetworkInterface { 301 if x != nil { 302 return x.NetworkInterfaces 303 } 304 return nil 305 } 306 307 func (x *Instance) GetPrefix() string { 308 if x != nil { 309 return x.Prefix 310 } 311 return "" 312 } 313 314 // A request to delete an instance. 315 type DeleteRequest struct { 316 state protoimpl.MessageState 317 sizeCache protoimpl.SizeCache 318 unknownFields protoimpl.UnknownFields 319 320 // The ID of the instance to delete. 321 Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` 322 // The hostname of the instance to delete. 323 Hostname string `protobuf:"bytes,2,opt,name=hostname,proto3" json:"hostname,omitempty"` 324 } 325 326 func (x *DeleteRequest) Reset() { 327 *x = DeleteRequest{} 328 if protoimpl.UnsafeEnabled { 329 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[3] 330 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 331 ms.StoreMessageInfo(mi) 332 } 333 } 334 335 func (x *DeleteRequest) String() string { 336 return protoimpl.X.MessageStringOf(x) 337 } 338 339 func (*DeleteRequest) ProtoMessage() {} 340 341 func (x *DeleteRequest) ProtoReflect() protoreflect.Message { 342 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[3] 343 if protoimpl.UnsafeEnabled && x != nil { 344 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 345 if ms.LoadMessageInfo() == nil { 346 ms.StoreMessageInfo(mi) 347 } 348 return ms 349 } 350 return mi.MessageOf(x) 351 } 352 353 // Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead. 354 func (*DeleteRequest) Descriptor() ([]byte, []int) { 355 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{3} 356 } 357 358 func (x *DeleteRequest) GetId() string { 359 if x != nil { 360 return x.Id 361 } 362 return "" 363 } 364 365 func (x *DeleteRequest) GetHostname() string { 366 if x != nil { 367 return x.Hostname 368 } 369 return "" 370 } 371 372 // A request to get an existing instance. 373 type GetRequest struct { 374 state protoimpl.MessageState 375 sizeCache protoimpl.SizeCache 376 unknownFields protoimpl.UnknownFields 377 378 // The ID of the instance to get. 379 Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` 380 // The hostname of the instance to get. 381 Hostname string `protobuf:"bytes,2,opt,name=hostname,proto3" json:"hostname,omitempty"` 382 } 383 384 func (x *GetRequest) Reset() { 385 *x = GetRequest{} 386 if protoimpl.UnsafeEnabled { 387 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[4] 388 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 389 ms.StoreMessageInfo(mi) 390 } 391 } 392 393 func (x *GetRequest) String() string { 394 return protoimpl.X.MessageStringOf(x) 395 } 396 397 func (*GetRequest) ProtoMessage() {} 398 399 func (x *GetRequest) ProtoReflect() protoreflect.Message { 400 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[4] 401 if protoimpl.UnsafeEnabled && x != nil { 402 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 403 if ms.LoadMessageInfo() == nil { 404 ms.StoreMessageInfo(mi) 405 } 406 return ms 407 } 408 return mi.MessageOf(x) 409 } 410 411 // Deprecated: Use GetRequest.ProtoReflect.Descriptor instead. 412 func (*GetRequest) Descriptor() ([]byte, []int) { 413 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{4} 414 } 415 416 func (x *GetRequest) GetId() string { 417 if x != nil { 418 return x.Id 419 } 420 return "" 421 } 422 423 func (x *GetRequest) GetHostname() string { 424 if x != nil { 425 return x.Hostname 426 } 427 return "" 428 } 429 430 // A request to list existing instances. 431 type ListRequest struct { 432 state protoimpl.MessageState 433 sizeCache protoimpl.SizeCache 434 unknownFields protoimpl.UnknownFields 435 436 // The prefix to list instances for. 437 Prefix string `protobuf:"bytes,1,opt,name=prefix,proto3" json:"prefix,omitempty"` 438 // The value of next_page_token received in a ListResponse. Used to get the 439 // next page of instances. If empty, gets the first page. 440 PageToken string `protobuf:"bytes,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"` 441 // The maximum number of results to include in the response. 442 PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"` 443 // A filter to apply when listing instances. Currently the only supported 444 // filter is "disks.image=<image>" where <image> is the name of the image to 445 // filter for. 446 Filter string `protobuf:"bytes,4,opt,name=filter,proto3" json:"filter,omitempty"` 447 } 448 449 func (x *ListRequest) Reset() { 450 *x = ListRequest{} 451 if protoimpl.UnsafeEnabled { 452 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[5] 453 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 454 ms.StoreMessageInfo(mi) 455 } 456 } 457 458 func (x *ListRequest) String() string { 459 return protoimpl.X.MessageStringOf(x) 460 } 461 462 func (*ListRequest) ProtoMessage() {} 463 464 func (x *ListRequest) ProtoReflect() protoreflect.Message { 465 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[5] 466 if protoimpl.UnsafeEnabled && x != nil { 467 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 468 if ms.LoadMessageInfo() == nil { 469 ms.StoreMessageInfo(mi) 470 } 471 return ms 472 } 473 return mi.MessageOf(x) 474 } 475 476 // Deprecated: Use ListRequest.ProtoReflect.Descriptor instead. 477 func (*ListRequest) Descriptor() ([]byte, []int) { 478 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{5} 479 } 480 481 func (x *ListRequest) GetPrefix() string { 482 if x != nil { 483 return x.Prefix 484 } 485 return "" 486 } 487 488 func (x *ListRequest) GetPageToken() string { 489 if x != nil { 490 return x.PageToken 491 } 492 return "" 493 } 494 495 func (x *ListRequest) GetPageSize() int32 { 496 if x != nil { 497 return x.PageSize 498 } 499 return 0 500 } 501 502 func (x *ListRequest) GetFilter() string { 503 if x != nil { 504 return x.Filter 505 } 506 return "" 507 } 508 509 // A response to a request to list instances. 510 type ListResponse struct { 511 state protoimpl.MessageState 512 sizeCache protoimpl.SizeCache 513 unknownFields protoimpl.UnknownFields 514 515 // The prefix the instances are for. 516 Prefix string `protobuf:"bytes,1,opt,name=prefix,proto3" json:"prefix,omitempty"` 517 // The instances matching the prefix. 518 Instances []*Instance `protobuf:"bytes,2,rep,name=instances,proto3" json:"instances,omitempty"` 519 // The value to use as the page_token in a ListRequest to get the next page of 520 // instances. If empty, there are no more instances. 521 NextPageToken string `protobuf:"bytes,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"` 522 } 523 524 func (x *ListResponse) Reset() { 525 *x = ListResponse{} 526 if protoimpl.UnsafeEnabled { 527 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[6] 528 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 529 ms.StoreMessageInfo(mi) 530 } 531 } 532 533 func (x *ListResponse) String() string { 534 return protoimpl.X.MessageStringOf(x) 535 } 536 537 func (*ListResponse) ProtoMessage() {} 538 539 func (x *ListResponse) ProtoReflect() protoreflect.Message { 540 mi := &file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[6] 541 if protoimpl.UnsafeEnabled && x != nil { 542 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 543 if ms.LoadMessageInfo() == nil { 544 ms.StoreMessageInfo(mi) 545 } 546 return ms 547 } 548 return mi.MessageOf(x) 549 } 550 551 // Deprecated: Use ListResponse.ProtoReflect.Descriptor instead. 552 func (*ListResponse) Descriptor() ([]byte, []int) { 553 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP(), []int{6} 554 } 555 556 func (x *ListResponse) GetPrefix() string { 557 if x != nil { 558 return x.Prefix 559 } 560 return "" 561 } 562 563 func (x *ListResponse) GetInstances() []*Instance { 564 if x != nil { 565 return x.Instances 566 } 567 return nil 568 } 569 570 func (x *ListResponse) GetNextPageToken() string { 571 if x != nil { 572 return x.NextPageToken 573 } 574 return "" 575 } 576 577 var File_go_chromium_org_luci_gce_api_instances_v1_service_proto protoreflect.FileDescriptor 578 579 var file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDesc = []byte{ 580 0x0a, 0x37, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 581 0x67, 0x2f, 0x6c, 0x75, 0x63, 0x69, 0x2f, 0x67, 0x63, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x69, 582 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x76, 0x31, 0x2f, 0x73, 0x65, 0x72, 0x76, 583 0x69, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x09, 0x69, 0x6e, 0x73, 0x74, 0x61, 584 0x6e, 0x63, 0x65, 0x73, 0x1a, 0x1b, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 585 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 586 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 587 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 588 0x74, 0x6f, 0x22, 0x1c, 0x0a, 0x04, 0x44, 0x69, 0x73, 0x6b, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6d, 589 0x61, 0x67, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x69, 0x6d, 0x61, 0x67, 0x65, 590 0x22, 0x56, 0x0a, 0x10, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x6e, 0x74, 0x65, 0x72, 591 0x66, 0x61, 0x63, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 592 0x5f, 0x69, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x6e, 0x74, 0x65, 0x72, 593 0x6e, 0x61, 0x6c, 0x49, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x65, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61, 594 0x6c, 0x5f, 0x69, 0x70, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0b, 0x65, 0x78, 0x74, 595 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x49, 0x70, 0x73, 0x22, 0xf4, 0x03, 0x0a, 0x08, 0x49, 0x6e, 0x73, 596 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 597 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x68, 0x6f, 0x73, 0x74, 0x6e, 0x61, 0x6d, 598 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x68, 0x6f, 0x73, 0x74, 0x6e, 0x61, 0x6d, 599 0x65, 0x12, 0x12, 0x0a, 0x04, 0x7a, 0x6f, 0x6e, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 600 0x04, 0x7a, 0x6f, 0x6e, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 601 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12, 602 0x34, 0x0a, 0x07, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 603 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 604 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x07, 0x63, 0x72, 605 0x65, 0x61, 0x74, 0x65, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 606 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x52, 0x08, 0x6c, 0x69, 0x66, 0x65, 0x74, 0x69, 0x6d, 607 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x18, 0x07, 0x20, 608 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x12, 0x38, 0x0a, 609 0x09, 0x63, 0x6f, 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x65, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 610 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 611 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x63, 0x6f, 612 0x6e, 0x6e, 0x65, 0x63, 0x74, 0x65, 0x64, 0x12, 0x18, 0x0a, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 613 0x75, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 614 0x74, 0x12, 0x18, 0x0a, 0x07, 0x64, 0x72, 0x61, 0x69, 0x6e, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 615 0x28, 0x08, 0x52, 0x07, 0x64, 0x72, 0x61, 0x69, 0x6e, 0x65, 0x64, 0x12, 0x27, 0x0a, 0x0f, 0x63, 616 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x72, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x0b, 617 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x76, 0x69, 618 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x25, 0x0a, 0x05, 0x64, 0x69, 0x73, 0x6b, 0x73, 0x18, 0x0c, 0x20, 619 0x03, 0x28, 0x0b, 0x32, 0x0f, 0x2e, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2e, 620 0x44, 0x69, 0x73, 0x6b, 0x52, 0x05, 0x64, 0x69, 0x73, 0x6b, 0x73, 0x12, 0x4a, 0x0a, 0x12, 0x6e, 621 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x5f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 622 0x73, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 623 0x63, 0x65, 0x73, 0x2e, 0x4e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x6e, 0x74, 0x65, 0x72, 624 0x66, 0x61, 0x63, 0x65, 0x52, 0x11, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x6e, 0x74, 625 0x65, 0x72, 0x66, 0x61, 0x63, 0x65, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 626 0x78, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x22, 627 0x3b, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 628 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 629 0x12, 0x1a, 0x0a, 0x08, 0x68, 0x6f, 0x73, 0x74, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 630 0x28, 0x09, 0x52, 0x08, 0x68, 0x6f, 0x73, 0x74, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x38, 0x0a, 0x0a, 631 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 632 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x68, 0x6f, 633 0x73, 0x74, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x68, 0x6f, 634 0x73, 0x74, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x79, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 635 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 636 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x1d, 0x0a, 637 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 638 0x09, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1b, 0x0a, 0x09, 639 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 640 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x66, 0x69, 0x6c, 641 0x74, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x66, 0x69, 0x6c, 0x74, 0x65, 642 0x72, 0x22, 0x81, 0x01, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 643 0x73, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 0x01, 0x20, 0x01, 644 0x28, 0x09, 0x52, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x31, 0x0a, 0x09, 0x69, 0x6e, 645 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x13, 0x2e, 646 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 647 0x63, 0x65, 0x52, 0x09, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x26, 0x0a, 648 0x0f, 0x6e, 0x65, 0x78, 0x74, 0x5f, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 649 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x6e, 0x65, 0x78, 0x74, 0x50, 0x61, 0x67, 0x65, 650 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x32, 0xb3, 0x01, 0x0a, 0x09, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 651 0x63, 0x65, 0x73, 0x12, 0x3a, 0x0a, 0x06, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x18, 0x2e, 652 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 653 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 654 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x12, 655 0x31, 0x0a, 0x03, 0x47, 0x65, 0x74, 0x12, 0x15, 0x2e, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 656 0x65, 0x73, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x13, 0x2e, 657 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 658 0x63, 0x65, 0x12, 0x37, 0x0a, 0x04, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x16, 0x2e, 0x69, 0x6e, 0x73, 659 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 660 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2e, 0x4c, 661 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x35, 0x5a, 0x33, 0x67, 662 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x6c, 663 0x75, 0x63, 0x69, 0x2f, 0x67, 0x63, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x69, 0x6e, 0x73, 0x74, 664 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 665 0x65, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 666 } 667 668 var ( 669 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescOnce sync.Once 670 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescData = file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDesc 671 ) 672 673 func file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescGZIP() []byte { 674 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescOnce.Do(func() { 675 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescData = protoimpl.X.CompressGZIP(file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescData) 676 }) 677 return file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDescData 678 } 679 680 var file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes = make([]protoimpl.MessageInfo, 7) 681 var file_go_chromium_org_luci_gce_api_instances_v1_service_proto_goTypes = []interface{}{ 682 (*Disk)(nil), // 0: instances.Disk 683 (*NetworkInterface)(nil), // 1: instances.NetworkInterface 684 (*Instance)(nil), // 2: instances.Instance 685 (*DeleteRequest)(nil), // 3: instances.DeleteRequest 686 (*GetRequest)(nil), // 4: instances.GetRequest 687 (*ListRequest)(nil), // 5: instances.ListRequest 688 (*ListResponse)(nil), // 6: instances.ListResponse 689 (*timestamppb.Timestamp)(nil), // 7: google.protobuf.Timestamp 690 (*emptypb.Empty)(nil), // 8: google.protobuf.Empty 691 } 692 var file_go_chromium_org_luci_gce_api_instances_v1_service_proto_depIdxs = []int32{ 693 7, // 0: instances.Instance.created:type_name -> google.protobuf.Timestamp 694 7, // 1: instances.Instance.connected:type_name -> google.protobuf.Timestamp 695 0, // 2: instances.Instance.disks:type_name -> instances.Disk 696 1, // 3: instances.Instance.network_interfaces:type_name -> instances.NetworkInterface 697 2, // 4: instances.ListResponse.instances:type_name -> instances.Instance 698 3, // 5: instances.Instances.Delete:input_type -> instances.DeleteRequest 699 4, // 6: instances.Instances.Get:input_type -> instances.GetRequest 700 5, // 7: instances.Instances.List:input_type -> instances.ListRequest 701 8, // 8: instances.Instances.Delete:output_type -> google.protobuf.Empty 702 2, // 9: instances.Instances.Get:output_type -> instances.Instance 703 6, // 10: instances.Instances.List:output_type -> instances.ListResponse 704 8, // [8:11] is the sub-list for method output_type 705 5, // [5:8] is the sub-list for method input_type 706 5, // [5:5] is the sub-list for extension type_name 707 5, // [5:5] is the sub-list for extension extendee 708 0, // [0:5] is the sub-list for field type_name 709 } 710 711 func init() { file_go_chromium_org_luci_gce_api_instances_v1_service_proto_init() } 712 func file_go_chromium_org_luci_gce_api_instances_v1_service_proto_init() { 713 if File_go_chromium_org_luci_gce_api_instances_v1_service_proto != nil { 714 return 715 } 716 if !protoimpl.UnsafeEnabled { 717 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 718 switch v := v.(*Disk); i { 719 case 0: 720 return &v.state 721 case 1: 722 return &v.sizeCache 723 case 2: 724 return &v.unknownFields 725 default: 726 return nil 727 } 728 } 729 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 730 switch v := v.(*NetworkInterface); i { 731 case 0: 732 return &v.state 733 case 1: 734 return &v.sizeCache 735 case 2: 736 return &v.unknownFields 737 default: 738 return nil 739 } 740 } 741 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { 742 switch v := v.(*Instance); i { 743 case 0: 744 return &v.state 745 case 1: 746 return &v.sizeCache 747 case 2: 748 return &v.unknownFields 749 default: 750 return nil 751 } 752 } 753 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { 754 switch v := v.(*DeleteRequest); i { 755 case 0: 756 return &v.state 757 case 1: 758 return &v.sizeCache 759 case 2: 760 return &v.unknownFields 761 default: 762 return nil 763 } 764 } 765 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { 766 switch v := v.(*GetRequest); i { 767 case 0: 768 return &v.state 769 case 1: 770 return &v.sizeCache 771 case 2: 772 return &v.unknownFields 773 default: 774 return nil 775 } 776 } 777 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { 778 switch v := v.(*ListRequest); i { 779 case 0: 780 return &v.state 781 case 1: 782 return &v.sizeCache 783 case 2: 784 return &v.unknownFields 785 default: 786 return nil 787 } 788 } 789 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { 790 switch v := v.(*ListResponse); i { 791 case 0: 792 return &v.state 793 case 1: 794 return &v.sizeCache 795 case 2: 796 return &v.unknownFields 797 default: 798 return nil 799 } 800 } 801 } 802 type x struct{} 803 out := protoimpl.TypeBuilder{ 804 File: protoimpl.DescBuilder{ 805 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 806 RawDescriptor: file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDesc, 807 NumEnums: 0, 808 NumMessages: 7, 809 NumExtensions: 0, 810 NumServices: 1, 811 }, 812 GoTypes: file_go_chromium_org_luci_gce_api_instances_v1_service_proto_goTypes, 813 DependencyIndexes: file_go_chromium_org_luci_gce_api_instances_v1_service_proto_depIdxs, 814 MessageInfos: file_go_chromium_org_luci_gce_api_instances_v1_service_proto_msgTypes, 815 }.Build() 816 File_go_chromium_org_luci_gce_api_instances_v1_service_proto = out.File 817 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_rawDesc = nil 818 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_goTypes = nil 819 file_go_chromium_org_luci_gce_api_instances_v1_service_proto_depIdxs = nil 820 } 821 822 // Reference imports to suppress errors if they are not otherwise used. 823 var _ context.Context 824 var _ grpc.ClientConnInterface 825 826 // This is a compile-time assertion to ensure that this generated file 827 // is compatible with the grpc package it is being compiled against. 828 const _ = grpc.SupportPackageIsVersion6 829 830 // InstancesClient is the client API for Instances service. 831 // 832 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. 833 type InstancesClient interface { 834 // Delete deletes an instance asynchronously. 835 Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) 836 // Get returns an existing instance. 837 Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*Instance, error) 838 // List returns existing instances. 839 List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error) 840 } 841 type instancesPRPCClient struct { 842 client *prpc.Client 843 } 844 845 func NewInstancesPRPCClient(client *prpc.Client) InstancesClient { 846 return &instancesPRPCClient{client} 847 } 848 849 func (c *instancesPRPCClient) Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { 850 out := new(emptypb.Empty) 851 err := c.client.Call(ctx, "instances.Instances", "Delete", in, out, opts...) 852 if err != nil { 853 return nil, err 854 } 855 return out, nil 856 } 857 858 func (c *instancesPRPCClient) Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*Instance, error) { 859 out := new(Instance) 860 err := c.client.Call(ctx, "instances.Instances", "Get", in, out, opts...) 861 if err != nil { 862 return nil, err 863 } 864 return out, nil 865 } 866 867 func (c *instancesPRPCClient) List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error) { 868 out := new(ListResponse) 869 err := c.client.Call(ctx, "instances.Instances", "List", in, out, opts...) 870 if err != nil { 871 return nil, err 872 } 873 return out, nil 874 } 875 876 type instancesClient struct { 877 cc grpc.ClientConnInterface 878 } 879 880 func NewInstancesClient(cc grpc.ClientConnInterface) InstancesClient { 881 return &instancesClient{cc} 882 } 883 884 func (c *instancesClient) Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) { 885 out := new(emptypb.Empty) 886 err := c.cc.Invoke(ctx, "/instances.Instances/Delete", in, out, opts...) 887 if err != nil { 888 return nil, err 889 } 890 return out, nil 891 } 892 893 func (c *instancesClient) Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*Instance, error) { 894 out := new(Instance) 895 err := c.cc.Invoke(ctx, "/instances.Instances/Get", in, out, opts...) 896 if err != nil { 897 return nil, err 898 } 899 return out, nil 900 } 901 902 func (c *instancesClient) List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error) { 903 out := new(ListResponse) 904 err := c.cc.Invoke(ctx, "/instances.Instances/List", in, out, opts...) 905 if err != nil { 906 return nil, err 907 } 908 return out, nil 909 } 910 911 // InstancesServer is the server API for Instances service. 912 type InstancesServer interface { 913 // Delete deletes an instance asynchronously. 914 Delete(context.Context, *DeleteRequest) (*emptypb.Empty, error) 915 // Get returns an existing instance. 916 Get(context.Context, *GetRequest) (*Instance, error) 917 // List returns existing instances. 918 List(context.Context, *ListRequest) (*ListResponse, error) 919 } 920 921 // UnimplementedInstancesServer can be embedded to have forward compatible implementations. 922 type UnimplementedInstancesServer struct { 923 } 924 925 func (*UnimplementedInstancesServer) Delete(context.Context, *DeleteRequest) (*emptypb.Empty, error) { 926 return nil, status.Errorf(codes.Unimplemented, "method Delete not implemented") 927 } 928 func (*UnimplementedInstancesServer) Get(context.Context, *GetRequest) (*Instance, error) { 929 return nil, status.Errorf(codes.Unimplemented, "method Get not implemented") 930 } 931 func (*UnimplementedInstancesServer) List(context.Context, *ListRequest) (*ListResponse, error) { 932 return nil, status.Errorf(codes.Unimplemented, "method List not implemented") 933 } 934 935 func RegisterInstancesServer(s prpc.Registrar, srv InstancesServer) { 936 s.RegisterService(&_Instances_serviceDesc, srv) 937 } 938 939 func _Instances_Delete_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 940 in := new(DeleteRequest) 941 if err := dec(in); err != nil { 942 return nil, err 943 } 944 if interceptor == nil { 945 return srv.(InstancesServer).Delete(ctx, in) 946 } 947 info := &grpc.UnaryServerInfo{ 948 Server: srv, 949 FullMethod: "/instances.Instances/Delete", 950 } 951 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 952 return srv.(InstancesServer).Delete(ctx, req.(*DeleteRequest)) 953 } 954 return interceptor(ctx, in, info, handler) 955 } 956 957 func _Instances_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 958 in := new(GetRequest) 959 if err := dec(in); err != nil { 960 return nil, err 961 } 962 if interceptor == nil { 963 return srv.(InstancesServer).Get(ctx, in) 964 } 965 info := &grpc.UnaryServerInfo{ 966 Server: srv, 967 FullMethod: "/instances.Instances/Get", 968 } 969 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 970 return srv.(InstancesServer).Get(ctx, req.(*GetRequest)) 971 } 972 return interceptor(ctx, in, info, handler) 973 } 974 975 func _Instances_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 976 in := new(ListRequest) 977 if err := dec(in); err != nil { 978 return nil, err 979 } 980 if interceptor == nil { 981 return srv.(InstancesServer).List(ctx, in) 982 } 983 info := &grpc.UnaryServerInfo{ 984 Server: srv, 985 FullMethod: "/instances.Instances/List", 986 } 987 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 988 return srv.(InstancesServer).List(ctx, req.(*ListRequest)) 989 } 990 return interceptor(ctx, in, info, handler) 991 } 992 993 var _Instances_serviceDesc = grpc.ServiceDesc{ 994 ServiceName: "instances.Instances", 995 HandlerType: (*InstancesServer)(nil), 996 Methods: []grpc.MethodDesc{ 997 { 998 MethodName: "Delete", 999 Handler: _Instances_Delete_Handler, 1000 }, 1001 { 1002 MethodName: "Get", 1003 Handler: _Instances_Get_Handler, 1004 }, 1005 { 1006 MethodName: "List", 1007 Handler: _Instances_List_Handler, 1008 }, 1009 }, 1010 Streams: []grpc.StreamDesc{}, 1011 Metadata: "go.chromium.org/luci/gce/api/instances/v1/service.proto", 1012 }