Package io.grpc.xds
Class XdsListenerResource
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class io.grpc.xds.client.XdsResourceType
XdsResourceType.Args, XdsResourceType.ResourceInvalidException, XdsResourceType.StructOrError<T>
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final String
private static final FilterRegistry
private static final XdsListenerResource
private static final String
(package private) static final String
Fields inherited from class io.grpc.xds.client.XdsResourceType
HASH_POLICY_FILTER_STATE_KEY, TYPE_URL_CLUSTER_CONFIG, TYPE_URL_TYPED_STRUCT, TYPE_URL_TYPED_STRUCT_UDPA
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
checkForUniqueness
(Set<EnvoyServerProtoData.FilterChainMatch> uniqueSet, EnvoyServerProtoData.FilterChainMatch filterChainMatch) protected XdsListenerResource.LdsUpdate
doParse
(XdsResourceType.Args args, com.google.protobuf.Message unpackedMessage) private static List
<EnvoyServerProtoData.FilterChainMatch> private static List
<EnvoyServerProtoData.FilterChainMatch> expandOnPrefixRange
(EnvoyServerProtoData.FilterChainMatch filterChainMatch) private static List
<EnvoyServerProtoData.FilterChainMatch> private static List
<EnvoyServerProtoData.FilterChainMatch> private static List
<EnvoyServerProtoData.FilterChainMatch> protected String
extractResourceName
(com.google.protobuf.Message unpackedResource) Extract the resource name from an older resource type that included the name within the resource contents itself.private static List
<EnvoyServerProtoData.FilterChainMatch> getCrossProduct
(EnvoyServerProtoData.FilterChainMatch filterChainMatch) (package private) static XdsListenerResource
protected boolean
private static boolean
isTerminalFilter
(Filter.FilterConfig filterConfig) (package private) static EnvoyServerProtoData.FilterChain
parseFilterChain
(FilterChain proto, TlsContextManager tlsContextManager, FilterRegistry filterRegistry, Set<EnvoyServerProtoData.FilterChainMatch> uniqueSet, Set<String> certProviderInstances) private static EnvoyServerProtoData.FilterChainMatch
(package private) static HttpConnectionManager
parseHttpConnectionManager
(HttpConnectionManager proto, FilterRegistry filterRegistry, boolean isForClient) (package private) static XdsResourceType.StructOrError
<Filter.FilterConfig> parseHttpFilter
(HttpFilter httpFilter, FilterRegistry filterRegistry, boolean isForClient) (package private) static EnvoyServerProtoData.Listener
parseServerSideListener
(Listener proto, TlsContextManager tlsContextManager, FilterRegistry filterRegistry, Set<String> certProviderInstances) private XdsListenerResource.LdsUpdate
processClientSideListener
(Listener listener) private XdsListenerResource.LdsUpdate
processServerSideListener
(Listener proto, XdsResourceType.Args args) boolean
typeName()
typeUrl()
(package private) static DownstreamTlsContext
validateDownstreamTlsContext
(DownstreamTlsContext downstreamTlsContext, Set<String> certProviderInstances) Methods inherited from class io.grpc.xds.client.XdsResourceType
unpackCompatibleType
-
Field Details
-
ADS_TYPE_URL_LDS
- See Also:
-
TYPE_URL_HTTP_CONNECTION_MANAGER
- See Also:
-
TRANSPORT_SOCKET_NAME_TLS
- See Also:
-
instance
-
filterRegistry
-
-
Constructor Details
-
XdsListenerResource
XdsListenerResource()
-
-
Method Details
-
getInstance
-
extractResourceName
Description copied from class:XdsResourceType
Extract the resource name from an older resource type that included the name within the resource contents itself. The newer approach has resources wrapped withenvoy.service.discovery.v3.Resource
which then provides the name. This method is only called for the old approach.- Overrides:
extractResourceName
in classXdsResourceType<XdsListenerResource.LdsUpdate>
- Returns:
- the resource's name, or
null
if name is not stored within the resource contents
-
typeName
- Specified by:
typeName
in classXdsResourceType<XdsListenerResource.LdsUpdate>
-
unpackedClassName
- Specified by:
unpackedClassName
in classXdsResourceType<XdsListenerResource.LdsUpdate>
-
typeUrl
- Specified by:
typeUrl
in classXdsResourceType<XdsListenerResource.LdsUpdate>
-
shouldRetrieveResourceKeysForArgs
public boolean shouldRetrieveResourceKeysForArgs()- Specified by:
shouldRetrieveResourceKeysForArgs
in classXdsResourceType<XdsListenerResource.LdsUpdate>
-
isFullStateOfTheWorld
protected boolean isFullStateOfTheWorld()- Specified by:
isFullStateOfTheWorld
in classXdsResourceType<XdsListenerResource.LdsUpdate>
-
doParse
protected XdsListenerResource.LdsUpdate doParse(XdsResourceType.Args args, com.google.protobuf.Message unpackedMessage) throws XdsResourceType.ResourceInvalidException - Specified by:
doParse
in classXdsResourceType<XdsListenerResource.LdsUpdate>
- Throws:
XdsResourceType.ResourceInvalidException
-
processClientSideListener
private XdsListenerResource.LdsUpdate processClientSideListener(Listener listener) throws XdsResourceType.ResourceInvalidException -
processServerSideListener
private XdsListenerResource.LdsUpdate processServerSideListener(Listener proto, XdsResourceType.Args args) throws XdsResourceType.ResourceInvalidException -
parseServerSideListener
static EnvoyServerProtoData.Listener parseServerSideListener(Listener proto, TlsContextManager tlsContextManager, FilterRegistry filterRegistry, Set<String> certProviderInstances) throws XdsResourceType.ResourceInvalidException -
parseFilterChain
static EnvoyServerProtoData.FilterChain parseFilterChain(FilterChain proto, TlsContextManager tlsContextManager, FilterRegistry filterRegistry, Set<EnvoyServerProtoData.FilterChainMatch> uniqueSet, Set<String> certProviderInstances) throws XdsResourceType.ResourceInvalidException -
validateDownstreamTlsContext
static DownstreamTlsContext validateDownstreamTlsContext(DownstreamTlsContext downstreamTlsContext, Set<String> certProviderInstances) throws XdsResourceType.ResourceInvalidException -
checkForUniqueness
private static void checkForUniqueness(Set<EnvoyServerProtoData.FilterChainMatch> uniqueSet, EnvoyServerProtoData.FilterChainMatch filterChainMatch) throws XdsResourceType.ResourceInvalidException -
getCrossProduct
private static List<EnvoyServerProtoData.FilterChainMatch> getCrossProduct(EnvoyServerProtoData.FilterChainMatch filterChainMatch) -
expandOnPrefixRange
private static List<EnvoyServerProtoData.FilterChainMatch> expandOnPrefixRange(EnvoyServerProtoData.FilterChainMatch filterChainMatch) -
expandOnApplicationProtocols
private static List<EnvoyServerProtoData.FilterChainMatch> expandOnApplicationProtocols(Collection<EnvoyServerProtoData.FilterChainMatch> set) -
expandOnSourcePrefixRange
private static List<EnvoyServerProtoData.FilterChainMatch> expandOnSourcePrefixRange(Collection<EnvoyServerProtoData.FilterChainMatch> set) -
expandOnSourcePorts
private static List<EnvoyServerProtoData.FilterChainMatch> expandOnSourcePorts(Collection<EnvoyServerProtoData.FilterChainMatch> set) -
expandOnServerNames
private static List<EnvoyServerProtoData.FilterChainMatch> expandOnServerNames(Collection<EnvoyServerProtoData.FilterChainMatch> set) -
parseFilterChainMatch
private static EnvoyServerProtoData.FilterChainMatch parseFilterChainMatch(FilterChainMatch proto) throws XdsResourceType.ResourceInvalidException -
parseHttpConnectionManager
static HttpConnectionManager parseHttpConnectionManager(HttpConnectionManager proto, FilterRegistry filterRegistry, boolean isForClient) throws XdsResourceType.ResourceInvalidException -
isTerminalFilter
-
parseHttpFilter
@Nullable static XdsResourceType.StructOrError<Filter.FilterConfig> parseHttpFilter(HttpFilter httpFilter, FilterRegistry filterRegistry, boolean isForClient)
-