Package io.grpc.xds
Class XdsNameResolver.ResolveState.RouteDiscoveryState
java.lang.Object
io.grpc.xds.XdsNameResolver.ResolveState.RouteDiscoveryState
- All Implemented Interfaces:
XdsClient.ResourceWatcher<XdsRouteConfigureResource.RdsUpdate>
- Enclosing class:
XdsNameResolver.ResolveState
private class XdsNameResolver.ResolveState.RouteDiscoveryState
extends Object
implements XdsClient.ResourceWatcher<XdsRouteConfigureResource.RdsUpdate>
Discovery state for RouteConfiguration resource. One instance for each Listener resource
update.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final List<Filter.NamedFilterConfig> private final longprivate final String -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateRouteDiscoveryState(String resourceName, long httpMaxStreamDurationNano, List<Filter.NamedFilterConfig> filterConfigs) -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidonError(io.grpc.Status error) Called when the resource discovery RPC encounters some transient error.voidonResourceDoesNotExist(String resourceName) Called when the requested resource is not available.
-
Field Details
-
resourceName
-
httpMaxStreamDurationNano
private final long httpMaxStreamDurationNano -
filterConfigs
-
-
Constructor Details
-
RouteDiscoveryState
private RouteDiscoveryState(String resourceName, long httpMaxStreamDurationNano, @Nullable List<Filter.NamedFilterConfig> filterConfigs)
-
-
Method Details
-
onChanged
- Specified by:
onChangedin interfaceXdsClient.ResourceWatcher<XdsRouteConfigureResource.RdsUpdate>
-
onError
public void onError(io.grpc.Status error) Description copied from interface:XdsClient.ResourceWatcherCalled when the resource discovery RPC encounters some transient error.Note that we expect that the implementer to: - Comply with the guarantee to not generate certain statuses by the library: https://grpc.github.io/grpc/core/md_doc_statuscodes.html. If the code needs to be propagated to the channel, override it with
Status.Code.UNAVAILABLE. - KeepStatusdescription in one form or another, as it contains valuable debugging information.- Specified by:
onErrorin interfaceXdsClient.ResourceWatcher<XdsRouteConfigureResource.RdsUpdate>
-
onResourceDoesNotExist
Description copied from interface:XdsClient.ResourceWatcherCalled when the requested resource is not available.- Specified by:
onResourceDoesNotExistin interfaceXdsClient.ResourceWatcher<XdsRouteConfigureResource.RdsUpdate>- Parameters:
resourceName- name of the resource requested in discovery request.
-