1// Copyright 2020 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// Code generated by protoc-gen-go. DO NOT EDIT. 16// versions: 17// protoc-gen-go v1.25.0-devel 18// protoc v3.13.0 19// source: google/api/logging.proto 20 21package serviceconfig 22 23import ( 24 reflect "reflect" 25 sync "sync" 26 27 proto "github.com/golang/protobuf/proto" 28 protoreflect "google.golang.org/protobuf/reflect/protoreflect" 29 protoimpl "google.golang.org/protobuf/runtime/protoimpl" 30) 31 32const ( 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// This is a compile-time assertion that a sufficiently up-to-date version 40// of the legacy proto package is being used. 41const _ = proto.ProtoPackageIsVersion4 42 43// Logging configuration of the service. 44// 45// The following example shows how to configure logs to be sent to the 46// producer and consumer projects. In the example, the `activity_history` 47// log is sent to both the producer and consumer projects, whereas the 48// `purchase_history` log is only sent to the producer project. 49// 50// monitored_resources: 51// - type: library.googleapis.com/branch 52// labels: 53// - key: city 54// description: The city where the library branch is located in. 55// - key: name 56// description: The name of the branch. 57// logs: 58// - name: activity_history 59// labels: 60// - key: customer_id 61// - name: purchase_history 62// logging: 63// producer_destinations: 64// - monitored_resource: library.googleapis.com/branch 65// logs: 66// - activity_history 67// - purchase_history 68// consumer_destinations: 69// - monitored_resource: library.googleapis.com/branch 70// logs: 71// - activity_history 72type Logging struct { 73 state protoimpl.MessageState 74 sizeCache protoimpl.SizeCache 75 unknownFields protoimpl.UnknownFields 76 77 // Logging configurations for sending logs to the producer project. 78 // There can be multiple producer destinations, each one must have a 79 // different monitored resource type. A log can be used in at most 80 // one producer destination. 81 ProducerDestinations []*Logging_LoggingDestination `protobuf:"bytes,1,rep,name=producer_destinations,json=producerDestinations,proto3" json:"producer_destinations,omitempty"` 82 // Logging configurations for sending logs to the consumer project. 83 // There can be multiple consumer destinations, each one must have a 84 // different monitored resource type. A log can be used in at most 85 // one consumer destination. 86 ConsumerDestinations []*Logging_LoggingDestination `protobuf:"bytes,2,rep,name=consumer_destinations,json=consumerDestinations,proto3" json:"consumer_destinations,omitempty"` 87} 88 89func (x *Logging) Reset() { 90 *x = Logging{} 91 if protoimpl.UnsafeEnabled { 92 mi := &file_google_api_logging_proto_msgTypes[0] 93 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 94 ms.StoreMessageInfo(mi) 95 } 96} 97 98func (x *Logging) String() string { 99 return protoimpl.X.MessageStringOf(x) 100} 101 102func (*Logging) ProtoMessage() {} 103 104func (x *Logging) ProtoReflect() protoreflect.Message { 105 mi := &file_google_api_logging_proto_msgTypes[0] 106 if protoimpl.UnsafeEnabled && x != nil { 107 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 108 if ms.LoadMessageInfo() == nil { 109 ms.StoreMessageInfo(mi) 110 } 111 return ms 112 } 113 return mi.MessageOf(x) 114} 115 116// Deprecated: Use Logging.ProtoReflect.Descriptor instead. 117func (*Logging) Descriptor() ([]byte, []int) { 118 return file_google_api_logging_proto_rawDescGZIP(), []int{0} 119} 120 121func (x *Logging) GetProducerDestinations() []*Logging_LoggingDestination { 122 if x != nil { 123 return x.ProducerDestinations 124 } 125 return nil 126} 127 128func (x *Logging) GetConsumerDestinations() []*Logging_LoggingDestination { 129 if x != nil { 130 return x.ConsumerDestinations 131 } 132 return nil 133} 134 135// Configuration of a specific logging destination (the producer project 136// or the consumer project). 137type Logging_LoggingDestination struct { 138 state protoimpl.MessageState 139 sizeCache protoimpl.SizeCache 140 unknownFields protoimpl.UnknownFields 141 142 // The monitored resource type. The type must be defined in the 143 // [Service.monitored_resources][google.api.Service.monitored_resources] section. 144 MonitoredResource string `protobuf:"bytes,3,opt,name=monitored_resource,json=monitoredResource,proto3" json:"monitored_resource,omitempty"` 145 // Names of the logs to be sent to this destination. Each name must 146 // be defined in the [Service.logs][google.api.Service.logs] section. If the log name is 147 // not a domain scoped name, it will be automatically prefixed with 148 // the service name followed by "/". 149 Logs []string `protobuf:"bytes,1,rep,name=logs,proto3" json:"logs,omitempty"` 150} 151 152func (x *Logging_LoggingDestination) Reset() { 153 *x = Logging_LoggingDestination{} 154 if protoimpl.UnsafeEnabled { 155 mi := &file_google_api_logging_proto_msgTypes[1] 156 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 157 ms.StoreMessageInfo(mi) 158 } 159} 160 161func (x *Logging_LoggingDestination) String() string { 162 return protoimpl.X.MessageStringOf(x) 163} 164 165func (*Logging_LoggingDestination) ProtoMessage() {} 166 167func (x *Logging_LoggingDestination) ProtoReflect() protoreflect.Message { 168 mi := &file_google_api_logging_proto_msgTypes[1] 169 if protoimpl.UnsafeEnabled && x != nil { 170 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) 171 if ms.LoadMessageInfo() == nil { 172 ms.StoreMessageInfo(mi) 173 } 174 return ms 175 } 176 return mi.MessageOf(x) 177} 178 179// Deprecated: Use Logging_LoggingDestination.ProtoReflect.Descriptor instead. 180func (*Logging_LoggingDestination) Descriptor() ([]byte, []int) { 181 return file_google_api_logging_proto_rawDescGZIP(), []int{0, 0} 182} 183 184func (x *Logging_LoggingDestination) GetMonitoredResource() string { 185 if x != nil { 186 return x.MonitoredResource 187 } 188 return "" 189} 190 191func (x *Logging_LoggingDestination) GetLogs() []string { 192 if x != nil { 193 return x.Logs 194 } 195 return nil 196} 197 198var File_google_api_logging_proto protoreflect.FileDescriptor 199 200var file_google_api_logging_proto_rawDesc = []byte{ 201 0x0a, 0x18, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6c, 0x6f, 0x67, 202 0x67, 0x69, 0x6e, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0a, 0x67, 0x6f, 0x6f, 0x67, 203 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x22, 0x9c, 0x02, 0x0a, 0x07, 0x4c, 0x6f, 0x67, 0x67, 0x69, 204 0x6e, 0x67, 0x12, 0x5b, 0x0a, 0x15, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x72, 0x5f, 0x64, 205 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 206 0x0b, 0x32, 0x26, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x4c, 207 0x6f, 0x67, 0x67, 0x69, 0x6e, 0x67, 0x2e, 0x4c, 0x6f, 0x67, 0x67, 0x69, 0x6e, 0x67, 0x44, 0x65, 208 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x14, 0x70, 0x72, 0x6f, 0x64, 0x75, 209 0x63, 0x65, 0x72, 0x44, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 210 0x5b, 0x0a, 0x15, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x72, 0x5f, 0x64, 0x65, 0x73, 0x74, 211 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 212 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x4c, 0x6f, 0x67, 0x67, 213 0x69, 0x6e, 0x67, 0x2e, 0x4c, 0x6f, 0x67, 0x67, 0x69, 0x6e, 0x67, 0x44, 0x65, 0x73, 0x74, 0x69, 214 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x14, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x72, 215 0x44, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x57, 0x0a, 0x12, 216 0x4c, 0x6f, 0x67, 0x67, 0x69, 0x6e, 0x67, 0x44, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, 0x69, 217 0x6f, 0x6e, 0x12, 0x2d, 0x0a, 0x12, 0x6d, 0x6f, 0x6e, 0x69, 0x74, 0x6f, 0x72, 0x65, 0x64, 0x5f, 218 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x11, 219 0x6d, 0x6f, 0x6e, 0x69, 0x74, 0x6f, 0x72, 0x65, 0x64, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 220 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 221 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x42, 0x6e, 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 222 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x42, 0x0c, 0x4c, 0x6f, 0x67, 0x67, 0x69, 0x6e, 0x67, 223 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x45, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 224 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e, 0x70, 0x72, 225 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69, 0x73, 0x2f, 0x61, 226 0x70, 0x69, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 227 0x3b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0xa2, 0x02, 228 0x04, 0x47, 0x41, 0x50, 0x49, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, 229} 230 231var ( 232 file_google_api_logging_proto_rawDescOnce sync.Once 233 file_google_api_logging_proto_rawDescData = file_google_api_logging_proto_rawDesc 234) 235 236func file_google_api_logging_proto_rawDescGZIP() []byte { 237 file_google_api_logging_proto_rawDescOnce.Do(func() { 238 file_google_api_logging_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_api_logging_proto_rawDescData) 239 }) 240 return file_google_api_logging_proto_rawDescData 241} 242 243var file_google_api_logging_proto_msgTypes = make([]protoimpl.MessageInfo, 2) 244var file_google_api_logging_proto_goTypes = []interface{}{ 245 (*Logging)(nil), // 0: google.api.Logging 246 (*Logging_LoggingDestination)(nil), // 1: google.api.Logging.LoggingDestination 247} 248var file_google_api_logging_proto_depIdxs = []int32{ 249 1, // 0: google.api.Logging.producer_destinations:type_name -> google.api.Logging.LoggingDestination 250 1, // 1: google.api.Logging.consumer_destinations:type_name -> google.api.Logging.LoggingDestination 251 2, // [2:2] is the sub-list for method output_type 252 2, // [2:2] is the sub-list for method input_type 253 2, // [2:2] is the sub-list for extension type_name 254 2, // [2:2] is the sub-list for extension extendee 255 0, // [0:2] is the sub-list for field type_name 256} 257 258func init() { file_google_api_logging_proto_init() } 259func file_google_api_logging_proto_init() { 260 if File_google_api_logging_proto != nil { 261 return 262 } 263 if !protoimpl.UnsafeEnabled { 264 file_google_api_logging_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { 265 switch v := v.(*Logging); i { 266 case 0: 267 return &v.state 268 case 1: 269 return &v.sizeCache 270 case 2: 271 return &v.unknownFields 272 default: 273 return nil 274 } 275 } 276 file_google_api_logging_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { 277 switch v := v.(*Logging_LoggingDestination); i { 278 case 0: 279 return &v.state 280 case 1: 281 return &v.sizeCache 282 case 2: 283 return &v.unknownFields 284 default: 285 return nil 286 } 287 } 288 } 289 type x struct{} 290 out := protoimpl.TypeBuilder{ 291 File: protoimpl.DescBuilder{ 292 GoPackagePath: reflect.TypeOf(x{}).PkgPath(), 293 RawDescriptor: file_google_api_logging_proto_rawDesc, 294 NumEnums: 0, 295 NumMessages: 2, 296 NumExtensions: 0, 297 NumServices: 0, 298 }, 299 GoTypes: file_google_api_logging_proto_goTypes, 300 DependencyIndexes: file_google_api_logging_proto_depIdxs, 301 MessageInfos: file_google_api_logging_proto_msgTypes, 302 }.Build() 303 File_google_api_logging_proto = out.File 304 file_google_api_logging_proto_rawDesc = nil 305 file_google_api_logging_proto_goTypes = nil 306 file_google_api_logging_proto_depIdxs = nil 307} 308