Class LoadReportClient


  • @Internal
    public final class LoadReportClient
    extends java.lang.Object
    Client of xDS load reporting service based on LRS protocol, which reports load stats of gRPC client's perspective to a management server.
    • Field Detail

      • logId

        private final io.grpc.InternalLogId logId
      • syncContext

        private final io.grpc.SynchronizationContext syncContext
      • timerService

        private final java.util.concurrent.ScheduledExecutorService timerService
      • retryStopwatch

        private final com.google.common.base.Stopwatch retryStopwatch
      • backoffPolicyProvider

        private final io.grpc.internal.BackoffPolicy.Provider backoffPolicyProvider
      • started

        private boolean started
      • lrsRpcRetryPolicy

        @Nullable
        private io.grpc.internal.BackoffPolicy lrsRpcRetryPolicy
      • lrsRpcRetryTimer

        @Nullable
        private io.grpc.SynchronizationContext.ScheduledHandle lrsRpcRetryTimer
    • Constructor Detail

      • LoadReportClient

        public LoadReportClient​(LoadStatsManager2 loadStatsManager,
                                XdsTransportFactory.XdsTransport xdsTransport,
                                EnvoyProtoData.Node node,
                                io.grpc.SynchronizationContext syncContext,
                                java.util.concurrent.ScheduledExecutorService scheduledExecutorService,
                                io.grpc.internal.BackoffPolicy.Provider backoffPolicyProvider,
                                com.google.common.base.Supplier<com.google.common.base.Stopwatch> stopwatchSupplier)
    • Method Detail

      • lrsStreamIsNull

        public boolean lrsStreamIsNull()
      • startLoadReporting

        public void startLoadReporting()
        Establishes load reporting communication and negotiates with traffic director to report load stats periodically. Calling this method on an already started LoadReportClient is no-op.
      • stopLoadReporting

        public void stopLoadReporting()
        Terminates load reporting. Calling this method on an already stopped LoadReportClient is no-op.
      • startLrsRpc

        private void startLrsRpc()