// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.10
// 	protoc        v7.35.1
// source: envoy/extensions/filters/network/generic_proxy/v3/route.proto

package generic_proxyv3

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

type VirtualHost struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The name of the virtual host.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// A list of hosts that will be matched to this virtual host. Wildcard hosts are supported in
	// the suffix or prefix form.
	//
	// Host search order:
	//  1. Exact names: “www.foo.com“.
	//  2. Suffix wildcards: “*.foo.com“ or “*-bar.foo.com“.
	//  3. Prefix wildcards: “foo.*“ or “foo-*“.
	//  4. Special wildcard “*“ matching any host and will be the default virtual host.
	//
	// .. note::
	//
	//	The wildcard will not match the empty string.
	//	e.g. ``*-bar.foo.com`` will match ``baz-bar.foo.com`` but not ``-bar.foo.com``.
	//	The longest wildcards match first.
	//	Only a single virtual host in the entire route configuration can match on ``*``. A domain
	//	must be unique across all virtual hosts or the config will fail to load.
	Hosts []string `protobuf:"bytes,2,rep,name=hosts,proto3" json:"hosts,omitempty"`
	// The match tree to use when resolving route actions for incoming requests.
	Routes        *v3.Matcher `protobuf:"bytes,3,opt,name=routes,proto3" json:"routes,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*VirtualHost) ProtoMessage() {}

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

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

func (x *VirtualHost) GetHosts() []string {
	if x != nil {
		return x.Hosts
	}
	return nil
}

func (x *VirtualHost) GetRoutes() *v3.Matcher {
	if x != nil {
		return x.Routes
	}
	return nil
}

// The generic proxy makes use of the xDS matching API for routing configurations.
//
// In the below example, we combine a top level tree matcher with a linear matcher to match
// the incoming requests, and send the matching requests to v1 of the upstream service.
//
// .. code-block:: yaml
//
//	name: example
//	routes:
//	  matcher_tree:
//	    input:
//	      name: request-service
//	      typed_config:
//	        "@type": type.googleapis.com/envoy.extensions.filters.network.generic_proxy.matcher.v3.ServiceMatchInput
//	    exact_match_map:
//	      map:
//	        service_name_0:
//	          matcher:
//	            matcher_list:
//	              matchers:
//	              - predicate:
//	                  and_matcher:
//	                    predicate:
//	                    - single_predicate:
//	                        input:
//	                          name: request-properties
//	                          typed_config:
//	                            "@type": type.googleapis.com/envoy.extensions.filters.network.generic_proxy.matcher.v3.PropertyMatchInput
//	                            property_name: version
//	                        value_match:
//	                          exact: v1
//	                    - single_predicate:
//	                        input:
//	                          name: request-properties
//	                          typed_config:
//	                            "@type": type.googleapis.com/envoy.extensions.filters.network.generic_proxy.matcher.v3.PropertyMatchInput
//	                            property_name: user
//	                        value_match:
//	                          exact: john
//	                on_match:
//	                  action:
//	                    name: route
//	                    typed_config:
//	                      "@type": type.googleapis.com/envoy.extensions.filters.network.generic_proxy.action.v3.routeAction
//	                      cluster: cluster_0
type RouteConfiguration struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The name of the route configuration. For example, it might match route_config_name in
	// envoy.extensions.filters.network.generic_proxy.v3.Rds.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The match tree to use when resolving route actions for incoming requests.
	// If no any virtual host is configured in the “virtual_hosts“ field or no special wildcard
	// virtual host is configured, the “routes“ field will be used as the default route table.
	// If both the wildcard virtual host and “routes“ are configured, the configuration will fail
	// to load.
	Routes *v3.Matcher `protobuf:"bytes,2,opt,name=routes,proto3" json:"routes,omitempty"`
	// An array of virtual hosts that make up the route table.
	VirtualHosts  []*VirtualHost `protobuf:"bytes,3,rep,name=virtual_hosts,json=virtualHosts,proto3" json:"virtual_hosts,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*RouteConfiguration) ProtoMessage() {}

func (x *RouteConfiguration) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_extensions_filters_network_generic_proxy_v3_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 RouteConfiguration.ProtoReflect.Descriptor instead.
func (*RouteConfiguration) Descriptor() ([]byte, []int) {
	return file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescGZIP(), []int{1}
}

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

func (x *RouteConfiguration) GetRoutes() *v3.Matcher {
	if x != nil {
		return x.Routes
	}
	return nil
}

func (x *RouteConfiguration) GetVirtualHosts() []*VirtualHost {
	if x != nil {
		return x.VirtualHosts
	}
	return nil
}

var File_envoy_extensions_filters_network_generic_proxy_v3_route_proto protoreflect.FileDescriptor

const file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDesc = "" +
	"\n" +
	"=envoy/extensions/filters/network/generic_proxy/v3/route.proto\x121envoy.extensions.filters.network.generic_proxy.v3\x1a\x1fxds/annotations/v3/status.proto\x1a!xds/type/matcher/v3/matcher.proto\x1a\x1dudpa/annotations/status.proto\x1a\x17validate/validate.proto\"\x8a\x01\n" +
	"\vVirtualHost\x12\x1b\n" +
	"\x04name\x18\x01 \x01(\tB\a\xfaB\x04r\x02\x10\x01R\x04name\x12\x1e\n" +
	"\x05hosts\x18\x02 \x03(\tB\b\xfaB\x05\x92\x01\x02\b\x01R\x05hosts\x12>\n" +
	"\x06routes\x18\x03 \x01(\v2\x1c.xds.type.matcher.v3.MatcherB\b\xfaB\x05\x8a\x01\x02\x10\x01R\x06routes\"\xcc\x01\n" +
	"\x12RouteConfiguration\x12\x1b\n" +
	"\x04name\x18\x01 \x01(\tB\a\xfaB\x04r\x02\x10\x01R\x04name\x124\n" +
	"\x06routes\x18\x02 \x01(\v2\x1c.xds.type.matcher.v3.MatcherR\x06routes\x12c\n" +
	"\rvirtual_hosts\x18\x03 \x03(\v2>.envoy.extensions.filters.network.generic_proxy.v3.VirtualHostR\fvirtualHostsB\xc9\x01\xba\x80\xc8\xd1\x06\x02\x10\x02\xd2Ƥ\xe1\x06\x02\b\x01\n" +
	"?io.envoyproxy.envoy.extensions.filters.network.generic_proxy.v3B\n" +
	"RouteProtoP\x01Zhgithub.com/envoyproxy/go-control-plane/envoy/extensions/filters/network/generic_proxy/v3;generic_proxyv3b\x06proto3"

var (
	file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescOnce sync.Once
	file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescData []byte
)

func file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescGZIP() []byte {
	file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescOnce.Do(func() {
		file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDesc), len(file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDesc)))
	})
	return file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDescData
}

var file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_goTypes = []any{
	(*VirtualHost)(nil),        // 0: envoy.extensions.filters.network.generic_proxy.v3.VirtualHost
	(*RouteConfiguration)(nil), // 1: envoy.extensions.filters.network.generic_proxy.v3.RouteConfiguration
	(*v3.Matcher)(nil),         // 2: xds.type.matcher.v3.Matcher
}
var file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_depIdxs = []int32{
	2, // 0: envoy.extensions.filters.network.generic_proxy.v3.VirtualHost.routes:type_name -> xds.type.matcher.v3.Matcher
	2, // 1: envoy.extensions.filters.network.generic_proxy.v3.RouteConfiguration.routes:type_name -> xds.type.matcher.v3.Matcher
	0, // 2: envoy.extensions.filters.network.generic_proxy.v3.RouteConfiguration.virtual_hosts:type_name -> envoy.extensions.filters.network.generic_proxy.v3.VirtualHost
	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_extensions_filters_network_generic_proxy_v3_route_proto_init() }
func file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_init() {
	if File_envoy_extensions_filters_network_generic_proxy_v3_route_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_filters_network_generic_proxy_v3_route_proto_rawDesc), len(file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   2,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_goTypes,
		DependencyIndexes: file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_depIdxs,
		MessageInfos:      file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_msgTypes,
	}.Build()
	File_envoy_extensions_filters_network_generic_proxy_v3_route_proto = out.File
	file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_goTypes = nil
	file_envoy_extensions_filters_network_generic_proxy_v3_route_proto_depIdxs = nil
}
