21 package com.griddynamics.jagger.invoker;
23 import org.slf4j.Logger;
24 import org.slf4j.LoggerFactory;
29 public abstract class PairSupplierFactoryLoadBalancer<Q, E>
extends QueryPoolLoadBalancer<Q, E> {
31 private final static Logger log = LoggerFactory.getLogger(PairSupplierFactoryLoadBalancer.class);
32 private final PairSupplierFactory<Q, E> pairSupplierFactory;
33 private volatile PairSupplier<Q, E> pairSupplier;
36 this.pairSupplierFactory = pairSupplierFactory;
47 log.debug(
"already initialized. returning...");
52 pairSupplier = pairSupplierFactory.create(queryProvider, endpointProvider);
53 log.info(
"{} pairs in total to balance", pairSupplier.size());