1// Code generated by protoc-gen-go. DO NOT EDIT. 2// source: google/api/servicemanagement/v1/resources.proto 3 4/* 5Package servicemanagement is a generated protocol buffer package. 6 7It is generated from these files: 8 google/api/servicemanagement/v1/resources.proto 9 google/api/servicemanagement/v1/servicemanager.proto 10 11It has these top-level messages: 12 ManagedService 13 OperationMetadata 14 Diagnostic 15 ConfigSource 16 ConfigFile 17 ConfigRef 18 ChangeReport 19 Rollout 20 ListServicesRequest 21 ListServicesResponse 22 GetServiceRequest 23 CreateServiceRequest 24 DeleteServiceRequest 25 UndeleteServiceRequest 26 UndeleteServiceResponse 27 GetServiceConfigRequest 28 ListServiceConfigsRequest 29 ListServiceConfigsResponse 30 CreateServiceConfigRequest 31 SubmitConfigSourceRequest 32 SubmitConfigSourceResponse 33 CreateServiceRolloutRequest 34 ListServiceRolloutsRequest 35 ListServiceRolloutsResponse 36 GetServiceRolloutRequest 37 EnableServiceRequest 38 DisableServiceRequest 39 GenerateConfigReportRequest 40 GenerateConfigReportResponse 41*/ 42package servicemanagement 43 44import proto "github.com/golang/protobuf/proto" 45import fmt "fmt" 46import math "math" 47import _ "google.golang.org/genproto/googleapis/api/annotations" 48import google_api2 "google.golang.org/genproto/googleapis/api/configchange" 49import _ "google.golang.org/genproto/googleapis/api/serviceconfig" 50import _ "google.golang.org/genproto/googleapis/longrunning" 51import _ "github.com/golang/protobuf/ptypes/any" 52import _ "google.golang.org/genproto/protobuf/field_mask" 53import _ "github.com/golang/protobuf/ptypes/struct" 54import google_protobuf9 "github.com/golang/protobuf/ptypes/timestamp" 55import _ "google.golang.org/genproto/googleapis/rpc/status" 56 57// Reference imports to suppress errors if they are not otherwise used. 58var _ = proto.Marshal 59var _ = fmt.Errorf 60var _ = math.Inf 61 62// This is a compile-time assertion to ensure that this generated file 63// is compatible with the proto package it is being compiled against. 64// A compilation error at this line likely means your copy of the 65// proto package needs to be updated. 66const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package 67 68// Code describes the status of one operation step. 69type OperationMetadata_Status int32 70 71const ( 72 // Unspecifed code. 73 OperationMetadata_STATUS_UNSPECIFIED OperationMetadata_Status = 0 74 // The step has completed without errors. 75 OperationMetadata_DONE OperationMetadata_Status = 1 76 // The step has not started yet. 77 OperationMetadata_NOT_STARTED OperationMetadata_Status = 2 78 // The step is in progress. 79 OperationMetadata_IN_PROGRESS OperationMetadata_Status = 3 80 // The step has completed with errors. 81 OperationMetadata_FAILED OperationMetadata_Status = 4 82 // The step has completed with cancellation. 83 OperationMetadata_CANCELLED OperationMetadata_Status = 5 84) 85 86var OperationMetadata_Status_name = map[int32]string{ 87 0: "STATUS_UNSPECIFIED", 88 1: "DONE", 89 2: "NOT_STARTED", 90 3: "IN_PROGRESS", 91 4: "FAILED", 92 5: "CANCELLED", 93} 94var OperationMetadata_Status_value = map[string]int32{ 95 "STATUS_UNSPECIFIED": 0, 96 "DONE": 1, 97 "NOT_STARTED": 2, 98 "IN_PROGRESS": 3, 99 "FAILED": 4, 100 "CANCELLED": 5, 101} 102 103func (x OperationMetadata_Status) String() string { 104 return proto.EnumName(OperationMetadata_Status_name, int32(x)) 105} 106func (OperationMetadata_Status) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{1, 0} } 107 108// The kind of diagnostic information possible. 109type Diagnostic_Kind int32 110 111const ( 112 // Warnings and errors 113 Diagnostic_WARNING Diagnostic_Kind = 0 114 // Only errors 115 Diagnostic_ERROR Diagnostic_Kind = 1 116) 117 118var Diagnostic_Kind_name = map[int32]string{ 119 0: "WARNING", 120 1: "ERROR", 121} 122var Diagnostic_Kind_value = map[string]int32{ 123 "WARNING": 0, 124 "ERROR": 1, 125} 126 127func (x Diagnostic_Kind) String() string { 128 return proto.EnumName(Diagnostic_Kind_name, int32(x)) 129} 130func (Diagnostic_Kind) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{2, 0} } 131 132type ConfigFile_FileType int32 133 134const ( 135 // Unknown file type. 136 ConfigFile_FILE_TYPE_UNSPECIFIED ConfigFile_FileType = 0 137 // YAML-specification of service. 138 ConfigFile_SERVICE_CONFIG_YAML ConfigFile_FileType = 1 139 // OpenAPI specification, serialized in JSON. 140 ConfigFile_OPEN_API_JSON ConfigFile_FileType = 2 141 // OpenAPI specification, serialized in YAML. 142 ConfigFile_OPEN_API_YAML ConfigFile_FileType = 3 143 // FileDescriptorSet, generated by protoc. 144 // 145 // To generate, use protoc with imports and source info included. 146 // For an example test.proto file, the following command would put the value 147 // in a new file named out.pb. 148 // 149 // $protoc --include_imports --include_source_info test.proto -o out.pb 150 ConfigFile_FILE_DESCRIPTOR_SET_PROTO ConfigFile_FileType = 4 151) 152 153var ConfigFile_FileType_name = map[int32]string{ 154 0: "FILE_TYPE_UNSPECIFIED", 155 1: "SERVICE_CONFIG_YAML", 156 2: "OPEN_API_JSON", 157 3: "OPEN_API_YAML", 158 4: "FILE_DESCRIPTOR_SET_PROTO", 159} 160var ConfigFile_FileType_value = map[string]int32{ 161 "FILE_TYPE_UNSPECIFIED": 0, 162 "SERVICE_CONFIG_YAML": 1, 163 "OPEN_API_JSON": 2, 164 "OPEN_API_YAML": 3, 165 "FILE_DESCRIPTOR_SET_PROTO": 4, 166} 167 168func (x ConfigFile_FileType) String() string { 169 return proto.EnumName(ConfigFile_FileType_name, int32(x)) 170} 171func (ConfigFile_FileType) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{4, 0} } 172 173// Status of a Rollout. 174type Rollout_RolloutStatus int32 175 176const ( 177 // No status specified. 178 Rollout_ROLLOUT_STATUS_UNSPECIFIED Rollout_RolloutStatus = 0 179 // The Rollout is in progress. 180 Rollout_IN_PROGRESS Rollout_RolloutStatus = 1 181 // The Rollout has completed successfully. 182 Rollout_SUCCESS Rollout_RolloutStatus = 2 183 // The Rollout has been cancelled. This can happen if you have overlapping 184 // Rollout pushes, and the previous ones will be cancelled. 185 Rollout_CANCELLED Rollout_RolloutStatus = 3 186 // The Rollout has failed. It is typically caused by configuration errors. 187 Rollout_FAILED Rollout_RolloutStatus = 4 188 // The Rollout has not started yet and is pending for execution. 189 Rollout_PENDING Rollout_RolloutStatus = 5 190) 191 192var Rollout_RolloutStatus_name = map[int32]string{ 193 0: "ROLLOUT_STATUS_UNSPECIFIED", 194 1: "IN_PROGRESS", 195 2: "SUCCESS", 196 3: "CANCELLED", 197 4: "FAILED", 198 5: "PENDING", 199} 200var Rollout_RolloutStatus_value = map[string]int32{ 201 "ROLLOUT_STATUS_UNSPECIFIED": 0, 202 "IN_PROGRESS": 1, 203 "SUCCESS": 2, 204 "CANCELLED": 3, 205 "FAILED": 4, 206 "PENDING": 5, 207} 208 209func (x Rollout_RolloutStatus) String() string { 210 return proto.EnumName(Rollout_RolloutStatus_name, int32(x)) 211} 212func (Rollout_RolloutStatus) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{7, 0} } 213 214// The full representation of a Service that is managed by 215// Google Service Management. 216type ManagedService struct { 217 // The name of the service. See the [overview](/service-management/overview) 218 // for naming requirements. 219 ServiceName string `protobuf:"bytes,2,opt,name=service_name,json=serviceName" json:"service_name,omitempty"` 220 // ID of the project that produces and owns this service. 221 ProducerProjectId string `protobuf:"bytes,3,opt,name=producer_project_id,json=producerProjectId" json:"producer_project_id,omitempty"` 222} 223 224func (m *ManagedService) Reset() { *m = ManagedService{} } 225func (m *ManagedService) String() string { return proto.CompactTextString(m) } 226func (*ManagedService) ProtoMessage() {} 227func (*ManagedService) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } 228 229func (m *ManagedService) GetServiceName() string { 230 if m != nil { 231 return m.ServiceName 232 } 233 return "" 234} 235 236func (m *ManagedService) GetProducerProjectId() string { 237 if m != nil { 238 return m.ProducerProjectId 239 } 240 return "" 241} 242 243// The metadata associated with a long running operation resource. 244type OperationMetadata struct { 245 // The full name of the resources that this operation is directly 246 // associated with. 247 ResourceNames []string `protobuf:"bytes,1,rep,name=resource_names,json=resourceNames" json:"resource_names,omitempty"` 248 // Detailed status information for each step. The order is undetermined. 249 Steps []*OperationMetadata_Step `protobuf:"bytes,2,rep,name=steps" json:"steps,omitempty"` 250 // Percentage of completion of this operation, ranging from 0 to 100. 251 ProgressPercentage int32 `protobuf:"varint,3,opt,name=progress_percentage,json=progressPercentage" json:"progress_percentage,omitempty"` 252 // The start time of the operation. 253 StartTime *google_protobuf9.Timestamp `protobuf:"bytes,4,opt,name=start_time,json=startTime" json:"start_time,omitempty"` 254} 255 256func (m *OperationMetadata) Reset() { *m = OperationMetadata{} } 257func (m *OperationMetadata) String() string { return proto.CompactTextString(m) } 258func (*OperationMetadata) ProtoMessage() {} 259func (*OperationMetadata) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } 260 261func (m *OperationMetadata) GetResourceNames() []string { 262 if m != nil { 263 return m.ResourceNames 264 } 265 return nil 266} 267 268func (m *OperationMetadata) GetSteps() []*OperationMetadata_Step { 269 if m != nil { 270 return m.Steps 271 } 272 return nil 273} 274 275func (m *OperationMetadata) GetProgressPercentage() int32 { 276 if m != nil { 277 return m.ProgressPercentage 278 } 279 return 0 280} 281 282func (m *OperationMetadata) GetStartTime() *google_protobuf9.Timestamp { 283 if m != nil { 284 return m.StartTime 285 } 286 return nil 287} 288 289// Represents the status of one operation step. 290type OperationMetadata_Step struct { 291 // The short description of the step. 292 Description string `protobuf:"bytes,2,opt,name=description" json:"description,omitempty"` 293 // The status code. 294 Status OperationMetadata_Status `protobuf:"varint,4,opt,name=status,enum=google.api.servicemanagement.v1.OperationMetadata_Status" json:"status,omitempty"` 295} 296 297func (m *OperationMetadata_Step) Reset() { *m = OperationMetadata_Step{} } 298func (m *OperationMetadata_Step) String() string { return proto.CompactTextString(m) } 299func (*OperationMetadata_Step) ProtoMessage() {} 300func (*OperationMetadata_Step) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1, 0} } 301 302func (m *OperationMetadata_Step) GetDescription() string { 303 if m != nil { 304 return m.Description 305 } 306 return "" 307} 308 309func (m *OperationMetadata_Step) GetStatus() OperationMetadata_Status { 310 if m != nil { 311 return m.Status 312 } 313 return OperationMetadata_STATUS_UNSPECIFIED 314} 315 316// Represents a diagnostic message (error or warning) 317type Diagnostic struct { 318 // File name and line number of the error or warning. 319 Location string `protobuf:"bytes,1,opt,name=location" json:"location,omitempty"` 320 // The kind of diagnostic information provided. 321 Kind Diagnostic_Kind `protobuf:"varint,2,opt,name=kind,enum=google.api.servicemanagement.v1.Diagnostic_Kind" json:"kind,omitempty"` 322 // Message describing the error or warning. 323 Message string `protobuf:"bytes,3,opt,name=message" json:"message,omitempty"` 324} 325 326func (m *Diagnostic) Reset() { *m = Diagnostic{} } 327func (m *Diagnostic) String() string { return proto.CompactTextString(m) } 328func (*Diagnostic) ProtoMessage() {} 329func (*Diagnostic) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} } 330 331func (m *Diagnostic) GetLocation() string { 332 if m != nil { 333 return m.Location 334 } 335 return "" 336} 337 338func (m *Diagnostic) GetKind() Diagnostic_Kind { 339 if m != nil { 340 return m.Kind 341 } 342 return Diagnostic_WARNING 343} 344 345func (m *Diagnostic) GetMessage() string { 346 if m != nil { 347 return m.Message 348 } 349 return "" 350} 351 352// Represents a source file which is used to generate the service configuration 353// defined by `google.api.Service`. 354type ConfigSource struct { 355 // A unique ID for a specific instance of this message, typically assigned 356 // by the client for tracking purpose. If empty, the server may choose to 357 // generate one instead. 358 Id string `protobuf:"bytes,5,opt,name=id" json:"id,omitempty"` 359 // Set of source configuration files that are used to generate a service 360 // configuration (`google.api.Service`). 361 Files []*ConfigFile `protobuf:"bytes,2,rep,name=files" json:"files,omitempty"` 362} 363 364func (m *ConfigSource) Reset() { *m = ConfigSource{} } 365func (m *ConfigSource) String() string { return proto.CompactTextString(m) } 366func (*ConfigSource) ProtoMessage() {} 367func (*ConfigSource) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} } 368 369func (m *ConfigSource) GetId() string { 370 if m != nil { 371 return m.Id 372 } 373 return "" 374} 375 376func (m *ConfigSource) GetFiles() []*ConfigFile { 377 if m != nil { 378 return m.Files 379 } 380 return nil 381} 382 383// Generic specification of a source configuration file 384type ConfigFile struct { 385 // The file name of the configuration file (full or relative path). 386 FilePath string `protobuf:"bytes,1,opt,name=file_path,json=filePath" json:"file_path,omitempty"` 387 // The bytes that constitute the file. 388 FileContents []byte `protobuf:"bytes,3,opt,name=file_contents,json=fileContents,proto3" json:"file_contents,omitempty"` 389 // The type of configuration file this represents. 390 FileType ConfigFile_FileType `protobuf:"varint,4,opt,name=file_type,json=fileType,enum=google.api.servicemanagement.v1.ConfigFile_FileType" json:"file_type,omitempty"` 391} 392 393func (m *ConfigFile) Reset() { *m = ConfigFile{} } 394func (m *ConfigFile) String() string { return proto.CompactTextString(m) } 395func (*ConfigFile) ProtoMessage() {} 396func (*ConfigFile) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} } 397 398func (m *ConfigFile) GetFilePath() string { 399 if m != nil { 400 return m.FilePath 401 } 402 return "" 403} 404 405func (m *ConfigFile) GetFileContents() []byte { 406 if m != nil { 407 return m.FileContents 408 } 409 return nil 410} 411 412func (m *ConfigFile) GetFileType() ConfigFile_FileType { 413 if m != nil { 414 return m.FileType 415 } 416 return ConfigFile_FILE_TYPE_UNSPECIFIED 417} 418 419// Represents a service configuration with its name and id. 420type ConfigRef struct { 421 // Resource name of a service config. It must have the following 422 // format: "services/{service name}/configs/{config id}". 423 Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` 424} 425 426func (m *ConfigRef) Reset() { *m = ConfigRef{} } 427func (m *ConfigRef) String() string { return proto.CompactTextString(m) } 428func (*ConfigRef) ProtoMessage() {} 429func (*ConfigRef) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} } 430 431func (m *ConfigRef) GetName() string { 432 if m != nil { 433 return m.Name 434 } 435 return "" 436} 437 438// Change report associated with a particular service configuration. 439// 440// It contains a list of ConfigChanges based on the comparison between 441// two service configurations. 442type ChangeReport struct { 443 // List of changes between two service configurations. 444 // The changes will be alphabetically sorted based on the identifier 445 // of each change. 446 // A ConfigChange identifier is a dot separated path to the configuration. 447 // Example: visibility.rules[selector='LibraryService.CreateBook'].restriction 448 ConfigChanges []*google_api2.ConfigChange `protobuf:"bytes,1,rep,name=config_changes,json=configChanges" json:"config_changes,omitempty"` 449} 450 451func (m *ChangeReport) Reset() { *m = ChangeReport{} } 452func (m *ChangeReport) String() string { return proto.CompactTextString(m) } 453func (*ChangeReport) ProtoMessage() {} 454func (*ChangeReport) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} } 455 456func (m *ChangeReport) GetConfigChanges() []*google_api2.ConfigChange { 457 if m != nil { 458 return m.ConfigChanges 459 } 460 return nil 461} 462 463// A rollout resource that defines how service configuration versions are pushed 464// to control plane systems. Typically, you create a new version of the 465// service config, and then create a Rollout to push the service config. 466type Rollout struct { 467 // Optional unique identifier of this Rollout. Only lower case letters, digits 468 // and '-' are allowed. 469 // 470 // If not specified by client, the server will generate one. The generated id 471 // will have the form of <date><revision number>, where "date" is the create 472 // date in ISO 8601 format. "revision number" is a monotonically increasing 473 // positive number that is reset every day for each service. 474 // An example of the generated rollout_id is '2016-02-16r1' 475 RolloutId string `protobuf:"bytes,1,opt,name=rollout_id,json=rolloutId" json:"rollout_id,omitempty"` 476 // Creation time of the rollout. Readonly. 477 CreateTime *google_protobuf9.Timestamp `protobuf:"bytes,2,opt,name=create_time,json=createTime" json:"create_time,omitempty"` 478 // The user who created the Rollout. Readonly. 479 CreatedBy string `protobuf:"bytes,3,opt,name=created_by,json=createdBy" json:"created_by,omitempty"` 480 // The status of this rollout. Readonly. In case of a failed rollout, 481 // the system will automatically rollback to the current Rollout 482 // version. Readonly. 483 Status Rollout_RolloutStatus `protobuf:"varint,4,opt,name=status,enum=google.api.servicemanagement.v1.Rollout_RolloutStatus" json:"status,omitempty"` 484 // Strategy that defines which versions of service configurations should be 485 // pushed 486 // and how they should be used at runtime. 487 // 488 // Types that are valid to be assigned to Strategy: 489 // *Rollout_TrafficPercentStrategy_ 490 // *Rollout_DeleteServiceStrategy_ 491 Strategy isRollout_Strategy `protobuf_oneof:"strategy"` 492 // The name of the service associated with this Rollout. 493 ServiceName string `protobuf:"bytes,8,opt,name=service_name,json=serviceName" json:"service_name,omitempty"` 494} 495 496func (m *Rollout) Reset() { *m = Rollout{} } 497func (m *Rollout) String() string { return proto.CompactTextString(m) } 498func (*Rollout) ProtoMessage() {} 499func (*Rollout) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} } 500 501type isRollout_Strategy interface { 502 isRollout_Strategy() 503} 504 505type Rollout_TrafficPercentStrategy_ struct { 506 TrafficPercentStrategy *Rollout_TrafficPercentStrategy `protobuf:"bytes,5,opt,name=traffic_percent_strategy,json=trafficPercentStrategy,oneof"` 507} 508type Rollout_DeleteServiceStrategy_ struct { 509 DeleteServiceStrategy *Rollout_DeleteServiceStrategy `protobuf:"bytes,200,opt,name=delete_service_strategy,json=deleteServiceStrategy,oneof"` 510} 511 512func (*Rollout_TrafficPercentStrategy_) isRollout_Strategy() {} 513func (*Rollout_DeleteServiceStrategy_) isRollout_Strategy() {} 514 515func (m *Rollout) GetStrategy() isRollout_Strategy { 516 if m != nil { 517 return m.Strategy 518 } 519 return nil 520} 521 522func (m *Rollout) GetRolloutId() string { 523 if m != nil { 524 return m.RolloutId 525 } 526 return "" 527} 528 529func (m *Rollout) GetCreateTime() *google_protobuf9.Timestamp { 530 if m != nil { 531 return m.CreateTime 532 } 533 return nil 534} 535 536func (m *Rollout) GetCreatedBy() string { 537 if m != nil { 538 return m.CreatedBy 539 } 540 return "" 541} 542 543func (m *Rollout) GetStatus() Rollout_RolloutStatus { 544 if m != nil { 545 return m.Status 546 } 547 return Rollout_ROLLOUT_STATUS_UNSPECIFIED 548} 549 550func (m *Rollout) GetTrafficPercentStrategy() *Rollout_TrafficPercentStrategy { 551 if x, ok := m.GetStrategy().(*Rollout_TrafficPercentStrategy_); ok { 552 return x.TrafficPercentStrategy 553 } 554 return nil 555} 556 557func (m *Rollout) GetDeleteServiceStrategy() *Rollout_DeleteServiceStrategy { 558 if x, ok := m.GetStrategy().(*Rollout_DeleteServiceStrategy_); ok { 559 return x.DeleteServiceStrategy 560 } 561 return nil 562} 563 564func (m *Rollout) GetServiceName() string { 565 if m != nil { 566 return m.ServiceName 567 } 568 return "" 569} 570 571// XXX_OneofFuncs is for the internal use of the proto package. 572func (*Rollout) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) { 573 return _Rollout_OneofMarshaler, _Rollout_OneofUnmarshaler, _Rollout_OneofSizer, []interface{}{ 574 (*Rollout_TrafficPercentStrategy_)(nil), 575 (*Rollout_DeleteServiceStrategy_)(nil), 576 } 577} 578 579func _Rollout_OneofMarshaler(msg proto.Message, b *proto.Buffer) error { 580 m := msg.(*Rollout) 581 // strategy 582 switch x := m.Strategy.(type) { 583 case *Rollout_TrafficPercentStrategy_: 584 b.EncodeVarint(5<<3 | proto.WireBytes) 585 if err := b.EncodeMessage(x.TrafficPercentStrategy); err != nil { 586 return err 587 } 588 case *Rollout_DeleteServiceStrategy_: 589 b.EncodeVarint(200<<3 | proto.WireBytes) 590 if err := b.EncodeMessage(x.DeleteServiceStrategy); err != nil { 591 return err 592 } 593 case nil: 594 default: 595 return fmt.Errorf("Rollout.Strategy has unexpected type %T", x) 596 } 597 return nil 598} 599 600func _Rollout_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) { 601 m := msg.(*Rollout) 602 switch tag { 603 case 5: // strategy.traffic_percent_strategy 604 if wire != proto.WireBytes { 605 return true, proto.ErrInternalBadWireType 606 } 607 msg := new(Rollout_TrafficPercentStrategy) 608 err := b.DecodeMessage(msg) 609 m.Strategy = &Rollout_TrafficPercentStrategy_{msg} 610 return true, err 611 case 200: // strategy.delete_service_strategy 612 if wire != proto.WireBytes { 613 return true, proto.ErrInternalBadWireType 614 } 615 msg := new(Rollout_DeleteServiceStrategy) 616 err := b.DecodeMessage(msg) 617 m.Strategy = &Rollout_DeleteServiceStrategy_{msg} 618 return true, err 619 default: 620 return false, nil 621 } 622} 623 624func _Rollout_OneofSizer(msg proto.Message) (n int) { 625 m := msg.(*Rollout) 626 // strategy 627 switch x := m.Strategy.(type) { 628 case *Rollout_TrafficPercentStrategy_: 629 s := proto.Size(x.TrafficPercentStrategy) 630 n += proto.SizeVarint(5<<3 | proto.WireBytes) 631 n += proto.SizeVarint(uint64(s)) 632 n += s 633 case *Rollout_DeleteServiceStrategy_: 634 s := proto.Size(x.DeleteServiceStrategy) 635 n += proto.SizeVarint(200<<3 | proto.WireBytes) 636 n += proto.SizeVarint(uint64(s)) 637 n += s 638 case nil: 639 default: 640 panic(fmt.Sprintf("proto: unexpected type %T in oneof", x)) 641 } 642 return n 643} 644 645// Strategy that specifies how Google Service Control should select 646// different 647// versions of service configurations based on traffic percentage. 648// 649// One example of how to gradually rollout a new service configuration using 650// this 651// strategy: 652// Day 1 653// 654// Rollout { 655// id: "example.googleapis.com/rollout_20160206" 656// traffic_percent_strategy { 657// percentages: { 658// "example.googleapis.com/20160201": 70.00 659// "example.googleapis.com/20160206": 30.00 660// } 661// } 662// } 663// 664// Day 2 665// 666// Rollout { 667// id: "example.googleapis.com/rollout_20160207" 668// traffic_percent_strategy: { 669// percentages: { 670// "example.googleapis.com/20160206": 100.00 671// } 672// } 673// } 674type Rollout_TrafficPercentStrategy struct { 675 // Maps service configuration IDs to their corresponding traffic percentage. 676 // Key is the service configuration ID, Value is the traffic percentage 677 // which must be greater than 0.0 and the sum must equal to 100.0. 678 Percentages map[string]float64 `protobuf:"bytes,1,rep,name=percentages" json:"percentages,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"fixed64,2,opt,name=value"` 679} 680 681func (m *Rollout_TrafficPercentStrategy) Reset() { *m = Rollout_TrafficPercentStrategy{} } 682func (m *Rollout_TrafficPercentStrategy) String() string { return proto.CompactTextString(m) } 683func (*Rollout_TrafficPercentStrategy) ProtoMessage() {} 684func (*Rollout_TrafficPercentStrategy) Descriptor() ([]byte, []int) { 685 return fileDescriptor0, []int{7, 0} 686} 687 688func (m *Rollout_TrafficPercentStrategy) GetPercentages() map[string]float64 { 689 if m != nil { 690 return m.Percentages 691 } 692 return nil 693} 694 695// Strategy used to delete a service. This strategy is a placeholder only 696// used by the system generated rollout to delete a service. 697type Rollout_DeleteServiceStrategy struct { 698} 699 700func (m *Rollout_DeleteServiceStrategy) Reset() { *m = Rollout_DeleteServiceStrategy{} } 701func (m *Rollout_DeleteServiceStrategy) String() string { return proto.CompactTextString(m) } 702func (*Rollout_DeleteServiceStrategy) ProtoMessage() {} 703func (*Rollout_DeleteServiceStrategy) Descriptor() ([]byte, []int) { 704 return fileDescriptor0, []int{7, 1} 705} 706 707func init() { 708 proto.RegisterType((*ManagedService)(nil), "google.api.servicemanagement.v1.ManagedService") 709 proto.RegisterType((*OperationMetadata)(nil), "google.api.servicemanagement.v1.OperationMetadata") 710 proto.RegisterType((*OperationMetadata_Step)(nil), "google.api.servicemanagement.v1.OperationMetadata.Step") 711 proto.RegisterType((*Diagnostic)(nil), "google.api.servicemanagement.v1.Diagnostic") 712 proto.RegisterType((*ConfigSource)(nil), "google.api.servicemanagement.v1.ConfigSource") 713 proto.RegisterType((*ConfigFile)(nil), "google.api.servicemanagement.v1.ConfigFile") 714 proto.RegisterType((*ConfigRef)(nil), "google.api.servicemanagement.v1.ConfigRef") 715 proto.RegisterType((*ChangeReport)(nil), "google.api.servicemanagement.v1.ChangeReport") 716 proto.RegisterType((*Rollout)(nil), "google.api.servicemanagement.v1.Rollout") 717 proto.RegisterType((*Rollout_TrafficPercentStrategy)(nil), "google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy") 718 proto.RegisterType((*Rollout_DeleteServiceStrategy)(nil), "google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy") 719 proto.RegisterEnum("google.api.servicemanagement.v1.OperationMetadata_Status", OperationMetadata_Status_name, OperationMetadata_Status_value) 720 proto.RegisterEnum("google.api.servicemanagement.v1.Diagnostic_Kind", Diagnostic_Kind_name, Diagnostic_Kind_value) 721 proto.RegisterEnum("google.api.servicemanagement.v1.ConfigFile_FileType", ConfigFile_FileType_name, ConfigFile_FileType_value) 722 proto.RegisterEnum("google.api.servicemanagement.v1.Rollout_RolloutStatus", Rollout_RolloutStatus_name, Rollout_RolloutStatus_value) 723} 724 725func init() { proto.RegisterFile("google/api/servicemanagement/v1/resources.proto", fileDescriptor0) } 726 727var fileDescriptor0 = []byte{ 728 // 1166 bytes of a gzipped FileDescriptorProto 729 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x56, 0xef, 0x8e, 0xdb, 0x44, 730 0x10, 0xaf, 0xf3, 0xe7, 0xee, 0x32, 0xb9, 0x0b, 0xee, 0x96, 0xf6, 0xd2, 0xd0, 0x3f, 0xc1, 0x15, 731 0xd2, 0x49, 0x48, 0x0e, 0x0d, 0x08, 0x28, 0x95, 0x5a, 0xe5, 0x12, 0xdf, 0x61, 0xc8, 0xd9, 0xee, 732 0xda, 0x07, 0x2a, 0x5f, 0xac, 0xad, 0xbd, 0x71, 0x4d, 0x13, 0xdb, 0xb2, 0x37, 0x27, 0x45, 0xfd, 733 0xc8, 0x0b, 0xf0, 0x0c, 0x7c, 0x81, 0x47, 0xe1, 0x03, 0x4f, 0x00, 0x2f, 0x83, 0xbc, 0x5e, 0xdf, 734 0xe5, 0xcf, 0xa1, 0x14, 0xf8, 0x92, 0xec, 0xfc, 0x66, 0xf6, 0x37, 0xb3, 0xb3, 0x33, 0xb3, 0x86, 735 0x5e, 0x10, 0xc7, 0xc1, 0x94, 0xf6, 0x48, 0x12, 0xf6, 0x32, 0x9a, 0x5e, 0x84, 0x1e, 0x9d, 0x91, 736 0x88, 0x04, 0x74, 0x46, 0x23, 0xd6, 0xbb, 0x78, 0xdc, 0x4b, 0x69, 0x16, 0xcf, 0x53, 0x8f, 0x66, 737 0x6a, 0x92, 0xc6, 0x2c, 0x46, 0x0f, 0x8b, 0x0d, 0x2a, 0x49, 0x42, 0x75, 0x63, 0x83, 0x7a, 0xf1, 738 0xb8, 0x73, 0x6f, 0x89, 0x91, 0x44, 0x51, 0xcc, 0x08, 0x0b, 0xe3, 0x48, 0x6c, 0xef, 0x3c, 0x58, 739 0xd2, 0x7a, 0x71, 0x34, 0x09, 0x03, 0xd7, 0x7b, 0x4d, 0xa2, 0x80, 0x0a, 0x7d, 0x7b, 0x33, 0x1e, 740 0xa1, 0x79, 0x24, 0x34, 0xd3, 0x38, 0x0a, 0xd2, 0x79, 0x14, 0x85, 0x51, 0xd0, 0x8b, 0x13, 0x9a, 741 0xae, 0xd0, 0xdf, 0x15, 0x46, 0x5c, 0x7a, 0x35, 0x9f, 0xf4, 0x48, 0xb4, 0x10, 0xaa, 0xee, 0xba, 742 0x6a, 0x12, 0xd2, 0xa9, 0xef, 0xce, 0x48, 0xf6, 0x46, 0x58, 0xdc, 0x5b, 0xb7, 0xc8, 0x58, 0x3a, 743 0xf7, 0x98, 0xd0, 0x3e, 0x5c, 0xd7, 0xb2, 0x70, 0x46, 0x33, 0x46, 0x66, 0x89, 0x30, 0x38, 0x14, 744 0x06, 0x69, 0xe2, 0xf5, 0x32, 0x46, 0xd8, 0x5c, 0x04, 0xa5, 0x78, 0xd0, 0x3a, 0xe3, 0x29, 0xf2, 745 0xed, 0xe2, 0x44, 0xe8, 0x43, 0xd8, 0x17, 0x87, 0x73, 0x23, 0x32, 0xa3, 0xed, 0x4a, 0x57, 0x3a, 746 0x6a, 0xe0, 0xa6, 0xc0, 0x0c, 0x32, 0xa3, 0x48, 0x85, 0x5b, 0x49, 0x1a, 0xfb, 0x73, 0x8f, 0xa6, 747 0x6e, 0x92, 0xc6, 0x3f, 0x52, 0x8f, 0xb9, 0xa1, 0xdf, 0xae, 0x72, 0xcb, 0x9b, 0xa5, 0xca, 0x2a, 748 0x34, 0xba, 0xaf, 0xfc, 0x55, 0x85, 0x9b, 0x66, 0x99, 0x8e, 0x33, 0xca, 0x88, 0x4f, 0x18, 0x41, 749 0x1f, 0x41, 0xab, 0xbc, 0x40, 0xee, 0x29, 0x6b, 0x4b, 0xdd, 0xea, 0x51, 0x03, 0x1f, 0x94, 0x68, 750 0xee, 0x2b, 0x43, 0x67, 0x50, 0xcf, 0x18, 0x4d, 0xb2, 0x76, 0xa5, 0x5b, 0x3d, 0x6a, 0xf6, 0xbf, 751 0x50, 0xb7, 0x5c, 0xb2, 0xba, 0xe1, 0x49, 0xb5, 0x19, 0x4d, 0x70, 0xc1, 0x82, 0x7a, 0x3c, 0xf6, 752 0x20, 0xa5, 0x59, 0xe6, 0x26, 0x34, 0xf5, 0x68, 0xc4, 0x48, 0x40, 0x79, 0xec, 0x75, 0x8c, 0x4a, 753 0x95, 0x75, 0xa9, 0x41, 0x4f, 0x00, 0x32, 0x46, 0x52, 0xe6, 0xe6, 0x39, 0x6d, 0xd7, 0xba, 0xd2, 754 0x51, 0xb3, 0xdf, 0x29, 0x83, 0x28, 0x13, 0xae, 0x3a, 0x65, 0xc2, 0x71, 0x83, 0x5b, 0xe7, 0x72, 755 0xe7, 0x2d, 0xd4, 0x72, 0xd7, 0xa8, 0x0b, 0x4d, 0x9f, 0x66, 0x5e, 0x1a, 0x26, 0x79, 0x58, 0x65, 756 0x46, 0x97, 0x20, 0xf4, 0x02, 0x76, 0x8a, 0x6b, 0xe1, 0x0e, 0x5a, 0xfd, 0x27, 0xff, 0xe9, 0x94, 757 0x39, 0x01, 0x16, 0x44, 0x4a, 0x00, 0x3b, 0x05, 0x82, 0xee, 0x00, 0xb2, 0x9d, 0x81, 0x73, 0x6e, 758 0xbb, 0xe7, 0x86, 0x6d, 0x69, 0x43, 0xfd, 0x44, 0xd7, 0x46, 0xf2, 0x0d, 0xb4, 0x07, 0xb5, 0x91, 759 0x69, 0x68, 0xb2, 0x84, 0xde, 0x83, 0xa6, 0x61, 0x3a, 0xae, 0xed, 0x0c, 0xb0, 0xa3, 0x8d, 0xe4, 760 0x4a, 0x0e, 0xe8, 0x86, 0x6b, 0x61, 0xf3, 0x14, 0x6b, 0xb6, 0x2d, 0x57, 0x11, 0xc0, 0xce, 0xc9, 761 0x40, 0x1f, 0x6b, 0x23, 0xb9, 0x86, 0x0e, 0xa0, 0x31, 0x1c, 0x18, 0x43, 0x6d, 0x9c, 0x8b, 0x75, 762 0xe5, 0x37, 0x09, 0x60, 0x14, 0x92, 0x20, 0x8a, 0x33, 0x16, 0x7a, 0xa8, 0x03, 0x7b, 0xd3, 0xd8, 763 0xe3, 0xa1, 0xb5, 0x25, 0x7e, 0xd2, 0x4b, 0x19, 0x8d, 0xa0, 0xf6, 0x26, 0x8c, 0x7c, 0x9e, 0x81, 764 0x56, 0xff, 0x93, 0xad, 0x87, 0xbc, 0xa2, 0x55, 0xbf, 0x0d, 0x23, 0x1f, 0xf3, 0xdd, 0xa8, 0x0d, 765 0xbb, 0x33, 0x9a, 0x65, 0xe5, 0xb5, 0x35, 0x70, 0x29, 0x2a, 0x0f, 0xa0, 0x96, 0xdb, 0xa1, 0x26, 766 0xec, 0x7e, 0x3f, 0xc0, 0x86, 0x6e, 0x9c, 0xca, 0x37, 0x50, 0x03, 0xea, 0x1a, 0xc6, 0x26, 0x96, 767 0x25, 0x85, 0xc0, 0xfe, 0x90, 0x37, 0xb6, 0xcd, 0x0b, 0x0c, 0xb5, 0xa0, 0x12, 0xfa, 0xed, 0x3a, 768 0x27, 0xa9, 0x84, 0x3e, 0x1a, 0x40, 0x7d, 0x12, 0x4e, 0x69, 0x59, 0x6b, 0x1f, 0x6f, 0x0d, 0xb0, 769 0x60, 0x3b, 0x09, 0xa7, 0x14, 0x17, 0x3b, 0x95, 0x5f, 0x2b, 0x00, 0x57, 0x28, 0xfa, 0x00, 0x1a, 770 0x39, 0xee, 0x26, 0x84, 0xbd, 0x2e, 0xd3, 0x91, 0x03, 0x16, 0x61, 0xaf, 0xd1, 0x23, 0x38, 0xe0, 771 0x4a, 0x2f, 0x8e, 0x18, 0x8d, 0x58, 0xc6, 0x8f, 0xb3, 0x8f, 0xf7, 0x73, 0x70, 0x28, 0x30, 0xf4, 772 0x42, 0x30, 0xb0, 0x45, 0x42, 0x45, 0x75, 0x7c, 0xf6, 0x2f, 0xe2, 0x52, 0xf3, 0x1f, 0x67, 0x91, 773 0xd0, 0xc2, 0x6f, 0xbe, 0x52, 0x7e, 0x92, 0x60, 0xaf, 0x84, 0xd1, 0x5d, 0xb8, 0x7d, 0xa2, 0x8f, 774 0x35, 0xd7, 0x79, 0x69, 0x69, 0x6b, 0x05, 0x72, 0x08, 0xb7, 0x6c, 0x0d, 0x7f, 0xa7, 0x0f, 0x35, 775 0x77, 0x68, 0x1a, 0x27, 0xfa, 0xa9, 0xfb, 0x72, 0x70, 0x36, 0x96, 0x25, 0x74, 0x13, 0x0e, 0x4c, 776 0x4b, 0x33, 0xdc, 0x81, 0xa5, 0xbb, 0xdf, 0xd8, 0xa6, 0x21, 0x57, 0x56, 0x20, 0x6e, 0x55, 0x45, 777 0xf7, 0xe1, 0x2e, 0x67, 0x1e, 0x69, 0xf6, 0x10, 0xeb, 0x96, 0x63, 0x62, 0xd7, 0xd6, 0x9c, 0xbc, 778 0xaa, 0x1c, 0x53, 0xae, 0x29, 0x0f, 0xa1, 0x51, 0x84, 0x89, 0xe9, 0x04, 0x21, 0xa8, 0xf1, 0x69, 779 0x53, 0xa4, 0x88, 0xaf, 0x15, 0x13, 0xf6, 0x87, 0x7c, 0xfe, 0x62, 0x9a, 0xc4, 0x29, 0x43, 0xcf, 780 0xa1, 0xb5, 0x32, 0x96, 0x8b, 0x81, 0xd1, 0xec, 0xb7, 0x97, 0xd3, 0x51, 0x50, 0x8a, 0x7d, 0x07, 781 0xde, 0x92, 0x94, 0x29, 0x7f, 0xee, 0xc0, 0x2e, 0x8e, 0xa7, 0xd3, 0x78, 0xce, 0xd0, 0x7d, 0x80, 782 0xb4, 0x58, 0xe6, 0xa3, 0xab, 0x70, 0xdb, 0x10, 0x88, 0xee, 0xa3, 0xa7, 0xd0, 0xf4, 0x52, 0x4a, 783 0x18, 0x2d, 0xda, 0xbe, 0xb2, 0xb5, 0xed, 0xa1, 0x30, 0xcf, 0x81, 0x9c, 0xbb, 0x90, 0x7c, 0xf7, 784 0xd5, 0x42, 0xd4, 0x68, 0x43, 0x20, 0xc7, 0x0b, 0x64, 0xac, 0x35, 0xfb, 0xe7, 0x5b, 0xaf, 0x53, 785 0x04, 0x5d, 0xfe, 0xaf, 0x76, 0x3a, 0x7a, 0x0b, 0x6d, 0x96, 0x92, 0xc9, 0x24, 0xf4, 0xca, 0x89, 786 0xe6, 0x66, 0x2c, 0x25, 0x8c, 0x06, 0x0b, 0x5e, 0xdb, 0xcd, 0xfe, 0xf3, 0x77, 0xf6, 0xe0, 0x14, 787 0x44, 0x62, 0xfe, 0xd9, 0x82, 0xe6, 0xeb, 0x1b, 0xf8, 0x0e, 0xbb, 0x56, 0x83, 0x16, 0x70, 0xe8, 788 0xd3, 0x29, 0x65, 0xd4, 0x2d, 0x5f, 0x8d, 0x4b, 0xdf, 0xbf, 0x4b, 0xdc, 0xf9, 0xb3, 0x77, 0x76, 789 0x3e, 0xe2, 0x44, 0xe2, 0x21, 0x5a, 0xf2, 0x7d, 0xdb, 0xbf, 0x4e, 0xb1, 0xf1, 0x52, 0xed, 0x6d, 790 0xbc, 0x54, 0x9d, 0x3f, 0x24, 0xb8, 0x73, 0xfd, 0x91, 0x50, 0x0a, 0xcd, 0xab, 0xf9, 0x5f, 0x96, 791 0x92, 0xf5, 0x3f, 0x13, 0xa5, 0x5e, 0x3d, 0x1c, 0x99, 0x16, 0xb1, 0x74, 0x81, 0x97, 0x9d, 0x74, 792 0x9e, 0x81, 0xbc, 0x6e, 0x80, 0x64, 0xa8, 0xbe, 0xa1, 0x0b, 0x51, 0x81, 0xf9, 0x12, 0xbd, 0x0f, 793 0xf5, 0x0b, 0x32, 0x9d, 0x17, 0x55, 0x27, 0xe1, 0x42, 0xf8, 0xaa, 0xf2, 0xa5, 0xd4, 0x39, 0x84, 794 0xdb, 0xd7, 0xe6, 0x48, 0x99, 0xc3, 0xc1, 0x4a, 0x6d, 0xa0, 0x07, 0xd0, 0xc1, 0xe6, 0x78, 0x6c, 795 0x9e, 0xf3, 0xa9, 0xbe, 0x39, 0xfb, 0xd7, 0x06, 0xbc, 0x94, 0x8f, 0x4c, 0xfb, 0x7c, 0x38, 0xcc, 796 0x85, 0xca, 0xea, 0x84, 0x5f, 0x1d, 0xfe, 0x4d, 0xd8, 0xb5, 0x34, 0x63, 0x94, 0x8f, 0xd6, 0xfa, 797 0x31, 0xc0, 0x5e, 0x79, 0xdb, 0xc7, 0x3f, 0x4b, 0xf0, 0xc8, 0x8b, 0x67, 0xdb, 0x12, 0x78, 0xdc, 798 0xc2, 0xe5, 0x57, 0x9b, 0x95, 0x77, 0x91, 0x25, 0xfd, 0x60, 0x89, 0x2d, 0x41, 0x3c, 0x25, 0x51, 799 0xa0, 0xc6, 0x69, 0xd0, 0x0b, 0x68, 0xc4, 0x7b, 0x4c, 0x7c, 0x02, 0x92, 0x24, 0xcc, 0xfe, 0xf1, 800 0x33, 0xf0, 0xe9, 0x06, 0xf8, 0x4b, 0xa5, 0x76, 0x3a, 0xb0, 0xcf, 0x5e, 0xed, 0x70, 0x8e, 0x4f, 801 0xff, 0x0e, 0x00, 0x00, 0xff, 0xff, 0x2d, 0x64, 0x4d, 0x1e, 0x49, 0x0a, 0x00, 0x00, 802} 803