Top Description Inners Fields Constructors Methods
io.grpc

public abstract Class InternalConfigSelector

extends Object
Class Inheritance
Annotations
@Internal
Static Imports
com.google.common.base.Preconditions.checkArgument, .Preconditions.checkNotNull, .Preconditions.checkState

Per method config selector that the channel or load balancers will use to choose the appropriate config or take config related actions for an RPC.

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
public static final Attributes.Key<InternalConfigSelector>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public abstract InternalConfigSelector.Result
selectConfig(LoadBalancer.PickSubchannelArgs args)

Selects the config for an PRC.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

KEYback to summary
public static final Attributes.Key<InternalConfigSelector> KEY
Annotations
@ResolutionResultAttr

Constructor Detail

InternalConfigSelectorback to summary
public InternalConfigSelector()

Method Detail

selectConfigback to summary
public abstract InternalConfigSelector.Result selectConfig(LoadBalancer.PickSubchannelArgs args)

Selects the config for an PRC.

io.grpc back to summary

public final Class InternalConfigSelector.Result

extends Object
Class Inheritance

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
private final Object
public ClientInterceptor
private final Status

Constructor Summary

AccessConstructor and Description
private
Result(Status status, Object config, ClientInterceptor interceptor)

Method Summary

Modifier and TypeMethod and Description
public static InternalConfigSelector.Result
forError(Status status)

Creates a Result with the given error status.

public Object
getConfig()

Returns a parsed config.

public ClientInterceptor
getInterceptor()

Returns an interceptor that will be applies to calls.

public Status
getStatus()

Returns the status of the config selection operation.

public static InternalConfigSelector.Result.Builder
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

configback to summary
private final Object config
interceptorback to summary
public ClientInterceptor interceptor
Annotations
@Nullable
statusback to summary
private final Status status

Constructor Detail

Resultback to summary
private Result(Status status, Object config, ClientInterceptor interceptor)

Method Detail

forErrorback to summary
public static InternalConfigSelector.Result forError(Status status)

Creates a Result with the given error status.

getConfigback to summary
public Object getConfig()

Returns a parsed config. Must have been returned via ServiceConfigParser.parseServiceConfig().getConfig()

getInterceptorback to summary
public ClientInterceptor getInterceptor()

Returns an interceptor that will be applies to calls.

Annotations
@Nullable
getStatusback to summary
public Status getStatus()

Returns the status of the config selection operation. If status is not Status#OK, this result should not be used.

newBuilderback to summary
public static InternalConfigSelector.Result.Builder newBuilder()
io.grpc back to summary

public final Class InternalConfigSelector.Result.Builder

extends Object
Class Inheritance

Field Summary

Modifier and TypeField and Description
private Object
private ClientInterceptor

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public InternalConfigSelector.Result
build()

Build this Result.

public InternalConfigSelector.Result.Builder

Returns:

this
setConfig
(Object config)

Sets the parsed config.

public InternalConfigSelector.Result.Builder

Returns:

this
setInterceptor
(ClientInterceptor interceptor)

Sets the interceptor.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

configback to summary
private Object config
interceptorback to summary
private ClientInterceptor interceptor

Constructor Detail

Builderback to summary
private Builder()

Method Detail

buildback to summary
public InternalConfigSelector.Result build()

Build this Result.

setConfigback to summary
public InternalConfigSelector.Result.Builder setConfig(Object config)

Sets the parsed config. This field is required.

Returns:InternalConfigSelector.Result.Builder

this

setInterceptorback to summary
public InternalConfigSelector.Result.Builder setInterceptor(ClientInterceptor interceptor)

Sets the interceptor. This field is optional.

Returns:InternalConfigSelector.Result.Builder

this