/** * Construct an implementation of {@link HystrixMetricsPublisherThreadPool} for {@link HystrixThreadPool} instances having key {@link HystrixThreadPoolKey}. * <p> * This will be invoked once per {@link HystrixThreadPoolKey} instance. * <p> * <b>Default Implementation</b> * <p> * Return instance of {@link HystrixMetricsPublisherThreadPoolDefault} * * @param threadPoolKey * {@link HystrixThreadPoolKey} representing the name or type of {@link HystrixThreadPool} * @param metrics * {@link HystrixThreadPoolMetrics} instance tracking metrics for the {@link HystrixThreadPool} instance having the key as defined by {@link HystrixThreadPoolKey} * @param properties * {@link HystrixThreadPoolProperties} instance for the {@link HystrixThreadPool} instance having the key as defined by {@link HystrixThreadPoolKey} * @return instance of {@link HystrixMetricsPublisherThreadPool} that will have its <code>initialize</code> method invoked once. */ public HystrixMetricsPublisherThreadPool getMetricsPublisherForThreadPool(HystrixThreadPoolKey threadPoolKey, HystrixThreadPoolMetrics metrics, HystrixThreadPoolProperties properties) { return new HystrixMetricsPublisherThreadPoolDefault(threadPoolKey, metrics, properties); }
/** * Construct an implementation of {@link HystrixMetricsPublisherThreadPool} for {@link HystrixThreadPool} instances having key {@link HystrixThreadPoolKey}. * <p> * This will be invoked once per {@link HystrixThreadPoolKey} instance. * <p> * <b>Default Implementation</b> * <p> * Return instance of {@link HystrixMetricsPublisherThreadPoolDefault} * * @param threadPoolKey * {@link HystrixThreadPoolKey} representing the name or type of {@link HystrixThreadPool} * @param metrics * {@link HystrixThreadPoolMetrics} instance tracking metrics for the {@link HystrixThreadPool} instance having the key as defined by {@link HystrixThreadPoolKey} * @param properties * {@link HystrixThreadPoolProperties} instance for the {@link HystrixThreadPool} instance having the key as defined by {@link HystrixThreadPoolKey} * @return instance of {@link HystrixMetricsPublisherThreadPool} that will have its <code>initialize</code> method invoked once. */ public HystrixMetricsPublisherThreadPool getMetricsPublisherForThreadPool(HystrixThreadPoolKey threadPoolKey, HystrixThreadPoolMetrics metrics, HystrixThreadPoolProperties properties) { return new HystrixMetricsPublisherThreadPoolDefault(threadPoolKey, metrics, properties); }