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