// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.10
// 	protoc        v6.33.2
// source: envoy/extensions/access_loggers/filters/process_ratelimit/v3/process_ratelimit.proto

package process_ratelimitv3

import (
	_ "github.com/cncf/xds/go/udpa/annotations"
	v3 "github.com/envoyproxy/go-control-plane/envoy/config/core/v3"
	_ "github.com/envoyproxy/protoc-gen-validate/validate"
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	reflect "reflect"
	sync "sync"
	unsafe "unsafe"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

// Filters for rate limiting the access log emission using global token buckets per process and shared across all listeners.
type ProcessRateLimitFilter struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The dynamic config for the token bucket.
	DynamicConfig *DynamicTokenBucket `protobuf:"bytes,1,opt,name=dynamic_config,json=dynamicConfig,proto3" json:"dynamic_config,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *ProcessRateLimitFilter) Reset() {
	*x = ProcessRateLimitFilter{}
	mi := &file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *ProcessRateLimitFilter) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*ProcessRateLimitFilter) ProtoMessage() {}

func (x *ProcessRateLimitFilter) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_msgTypes[0]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use ProcessRateLimitFilter.ProtoReflect.Descriptor instead.
func (*ProcessRateLimitFilter) Descriptor() ([]byte, []int) {
	return file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescGZIP(), []int{0}
}

func (x *ProcessRateLimitFilter) GetDynamicConfig() *DynamicTokenBucket {
	if x != nil {
		return x.DynamicConfig
	}
	return nil
}

type DynamicTokenBucket struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// the key used to find the token bucket in the singleton map.
	ResourceName string `protobuf:"bytes,1,opt,name=resource_name,json=resourceName,proto3" json:"resource_name,omitempty"`
	// The configuration source for the :ref:`token_bucket <envoy_v3_api_msg_type.v3.TokenBucket>`.
	// It should stay the same through the process lifetime.
	ConfigSource  *v3.ConfigSource `protobuf:"bytes,2,opt,name=config_source,json=configSource,proto3" json:"config_source,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *DynamicTokenBucket) Reset() {
	*x = DynamicTokenBucket{}
	mi := &file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *DynamicTokenBucket) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*DynamicTokenBucket) ProtoMessage() {}

func (x *DynamicTokenBucket) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_msgTypes[1]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use DynamicTokenBucket.ProtoReflect.Descriptor instead.
func (*DynamicTokenBucket) Descriptor() ([]byte, []int) {
	return file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescGZIP(), []int{1}
}

func (x *DynamicTokenBucket) GetResourceName() string {
	if x != nil {
		return x.ResourceName
	}
	return ""
}

func (x *DynamicTokenBucket) GetConfigSource() *v3.ConfigSource {
	if x != nil {
		return x.ConfigSource
	}
	return nil
}

var File_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto protoreflect.FileDescriptor

const file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDesc = "" +
	"\n" +
	"Tenvoy/extensions/access_loggers/filters/process_ratelimit/v3/process_ratelimit.proto\x12<envoy.extensions.access_loggers.filters.process_ratelimit.v3\x1a(envoy/config/core/v3/config_source.proto\x1a\x1dudpa/annotations/status.proto\x1a\x17validate/validate.proto\"\x91\x01\n" +
	"\x16ProcessRateLimitFilter\x12w\n" +
	"\x0edynamic_config\x18\x01 \x01(\v2P.envoy.extensions.access_loggers.filters.process_ratelimit.v3.DynamicTokenBucketR\rdynamicConfig\"\x95\x01\n" +
	"\x12DynamicTokenBucket\x12,\n" +
	"\rresource_name\x18\x01 \x01(\tB\a\xfaB\x04r\x02\x10\x01R\fresourceName\x12Q\n" +
	"\rconfig_source\x18\x02 \x01(\v2\".envoy.config.core.v3.ConfigSourceB\b\xfaB\x05\x8a\x01\x02\x10\x01R\fconfigSourceB\xe6\x01\xba\x80\xc8\xd1\x06\x02\x10\x02\n" +
	"Jio.envoyproxy.envoy.extensions.access_loggers.filters.process_ratelimit.v3B\x15ProcessRatelimitProtoP\x01Zwgithub.com/envoyproxy/go-control-plane/envoy/extensions/access_loggers/filters/process_ratelimit/v3;process_ratelimitv3b\x06proto3"

var (
	file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescOnce sync.Once
	file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescData []byte
)

func file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescGZIP() []byte {
	file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescOnce.Do(func() {
		file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDesc), len(file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDesc)))
	})
	return file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDescData
}

var file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_goTypes = []any{
	(*ProcessRateLimitFilter)(nil), // 0: envoy.extensions.access_loggers.filters.process_ratelimit.v3.ProcessRateLimitFilter
	(*DynamicTokenBucket)(nil),     // 1: envoy.extensions.access_loggers.filters.process_ratelimit.v3.DynamicTokenBucket
	(*v3.ConfigSource)(nil),        // 2: envoy.config.core.v3.ConfigSource
}
var file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_depIdxs = []int32{
	1, // 0: envoy.extensions.access_loggers.filters.process_ratelimit.v3.ProcessRateLimitFilter.dynamic_config:type_name -> envoy.extensions.access_loggers.filters.process_ratelimit.v3.DynamicTokenBucket
	2, // 1: envoy.extensions.access_loggers.filters.process_ratelimit.v3.DynamicTokenBucket.config_source:type_name -> envoy.config.core.v3.ConfigSource
	2, // [2:2] is the sub-list for method output_type
	2, // [2:2] is the sub-list for method input_type
	2, // [2:2] is the sub-list for extension type_name
	2, // [2:2] is the sub-list for extension extendee
	0, // [0:2] is the sub-list for field type_name
}

func init() {
	file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_init()
}
func file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_init() {
	if File_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDesc), len(file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   2,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_goTypes,
		DependencyIndexes: file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_depIdxs,
		MessageInfos:      file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_msgTypes,
	}.Build()
	File_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto = out.File
	file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_goTypes = nil
	file_envoy_extensions_access_loggers_filters_process_ratelimit_v3_process_ratelimit_proto_depIdxs = nil
}
