public IHystrixCommandProperties GetCommandProperties(HystrixCommandKey commandKey, HystrixCommandPropertiesSetter setter) { if (setter == null) { setter = UnitTestSetterFactory.GetCommandPropertiesSetter(); } return new MockingHystrixCommandProperties(setter); }
internal HystrixCommandMetrics(HystrixCommandKey key, HystrixCommandGroupKey commandGroup, IHystrixCommandProperties properties, IHystrixEventNotifier eventNotifier) { this.key = key; this.group = commandGroup; this.properties = properties; this.counter = new HystrixRollingNumber(properties.MetricsRollingStatisticalWindowInMilliseconds, properties.MetricsRollingStatisticalWindowBuckets); this.percentileExecution = new HystrixRollingPercentile(properties.MetricsRollingPercentileWindowInMilliseconds, properties.MetricsRollingPercentileWindowBuckets, properties.MetricsRollingPercentileBucketSize, properties.MetricsRollingPercentileEnabled); this.percentileTotal = new HystrixRollingPercentile(properties.MetricsRollingPercentileWindowInMilliseconds, properties.MetricsRollingPercentileWindowBuckets, properties.MetricsRollingPercentileBucketSize, properties.MetricsRollingPercentileEnabled); this.eventNotifier = eventNotifier; }
public RequestCacheKey(HystrixCommandKey commandKey, IHystrixConcurrencyStrategy concurrencyStrategy) { type = 1; if (commandKey == null) { this.key = null; } else { this.key = commandKey.Name; } this.concurrencyStrategy = concurrencyStrategy; }
public RequestCacheKey(HystrixCommandKey commandKey, IHystrixConcurrencyStrategy concurrencyStrategy) { type = 1; if (commandKey == null) { this.key = null; } else { this.key = commandKey.Name; } this.concurrencyStrategy = concurrencyStrategy; }
private static IHystrixCircuitBreaker GetCircuitBreaker(HystrixCommandKey key, HystrixCommandGroupKey commandGroup, HystrixCommandMetrics metrics, HystrixCommandPropertiesSetter properties) { return new HystrixCircuitBreakerImpl(new MockingHystrixCommandProperties(properties), metrics); }
public static HystrixCommandMetrics GetInstance(HystrixCommandKey key) { return(metrics[key.Name]); }
public static HystrixCommandMetrics GetInstance(HystrixCommandKey key, HystrixCommandGroupKey commandGroup, IHystrixCommandProperties properties) { return(metrics.GetOrAdd(key.Name, w => new HystrixCommandMetrics(key, commandGroup, properties, HystrixPlugins.Instance.EventNotifier))); }
public IHystrixMetricsPublisherCommand GetMetricsPublisherForCommand(HystrixCommandKey commandKey, HystrixCommandGroupKey commandGroupKey, HystrixCommandMetrics metrics, IHystrixCircuitBreaker circuitBreaker, IHystrixCommandProperties properties) { return new HystrixServoMetricsPublisherCommand(commandKey, commandGroupKey, metrics, circuitBreaker, properties); }
public HystrixCommandSetter AndCommandKey(HystrixCommandKey commandKey) { CommandKey = commandKey; return(this); }
public string GetCommandPropertiesCacheKey(HystrixCommandKey commandKey, HystrixCommandPropertiesSetter setter) { return null; }
public static HystrixRequestCache GetInstance(HystrixCommandKey key, IHystrixConcurrencyStrategy concurrencyStrategy) { return(GetInstance(new RequestCacheKey(key, concurrencyStrategy), concurrencyStrategy)); }
public HystrixCommandSetter AndCommandKey(HystrixCommandKey commandKey) { CommandKey = commandKey; return this; }