// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.10
// 	protoc        v7.35.1
// source: envoy/config/route/v3/scoped_route.proto

package routev3

import (
	_ "github.com/cncf/xds/go/udpa/annotations"
	_ "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)
)

// Specifies a routing scope, which associates a
// :ref:`Key<envoy_v3_api_msg_config.route.v3.ScopedRouteConfiguration.Key>` to a
// :ref:`envoy_v3_api_msg_config.route.v3.RouteConfiguration`.
// The :ref:`envoy_v3_api_msg_config.route.v3.RouteConfiguration` can be obtained dynamically
// via RDS (:ref:`route_configuration_name<envoy_v3_api_field_config.route.v3.ScopedRouteConfiguration.route_configuration_name>`)
// or specified inline (:ref:`route_configuration<envoy_v3_api_field_config.route.v3.ScopedRouteConfiguration.route_configuration>`).
//
// The HTTP connection manager builds up a table consisting of these Key to
// RouteConfiguration mappings, and looks up the RouteConfiguration to use per
// request according to the algorithm specified in the
// :ref:`scope_key_builder<envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.ScopedRoutes.scope_key_builder>`
// assigned to the HttpConnectionManager.
//
// For example, with the following configurations (in YAML):
//
// HttpConnectionManager config:
//
// .. code::
//
//	...
//	scoped_routes:
//	  name: foo-scoped-routes
//	  scope_key_builder:
//	    fragments:
//	      - header_value_extractor:
//	          name: X-Route-Selector
//	          element_separator: ","
//	          element:
//	            separator: =
//	            key: vip
//
// ScopedRouteConfiguration resources (specified statically via
// :ref:`scoped_route_configurations_list<envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.ScopedRoutes.scoped_route_configurations_list>`
// or obtained dynamically via SRDS):
//
// .. code::
//
//	(1)
//	 name: route-scope1
//	 route_configuration_name: route-config1
//	 key:
//	    fragments:
//	      - string_key: 172.10.10.20
//
//	(2)
//	 name: route-scope2
//	 route_configuration_name: route-config2
//	 key:
//	   fragments:
//	     - string_key: 172.20.20.30
//
// A request from a client such as:
//
// .. code::
//
//	GET / HTTP/1.1
//	Host: foo.com
//	X-Route-Selector: vip=172.10.10.20
//
// would result in the routing table defined by the “route-config1“
// RouteConfiguration being assigned to the HTTP request/stream.
//
// [#next-free-field: 6]
type ScopedRouteConfiguration struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Whether the RouteConfiguration should be loaded on demand.
	OnDemand bool `protobuf:"varint,4,opt,name=on_demand,json=onDemand,proto3" json:"on_demand,omitempty"`
	// The name assigned to the routing scope.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The resource name to use for a :ref:`envoy_v3_api_msg_service.discovery.v3.DiscoveryRequest` to an
	// RDS server to fetch the :ref:`envoy_v3_api_msg_config.route.v3.RouteConfiguration` associated
	// with this scope.
	RouteConfigurationName string `protobuf:"bytes,2,opt,name=route_configuration_name,json=routeConfigurationName,proto3" json:"route_configuration_name,omitempty"`
	// The :ref:`envoy_v3_api_msg_config.route.v3.RouteConfiguration` associated with the scope.
	RouteConfiguration *RouteConfiguration `protobuf:"bytes,5,opt,name=route_configuration,json=routeConfiguration,proto3" json:"route_configuration,omitempty"`
	// The key to match against.
	Key           *ScopedRouteConfiguration_Key `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*ScopedRouteConfiguration) ProtoMessage() {}

func (x *ScopedRouteConfiguration) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_config_route_v3_scoped_route_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 ScopedRouteConfiguration.ProtoReflect.Descriptor instead.
func (*ScopedRouteConfiguration) Descriptor() ([]byte, []int) {
	return file_envoy_config_route_v3_scoped_route_proto_rawDescGZIP(), []int{0}
}

func (x *ScopedRouteConfiguration) GetOnDemand() bool {
	if x != nil {
		return x.OnDemand
	}
	return false
}

func (x *ScopedRouteConfiguration) GetName() string {
	if x != nil {
		return x.Name
	}
	return ""
}

func (x *ScopedRouteConfiguration) GetRouteConfigurationName() string {
	if x != nil {
		return x.RouteConfigurationName
	}
	return ""
}

func (x *ScopedRouteConfiguration) GetRouteConfiguration() *RouteConfiguration {
	if x != nil {
		return x.RouteConfiguration
	}
	return nil
}

func (x *ScopedRouteConfiguration) GetKey() *ScopedRouteConfiguration_Key {
	if x != nil {
		return x.Key
	}
	return nil
}

// Specifies a key which is matched against the output of the
// :ref:`scope_key_builder<envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.ScopedRoutes.scope_key_builder>`
// specified in the HttpConnectionManager. The matching is done per HTTP
// request and is dependent on the order of the fragments contained in the
// Key.
type ScopedRouteConfiguration_Key struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The ordered set of fragments to match against. The order must match the
	// fragments in the corresponding
	// :ref:`scope_key_builder<envoy_v3_api_field_extensions.filters.network.http_connection_manager.v3.ScopedRoutes.scope_key_builder>`.
	Fragments     []*ScopedRouteConfiguration_Key_Fragment `protobuf:"bytes,1,rep,name=fragments,proto3" json:"fragments,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*ScopedRouteConfiguration_Key) ProtoMessage() {}

func (x *ScopedRouteConfiguration_Key) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_config_route_v3_scoped_route_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 ScopedRouteConfiguration_Key.ProtoReflect.Descriptor instead.
func (*ScopedRouteConfiguration_Key) Descriptor() ([]byte, []int) {
	return file_envoy_config_route_v3_scoped_route_proto_rawDescGZIP(), []int{0, 0}
}

func (x *ScopedRouteConfiguration_Key) GetFragments() []*ScopedRouteConfiguration_Key_Fragment {
	if x != nil {
		return x.Fragments
	}
	return nil
}

type ScopedRouteConfiguration_Key_Fragment struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Types that are valid to be assigned to Type:
	//
	//	*ScopedRouteConfiguration_Key_Fragment_StringKey
	Type          isScopedRouteConfiguration_Key_Fragment_Type `protobuf_oneof:"type"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *ScopedRouteConfiguration_Key_Fragment) Reset() {
	*x = ScopedRouteConfiguration_Key_Fragment{}
	mi := &file_envoy_config_route_v3_scoped_route_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

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

func (*ScopedRouteConfiguration_Key_Fragment) ProtoMessage() {}

func (x *ScopedRouteConfiguration_Key_Fragment) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_config_route_v3_scoped_route_proto_msgTypes[2]
	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 ScopedRouteConfiguration_Key_Fragment.ProtoReflect.Descriptor instead.
func (*ScopedRouteConfiguration_Key_Fragment) Descriptor() ([]byte, []int) {
	return file_envoy_config_route_v3_scoped_route_proto_rawDescGZIP(), []int{0, 0, 0}
}

func (x *ScopedRouteConfiguration_Key_Fragment) GetType() isScopedRouteConfiguration_Key_Fragment_Type {
	if x != nil {
		return x.Type
	}
	return nil
}

func (x *ScopedRouteConfiguration_Key_Fragment) GetStringKey() string {
	if x != nil {
		if x, ok := x.Type.(*ScopedRouteConfiguration_Key_Fragment_StringKey); ok {
			return x.StringKey
		}
	}
	return ""
}

type isScopedRouteConfiguration_Key_Fragment_Type interface {
	isScopedRouteConfiguration_Key_Fragment_Type()
}

type ScopedRouteConfiguration_Key_Fragment_StringKey struct {
	// A string to match against.
	StringKey string `protobuf:"bytes,1,opt,name=string_key,json=stringKey,proto3,oneof"`
}

func (*ScopedRouteConfiguration_Key_Fragment_StringKey) isScopedRouteConfiguration_Key_Fragment_Type() {
}

var File_envoy_config_route_v3_scoped_route_proto protoreflect.FileDescriptor

const file_envoy_config_route_v3_scoped_route_proto_rawDesc = "" +
	"\n" +
	"(envoy/config/route/v3/scoped_route.proto\x12\x15envoy.config.route.v3\x1a!envoy/config/route/v3/route.proto\x1a\x1eudpa/annotations/migrate.proto\x1a\x1dudpa/annotations/status.proto\x1a!udpa/annotations/versioning.proto\x1a\x17validate/validate.proto\"\xaa\x05\n" +
	"\x18ScopedRouteConfiguration\x12\x1b\n" +
	"\ton_demand\x18\x04 \x01(\bR\bonDemand\x12\x1b\n" +
	"\x04name\x18\x01 \x01(\tB\a\xfaB\x04r\x02\x10\x01R\x04name\x12N\n" +
	"\x18route_configuration_name\x18\x02 \x01(\tB\x14\xf2\x98\xfe\x8f\x05\x0e\x12\froute_configR\x16routeConfigurationName\x12p\n" +
	"\x13route_configuration\x18\x05 \x01(\v2).envoy.config.route.v3.RouteConfigurationB\x14\xf2\x98\xfe\x8f\x05\x0e\x12\froute_configR\x12routeConfiguration\x12O\n" +
	"\x03key\x18\x03 \x01(\v23.envoy.config.route.v3.ScopedRouteConfiguration.KeyB\b\xfaB\x05\x8a\x01\x02\x10\x01R\x03key\x1a\x92\x02\n" +
	"\x03Key\x12d\n" +
	"\tfragments\x18\x01 \x03(\v2<.envoy.config.route.v3.ScopedRouteConfiguration.Key.FragmentB\b\xfaB\x05\x92\x01\x02\b\x01R\tfragments\x1as\n" +
	"\bFragment\x12\x1f\n" +
	"\n" +
	"string_key\x18\x01 \x01(\tH\x00R\tstringKey:9\x9aň\x1e4\n" +
	"2envoy.api.v2.ScopedRouteConfiguration.Key.FragmentB\v\n" +
	"\x04type\x12\x03\xf8B\x01:0\x9aň\x1e+\n" +
	")envoy.api.v2.ScopedRouteConfiguration.Key:,\x9aň\x1e'\n" +
	"%envoy.api.v2.ScopedRouteConfigurationB\x87\x01\xba\x80\xc8\xd1\x06\x02\x10\x02\n" +
	"#io.envoyproxy.envoy.config.route.v3B\x10ScopedRouteProtoP\x01ZDgithub.com/envoyproxy/go-control-plane/envoy/config/route/v3;routev3b\x06proto3"

var (
	file_envoy_config_route_v3_scoped_route_proto_rawDescOnce sync.Once
	file_envoy_config_route_v3_scoped_route_proto_rawDescData []byte
)

func file_envoy_config_route_v3_scoped_route_proto_rawDescGZIP() []byte {
	file_envoy_config_route_v3_scoped_route_proto_rawDescOnce.Do(func() {
		file_envoy_config_route_v3_scoped_route_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_envoy_config_route_v3_scoped_route_proto_rawDesc), len(file_envoy_config_route_v3_scoped_route_proto_rawDesc)))
	})
	return file_envoy_config_route_v3_scoped_route_proto_rawDescData
}

var file_envoy_config_route_v3_scoped_route_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
var file_envoy_config_route_v3_scoped_route_proto_goTypes = []any{
	(*ScopedRouteConfiguration)(nil),              // 0: envoy.config.route.v3.ScopedRouteConfiguration
	(*ScopedRouteConfiguration_Key)(nil),          // 1: envoy.config.route.v3.ScopedRouteConfiguration.Key
	(*ScopedRouteConfiguration_Key_Fragment)(nil), // 2: envoy.config.route.v3.ScopedRouteConfiguration.Key.Fragment
	(*RouteConfiguration)(nil),                    // 3: envoy.config.route.v3.RouteConfiguration
}
var file_envoy_config_route_v3_scoped_route_proto_depIdxs = []int32{
	3, // 0: envoy.config.route.v3.ScopedRouteConfiguration.route_configuration:type_name -> envoy.config.route.v3.RouteConfiguration
	1, // 1: envoy.config.route.v3.ScopedRouteConfiguration.key:type_name -> envoy.config.route.v3.ScopedRouteConfiguration.Key
	2, // 2: envoy.config.route.v3.ScopedRouteConfiguration.Key.fragments:type_name -> envoy.config.route.v3.ScopedRouteConfiguration.Key.Fragment
	3, // [3:3] is the sub-list for method output_type
	3, // [3:3] is the sub-list for method input_type
	3, // [3:3] is the sub-list for extension type_name
	3, // [3:3] is the sub-list for extension extendee
	0, // [0:3] is the sub-list for field type_name
}

func init() { file_envoy_config_route_v3_scoped_route_proto_init() }
func file_envoy_config_route_v3_scoped_route_proto_init() {
	if File_envoy_config_route_v3_scoped_route_proto != nil {
		return
	}
	file_envoy_config_route_v3_route_proto_init()
	file_envoy_config_route_v3_scoped_route_proto_msgTypes[2].OneofWrappers = []any{
		(*ScopedRouteConfiguration_Key_Fragment_StringKey)(nil),
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_envoy_config_route_v3_scoped_route_proto_rawDesc), len(file_envoy_config_route_v3_scoped_route_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   3,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_envoy_config_route_v3_scoped_route_proto_goTypes,
		DependencyIndexes: file_envoy_config_route_v3_scoped_route_proto_depIdxs,
		MessageInfos:      file_envoy_config_route_v3_scoped_route_proto_msgTypes,
	}.Build()
	File_envoy_config_route_v3_scoped_route_proto = out.File
	file_envoy_config_route_v3_scoped_route_proto_goTypes = nil
	file_envoy_config_route_v3_scoped_route_proto_depIdxs = nil
}
