Search in sources :

Example 6 with ClusterDropStats

use of io.grpc.xds.LoadStatsManager2.ClusterDropStats in project grpc-java by grpc.

the class ClientXdsClient method addClusterDropStats.

@Override
ClusterDropStats addClusterDropStats(final ServerInfo serverInfo, String clusterName, @Nullable String edsServiceName) {
    ClusterDropStats dropCounter = loadStatsManager.getClusterDropStats(clusterName, edsServiceName);
    syncContext.execute(new Runnable() {

        @Override
        public void run() {
            if (!reportingLoad) {
                serverLrsClientMap.get(serverInfo).startLoadReporting();
                reportingLoad = true;
            }
        }
    });
    return dropCounter;
}
Also used : ClusterDropStats(io.grpc.xds.LoadStatsManager2.ClusterDropStats)

Aggregations

ClusterDropStats (io.grpc.xds.LoadStatsManager2.ClusterDropStats)6 Test (org.junit.Test)4 ClusterStats (io.grpc.xds.Stats.ClusterStats)3 ClusterLocalityStats (io.grpc.xds.LoadStatsManager2.ClusterLocalityStats)2 UpstreamLocalityStats (io.grpc.xds.Stats.UpstreamLocalityStats)1