Interface ChannelProvider

  • All Superinterfaces:
    Comparable<ChannelProvider>

    public interface ChannelProvider
    extends Comparable<ChannelProvider>
    A provider of named gRPC Channel instances.

    Instances of this interface are loaded by the ServiceLoader when building gRPC channel instances to provide a Channel for a remote gRPC service. This allows application code to provide channels that require configuration not supported by the out-of-the-box Coherence configuration.

    Since:
    20.12
    Author:
    Jonathan Knight 2020.12.15
    • Method Detail

      • getChannel

        Optional<io.grpc.Channel> getChannel​(String sName)
        Return the Channel.
        Parameters:
        sName - the name of the channel to get
        Returns:
        the Channel
      • getPriority

        default int getPriority()
        Returns the priority for this provider.

        Sessions will be created in priority order, the highest priority first.

        The default priority is zero (see DEFAULT_PRIORITY.

        Returns:
        the priority for this provider