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